CN115048915A - Data processing method and system of electric power file based on operation platform - Google Patents
Data processing method and system of electric power file based on operation platform Download PDFInfo
- Publication number
- CN115048915A CN115048915A CN202210985917.6A CN202210985917A CN115048915A CN 115048915 A CN115048915 A CN 115048915A CN 202210985917 A CN202210985917 A CN 202210985917A CN 115048915 A CN115048915 A CN 115048915A
- Authority
- CN
- China
- Prior art keywords
- region
- image
- new image
- pixel value
- file
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Granted
Links
- 238000003672 processing method Methods 0.000 title claims abstract description 24
- 238000012545 processing Methods 0.000 claims abstract description 38
- 238000012790 confirmation Methods 0.000 claims abstract description 15
- 238000000034 method Methods 0.000 claims abstract description 14
- 238000005192 partition Methods 0.000 claims abstract description 6
- 230000009467 reduction Effects 0.000 claims description 81
- 230000008859 change Effects 0.000 claims description 25
- 230000004927 fusion Effects 0.000 claims description 24
- 230000000007 visual effect Effects 0.000 claims description 11
- 230000003321 amplification Effects 0.000 claims description 9
- 238000012986 modification Methods 0.000 claims description 9
- 230000004048 modification Effects 0.000 claims description 9
- 238000003199 nucleic acid amplification method Methods 0.000 claims description 9
- 230000001788 irregular Effects 0.000 claims description 7
- 230000001360 synchronised effect Effects 0.000 claims description 6
- 238000004458 analytical method Methods 0.000 claims description 3
- 238000000605 extraction Methods 0.000 claims description 3
- 238000010586 diagram Methods 0.000 description 8
- 230000008569 process Effects 0.000 description 4
- 238000011946 reduction process Methods 0.000 description 4
- 238000011161 development Methods 0.000 description 3
- 239000003086 colorant Substances 0.000 description 2
- 230000003247 decreasing effect Effects 0.000 description 2
- 239000004973 liquid crystal related substance Substances 0.000 description 2
- 230000009286 beneficial effect Effects 0.000 description 1
- 230000007547 defect Effects 0.000 description 1
- 239000000284 extract Substances 0.000 description 1
- 238000011835 investigation Methods 0.000 description 1
- 238000000638 solvent extraction Methods 0.000 description 1
- 238000006467 substitution reaction Methods 0.000 description 1
- 230000009466 transformation Effects 0.000 description 1
- 238000000844 transformation Methods 0.000 description 1
Images
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F40/00—Handling natural language data
- G06F40/10—Text processing
- G06F40/166—Editing, e.g. inserting or deleting
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F40/00—Handling natural language data
- G06F40/10—Text processing
- G06F40/103—Formatting, i.e. changing of presentation of documents
- G06F40/106—Display of layout of documents; Previewing
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F40/00—Handling natural language data
- G06F40/10—Text processing
- G06F40/103—Formatting, i.e. changing of presentation of documents
- G06F40/109—Font handling; Temporal or kinetic typography
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T3/00—Geometric image transformations in the plane of the image
- G06T3/40—Scaling of whole images or parts thereof, e.g. expanding or contracting
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06V—IMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
- G06V30/00—Character recognition; Recognising digital ink; Document-oriented image-based pattern recognition
- G06V30/40—Document-oriented image-based pattern recognition
- G06V30/41—Analysis of document content
- G06V30/418—Document matching, e.g. of document images
-
- Y—GENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
- Y04—INFORMATION OR COMMUNICATION TECHNOLOGIES HAVING AN IMPACT ON OTHER TECHNOLOGY AREAS
- Y04S—SYSTEMS INTEGRATING TECHNOLOGIES RELATED TO POWER NETWORK OPERATION, COMMUNICATION OR INFORMATION TECHNOLOGIES FOR IMPROVING THE ELECTRICAL POWER GENERATION, TRANSMISSION, DISTRIBUTION, MANAGEMENT OR USAGE, i.e. SMART GRIDS
- Y04S10/00—Systems supporting electrical power generation, transmission or distribution
- Y04S10/50—Systems or methods supporting the power network operation or management, involving a certain degree of interaction with the load-side end user applications
Landscapes
- Engineering & Computer Science (AREA)
- Theoretical Computer Science (AREA)
- General Physics & Mathematics (AREA)
- Physics & Mathematics (AREA)
- Artificial Intelligence (AREA)
- Audiology, Speech & Language Pathology (AREA)
- Health & Medical Sciences (AREA)
- Computational Linguistics (AREA)
- General Health & Medical Sciences (AREA)
- General Engineering & Computer Science (AREA)
- Computer Vision & Pattern Recognition (AREA)
- Multimedia (AREA)
- Supply And Distribution Of Alternating Current (AREA)
- Editing Of Facsimile Originals (AREA)
Abstract
The invention discloses a data processing method and a data processing system of an electric power file based on an operation platform, wherein the data processing method comprises the following steps: analyzing the online power report to obtain at least one file subregion of the online power report; extracting editable content in the file sub-region; editing and modifying the editable content through an editing device based on rich text editing software to obtain modified content, and adjusting the modified content according to the plate-type specification of the file sub-region and/or the content format of the adjacent file sub-region to obtain adjusted content; the method comprises the steps that partition processing is conducted on a display area based on a preset proportion to obtain a first display area and a second display area, adjusted contents are displayed through the first display area after being synchronously modified in a power report, and edited file sub-areas are displayed through the second display area; and after first confirmation information input by a user is received, taking the modified online power report as a final online power report.
Description
Technical Field
The invention relates to the technical field of data processing, in particular to a data processing method and system of an electric power file based on an operation platform.
Background
With the rapid development of modern power enterprises, a large number of power reports need to be made to show development conditions, generally speaking, the power reports have text display areas and picture display areas, and users can visually display power development data.
In the prior art, the prepared power report can be uploaded to a server, a user can check the power report in a webpage mode, and when the user needs to modify the power investigation report, the user can insert contents according to personal habits, so that newly inserted data can be different from an original data format, and the modified power report is relatively disordered.
Therefore, it is a problem that needs to be solved urgently how to make the inserted data conform to the plate-type requirement of the power report by adaptively adjusting the format and the content after the power report is edited by the user.
Disclosure of Invention
The invention overcomes the defects of the prior art and provides a data processing method and a data processing system of an electric power file based on an operation platform, which can adaptively adjust the format and the content after a user edits an online electric power report, so that the inserted data meets the plate-type requirements of the electric power report.
In order to solve the technical problems, the technical scheme of the invention is as follows:
the embodiment of the invention provides a data processing method of an electric power file based on an operation platform, wherein a management cockpit comprises a display device and an editing device, the display device comprises a display area and an editable area, and the electric power report is visually edited by the following steps of:
s1, displaying the corresponding online power report in a display device according to the selection of a user, and analyzing the online power report to obtain at least one file sub-region of the online power report;
s2, determining a file sub-area selected by a user, extracting editable contents in the file sub-area, and establishing a rich text editing area in the editable area;
s3, editing and modifying the editable content through an editing device based on rich text editing software to obtain modified content, and adjusting the modified content according to the plate type specification of the file sub-region and/or the content format of the adjacent file sub-region to obtain adjusted content;
s4, performing partition processing on the display area based on a preset proportion to obtain a first display area and a second display area, displaying the adjusted content in the online power report after synchronous modification through the first display area, and displaying the edited file sub-area through the second display area;
and S5, after receiving the first confirmation information input by the user, taking the modified online power report as a final online power report, and finishing the visual editing of the power report.
Further, the S1 includes:
acquiring an initial template corresponding to the online power report, wherein the initial template comprises at least one initial area, and the initial area comprises any one or more of a text editing area or a picture editing area;
analyzing the online power report based on the corresponding relation between the initial template and the initial area to obtain a file sub-area corresponding to the initial area;
determining a contour pixel point of each file subregion, and calculating according to a first pixel value of the contour pixel point and a second pixel value of an adjacent pixel point of the contour pixel point to obtain a third pixel value for displaying;
and controlling the contour pixel points of each file sub-region to be displayed according to the third pixel value.
Further, the determining of the contour pixel point of each file subregion calculates according to the first pixel value of the contour pixel point and the second pixel value of the adjacent pixel point of the contour pixel point to obtain a third pixel value for displaying, and includes:
if the absolute value of the difference value between the first pixel value and the second pixel value is judged to be larger than or equal to a preset pixel value, taking the first pixel value as a third pixel value for displaying;
if the absolute value of the difference value between the first pixel value and the second pixel value is smaller than a preset pixel value, determining the change trend of the pixel values of the contour pixel points according to the second pixel value;
if the change trend is an increasing trend, adding a preset pixel value to the first pixel value to obtain a third pixel value;
if the change trend is a reduction trend, subtracting a preset pixel value from the first pixel value to obtain a third pixel value;
and taking the calculated third pixel value as a third pixel value for displaying in place of the previous first pixel value.
Further, if it is determined that the absolute value of the difference between the first pixel value and the second pixel value is smaller than a preset pixel value, determining a variation trend of the pixel values of the contour pixel points according to the second pixel value, including:
if the second pixel value is smaller than or equal to a preset pixel value, determining the change trend of the pixel values of the contour pixel points to be an increasing trend;
and if the second pixel value is larger than the preset pixel value, determining the change trend of the pixel values of the contour pixel points to be a reduction trend.
Further, the method also comprises the following steps:
counting the number of pixels of a third pixel value which is the same as the first pixel value to obtain a first number, and counting the number of pixels of a third pixel value which is different from the first pixel value to obtain a second number;
obtaining a pixel value change ratio according to the first quantity and the second quantity, and selecting a first preset pixel value and a second preset pixel value if the pixel value change ratio is greater than a preset ratio;
and controlling the contour pixel points to alternately display preset time periods according to the first preset pixel value and the second preset pixel value respectively.
Further, the S3 includes:
if the initial area is a picture editing area, deleting a history image in the editable content according to user operation, and adding a new image;
acquiring plate type specifications of file subregions, wherein the plate type specifications comprise shape specifications and/or size specifications;
if the image shape of the new image is judged to be different from the shape specification of the file subregion, acquiring the content format of other file subregions adjacent to the file subregion to obtain a reference shape specification, wherein the reference shape specification is one of an adjusted shape or an unadjusted shape;
if the reference shape specification is the adjusted shape, displaying a new image according to the shape specification of the file sub-region, fusing the new image with the file sub-region, fusing the displayed new image and the file sub-region into the same shape, and obtaining the adjusted content of the image;
and if the reference shape specification is the irregular shape, adjusting the image size of the new image according to the size specification of the file sub-region, fusing the new image and the file sub-region, wherein the new image and the file sub-region have different shapes at the moment, and obtaining the adjusted content of the image.
Further, if the reference shape specification is an adjusted shape, displaying a new image according to the shape specification of the file sub-region, and fusing the new image with the file sub-region, so that the displayed new image and the file sub-region are fused into the same shape, including:
selecting an image center point of the new image and selecting a region center point of the file sub-region;
based on the image central point and the area central point, overlapping the new image and the file sub-area to obtain a fusion central point, and establishing a coordinate system according to the fusion central point;
acquiring an image coordinate value of each image pixel point in a new image and a region coordinate value of each region pixel point in a file sub-region;
and comparing the image coordinate values with the region coordinate values, adjusting the image size of the new image to obtain a first target size, and fusing the new image of the first target size with the file subregion according to the fusion central point to fuse the displayed new image and the file subregion into the same shape.
Further, the comparing the image coordinate value with the area coordinate value, adjusting the image size of the new image to obtain the first target size, and fusing the new image of the first target size with the file sub-area according to the fusion center point, so that the displayed new image and the file sub-area are fused into the same shape, including:
if the coordinates of the image coordinate values do not completely comprise the coordinates of the area coordinate values, acquiring all the coordinates which do not completely comprise the area coordinate values to obtain a first coordinate quantity, and determining a first magnification factor of the new image according to the first coordinate quantity;
amplifying the new image according to the first amplification factor, and extracting the image coordinate value of each image pixel point in the amplified new image;
and comparing the coordinate values of the amplified image with the coordinate values of the region again, and if the coordinate values of the image coordinate values of the amplified new image completely comprise the coordinate values of the region coordinate values, not amplifying the new image any more and taking the size of the new image at the moment as the first target size.
Further, if it is determined that the coordinates of the image coordinate values do not completely include the coordinates of the area coordinate values, acquiring all the coordinates that do not completely include the area coordinate values to obtain a first coordinate number, and determining a first magnification factor of the new image according to the first coordinate number, including:
acquiring a first total number of pixel points in a file subregion;
calculating a first magnification factor of the new image according to the first coordinate quantity, the first total quantity and the magnification weight value, calculating the first magnification factor by the following formula,
wherein,is the first magnification factor and is the second magnification factor,in order to be the first number of coordinates,in the first total number, the number of the first,to amplify the weight value.
Further, the comparing the image coordinate value with the area coordinate value, adjusting the image size of the new image to obtain the first target size, and fusing the new image of the first target size with the file sub-area according to the fusion center point, so that the displayed new image and the file sub-area are fused into the same shape, including:
if the coordinates of the image coordinate values completely comprise the coordinates of the area coordinate values, acquiring all the image coordinate values which do not completely comprise the area coordinate values in the image coordinate values to obtain a second coordinate number, and determining a first reduction multiple of the new image according to the second coordinate number;
reducing the new image according to the first reduction multiple, and extracting the image coordinate value of each image pixel point in the new image after reduction;
comparing the reduced image coordinate values with the region coordinate values again, if the coordinates of the image coordinate values of the reduced new image completely comprise the coordinates of the region coordinate values, obtaining all image coordinate values which do not correspond to the coordinates completely comprising the region coordinate values in the image coordinate values again to obtain a third coordinate number, and determining a second reduction multiple of the new image according to the third coordinate number;
and continuously comparing the image coordinate values after the reduction processing with the region coordinate values until the coordinates of the image coordinate values of the new image after the reduction processing do not completely include the coordinates of the region coordinate values, and taking the image size of the new image before the reduction as the first target size.
Further, if it is determined that the coordinates of the image coordinate values completely include the coordinates of the area coordinate values, acquiring all image coordinate values in the image coordinate values that do not correspond to the coordinates that completely include the area coordinate values, obtaining a second coordinate number, and determining a first reduction multiple of the new image according to the second coordinate number, including:
acquiring a second total number of image pixel points in the new image;
calculating according to the second coordinate number, the second total number and the reduction weight value to obtain a first reduction multiple of the new image, calculating the first reduction multiple by the following formula,
wherein,is the first reduction multiple of the first size,in order to be the second number of coordinates,in order to be the second total number,to reduce the weight value.
Further, if the reference shape specification is an irregular shape, adjusting the image size of the new image according to the size specification of the file sub-region, fusing the new image and the file sub-region, and obtaining the adjusted content of the image, where the new image and the file sub-region have different shapes, includes:
selecting an image center point of a new image and selecting an area center point of a file sub-area;
based on the image central point and the area central point, overlapping the new image and the file sub-area to obtain a fusion central point;
if the size of the new image is smaller than the size of the file sub-region in all dimensions, fusing the new image and the file sub-region;
if the size of the new image is larger than the size of the file sub-region in any dimension, obtaining a second reduction multiple according to the difference value between the size of the new image and the size of the file sub-region, calculating a third reduction multiple through the following formula,
wherein,is the third reduction multiple of the first reduction factor,for the size of the new image to be,is the size of a sub-area of the file,to reduce the coefficient value;
and after the new image is reduced based on the reduction multiple, fusing the reduced new image with the file sub-region.
Further, if the size of the new image is smaller than the size of the file sub-region in all dimensions, respectively, fusing the new image and the file sub-region, including:
if the size of the new image is smaller than the size of the file sub-region in all dimensions respectively, outputting first feedback information;
if second confirmation information of the user is received, fusing the new image and the file sub-region;
and if a second magnification factor of the user is received, amplifying the new image according to the second magnification factor, and fusing the new image and the file sub-region when the size of the amplified new image is judged to be smaller than that of the file sub-region in all dimensions.
Further, the S3 includes:
if the initial area is a character editing area, deleting the historical characters in the editable content according to the user operation, and adding new characters to obtain the modified content;
acquiring a content format of a sub-region of an adjacent file, and taking a corresponding character size and a character style in the content format as a reference character size and a reference character style;
and adjusting the new characters in the modified content according to the size of the reference characters and the reference character style to obtain the adjusted content of the characters.
The embodiment of the invention provides a data processing system of an electric power file based on an operation platform, which comprises a display device and an editing device, wherein the display device comprises a display area and an editable area, and the electric power report is visually edited through the following modules, wherein the data processing system comprises:
the analysis module is used for displaying the corresponding online power report in the display equipment according to the selection of the user, and analyzing the online power report to obtain at least one file subregion of the online power report;
the extraction module is used for determining a file sub-region selected by a user, extracting editable contents in the file sub-region and establishing a rich text editing region in the editable region;
the modification module is used for editing and modifying the editable content through an editing device based on rich text editing software to obtain modified content, and adjusting the modified content according to the plate type specification of the file sub-area and/or the content format of the adjacent file sub-area to obtain adjusted content;
the processing module is used for carrying out partition processing on the display area based on a preset proportion to obtain a first display area and a second display area, displaying the adjusted content in the online power report after synchronous modification through the first display area, and displaying the edited file sub-area through the second display area;
and the confirmation module is used for taking the modified online power report as a final online power report after receiving the first confirmation information input by the user, and finishing the visual editing of the power report.
The invention has the beneficial effects that:
(1) in the process of editing the online power report, the online power report is analyzed to obtain a plurality of file sub-regions which can be edited by users, and then the contents in the file sub-regions are edited by an editing device to obtain edited contents; in order to enable the content to conform to the plate-type specification of the file sub-area of the online power report and/or the content format of the adjacent file sub-area, the inserted content can be adjusted differently according to different conditions, so that the plate-type specification of the adjusted content file sub-area and/or the content format of the adjacent file sub-area correspond to each other, and the consistency of the online power report during viewing is ensured;
(2) after the online power report is analyzed, in order to improve the contrast of the contour, the third pixel value for displaying is obtained by calculating based on the first pixel value of the contour pixel point and the second pixel value of the adjacent pixel point of the contour pixel point, and the contour is made to be clear by the third pixel value. In addition, the scheme considers that after the display color of the outline is adjusted, the outline can be displayed in a plurality of gray value types, the editing of a user can be influenced, and the alternate display of the outline pixel points can be controlled according to the first preset pixel value and the second preset pixel value under a certain condition, so that the outline can be displayed to the user more intuitively;
(3) in order to enable the added new image to be matched with the file sub-region, the method is divided into two conditions, wherein one condition is that the shape of the new image needs to be adjusted, and the other condition is that the shape of the new image does not need to be adjusted; aiming at the condition that the shape of a new image needs to be adjusted, the scheme also provides a new image amplifying and reducing scheme, wherein the amplifying times and the reducing times are calculated for the server to automatically amplify or reduce for multiple times, and the distortion rate of the new image is minimized under the condition that the size of the new image is most suitable; in addition, the scheme is different from the embodiment needing to adjust the shape aiming at the embodiment without adjusting the shape, the shape is adjusted by changing the shape of a new image, and therefore the server needs to be used for carrying out point-by-point adjustment to achieve the required accurate new image; aiming at the embodiment without adjusting the shape, the required new image can be realized by artificial intervention adjustment without little adjustment of the server, so that the data processing amount of the server is reduced.
Drawings
In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the drawings needed to be used in the description of the embodiments will be briefly introduced below, and it is obvious that the drawings in the following description are only some embodiments of the present invention, and it is obvious for those skilled in the art to obtain other drawings based on these drawings without inventive exercise.
FIG. 1 is a schematic diagram of a scenario provided by the present invention;
FIG. 2 is a schematic diagram of a data processing method for an operating platform-based power file;
FIG. 3 is a diagram illustrating a first new image and a file sub-region provided in the present invention;
FIG. 4 is a diagram illustrating a second new image and a file sub-region provided in the present invention;
FIG. 5 is a diagram illustrating a third new image and a file sub-region provided in the present invention;
FIG. 6 is a diagram illustrating a fourth new image and a file sub-region provided by the present invention;
FIG. 7 is a diagram illustrating a fifth new image and a file sub-region provided in the present invention;
FIG. 8 is a schematic diagram of a data processing system based on an operating platform power file.
Detailed Description
In order that the present invention may be more readily and clearly understood, a more particular description of the invention briefly described above will be rendered by reference to specific embodiments that are illustrated in the appended drawings.
Referring to fig. 1, which is a schematic view of a scene provided in an embodiment of the present invention, a display device 1 may be a liquid crystal display, and specifically may be a large-sized liquid crystal display, where the display device 1 includes a display area and an editable area, it can be understood that the display area is used for displaying an online power report, and the editable area is used for a user to edit the online power report based on an editing apparatus; the editing apparatus 2 may be a device for inputting data, such as a keyboard and a mouse.
The embodiment of the invention provides a data processing method of an electric power file based on an operation platform, which carries out electric power report visual editing through the following steps, including steps S1-S5, referring to FIG. 2, specifically as follows:
and S1, displaying one online power report selected by the user in the webpage in the display equipment, and analyzing the online power report to obtain at least one file sub-area of the online power report.
When the power report needs to be edited, the scheme firstly analyzes the online power report to obtain at least one file sub-region of the online power report, and then edits the content in the file sub-region.
In some embodiments, the S1 includes S11-S14:
and S11, acquiring an initial template corresponding to the online power report, wherein the initial template comprises at least one initial area, and the initial area comprises any one or more of a text editing area or a picture editing area.
It should be noted that, the online power reports in the present embodiment are all established based on one initial template, and the initial templates corresponding to online power reports of the same type may be the same.
When the online power report needs to be edited, the initial template corresponding to the online power report is determined first, and then the online power report is analyzed by using the initial template to obtain the required content.
And S12, analyzing the online power report based on the corresponding relation between the initial template and the initial area to obtain a file sub-area corresponding to the initial area.
The initial template in the scheme comprises at least one initial area, and each initial area corresponds to any one or more of a character editing area or a picture editing area. It can be understood that the online power report generally includes a text region and a picture region, and the present solution may use the initial region to parse the online power report to obtain a file sub-region corresponding to the initial region.
And S13, determining the contour pixel point of each file sub-region, and calculating according to the first pixel value of the contour pixel point and the second pixel value of the adjacent pixel point of the contour pixel point to obtain a third pixel value for display, wherein the first pixel value, the second pixel value and the third pixel value can refer to the gray value of the pixel point.
After the file sub-regions are obtained, each file sub-region has a corresponding outline, it can be understood that the content displayed by the online power report is more, the background color may also be of a larger variety of gray values, when the bottom plate color or the region color of the file sub-region is consistent with or close to the color of the outline, the outline definition is not sufficient, or the outline can be displayed in an intermittent manner, a clear outline reference cannot be provided for a user, and when a subsequent user edits the content in the file sub-region, the editing may be inaccurate.
In some embodiments, the S13 includes S131-S135:
s131, if the absolute value of the difference between the first pixel value and the second pixel value is greater than or equal to a preset pixel value, using the first pixel value as a third pixel value for displaying.
It can be understood that, according to the present disclosure, a difference between the first pixel value and the second pixel value is obtained first, and if the difference is greater than or equal to the preset pixel value, it is indicated that the color of the contour is greatly different from the color of the neighboring area of the contour, at this time, the present disclosure directly uses the first pixel value as the third pixel value for displaying, for example, the preset pixel value is 127, at this time, the first pixel value may be 1, the second pixel value may be 130, at this time, the color contrast between the first pixel value and the second pixel value is large, that is, the gray level difference between the first pixel value and the second pixel value is large, which facilitates the user to distinguish the image contour.
For example, the color corresponding to the first pixel value may be black, the color corresponding to the second pixel value may be white, and the degree of distinction between black and white may be large.
And S132, if the absolute value of the difference value between the first pixel value and the second pixel value is judged to be smaller than a preset pixel value, determining the change trend of the pixel values of the contour pixel points according to the second pixel value.
It can be understood that, if the difference value is less than or equal to the preset pixel value, it is indicated that the difference between the color of the outline and the colors of the file sub-region and the adjacent region of the outline is small, and at this time, the variation trend of the pixel value of the outline pixel point is determined based on the second pixel value. For example, the preset pixel value is 127, the first pixel value may be 120, the second pixel value may be 130, and the color contrast between the first pixel value and the second pixel value is small, that is, the gray level difference between the first pixel value and the second pixel value is small, which is inconvenient for a user to distinguish the image contour.
For example, the color corresponding to the first pixel value is dark gray, the color corresponding to the second pixel value is black, and the difference between the dark gray and the black is small, the present solution determines the variation trend of the pixel values of the contour pixel points based on the first pixel value (corresponding to dark gray), and at this time, the gray levels of the first pixel value and the second pixel value are closer.
In some embodiments, the step S132 (determining a variation trend of the pixel values of the contour pixel according to the second pixel value if the absolute value of the difference between the first pixel value and the second pixel value is smaller than a predetermined pixel value) includes:
and if the second pixel value is less than or equal to the preset pixel value, determining that the change trend of the pixel values of the contour pixel points is an increasing trend. The predetermined pixel value is about half 255, for example, and 127 is a specific example. For example, the gray value of the second pixel value is 80 (which may be obtained by dividing the R value of the pixel point by the G value and the B value by 3), and the gray value of the preset pixel value is 127, then the change trend of the pixel value of the contour pixel point is an increasing trend, that is, the gray value of the first pixel value needs to be increased to increase the difference between the first pixel value and the second pixel value.
And if the second pixel value is larger than the preset pixel value, determining the change trend of the pixel values of the contour pixel points to be a reduction trend. For example, if the second pixel value is, for example, a gray scale value of 180, and the predetermined pixel value is, for example, 127, the change trend of the pixel values of the contour pixel points is a decreasing trend, i.e., the gray scale value of the first pixel value needs to be decreased to increase the difference between the first pixel value and the second pixel value.
And S133, if the change trend is an increasing trend, adding a preset pixel value to the first pixel value to obtain a third pixel value.
It can be understood that, in the present embodiment, the first pixel value is added to a predetermined pixel value (gray scale value) to obtain a third pixel value, for example, the first pixel value before the increase is 80, the second pixel value is 55, the first pixel value after the increase is 207 (gray scale value 80 plus gray scale value 127), and then the third pixel value is used to display the corresponding contour, so as to increase the distinction degree of the contour. The method can be realized, the gray values of two adjacent pixel points are relatively close and are dark (less than 127), at the moment, the method can adjust the first pixel value and brighten the first pixel value, so that the contrast between the outline pixel point and the adjacent pixel point is increased, and the corresponding pixel point is brightened from dark.
And S134, if the change trend is a reduction trend, subtracting a preset pixel value from the first pixel value to obtain a third pixel value. For example, the first pixel value before the reduction is 197, the second pixel value is 180, the first pixel value after the reduction may be 70 (gray value 197 minus gray value 127), and then the corresponding contour is displayed by the third pixel value, so as to increase the discrimination of the contour. The method can be realized, the gray values of two adjacent pixel points are relatively close and are both bright (larger than 127), at the moment, the invention adjusts the first pixel value and dims the first pixel value, so that the contrast between the outline pixel point and the adjacent pixel point is increased, and the corresponding pixel point is brightened or darkened.
S135, the calculated third pixel value is used as the third pixel value for displaying in place of the previous first pixel value.
And S14, controlling the contour pixel points of each file sub-region to be displayed according to the third pixel value.
It can be understood that after the third pixel value is obtained, the contour pixel points of each file sub-region are controlled to be displayed according to the third pixel value, and clear reference of the contour boundary can be provided for a user. According to the scheme, the display color of the outline is adjusted through the embodiment, the contrast of the outline display is increased, the user can refer to the outline display more intuitively in the editing process, and the accuracy of the user in the editing process is improved.
In view of the fact that the display color of the outline may be adjusted to result in the display of the outline with more types of gray values, which may affect the editing and viewing of the user, on the basis of the above embodiment, the method further includes:
and counting the number of pixel points of a third pixel value which is the same as the first pixel value to obtain a first number, and counting the number of pixel points of the third pixel value which is different from the first pixel value to obtain a second number. The scheme can count the number of the pixel points of the third pixel value which is the same as the first pixel value and the number of the pixel points of the third pixel value which is different from the first pixel value.
And obtaining a pixel value change ratio according to the first quantity and the second quantity, and selecting a first preset pixel value and a second preset pixel value if the pixel value change ratio is greater than a preset ratio. According to the scheme, the pixel value change ratios of the first quantity and the second quantity are calculated, if the pixel value change ratios are larger than the preset ratios, the fact that the display colors of the outlines are adjusted more and are possibly displayed in a mode of more gray value types is shown, at the moment, the scheme selects a first preset pixel value and a second preset pixel value, wherein the first preset pixel value can be a pixel value corresponding to white, and the second preset pixel value can be a pixel value corresponding to black.
And controlling the contour pixel points to alternately display preset time periods according to the first preset pixel value and the second preset pixel value respectively. According to the scheme, the contour pixel points are controlled to carry out stroboflash according to the first preset pixel value and the second preset pixel value, for example, the stroboflash can be displayed in a white mode by 1S, black is displayed in a black mode by 1S, and alternate display is carried out to visually display the contour lines to a user.
S2, determining the file sub-area selected by the user, extracting editable contents in the file sub-area, and establishing a rich text editing area in the editable area.
When a user wants to edit the content in one of the file sub-regions, the corresponding file sub-region can be selected based on the editing device, and the server extracts the editable content in the file sub-region and establishes the rich text editing region in the editable region.
The rich text editing area is an area for a user to edit data, the user can edit the content in the rich text editing area based on rich text editing software, and the rich text editing software is a text editor which can be embedded in a browser and can be obtained by what you see, and is referred to as the prior art and is not described any more.
And S3, editing and modifying the editable content through an editing device based on rich text editing software to obtain modified content, and adjusting the modified content according to the plate type specification of the file sub-region and/or the content format of the adjacent file sub-region to obtain adjusted content.
It can be understood that, in the present scheme, the editable content can be edited and modified by using an editing apparatus based on rich text editing software, where the rich text editing software is the prior art and is not described herein again.
Because the data input by the user may not match the original content of the file sub-region, for example, the font and size of the characters are different, and the shape and size of the picture also do not match the file sub-region, the modified content can be adjusted according to the plate-type specification of the file sub-region and/or the content format of the adjacent file sub-region after the modified content is obtained, so as to obtain the adjusted content.
Aiming at the difference that the initial area is the picture editing area and the initial area is the character editing area, the scheme has different layout implementation modes, and specifically comprises the following steps:
for the case where the initial region is a picture editing region:
in some embodiments, the S3 includes S31-S35:
and S31, if the initial area is the picture editing area, deleting the history images in the editable content according to the user operation and adding new images.
It will be appreciated that when a user wants to insert a new image into an online power report, the scheme will first delete the historical image from the editable content and then add the new image.
S32, acquiring plate specifications of the file subareas, wherein the plate specifications comprise shape specifications and/or size specifications.
According to the scheme, in order to enable the added new image to be matched with the file sub-region, the shape specification and/or the size specification of the file sub-region can be obtained, so that the new image can be automatically adjusted accurately, and the shape specification and/or the size specification of the new image can be adapted to the file sub-region.
And S33, if the image shape of the new image is judged to be different from the shape specification of the file sub-region, acquiring the content format of other file sub-regions adjacent to the file sub-region to obtain a reference shape specification, wherein the reference shape specification is one of an adjusted shape or an unadjusted shape.
For example, the image shape of the new image is a circle, the shape of the file sub-region is a square, and then the image shape of the new image is different from the shape specification of the file sub-region, and at this time, the content format of other file sub-regions adjacent to the file sub-region is obtained, and then the reference shape specification is obtained to determine whether the shape of the new image needs to be adjusted, if the adjustment needs to be performed, the reference shape specification is an adjusted shape, and if the adjustment of the shape does not need to be performed, the reference shape specification is an unadjusted shape.
And S34, if the reference shape specification is the adjusted shape, displaying the new image according to the shape specification of the file sub-region, fusing the new image and the file sub-region to form the same shape, and obtaining the adjusted content of the image.
It can be understood that, when the reference shape specification is the adjusted shape, the scheme displays a new image according to the shape specification of the file sub-region, and then fuses the new image with the file sub-region, so that the displayed new image and the file sub-region are fused into the same shape, and the adjusted content of the image is obtained.
In some embodiments, S34 (which displays the new image with the shape specification of the file sub-region if the reference shape specification is an adjusted shape, fusing the new image with the file sub-region such that the displayed new image fuses to the same shape as the file sub-region) includes S341-S344:
s341, selecting the image center point of the new image and the area center point of the selected file sub-area.
And S342, overlapping the new image and the file sub-region based on the image central point and the region central point to obtain a fusion central point, and establishing a coordinate system according to the fusion central point.
Firstly, the scheme determines the image center point of a new image and the area center point of a file sub-area, then utilizes the image center point and the image center point to carry out fusion to obtain a fusion center point, and establishes a coordinate system at the fusion center point.
S343, obtaining the image coordinate value of each image pixel point in the new image and the area coordinate value of each area pixel point in the file sub-area.
According to the scheme, the new image is taken as a circle, the file subareas are taken as squares for explanation, the image coordinate values are the image coordinate values corresponding to the pixel points in the new image, and the area coordinate values are the coordinate values of each pixel point in the file subareas.
And S344, comparing the image coordinate values with the area coordinate values, adjusting the image size of the new image to obtain a first target size, and fusing the new image with the file sub-area according to the fusion central point to fuse the displayed new image and the file sub-area into the same shape.
According to the scheme, the image coordinate values and the area coordinate values are compared, then the image size of the new image is adjusted to obtain the first target size, the new image with the first target size and the file subarea are fused according to the fusion central point, and the displayed new image and the file subarea are fused into the same shape.
In the first case, a new image needs to be magnified:
in some embodiments, S344 (comparing the image coordinate values with the region coordinate values, adjusting the image size of the new image to obtain the first target size, and fusing the new image of the first target size with the sub-region of the file according to the fusion center point, so that the displayed new image and the sub-region of the file are fused into the same shape) includes a 1-A3:
a1, if the coordinates of the image coordinate values do not completely include the coordinates of the area coordinate values, acquiring all the coordinates which do not completely include the area coordinate values to obtain a first coordinate number, and determining a first magnification factor of the new image according to the first coordinate number.
It is to be understood that, if the coordinates of the image coordinate values do not completely include the coordinates of the area coordinate values, all the coordinates not completely including the area coordinate values are acquired at this time to obtain a first coordinate number, and the first magnification of the new image is determined according to the first coordinate number. It is understood that the larger the number of first coordinates, the larger the corresponding first magnification.
For example, referring to fig. 3, the new image is a circle, the file sub-region is a square, the coordinates of the region coordinate values corresponding to the four corners of the square are not included by the coordinates of the image coordinate values, and the larger the area of the four corners is, the larger the number of the corresponding first coordinates is, which indicates that the larger the new image needs to be enlarged, the larger the corresponding first enlargement factor is.
And A2, amplifying the new image according to the first amplification factor, and extracting the image coordinate value of each image pixel point in the amplified new image.
According to the scheme, after the first magnification factor is obtained, the new image is amplified by the first magnification factor, and after the new image is amplified, the image coordinate value of each image pixel point in the amplified new image is extracted again.
And a3, comparing the enlarged image coordinate values with the region coordinate values again, and if the coordinates of the enlarged image coordinate values of the new image are judged to completely include the coordinates of the region coordinate values, then the new image is not enlarged again, and the size of the new image at this time is taken as the first target size.
According to the scheme, the new image is amplified by the first amplification factor, after amplification, the image coordinate value of each image pixel point in the amplified new image is extracted again, the amplified image coordinate value is compared with the region coordinate value again, if the coordinates of the image coordinate value of the amplified new image completely comprise the coordinates of the region coordinate value, the new image is not amplified any more, and the size of the new image at the moment is taken as the first target size.
It should be noted that, the server in this scheme may perform automatic amplification processing for multiple times, and perform comparison with the previous image again after each amplification processing until the coordinates of the coordinate values of the image after the new image is amplified completely include the coordinates of the area coordinate values, and then do not perform amplification processing on the new image any more, so that the size of the new image at this time is the most appropriate size, and at the same time, the distortion rate of the new image can be minimized.
Wherein, if it is determined that the coordinates of the image coordinate values do not completely include the coordinates of the area coordinate values, acquiring all the coordinates that do not completely include the area coordinate values to obtain a first coordinate number, and determining a first magnification factor of the new image according to the first coordinate number, includes:
acquiring a first total number of pixel points in a file subregion;
calculating to obtain a first magnification factor of the new image according to the first coordinate quantity, the first total quantity and the magnification weight value, calculating the first magnification factor by the following formula,
wherein,is the first magnification factor and is the second magnification factor,in order to be the first number of coordinates,in the first total number, the number of the first,to amplify the weight value.
In the above formula, the number of the first coordinatesThe larger the size of the tube is,the larger the corresponding first magnification factor, the larger the magnification factor, and thus the larger the magnification factor, for the new image.
It should be noted that, in the present scheme, the new image is rapidly and progressively amplified at a proper amplitude through the calculation of the first amplification factor, so as to obtain the final new image.
In the second case, the new image reduction processing is required:
in some embodiments, S344 (comparing the image coordinate values with the region coordinate values, adjusting the image size of the new image to obtain a first target size, and fusing the new image of the first target size with the sub-region of the file according to the fusion center point, so that the displayed new image and the sub-region of the file are fused into the same shape) includes B1-B4:
b1, if the coordinates of the image coordinate values completely include the coordinates of the area coordinate values, acquiring all the image coordinate values that do not completely include the area coordinate values in the image coordinate values, obtaining a second coordinate number, and determining a first reduction multiple of the new image according to the second coordinate number.
It can be understood that, if the coordinates of the image coordinate values completely include the coordinates of the area coordinate values, all the image coordinate values not completely including the area coordinate values are acquired at this time, the second coordinate number is obtained, and the first reduction factor of the new image is determined according to the second coordinate number. It is understood that the larger the number of second coordinates, the larger the corresponding first reduction factor.
For example, referring to fig. 4, the new image is a circle, the file sub-region is a square, the circle completely includes the square, and in the drawing, the number of coordinates corresponding to the area between the square and the circle, that is, the number of second coordinates of all image coordinate values that do not completely include the region coordinate value in the image coordinate values, it can be understood that the larger the area is, the more the number of corresponding second coordinates is, the smaller the new image needs to be reduced, and the larger the corresponding first reduction factor is.
Wherein, if it is determined that the coordinates of the image coordinate values completely include the coordinates of the area coordinate values, acquiring all image coordinate values in the image coordinate values that do not correspond to the coordinates that completely include the area coordinate values, obtaining a second coordinate number, and determining a first reduction multiple of the new image according to the second coordinate number, includes:
acquiring a second total number of image pixel points in the new image;
calculating according to the second coordinate number, the second total number and the reduction weight value to obtain a first reduction multiple of the new image, calculating the first reduction multiple by the following formula,
wherein,is a first reduction multiple of the first size,in order to be the second number of coordinates,in order to be the second total number,to reduce the weight value.
Number of second coordinates in the above formulaThe larger the size of the tube is,the larger the corresponding first reduction factorThe larger the image, the larger the magnification of the new image.
And B2, carrying out reduction processing on the new image according to the first reduction multiple, and extracting the image coordinate value of each image pixel point in the new image after the reduction processing.
According to the scheme, after the first reduction multiple is obtained, the new image is reduced by the first reduction multiple, and after the new image is reduced, the image coordinate value of each image pixel point in the new image after the reduction processing is extracted again.
And B3, comparing the image coordinate values after the reduction processing with the region coordinate values again, if the coordinates of the image coordinate values after the reduction processing of the new image completely comprise the coordinates of the region coordinate values, obtaining all the image coordinate values which do not completely comprise the region coordinate values in the image coordinate values again to obtain a third coordinate number, and determining a second reduction multiple of the new image according to the third coordinate number.
According to the scheme, after the image is reduced, the image coordinate value of each image pixel point in the new image after the reduction processing is extracted again, the image coordinate value after the reduction processing is compared with the region coordinate value again, if the coordinate of the image coordinate value after the new image is reduced is judged to be the coordinate completely including the region coordinate value, the third coordinate quantity is obtained through calculation again on the same principle, and the second reduction multiple of the new image is determined according to the third coordinate quantity.
B4, the image coordinate values after the reduction process are continuously compared with the region coordinate values until the coordinates of the image coordinate values of the new image after the reduction process do not completely include the coordinates of the region coordinate values, and the image size of the new image before the reduction is set as the first target size.
According to the scheme, after the second reduction multiple is obtained, the image coordinate values after the reduction processing are compared with the region coordinate values until the coordinates of the image coordinate values of the new image after the reduction processing do not completely include the coordinates of the region coordinate values, and the image size of the new image before the reduction is taken as the first target size.
For example, referring to fig. 5, if the coordinates of the image coordinate values of the new image after the reduction processing in fig. 5 do not completely include the coordinates of the area coordinate values, the present embodiment may use the image size of the new image before the reduction of the image corresponding to fig. 5 as the first target size.
It should be understood that the image corresponding to fig. 5 refers to a circle reduced to a degree just like the intersection region of the square, and the reduced degree corresponding to the new image before the reduction is just like the intersection region of the square, so that the previous image is the best image, and the scheme can minimize the distortion rate during the image enlargement and reduction process under the condition of obtaining the required image size.
In the above embodiment, after the new image is resized, the extra portion outside the file sub-area may be cut out, the shape of the new image may be changed, and the cut out portion may be used as the content filled in the file sub-area.
And S35, if the reference shape specification is an irregular shape, adjusting the image size of the new image according to the size specification of the file sub-region, fusing the new image and the file sub-region, wherein the new image and the file sub-region have different shapes, and obtaining the adjusted content of the image.
It can be understood that if the reference shape specification is an irregular shape, the shape of the new image does not need to be adjusted, but only the image size of the new image needs to be adjusted.
In some embodiments, S35 (where the new image is resized according to the size specification of the file sub-region if the reference shape specification is an irregular shape, and the new image is merged with the file sub-region, where the new image and the file sub-region are different shapes and the resized content of the image is obtained) includes S351-S355:
s351, selecting the image center point of the new image and selecting the area center point of the file sub-area.
And S352, based on the image central point and the area central point, overlapping the new image and the file sub-area to obtain a fusion central point.
Firstly, the scheme determines the image center point of a new image and the area center point of a file sub-area, then the image center point and the image center point are fused to obtain a fusion center point, and a coordinate system is established at the fusion center point.
And S353, if the size of the new image is smaller than that of the file sub-region in all dimensions, fusing the new image and the file sub-region.
All dimensions may refer to a length dimension and a width dimension, and it can be understood that, referring to fig. 6, the sizes of the new image corresponding to fig. 6 are respectively smaller than the sizes of the file sub-regions in the length dimension and the width dimension, and at this time, the new image and the file sub-regions may be directly merged.
In some embodiments, S353 (said fusing the new image and the file sub-region if the size of the new image is smaller than the size of the file sub-region in all dimensions, respectively) comprises:
and if the size of the new image is smaller than the size of the file sub-area in all dimensions, outputting first feedback information. It will be appreciated that the present solution generates the first feedback information to be presented to the user when the size of the new image is smaller than the size of the sub-region of the file in all dimensions, respectively.
And if second confirmation information of the user is received, fusing the new image and the file sub-region. It will be appreciated that if second confirmation information is received from the user indicating that the user feels that the new image is of a correct size, the server may merge the new image directly with the sub-region of the file.
And if a second magnification factor of the user is received, amplifying the new image according to the second magnification factor, and fusing the new image and the file sub-region when the size of the amplified new image is judged to be smaller than that of the file sub-region in all dimensions. It will be appreciated that if the user is said to feel that the size of the new image is too small, a second magnification factor may be entered, and the server may magnify the new image according to the second magnification factor after receiving the second magnification factor of the user.
S354, if the size of the new image is larger than the size of the file sub-region in any dimension, obtaining a second reduction multiple according to the difference value between the size of the new image and the size of the file sub-region, calculating a third reduction multiple through the following formula,
wherein,is the third reduction multiple of the first reduction factor,for the size of the new image to be,is the size of a sub-area of the file,to reduce the coefficient value.
Referring to fig. 7, although the size of the new image corresponding to fig. 7 is larger than the width of the file sub-region in the width dimension, but is smaller than the size of the file sub-region in the length dimension, at this time, the new image cannot be placed in the file sub-region, and therefore, the new image needs to be reduced.
In the above formula, the larger the difference between the size of the new image (for example, the diameter of the new image) and the size of the sub-area of the file (for example, the width dimension), the larger the second reduction factor is obtained, and the larger the adjustment range for the new image is.
And S355, after the new image is reduced based on the reduction multiple, fusing the new image after the reduction processing with the file sub-region.
It is understood that after the new image is reduced by the reduction factor, the new image after the reduction process is merged with the file sub-region.
It should be noted that the present embodiment (not adjusting the shape) is different from the above-mentioned embodiment (adjusting the shape) in that the shape of the new image is changed, so that the server needs to adjust the new image a little by a little to achieve the required accurate new image; aiming at the embodiment without adjusting the shape, the required new image can be realized by artificial intervention adjustment without little adjustment of the server, so that the data processing amount of the server is reduced.
For the case where the initial region is a text editing region:
in other embodiments, the S3 includes:
and if the initial area is a character editing area, deleting the historical characters in the editable content according to the user operation, and adding new characters to obtain the modified content. It can be understood that, first, the present solution deletes the history words in the editable content, and then adds new words to obtain the modified content.
And acquiring a content format of the adjacent file sub-region, and taking the corresponding character size and character style in the content format as a reference character size and a reference character style.
And adjusting the new characters in the modified content according to the size of the reference characters and the reference character style to obtain the adjusted content of the characters.
It can be understood that, according to the scheme, the content format of the adjacent file sub-region is referred to, then the corresponding character size and character style in the content format are used as the reference character size and the reference character style, and the new characters in the modified content are adjusted to obtain the adjusted content of the characters.
And S4, partitioning the display area based on a preset proportion to obtain a first display area and a second display area, displaying the adjusted content in the online power report after synchronous modification through the first display area, and displaying the edited file sub-area through the second display area.
According to the scheme, the display area is partitioned according to a preset proportion (for example, one half) to obtain a first display area and a second display area, then the adjusted content is displayed through the first display area after being synchronously modified in the online power report, and the edited file sub-area is displayed through the second display area.
It can be understood that the user can highlight the edited sub-region of the file through the second display region, so that the edited content is more prominent, and the accuracy of the user in the editing process is improved.
And S5, after receiving the first confirmation information input by the user, taking the modified online power report as a final online power report, and finishing the visual editing of the power report.
After the user finishes editing, the server receives the first confirmation information input by the user, takes the modified online power report as a final online power report, and finishes the visual editing of the online power report.
In order to implement the data processing method of the power file based on the operation platform provided by the present invention, referring to fig. 8, the data processing system of the power file based on the operation platform performs the visual editing of the power report through the following modules, including:
the analysis module is used for displaying the corresponding online power report in the display equipment according to the selection of the user, and analyzing the online power report to obtain at least one file subregion of the online power report;
the extraction module is used for determining a file sub-region selected by a user, extracting editable contents in the file sub-region and establishing a rich text editing region in the editable region;
the modification module is used for editing and modifying the editable content through an editing device based on rich text editing software to obtain modified content, and adjusting the modified content according to the plate type specification of the file sub-area and/or the content format of the adjacent file sub-area to obtain adjusted content;
the processing module is used for carrying out partition processing on the display area based on a preset proportion to obtain a first display area and a second display area, displaying the adjusted content in the online power report after synchronous modification through the first display area, and displaying the edited file sub-area through the second display area;
and the confirmation module is used for taking the modified online power report as a final online power report after receiving the first confirmation information input by the user, and finishing the visual editing of the power report.
In addition to the above embodiments, the present invention may have other embodiments; all technical solutions formed by adopting equivalent substitutions or equivalent transformations fall within the protection scope of the claims of the present invention.
Claims (15)
1. The data processing method of the power file based on the operation platform is characterized by comprising a display device and an editing device, wherein the display device comprises a display area and an editable area, and power report visual editing is performed through the following steps of:
s1, displaying the corresponding online power report in a display device according to the selection of a user, and analyzing the online power report to obtain at least one file sub-region of the online power report;
s2, determining a file sub-region selected by a user, extracting editable contents in the file sub-region, and establishing a rich text editing region in the editable region;
s3, editing and modifying the editable content through an editing device based on rich text editing software to obtain modified content, and adjusting the modified content according to the plate type specification of the file sub-region and/or the content format of the adjacent file sub-region to obtain adjusted content;
s4, performing partition processing on the display area based on a preset proportion to obtain a first display area and a second display area, displaying the adjusted content in the online power report after synchronous modification through the first display area, and displaying the edited file sub-area through the second display area;
and S5, after the first confirmation information input by the user is received, taking the modified online power report as a final online power report, and finishing the visual editing of the power report.
2. The data processing method for power files based on an operating platform according to claim 1,
the S1 includes:
acquiring an initial template corresponding to the online power report, wherein the initial template comprises at least one initial area, and the initial area comprises any one or more of a text editing area or a picture editing area;
analyzing the online power report based on the corresponding relation between the initial template and the initial area to obtain a file sub-area corresponding to the initial area;
determining a contour pixel point of each file subregion, and calculating according to a first pixel value of the contour pixel point and a second pixel value of an adjacent pixel point of the contour pixel point to obtain a third pixel value for displaying;
and controlling the contour pixel points of each file sub-region to be displayed according to the third pixel value.
3. The data processing method for power files based on an operating platform according to claim 2,
the determining of the contour pixel point of each file subregion calculates according to the first pixel value of the contour pixel point and the second pixel value of the adjacent pixel point of the contour pixel point to obtain a third pixel value for displaying, and includes:
if the absolute value of the difference value between the first pixel value and the second pixel value is judged to be larger than or equal to a preset pixel value, taking the first pixel value as a third pixel value for displaying;
if the absolute value of the difference value between the first pixel value and the second pixel value is smaller than a preset pixel value, determining the change trend of the pixel values of the contour pixel points according to the second pixel value;
if the change trend is an increasing trend, adding a preset pixel value to the first pixel value to obtain a third pixel value;
if the change trend is a reduction trend, subtracting a preset pixel value from the first pixel value to obtain a third pixel value;
and taking the calculated third pixel value as a third pixel value for displaying in place of the previous first pixel value.
4. The data processing method for power files based on an operating platform according to claim 3,
if the absolute value of the difference value between the first pixel value and the second pixel value is smaller than a preset pixel value, determining the variation trend of the pixel values of the contour pixel points according to the second pixel value, including:
if the second pixel value is smaller than or equal to a preset pixel value, determining the change trend of the pixel values of the contour pixel points to be an increasing trend;
and if the second pixel value is larger than the preset pixel value, determining the change trend of the pixel values of the contour pixel points to be a reduction trend.
5. The data processing method for the power file based on the operating platform as claimed in claim 3, further comprising:
counting the number of pixel points of a third pixel value which is the same as the first pixel value to obtain a first number, and counting the number of pixel points of the third pixel value which is different from the first pixel value to obtain a second number;
obtaining a pixel value change ratio according to the first quantity and the second quantity, and selecting a first preset pixel value and a second preset pixel value if the pixel value change ratio is greater than a preset ratio;
and controlling the contour pixel points to alternately display preset time periods according to the first preset pixel value and the second preset pixel value respectively.
6. The data processing method for power files based on an operating platform according to claim 2,
the S3 includes:
if the initial area is a picture editing area, deleting a historical image in editable content according to user operation, and adding a new image;
acquiring plate type specifications of file subregions, wherein the plate type specifications comprise shape specifications and/or size specifications;
if the image shape of the new image is judged to be different from the shape specification of the file subregion, acquiring the content format of other file subregions adjacent to the file subregion to obtain a reference shape specification, wherein the reference shape specification is one of an adjusted shape or an unadjusted shape;
if the reference shape specification is the adjusted shape, displaying a new image according to the shape specification of the file sub-region, fusing the new image with the file sub-region, fusing the displayed new image and the file sub-region into the same shape, and obtaining the adjusted content of the image;
and if the reference shape specification is the irregular shape, adjusting the image size of the new image according to the size specification of the file sub-region, fusing the new image and the file sub-region, wherein the new image and the file sub-region have different shapes at the moment, and obtaining the adjusted content of the image.
7. The data processing method for power files based on an operating platform according to claim 6,
if the reference shape specification is an adjusted shape, displaying a new image according to the shape specification of the file sub-region, and fusing the new image and the file sub-region to fuse the displayed new image and the file sub-region into the same shape, including:
selecting an image center point of the new image and selecting a region center point of the file sub-region;
based on the image central point and the area central point, overlapping the new image and the file sub-area to obtain a fusion central point, and establishing a coordinate system according to the fusion central point;
acquiring an image coordinate value of each image pixel point in a new image and a region coordinate value of each region pixel point in a file sub-region;
and comparing the image coordinate values with the region coordinate values, adjusting the image size of the new image to obtain a first target size, and fusing the new image of the first target size with the file subregion according to the fusion central point to fuse the displayed new image and the file subregion into the same shape.
8. The data processing method for power files based on an operating platform according to claim 7,
the method for fusing the displayed new image and the file subregion into the same shape comprises the following steps of comparing the image coordinate values with the region coordinate values, adjusting the image size of the new image to obtain a first target size, fusing the new image of the first target size with the file subregion according to a fusion central point, and fusing the displayed new image and the file subregion into the same shape:
if the coordinates of the image coordinate values do not completely comprise the coordinates of the area coordinate values, acquiring all the coordinates which do not completely comprise the area coordinate values to obtain a first coordinate quantity, and determining a first magnification factor of the new image according to the first coordinate quantity;
amplifying the new image according to the first amplification factor, and extracting the image coordinate value of each image pixel point in the amplified new image;
and comparing the enlarged image coordinate value with the region coordinate value again, and if the coordinates of the enlarged image coordinate value of the new image completely comprise the coordinates of the region coordinate value, not enlarging the new image and taking the size of the new image as the first target size.
9. The data processing method for power files based on an operating platform according to claim 8,
if the coordinates of the image coordinate values do not completely include the coordinates of the area coordinate values, acquiring all the coordinates which do not completely include the area coordinate values to obtain a first coordinate quantity, and determining a first magnification factor of the new image according to the first coordinate quantity, wherein the steps of:
acquiring a first total number of pixel points in a file subregion;
calculating to obtain a first magnification factor of the new image according to the first coordinate quantity, the first total quantity and the magnification weight value, calculating the first magnification factor by the following formula,
10. The data processing method of the power file based on the operating platform according to claim 7, wherein the comparing the image coordinate values with the region coordinate values, adjusting the image size of the new image to obtain a first target size, and fusing the new image of the first target size with the file sub-region according to the fusion center point, so that the displayed new image and the file sub-region are fused into the same shape, comprises:
if the coordinates of the image coordinate values completely comprise the coordinates of the area coordinate values, acquiring all the image coordinate values which do not completely comprise the area coordinate values in the image coordinate values to obtain a second coordinate number, and determining a first reduction multiple of the new image according to the second coordinate number;
reducing the new image according to the first reduction multiple, and extracting the image coordinate value of each image pixel point in the new image after reduction;
comparing the reduced image coordinate values with the region coordinate values again, if the coordinates of the image coordinate values of the reduced new image completely comprise the coordinates of the region coordinate values, obtaining all image coordinate values which do not correspond to the coordinates completely comprising the region coordinate values in the image coordinate values again to obtain a third coordinate number, and determining a second reduction multiple of the new image according to the third coordinate number;
and continuously comparing the image coordinate values after the reduction processing with the region coordinate values until the coordinates of the image coordinate values of the new image after the reduction processing do not completely include the coordinates of the region coordinate values, and taking the image size of the new image before the reduction as the first target size.
11. The data processing method for power files based on an operating platform according to claim 10,
if the coordinates of the image coordinate values completely comprise the coordinates of the area coordinate values, all the image coordinate values which do not correspond to the coordinates completely comprising the area coordinate values in the image coordinate values are obtained, a second coordinate quantity is obtained, and a first reduction multiple of the new image is determined according to the second coordinate quantity, wherein the method comprises the following steps:
acquiring a second total number of image pixel points in the new image;
calculating according to the second coordinate number, the second total number and the reduction weight value to obtain a first reduction multiple of the new image, calculating the first reduction multiple by the following formula,
12. The data processing method for power files based on an operating platform according to claim 6,
if the reference shape specification is an irregular shape, adjusting the image size of the new image according to the size specification of the file sub-region, fusing the new image and the file sub-region, and obtaining the adjusted content of the image, wherein the new image and the file sub-region are different in shape at the moment, and the method comprises the following steps:
selecting an image center point of the new image and selecting a region center point of the file sub-region;
based on the image central point and the area central point, overlapping the new image and the file sub-area to obtain a fusion central point;
if the size of the new image is smaller than the size of the file sub-region in all dimensions, fusing the new image and the file sub-region;
if the size of the new image is larger than the size of the file sub-region in any dimension, obtaining a second reduction multiple according to the difference value between the size of the new image and the size of the file sub-region, calculating a third reduction multiple through the following formula,
wherein,is the third reduction multiple of the first reduction factor,for the size of the new image to be,is the size of a sub-area of the file,to reduce the coefficient value;
and after the new image is reduced based on the reduction multiple, fusing the reduced new image with the file sub-region.
13. The data processing method for power files based on an operating platform according to claim 12,
if the size of the new image is smaller than the size of the file sub-region in all dimensions, fusing the new image and the file sub-region, including:
if the size of the new image is smaller than the size of the file sub-region in all dimensions respectively, outputting first feedback information;
if second confirmation information of the user is received, fusing the new image and the file sub-region;
and if a second magnification factor of the user is received, amplifying the new image according to the second magnification factor, and fusing the new image and the file sub-region when the size of the amplified new image is judged to be smaller than that of the file sub-region in all dimensions.
14. The data processing method for power files based on an operating platform according to claim 2,
the S3 includes:
if the initial area is a character editing area, deleting the historical characters in the editable content according to the user operation, and adding new characters to obtain the modified content;
acquiring a content format of a sub-region of an adjacent file, and taking a corresponding character size and a character style in the content format as a reference character size and a reference character style;
and adjusting the new characters in the modified content according to the size of the reference characters and the reference character style to obtain the adjusted content of the characters.
15. The data processing system of the power file based on the operation platform is characterized by comprising a display device and an editing device, wherein the display device comprises a display area and an editable area, and power report visual editing is performed through the following modules, including:
the analysis module is used for displaying the corresponding online power report in the display equipment according to the selection of the user, and analyzing the online power report to obtain at least one file subregion of the online power report;
the extraction module is used for determining a file sub-region selected by a user, extracting editable contents in the file sub-region and establishing a rich text editing region in the editable region;
the modification module is used for editing and modifying the editable content through an editing device based on rich text editing software to obtain modified content, and adjusting the modified content according to the plate type specification of the file sub-area and/or the content format of the adjacent file sub-area to obtain adjusted content;
the processing module is used for carrying out partition processing on the display area based on a preset proportion to obtain a first display area and a second display area, displaying the adjusted content in the online power report after synchronous modification through the first display area, and displaying the edited file sub-area through the second display area;
and the confirmation module is used for taking the modified online power report as a final online power report after receiving the first confirmation information input by the user, and finishing the visual editing of the power report.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202210985917.6A CN115048915B (en) | 2022-08-17 | 2022-08-17 | Data processing method and system of electric power file based on operation platform |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202210985917.6A CN115048915B (en) | 2022-08-17 | 2022-08-17 | Data processing method and system of electric power file based on operation platform |
Publications (2)
Publication Number | Publication Date |
---|---|
CN115048915A true CN115048915A (en) | 2022-09-13 |
CN115048915B CN115048915B (en) | 2022-11-01 |
Family
ID=83168312
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202210985917.6A Active CN115048915B (en) | 2022-08-17 | 2022-08-17 | Data processing method and system of electric power file based on operation platform |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN115048915B (en) |
Citations (14)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
WO2004068368A1 (en) * | 2003-01-31 | 2004-08-12 | Canon Kabushiki Kaisha | Image processing method, system, program, program storage medium and information processing apparatus |
CN1745381A (en) * | 2003-01-31 | 2006-03-08 | 佳能株式会社 | Image processing method, system, program, program storage medium and information processing apparatus |
CN107656941A (en) * | 2016-07-26 | 2018-02-02 | 阿里巴巴集团控股有限公司 | Document analysis method, apparatus and editor |
CN109299446A (en) * | 2018-08-03 | 2019-02-01 | 新华三大数据技术有限公司 | Report-generating method and device |
CN109948510A (en) * | 2019-03-14 | 2019-06-28 | 北京易道博识科技有限公司 | A kind of file and picture example dividing method and device |
CN110019860A (en) * | 2017-12-04 | 2019-07-16 | 天津三星电子有限公司 | A kind of processing method and electronic equipment of multimedia file |
GB2578988A (en) * | 2018-09-19 | 2020-06-03 | Imagical LLC | Automated text layout, color and other stylization on an image or video, and the tracking and application of user color preferences |
CN111488104A (en) * | 2020-04-16 | 2020-08-04 | 维沃移动通信有限公司 | Font editing method and electronic equipment |
CN111553137A (en) * | 2020-03-30 | 2020-08-18 | 平安医疗健康管理股份有限公司 | Report generation method and device, storage medium and computer equipment |
CN112017195A (en) * | 2020-08-26 | 2020-12-01 | 上海三维工程建设咨询有限公司 | Intelligent integrated monitoring system applied to urban rail transit |
CN112989782A (en) * | 2021-04-22 | 2021-06-18 | 北京三维天地科技股份有限公司 | Method for automatic template configuration and report generation |
CN113076814A (en) * | 2021-03-15 | 2021-07-06 | 腾讯科技(深圳)有限公司 | Text area determination method, device, equipment and readable storage medium |
WO2021169502A1 (en) * | 2020-02-27 | 2021-09-02 | Changsha Pixel Code Technology Co. Ltd | A pixel image as well as its processing method and application system |
CN113744830A (en) * | 2021-08-20 | 2021-12-03 | 海南视联大健康智慧医疗科技有限公司 | Report generation method and device, electronic equipment and storage medium |
-
2022
- 2022-08-17 CN CN202210985917.6A patent/CN115048915B/en active Active
Patent Citations (14)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN1745381A (en) * | 2003-01-31 | 2006-03-08 | 佳能株式会社 | Image processing method, system, program, program storage medium and information processing apparatus |
WO2004068368A1 (en) * | 2003-01-31 | 2004-08-12 | Canon Kabushiki Kaisha | Image processing method, system, program, program storage medium and information processing apparatus |
CN107656941A (en) * | 2016-07-26 | 2018-02-02 | 阿里巴巴集团控股有限公司 | Document analysis method, apparatus and editor |
CN110019860A (en) * | 2017-12-04 | 2019-07-16 | 天津三星电子有限公司 | A kind of processing method and electronic equipment of multimedia file |
CN109299446A (en) * | 2018-08-03 | 2019-02-01 | 新华三大数据技术有限公司 | Report-generating method and device |
GB2578988A (en) * | 2018-09-19 | 2020-06-03 | Imagical LLC | Automated text layout, color and other stylization on an image or video, and the tracking and application of user color preferences |
CN109948510A (en) * | 2019-03-14 | 2019-06-28 | 北京易道博识科技有限公司 | A kind of file and picture example dividing method and device |
WO2021169502A1 (en) * | 2020-02-27 | 2021-09-02 | Changsha Pixel Code Technology Co. Ltd | A pixel image as well as its processing method and application system |
CN111553137A (en) * | 2020-03-30 | 2020-08-18 | 平安医疗健康管理股份有限公司 | Report generation method and device, storage medium and computer equipment |
CN111488104A (en) * | 2020-04-16 | 2020-08-04 | 维沃移动通信有限公司 | Font editing method and electronic equipment |
CN112017195A (en) * | 2020-08-26 | 2020-12-01 | 上海三维工程建设咨询有限公司 | Intelligent integrated monitoring system applied to urban rail transit |
CN113076814A (en) * | 2021-03-15 | 2021-07-06 | 腾讯科技(深圳)有限公司 | Text area determination method, device, equipment and readable storage medium |
CN112989782A (en) * | 2021-04-22 | 2021-06-18 | 北京三维天地科技股份有限公司 | Method for automatic template configuration and report generation |
CN113744830A (en) * | 2021-08-20 | 2021-12-03 | 海南视联大健康智慧医疗科技有限公司 | Report generation method and device, electronic equipment and storage medium |
Non-Patent Citations (4)
Title |
---|
COCO: "联合编辑文档 你来定规矩", 《电脑迷》 * |
TOSHIKI HONDA; KOHEI MUKAIYAMA; TAKEHARU SHIRAI; TETSUSHI OHKI;: "Ransomware Detection Considering User"s Document Editing", 《2018 IEEE 32ND INTERNATIONAL CONFERENCE ON ADVANCED INFORMATION NETWORKING AND APPLICATIONS (AINA)》 * |
小T: "文档我做主 调配由我定", 《电脑迷》 * |
景天虎 马小龙 刘均利 莫时旭: "Word文档中AutoCAD数据格式图形显示效果的高效编辑研究", 《图学学报》 * |
Also Published As
Publication number | Publication date |
---|---|
CN115048915B (en) | 2022-11-01 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
US7561722B2 (en) | System and method for interactive document layout | |
US7356202B2 (en) | Image processing apparatus, an image processing method, and a computer readable medium having recorded thereon a processing program for permitting a computer to perform image processing routines | |
EP0441359A2 (en) | Method of and apparatus for extracting image contour data | |
US20050076295A1 (en) | System and method of specifying image document layout definition | |
JP3354754B2 (en) | Kerning treatment method | |
JP2003030673A (en) | Image layout evaluation method, image layout evaluation system and image layout evaluation processing program | |
DE69713977T2 (en) | Method and device for retouching a digital color image | |
JP2004228994A (en) | Image editor, image trimming method, and program | |
US20040165000A1 (en) | Picture layout processing apparatus, picture layout processing method, and program therefor | |
US10977832B2 (en) | Method and apparatus for assigning colours to an image | |
US7079702B2 (en) | Image processing method and apparatus for judging image condition and correcting image | |
CN115048915B (en) | Data processing method and system of electric power file based on operation platform | |
US7463787B2 (en) | Picture editing | |
CN110248147B (en) | Image display method and device | |
EP0322794A2 (en) | Method and apparatus for generating patterns | |
JP6006560B2 (en) | Web content color creation support method and web content color creation support device | |
CN112580123A (en) | Editing method and device of beam graphics primitives, electronic equipment and readable storage medium | |
US5302967A (en) | Figure processing apparatus and method aided by display with ruled lines | |
EP0459711A2 (en) | Method and apparatus for processing image data | |
CN115964037B (en) | Engineering data visualization low-code configuration method and system | |
US10438387B2 (en) | Whatif one-page multi-y axis graphing system | |
US7197181B1 (en) | Quick method for color-based selection of objects in a raster image | |
JP7532110B2 (en) | Image processing device, image processing method, and program | |
KR102064367B1 (en) | Image tagging device and method thereof | |
CN111083468A (en) | Short video quality evaluation method and system based on image gradient |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
GR01 | Patent grant | ||
GR01 | Patent grant |