CN106779590A - The generation method and system of a kind of E-seal - Google Patents

The generation method and system of a kind of E-seal Download PDF

Info

Publication number
CN106779590A
CN106779590A CN201611091169.8A CN201611091169A CN106779590A CN 106779590 A CN106779590 A CN 106779590A CN 201611091169 A CN201611091169 A CN 201611091169A CN 106779590 A CN106779590 A CN 106779590A
Authority
CN
China
Prior art keywords
seal
character
information
target
seal information
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.)
Pending
Application number
CN201611091169.8A
Other languages
Chinese (zh)
Inventor
胡文彬
彭甜
危明武
钟娜
刘祥涛
赵彦晖
孙淏添
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Electronic Invoice Marketing Data Services Ltd
Original Assignee
Electronic Invoice Marketing Data Services Ltd
Priority date (The priority date 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 date listed.)
Filing date
Publication date
Application filed by Electronic Invoice Marketing Data Services Ltd filed Critical Electronic Invoice Marketing Data Services Ltd
Priority to CN201611091169.8A priority Critical patent/CN106779590A/en
Publication of CN106779590A publication Critical patent/CN106779590A/en
Pending legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06QINFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
    • G06Q10/00Administration; Management
    • G06Q10/10Office automation; Time management
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06QINFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
    • G06Q30/00Commerce
    • G06Q30/04Billing or invoicing
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T11/002D [Two Dimensional] image generation
    • G06T11/20Drawing from basic elements, e.g. lines or circles
    • G06T11/203Drawing of straight lines or curves
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T11/002D [Two Dimensional] image generation
    • G06T11/60Editing figures and text; Combining figures or text

Landscapes

  • Engineering & Computer Science (AREA)
  • Business, Economics & Management (AREA)
  • General Physics & Mathematics (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • Strategic Management (AREA)
  • Entrepreneurship & Innovation (AREA)
  • Development Economics (AREA)
  • Human Resources & Organizations (AREA)
  • Economics (AREA)
  • Marketing (AREA)
  • General Business, Economics & Management (AREA)
  • Finance (AREA)
  • Data Mining & Analysis (AREA)
  • Accounting & Taxation (AREA)
  • Operations Research (AREA)
  • Quality & Reliability (AREA)
  • Tourism & Hospitality (AREA)
  • Processing Or Creating Images (AREA)

Abstract

The embodiment of the invention discloses the generation method and system of a kind of E-seal, for the generation demand of self-adapting electronic seal, flexibly, E-seal is easily generated.Present invention method includes:Define canvas interface;Preset pattern of the generation with pre-set dimension in canvas interface;Based on pre-set dimension, the typesetting parameter of target seal information is calculated according to preset algorithm;Target seal information is generated in preset pattern according to typesetting parameter;The preset pattern of generation target seal information is processed according to preset rules, E-seal picture is obtained.

Description

The generation method and system of a kind of E-seal
Technical field
The present invention relates to E-seal technical field, more particularly to a kind of E-seal generation method and system.
Background technology
Electronic invoice as the information age product, it is advantageously implemented taxpayer, consumption using as paper invoice Person and the good pattern of tax authority's tripartite's win-win.Wherein, for taxpayer particularly electric business enterprise, electronic invoice can drop Low its operation cost, strengthens its business reputation, promotes management functions to develop in a healthy way;For consumer, ask for, preserve invoice Problem is also readily solved so that consumption and quality right-safeguarding are more secure;For the tax authority, the printing of paper invoice is reduced, Also section Zhi Jieneng, consumption reduction emission reduction will be promoted.
In general, the content of electronic invoice contains complete invoice information, is imitated with law as paper invoice Power, its Invoice Seal is generated by E-seal technology.E-seal technology be with simulation with digital technique tradition material object seal, its Management, occupation mode meet custom and the experience of seal in kind, and the e-file that it is added a cover has the paper added a cover with seal in kind Open file identical outward appearance, identical validity and similar occupation mode.
At present, E-seal is directly made using drawing tools such as Photoshop, or by seal in kind on paper After affixing one's seal, it is scanned using scanner, reuses to repair figure instrument and carry out treatment and be made E-seal, but these methods are related to too Many manual operationss, manufacturing process is relatively complicated, and cannot be with external system from the dynamic docking of realization.In addition, also having part at present E-seal Auto-Generation Tool, its way is to make seal profile using drawing tools in advance, further according to enterprise's name of input The information such as title generation E-seal, though this method realizes automation to a certain extent, because its seal profile is solid Fixed, it is impossible to it is adjusted according to actual needs, while self adaptation can not be accomplished to information such as the enterprise names of input, so that So that the E-seal of generation often occurs typesetting entanglement.
The content of the invention
The generation method and system of a kind of E-seal are the embodiment of the invention provides, for self-adapting electronic seal Generation demand, flexibly, easily generates E-seal.
In view of this, first aspect present invention provides a kind of generation method of E-seal, it may include:
Define canvas interface;
Preset pattern of the generation with pre-set dimension in canvas interface;
Based on pre-set dimension, the typesetting parameter of target seal information is calculated according to preset algorithm;
Target seal information is generated in preset pattern according to typesetting parameter;
The preset pattern of generation target seal information is processed according to preset rules, E-seal picture is obtained..
With reference to the embodiment of the present invention in a first aspect, the first implementation method of the first aspect in the embodiment of the present invention In, based on pre-set dimension, the typesetting parameter for calculating target seal information according to preset algorithm includes:
Obtain the typesetting pattern and display parameters of target seal information;
According to pre-set dimension, typesetting pattern and display parameters, the typesetting parameter of target seal information is calculated;
Wherein, display parameters include the back gauge between character types, character boundary, character pitch, character and preset pattern.
With reference to the first implementation method of the first aspect of the embodiment of the present invention, in the first aspect of the embodiment of the present invention In second implementation method, according to pre-set dimension, typesetting pattern and display parameters, the typesetting parameter bag of target seal information is calculated Include:
Typesetting pattern is arc typesetting, target seal information place camber line is calculated according to pre-set dimension, display parameters and is formed Curvilinear figure in preset arc length length;
According to target character spacing, pre-set dimension, the word of the length, display parameters and target seal information of presetting arc length Symbol number, calculate target seal information in target character in preset pattern or the coordinate of curvilinear figure, according to target character spacing The length of default arc length, display parameters, number of characters are calculated, or target character spacing is character pitch;
The tangent line radian of target character in coordinate and target seal information is determined for typesetting parameter, according to tangent line radian Coordinate is calculated.
With reference to second implementation method of the first aspect of the embodiment of the present invention, in the first aspect of the embodiment of the present invention It is pre- in the curvilinear figure that the camber line according to where pre-set dimension, back gauge calculate target seal information is formed in the third implementation method If the length of arc length includes:
The size ginseng of the curvilinear figure that the camber line according to where pre-set dimension, display parameters calculate target seal information is formed Number;
The coordinate of the pinpoint of arc length is preset in calculated curve figure according to dimensional parameters and presetted pixel point;
Coordinate according to pinpoint calculates the length of default arc length.
With reference to the first implementation method of the first aspect of the embodiment of the present invention, in the first aspect of the embodiment of the present invention In 4th kind of implementation method, according to pre-set dimension, typesetting pattern and display parameters, the typesetting parameter bag of target seal information is calculated Include:
Type-setting mode is horizontal typesetting, and the number of characters according to display parameters and target seal information calculates target seal letter The character length of breath;
Target character is in preset pattern in calculating target seal information according to character length, display parameters, pre-set dimension Coordinate is typesetting parameter.
With reference to the 4th kind of implementation method of the first aspect of the embodiment of the present invention, in the first aspect of the embodiment of the present invention In 5th kind of implementation method, the method also includes:
Target seal information includes the first seal information and the second seal information of horizontal row version, according to display parameters and The character length that the number of characters of target seal information calculates target seal information includes:
Display parameters, the number of characters of the first seal information according to the first seal information, and the second seal information is aobvious Show parameter, the number of characters of the second seal information, the character length of the first seal information and the word of the second seal information are calculated respectively Symbol length;
Character starting of the target seal information in preset pattern is calculated according to character length, display parameters, pre-set dimension Coordinate includes for typesetting parameter:
Character length, the display parameters of the first seal information, pre-set dimension according to the first seal information calculate first and print First coordinate of first character of chapter information in preset pattern;
Display parameters according to the first coordinate, the character length of the second seal information, the second seal information calculate second and print Second coordinate of second character of chapter information in preset pattern;
Determine that the first coordinate and the second coordinate are typesetting parameter.
It is any one in reference to the first implementation method to the 5th kind of implementation method of the first aspect of the embodiment of the present invention Kind, in the 6th kind of implementation method of the first aspect of the embodiment of the present invention, process generation target seal according to preset rules and believe The preset pattern of breath, obtaining E-seal picture includes:
The preset pattern for generating target seal information is set to the picture compression form of background transparent, E-seal is obtained Picture.
With reference to the embodiment of the present invention in a first aspect, the first implementation method of the first aspect of the embodiment of the present invention is to Any one in six kinds of implementation methods, in the 7th kind of implementation method of the first aspect of the embodiment of the present invention, if electronic seal Chapter is electronic invoice special seal, and preset pattern of the generation with pre-set dimension includes in canvas interface:
Ellipse of the generation with pre-set dimension in canvas interface;
Based on pre-set dimension, the typesetting parameter for calculating target seal information according to preset algorithm includes:
Based on pre-set dimension, enterprise name character information, duty paragraph character information, invoice are calculated respectively according to preset algorithm special With the typesetting parameter of chapter character information;
Target seal information is generated in preset pattern according to typesetting parameter, obtaining E-seal picture includes:
Enterprise name character information, duty paragraph character information, Invoice Seal word are generated in ellipse according to typesetting parameter Symbol information;
The preset pattern of generation target seal information is processed according to preset rules, obtaining E-seal picture includes:
Generation enterprise name character information, duty paragraph character information, Invoice Seal character information are processed according to preset rules Preset pattern, obtain electronic invoice special seal picture.
Second aspect present invention provides a kind of generation system of E-seal, it may include:
Definition module, for defining canvas interface;
First generation module, for preset pattern of the generation with pre-set dimension in canvas interface;
Computing module, for based on pre-set dimension, the typesetting parameter of target seal information being calculated according to preset algorithm;
Second generation module, for generating target seal information in preset pattern according to typesetting parameter;
Processing module, the preset pattern for processing generation target seal information according to preset rules, obtains E-seal Picture.
With reference to the second aspect of the embodiment of the present invention, in the first implementation method of the second aspect of the embodiment of the present invention In, computing module, specifically for:
Obtain the typesetting pattern and display parameters of target seal information;
According to pre-set dimension, typesetting pattern and display parameters, the typesetting parameter of target seal information is calculated;
Wherein, display parameters include back gauge between character types, character boundary, character pitch, character and preset pattern, Alignment mode, character row away from.
With reference to the first implementation method of the second aspect of the embodiment of the present invention, in the second aspect of the embodiment of the present invention In second implementation method, computing module, also particularly useful for:
Typesetting pattern is arc typesetting, target seal information place camber line is calculated according to pre-set dimension, display parameters and is formed Curvilinear figure in preset arc length length;
According to target character spacing, pre-set dimension, the word of the length, display parameters and target seal information of presetting arc length Symbol number, calculate target seal information in target character in preset pattern or the coordinate of curvilinear figure, according to target character spacing The length of default arc length, display parameters, number of characters are calculated, or target character spacing is character pitch;
The tangent line radian of target character in coordinate and target seal information is determined for typesetting parameter, according to tangent line radian Coordinate is calculated.
With reference to second implementation method of the second aspect of the embodiment of the present invention, in the second aspect of the embodiment of the present invention In the third implementation method, computing module, also particularly useful for:
The size ginseng of the curvilinear figure that the camber line according to where pre-set dimension, display parameters calculate target seal information is formed Number;
The coordinate of the pinpoint of arc length is preset in calculated curve figure according to dimensional parameters and presetted pixel point;
Coordinate according to pinpoint calculates the length of default arc length.
With reference to the first implementation method of the second aspect of the embodiment of the present invention, in the second aspect of the embodiment of the present invention In 4th kind of implementation method, computing module, specifically for:
Type-setting mode is horizontal typesetting, and the number of characters according to display parameters and target seal information calculates target seal letter The character length of breath;
Target character is in preset pattern in calculating target seal information according to character length, display parameters, pre-set dimension Coordinate is typesetting parameter.
With reference to the 4th kind of implementation method of the second aspect of the embodiment of the present invention, in the second aspect of the embodiment of the present invention In 5th kind of implementation method, system also includes:
Target seal information includes the first seal information and the second seal information of horizontal row version, and computing module is also specific For:
Display parameters, the number of characters of the first seal information according to the first seal information, and the second seal information is aobvious Show parameter, the number of characters of the second seal information, the character length of the first seal information and the word of the second seal information are calculated respectively Symbol length;
Character length, the display parameters of the first seal information, pre-set dimension according to the first seal information calculate first and print First coordinate of first character of chapter information in preset pattern;
Display parameters according to the first coordinate, the character length of the second seal information, the second seal information calculate second and print Second coordinate of second character of chapter information in preset pattern;
Determine that the first coordinate and the second coordinate are typesetting parameter.
It is any one in reference to the first implementation method to the 5th kind of implementation method of the second aspect of the embodiment of the present invention Kind, in the 6th kind of implementation method of the second aspect of the embodiment of the present invention, processing module, specifically for:
The preset pattern for generating target seal information is set to the picture compression form of background transparent, E-seal is obtained Picture.
With reference to the second aspect of the embodiment of the present invention, the first implementation method of the second aspect of the embodiment of the present invention to Any one in six kinds of implementation methods, in the 7th kind of implementation method of the second aspect of the embodiment of the present invention, the first generation Module, specifically for:
Ellipse of the generation with pre-set dimension in canvas interface;
Computing module, specifically for:
Based on pre-set dimension, enterprise name character information, duty paragraph character information, invoice are calculated respectively according to preset algorithm special With the typesetting parameter of chapter character information;
Second generation module, specifically for:
Enterprise name character information, duty paragraph character information, Invoice Seal word are generated in ellipse according to typesetting parameter Symbol information;
Processing module, specifically for:
Generation enterprise name character information, duty paragraph character information, Invoice Seal character information are processed according to preset rules Preset pattern, obtain electronic invoice special seal picture.
As can be seen from the above technical solutions, the embodiment of the present invention has advantages below:
In the present embodiment, by preset pattern of the generation with pre-set dimension in canvas interface, target can calculated After the typesetting parameter of seal information, generation target seal information obtains E-seal picture in preset pattern, it is possible to export The E-seal picture.It follows that first, the method for automatically generating E-seal picture, without manual intervention, is conducive to carrying The formation efficiency of E-seal high;Secondly, the attribute such as the figure of E-seal picture and the size of character can be according to actual needs Configuration, flexibility ratio is high, can accomplish good self adaptation to different target seal information, and the E-seal of generation is accurate;Again It is secondary, can be used for generating various types of E-seals, and can be called by external system and automatically generate seal, it is applied widely.
Brief description of the drawings
Fig. 1 is generation method one embodiment schematic diagram of E-seal in the embodiment of the present invention;
Fig. 2 is another embodiment schematic diagram of generation method of E-seal in the embodiment of the present invention;
Fig. 3 is the first computational methods schematic diagram of typesetting parameter in the generation method of E-seal in the embodiment of the present invention;
Fig. 4 is the second computational methods schematic diagram of typesetting parameter in the generation method of E-seal in the embodiment of the present invention;
Fig. 5 is another embodiment schematic diagram of generation method of E-seal in the embodiment of the present invention;
Fig. 6 is the generation method schematic diagram of enterprise name character information in E-seal in the embodiment of the present invention;
Fig. 7 is the generation method schematic diagram of duty paragraph character information in E-seal in the embodiment of the present invention;
Fig. 8 is the generation method schematic diagram of Invoice Seal character information in E-seal in the embodiment of the present invention;
Fig. 9 is the schematic diagram of the electronic invoice special seal of generation in the embodiment of the present invention;
Figure 10 is generation system one embodiment schematic diagram of E-seal in the embodiment of the present invention.
Specific embodiment
The generation method and system of a kind of E-seal are the embodiment of the invention provides, for self-adapting electronic seal Generation demand, flexibly, easily generates E-seal.
In order that those skilled in the art more fully understand the present invention program, below in conjunction with the embodiment of the present invention Accompanying drawing, is clearly and completely described to the technical scheme in the embodiment of the present invention, it is clear that described embodiment is only The embodiment of a part of the invention, rather than whole embodiments.Based on the embodiment in the present invention, ordinary skill people The every other embodiment that member is obtained under the premise of creative work is not made, should all belong to the model of present invention protection Enclose.
Term " first ", " second ", " the 3rd ", " in description and claims of this specification and above-mentioned accompanying drawing Four " etc. (if present) is for distinguishing similar object, without for describing specific order or precedence.Should manage The data that solution is so used can be exchanged in the appropriate case, so that the embodiments described herein can be with except illustrating herein Or the order beyond the content of description is implemented.Additionally, term " comprising " and " having " and their any deformation, it is intended that Covering is non-exclusive to be included, for example, the process, method, system, product or the equipment that contain series of steps or unit need not be limited In those steps or unit for clearly listing, but may include not list clearly or for these processes, method, product Product or other intrinsic steps of equipment or unit.
For ease of understanding, the idiographic flow in the embodiment of the present invention is described below, refers to Fig. 1, the present invention is real The generation method one embodiment for applying E-seal in example includes:
101st, canvas interface is defined;
In the present embodiment, the generation method of E-seal can apply to mobile terminal, the mobile terminal can include but It is not limited to the electronic equipment with display screen such as mobile phone, panel computer, IPAD.
When user needs to carry out the preparation of E-seal by mobile terminal, mobile terminal can accordingly be grasped Make, after operational order is received, mobile terminal can define canvas interface, and E-seal is generated with the canvas interface.
It should be noted that in the present embodiment, background, size, shape of canvas interface etc. can be configured, specifically Do not limit herein.
It is understood that in actual applications, operational order can not also be triggered by user, it is also possible to by mobile terminal Automatic triggering, can be according to actual setting depending on, do not limit herein specifically.
102nd, preset pattern of the generation with pre-set dimension in canvas interface;
In the present embodiment, after defining canvas interface, the preset pattern with pre-set dimension can be generated in canvas interface.
Specifically, preset pattern is the shape of E-seal, can be including but not limited to circular, oval, square, in advance If size is the size of E-seal, in actual applications, different types of E-seal has different standard shapes, With different standard sizes, after it is determined that needing the type of the E-seal of preparation, can be true according to the type of E-seal Fixed its pre-set dimension and preset pattern.
In actual applications, the mapping relations between pre-set dimension and preset pattern can be stored in mobile terminal, Cloud Server is stored in, and mobile terminal is issued to by Cloud Server, do not limited herein specifically.
103rd, based on pre-set dimension, the typesetting parameter of target seal information is calculated according to preset algorithm;
In the present embodiment, after preset pattern of the generation with pre-set dimension in canvas interface, pre-set dimension can be based on, The typesetting parameter of target seal information is calculated according to preset algorithm.
Specifically, can be including various seal information, such as seal title, seal numbering, five-pointed star character in E-seal Deng, this various seal information can have different display locations in preset pattern, for the change of self-adapting electronic seal, its Display location also should correspondingly change, then can be based on the pre-set dimension of preset pattern, and calculating target according to preset algorithm prints Display location of the chapter information in preset pattern is typesetting parameter.
In actual applications, preset algorithm can be stored in mobile terminal, be the calculating function for being dependent on pre-set dimension, In the preset algorithm, in addition to pre-set dimension this variable, multiple typesetting parameters for calculating target seal information can be included Variable, specifically variable can be configured according to actual needs.It is understood that preset algorithm can be updated change Change, to cause that the typesetting parameter of target seal information constantly tends to accurate.
It is understood that according to the shape of preset pattern, pre-set dimension can be different variables, for example, it is assumed that in advance If figure is circle, then its pre-set dimension can be radius or diameter, it is assumed that preset pattern is ellipse, then its default chi Very little can be major semiaxis, semi-minor axis, it is assumed that preset pattern is square, then its pre-set dimension can be length, width.
104th, target seal information is generated in preset pattern according to typesetting parameter;
In the present embodiment, based on pre-set dimension, after calculating the typesetting parameter of target seal information according to preset algorithm, can be with Target seal information is generated in preset pattern according to typesetting parameter.
Specifically, after obtaining the typesetting parameter of target seal information, you can to judge target seal information in preset pattern In specific display location, then target seal information can be generated in the display location.
105th, the preset pattern of generation target seal information is processed according to preset rules, E-seal picture is obtained
In the present embodiment, after generating target seal information in preset pattern according to typesetting parameter, can be according to default rule Then the preset pattern for the treatment of generation target seal information, obtains E-seal picture.
Specifically, after generating target seal information in preset pattern, the background color of preset pattern can be set to It is transparent, it is possible to the preset pattern boil down to picture format for generating target seal information to be obtained into E-seal picture, such as PNG Form, JPG forms.Target seal information is generated in preset pattern, and after preset pattern is processed accordingly, if target Seal information is whole generation information of E-seal, you can to think to complete the generation of E-seal.
It is understood that the background color of preset pattern refers to the face within the sideline of preset pattern in the present embodiment Color, in actual applications, except the transparent of described above, or other, can set according to actual needs, specifically herein not Limit.
It should be noted that in actual applications, E-seal picture can not also be compressed, and in the situation of compression Under, or other picture compression forms, such as TIFF picture compressions form, do not limit herein specifically.
In actual applications, target seal information can be one, or multiple, visible electronic seal it is specific in Depending on appearance, if target seal information is multiple, then this multiple target seal information can be generated in preset pattern successively, Can simultaneously generate, not limit herein specifically.
It is understood that in the embodiment of the present invention, target seal information can have different showing in preset pattern Show form, refer to Fig. 2, another embodiment of the generation method of E-seal includes in the embodiment of the present invention:
Step 201 in the present embodiment is identical to step 102 with the step 101 in embodiment illustrated in fig. 1 to step 202, Here is omitted.
203rd, the typesetting pattern and display parameters of target seal information are obtained;
In the present embodiment, after preset pattern of the generation with pre-set dimension in canvas interface, target seal can be obtained The typesetting pattern and display parameters of information.
Specifically, target seal information can be shown in the form of character, such as word, numeral or pattern, in electronics In seal, the typesetting pattern of target seal information can include arc typesetting and horizontal typesetting, and display parameters can include character Back gauge, alignment mode, character row between type, character boundary, character pitch, character and preset pattern away from, wherein, word Symbol type is font, and character boundary is font size.By above-mentioned typesetting pattern and display parameters, can be with precise control preset pattern The generation of target seal information.
It is understood that in actual applications, if the need for target seal information has vertical typesetting, then typesetting pattern Vertical typesetting can also be included, additionally, display parameters also can also specifically not limited including character color etc. herein.
204th, according to pre-set dimension, typesetting pattern and display parameters, the typesetting parameter of target seal information is calculated;
In the present embodiment, after obtaining the typesetting pattern and display parameters of target seal information, can be according to preset pattern Pre-set dimension, typesetting pattern and display parameters, calculate the typesetting parameter of target seal information.
Specifically, the content based on 103 explanations in embodiment illustrated in fig. 1, different typesetting patterns can be to that should have difference Preset algorithm, accordingly, in corresponding preset algorithm, pre-set dimension and display parameters can think variable, based on It is typesetting parameter to calculate display location of the target seal information in preset pattern.
205th, target seal information is generated in preset pattern according to typesetting parameter and display parameters;
In the present embodiment, according to pre-set dimension, typesetting pattern and display parameters, the typesetting parameter of target seal information is calculated Afterwards, target seal information can be generated in preset pattern according to typesetting parameter and display parameters.
Specifically, the change of target seal information self-adapting preset pattern is only caused due to typesetting parameter, but target seal Being particularly shown for information may also rely on display parameters, such as the character types of target seal information, character boundary, character color Deng, then the attribute of target seal information can be adjusted according to display parameters further, be generated with preset pattern Desired target seal information, self adaptation degree is higher.For example, the corresponding character of target seal information generated in preset pattern Type can be the Song typeface, and corresponding character boundary can be No. four, and corresponding character color can be red.
Step 206 in the present embodiment is identical with the step 105 in embodiment illustrated in fig. 1, and here is omitted.
207th, E-seal picture is exported.
In the present embodiment, the preset pattern of generation target seal information is processed according to preset rules, obtain E-seal figure After piece, E-seal picture can be exported.
Specifically, after E-seal picture is obtained, outwards can be output as such as E-seal picture by mobile terminal The file or file stream of PNG or JPG picture compression forms, for external system, such as electronic invoice service platform carries out electronic invoice Called during pdf document stamped signature.
Based on described above, according to different typesetting patterns, the calculating to typesetting parameter separately below is specifically described:
First, typesetting pattern is arc typesetting
Specifically refer to Fig. 3, in the embodiment of the present invention in the generation method of E-seal typesetting parameter the first calculating side Method includes:
301st, typesetting pattern is arc typesetting, the camber line according to where pre-set dimension, display parameters calculate target seal information The dimensional parameters of the curvilinear figure of formation;
In the present embodiment, if typesetting pattern of the target seal information in preset pattern is arc typesetting, then can be with root Arc where target seal information is calculated according to the back gauge in the pre-set dimension of preset pattern, display parameters between character and preset pattern The dimensional parameters of the curvilinear figure that shape is formed.
Specifically, after the curved typesetting of target seal information, the curvilinear figure that place camber line is formed can be circular or ellipse Circle, and the curvilinear figure is in preset pattern, then by the pre-set dimension and target information that combine preset pattern Character and preset pattern between back gauge can calculate the dimensional parameters of curvilinear figure where target seal information, if curve map Shape is circle, then the dimensional parameters can be radius or diameter, if the curvilinear figure is ellipse, then the dimensional parameters can Think major semiaxis, semi-minor axis.
For example, it is assumed that preset pattern is circle, the curvilinear figure that camber line where target seal information is formed also is circle, its In, shown in canvas interface a diameter of 5 centimetres of preset pattern, the back gauge in target seal information between character and circle is 0.5 centimetre, then the diameter that can determine curvilinear figure can be 4 centimetres.
302nd, the seat of the pinpoint of arc length is preset in calculated curve figure according to dimensional parameters and presetted pixel point Mark;
In the present embodiment, the curvilinear figure that the camber line according to where pre-set dimension, back gauge calculate target seal information is formed After dimensional parameters, the pinpoint of arc length can be preset in calculated curve figure according to dimensional parameters and presetted pixel point Coordinate.
Specifically, no matter between or for curve, be made up of several pixels, between pixel away from From being certain, i.e. presetted pixel point distance, the image quality effect of presentation content is can serve to indicate that, then according to curvilinear figure Dimensional parameters and presetted pixel point distance, can with calculated curve figure preset arc length target pixel points coordinate, i.e., The coordinate of pinpoint.
In actual applications, the coordinate-system of X, Y-axis with the center of curve map as origin, can be set up, step is continued to use The preset pattern and curvilinear figure illustrated in rapid 301, it may be determined that the coordinate of X-axis left end point is (- 2,0), then assuming that Presetted pixel point distance is A, then the coordinate of next pixel is (- 2+A, 0) in the X-axis, thus method and binding curve The corresponding normal equation of figure, can calculate the coordinate of the pinpoint of default arc length.
It is understood that the default arc length in the present embodiment can be the semi-perimeter of curvilinear figure, it is also possible to more than or Less than the semi-perimeter, can according to actual needs be configured, not limit herein specifically.
303rd, the coordinate according to pinpoint calculates the length of default arc length;
In the present embodiment, the target for presetting arc length in calculated curve figure according to dimensional parameters and presetted pixel point is determined After the coordinate of point, the length of default arc length can be calculated according to the coordinate of pinpoint.
Specifically, after the coordinate of the individual fixed point of the default arc length of determination, it is possible to use air line distance formula calculates two fixed points Between air line distance, by parity of reasoning, can be by the air line distance between all adjacent fixed points in default arc length, will be all adjacent Air line distance between fixed point adds up, you can to calculate the length of default arc length.It is understood that the length of the default arc length It is approximation to spend.
It should be noted that the content that step 302 is illustrated to step 303 in the present embodiment is the length for calculating default arc length A kind of mode, in actual applications, it would however also be possible to employ other manner, such as can calculate public with reference to arc length according to dimensional parameters Formula is calculated the length for presetting arc length, is not limited herein specifically.
304th, according to target character spacing, pre-set dimension, the length of default arc length, display parameters and target seal information Number of characters, calculate target seal information in target character in preset pattern or the coordinate of curvilinear figure;
In the present embodiment, after the coordinate according to pinpoint calculates the length of default arc length, can be according between target character Away from, the number of characters of the length, display parameters and target seal information of default arc length, target character in target seal information is calculated In preset pattern or the coordinate of curvilinear figure, wherein, it is big that target character spacing can preset the length of arc length, character according to Small, number of characters is calculated, or target character spacing can also be character pitch.
In actual applications, there may be following two situations:
1st, the character length of target seal information is the length of default arc length, in such a case it is possible to target seal The original character length of information is calculated, will in display parameters character boundary character duration, with target seal information The product of number of characters as target seal information original character length, if the original character length of target seal information is not more than The length of default arc length, then illustrate target seal information can on default arc length this curve, wherein, target seal is believed The bebinning character of breath can be the first end point of default arc length, and that character can be default arc length is put at the end of target seal information Two end points.Therefore, it can believe target seal using the number of characters of the length, character boundary and target seal information of default arc length The target character spacing of breath is calculated, that is, preset the character duration * number of characters+(character in the length=character boundary of arc length Number -1) * target character spacing, the target character spacing be in target seal information between the corresponding coordinate of adjacent character away from From, after obtaining target character spacing, can according to target character spacing, pre-set dimension, the length of default arc length, display parameters with And the number of characters of target seal information, target character is in preset pattern or the coordinate of curvilinear figure in calculating target seal information.
Specifically, target character can be a character, such as bebinning character, or each in target seal information Character, it is assumed that target character is each character in target seal information, then with reference in pre-set dimension and display parameters Back gauge, it may be determined that the first end point of default arc length in preset pattern or the coordinate of curvilinear figure, for example, continuing to use step 302 Illustration, it is assumed that default arc length is the upper half girth of curvilinear figure, it may be determined that the coordinate of first end point is (- 2,0), then On the basis of the coordinate of first end point, the character duration of character boundary can be obtained in combining target character pitch, display parameters After to first end point another character curvilinear figure coordinate, in conjunction with the number of characters of target seal information, you can obtain each Coordinate of the character in curvilinear figure.
2nd, the character length of target seal information is not the length of default arc length, wherein, if target seal information is original Character length is more than the length of default arc length, then can in addition calculate the character length of target seal information, if target seal is believed The character length of breath is set smaller than the length of default arc length, then the character that can also in addition calculate target seal information is long Degree, then target character spacing now is the character pitch set in display parameters, the character length of target seal information Character duration * number of characters+(number of characters -1) * character pitches in=character boundary, obtain the character length of target seal information Afterwards, can be according to target character spacing, pre-set dimension, the word of the length, display parameters and target seal information of presetting arc length Symbol number, calculate target seal information in target character in preset pattern or the coordinate of curvilinear figure,
Specifically, assume that target character is each character in target seal information, and target seal information character Length is more than the length of default arc length, then with reference to the back gauge in pre-set dimension and display parameters, it may be determined that default arc length First end point in preset pattern or the coordinate of curvilinear figure, for example, continuing to use the illustration of step 302, it is assumed that default arc length Be the upper half girth of curvilinear figure, it may be determined that the coordinate of first end point be (- 2,0), then first end point coordinate basis On, the character length of target seal information can be more than the coordinate symmetry principle of binding curve figure the length of default arc length Part mapping to the coordinate of the lower half girth of curvilinear figure in, it is possible to determine the seat of the bebinning character of target seal information Mark, the character duration in conjunction with character boundary in target character spacing, display parameters can obtain another character after bebinning character In the coordinate of curvilinear figure, in conjunction with the number of characters of target seal information, you can obtain coordinate of each character in curvilinear figure.
It should be noted that in above-mentioned two situations, because curve map is located in preset pattern, then finally, it can It is considered to obtain coordinate of the target character in preset pattern, for example, continuing to use the content of step 301 illustration, first end point Coordinate be that coordinate in preset pattern is still (- 2,0).
It is understood that the coordinate of target character can be the center of target character in the present embodiment, in reality In, or other, can specifically be set according to actual conditions, do not limit herein.
305th, the tangent line radian for determining target character in coordinate and target seal information is typesetting parameter;
In the present embodiment, obtain in target seal information after coordinate of the target character in preset pattern or curvilinear figure, Because target seal information is arc typesetting, then the determination of the coordinate of target character cannot still determine target character in default figure Direction in shape or curvilinear figure, then can be according to the coordinate further to the target character in preset pattern or curvilinear figure Tangent line radian calculated, it is possible to the coordinate and the tangent line radian are defined as typesetting parameter, to determine target character Final display location in preset pattern or curvilinear figure.
306th, target seal information is generated in preset pattern according to typesetting parameter and display parameters.
In the present embodiment, the tangent line radian of target character in coordinate and target seal information is determined for after typesetting parameter, Target seal information can be generated in preset pattern according to typesetting parameter.
Specifically, the content based on step 205 explanation in embodiment illustrated in fig. 2, determines the typesetting ginseng of target seal information After number, each word of target seal information can be input into preset pattern according to the coordinate of target character and tangent line radian Symbol so that target seal information arc arrangement in preset pattern, while, it is possible to use display parameters are to target seal information Attribute is adjusted correspondingly, to generate desired target seal information in preset pattern.
In actual applications, such as translate, rotate, drawString method of java can be used in combination, The character of target seal information is generated on curvilinear figure one by one, and a target seal information for arc trend is finally presented.
2nd, typesetting pattern is horizontal typesetting
Specifically refer to Fig. 4, in the embodiment of the present invention in the generation method of E-seal typesetting parameter the second calculating side Method includes:
401st, type-setting mode is horizontal typesetting, and the number of characters according to display parameters and target seal information calculates target print The character length of chapter information;
In the present embodiment, if type-setting mode is horizontal typesetting, then character boundary, display that can be in display parameters The number of characters of character pitch and target seal information in parameter calculates the character length of target seal information.
Specifically, character duration * number of characters in the character length=character boundary of target seal information+(number of characters- 1) * character pitches.、
402nd, target character is in default figure in calculating target seal information according to character length, display parameters, pre-set dimension The coordinate of shape is typesetting parameter;
In the present embodiment, after being calculated the character length of target seal information, can be according to character length, display parameters In character boundary, pre-set dimension calculate target seal information in target character preset pattern coordinate be typesetting parameter.
Specifically, target character can be a character, such as bebinning character, or each in target seal information Character, it is assumed that target character is the bebinning character of target seal information, then can be according to the character in character length, display parameters It is typesetting parameter that size, pre-set dimension calculate bebinning character in the coordinate of preset pattern.For example, it is assumed that preset pattern is circle, Its radius is 2.5 centimetres, and the character length of the target seal information being calculated is 3 centimetres, if target seal information is with placed in the middle Mode is located in the X-axis with the central point of preset pattern as the origin of coordinates, i.e., from display parameters in determination target seal information The alignment thereof of character, the then coordinate that can determine target character is {-(character duration/2 in 3/2- character boundaries), 0 }
It is understood that in actual applications, except the calculation of described above, it is also possible to which combining target seal is believed Character is calculated the coordinate of target character with the back gauge in preset pattern sideline in breath, can also on the basis of X-axis line, according to Character is calculated the coordinate of target character with the distance of X-axis in target seal information, is not limited herein specifically.
Further, the content for being illustrated based on step 401 to step 402, in actual applications, if target seal packet Include the first seal information and the second seal information of horizontal typesetting, then the first seal can also be calculated by following manner The typesetting parameter of information and the second seal information:
Display parameters, the number of characters of the first seal information according to the first seal information, and the second seal information is aobvious Show parameter, the number of characters of the second seal information, the character length of the first seal information and the word of the second seal information are calculated respectively Symbol length;
Character length, the display parameters of the first seal information, pre-set dimension according to the first seal information calculate first and print First coordinate of first character of chapter information in preset pattern;
Display parameters according to the first coordinate, the character length of the second seal information, the second seal information calculate second and print Second coordinate of second character of chapter information in preset pattern;
Determine that the first coordinate and the second coordinate are typesetting parameter.
Specifically, the content based on step 401 explanation, it is possible, firstly, to calculate the character length of the first seal information respectively And second seal information character length, secondly, can with step 402 illustrate content, can calculate in advance the first seal letter First character of breath then, with reference to the first coordinate, can further calculate the second seal information in the first coordinate of preset pattern The second character preset pattern the second coordinate.For example, it is assumed that the first coordinate is the seat of bebinning character in the first seal information Mark (- 1.2,0), if the second seal information is located at the lower section of the first seal information, and is also arrangement placed in the middle in preset pattern, with The character row of the first seal information is away from being 0.2 centimetre, then when the second character is bebinning character in the second seal information, second Coordinate is {-(character duration/2 in the character boundary of character length/2- the second seal information of the second seal information) ,-(the Character height in the character boundary of character height/2+0.2+ the second seal information in the character boundary of one seal information/ 2) }, so as to after the first coordinate and the second coordinate is obtained, it may be determined that the first coordinate and the second coordinate are respectively the first seal The typesetting parameter of the typesetting parameter of information, the second seal information.
403rd, target seal information is generated in preset pattern according to typesetting parameter and display parameters.
In the present embodiment, existed according to target character in character length, display parameters, pre-set dimension calculating target seal information The coordinate of preset pattern be typesetting parameter after, target seal information can be generated in preset pattern according to typesetting parameter.
Specifically, the content based on step 205 explanation in embodiment illustrated in fig. 2, determines the typesetting ginseng of target seal information After number, each character of target seal information can be input into preset pattern according to the coordinate of target character so that target prints Chapter information horizontal arrangement in preset pattern, while, it is possible to use display parameters are carried out accordingly to the attribute of target seal information Adjustment, to generate desired target seal information in preset pattern.If additionally, target seal information includes horizontal row version First seal information and the second seal information, then can also be after corresponding first coordinate and the second coordinate be calculated, can be with First seal information and the second seal information are generated according to the first coordinate, the second coordinate respectively in preset pattern.
In actual applications, the such as drawString methods of java can be used in combination, the word of target seal information Symbol is generated on preset pattern one by one, and the target seal information being horizontally orientated to finally is presented.
It should be noted that the electronic invoice that the E-seal that existing electronics special invoice is used is generally ellipse is special Chapter, target seal information generally comprise enterprise name character information, duty paragraph character information, Invoice Seal character information these three Information, is specifically described below according to this application:
Fig. 5 is referred to, another embodiment of the generation method of E-seal includes in the embodiment of the present invention:
Step 501 in the present embodiment is identical with the step 101 in embodiment illustrated in fig. 1, and here is omitted.
502nd, ellipse of the generation with pre-set dimension in canvas interface;
In the present embodiment, after defining canvas interface, the ellipse with pre-set dimension can be generated in canvas interface.Its In, pre-set dimension can be oval major axis and short axle.
503rd, based on pre-set dimension, the typesetting parameter of enterprise name character information is calculated according to preset algorithm, and according to row Version parameter generates enterprise name character information in ellipse;
In the present embodiment, after ellipse of the generation with pre-set dimension in canvas interface, pre-set dimension can be based on, pressed The typesetting parameter of enterprise name character information is calculated according to preset algorithm, it is possible to which enterprise is generated in ellipse according to typesetting parameter Name character information.
Based on the content illustrated in embodiment illustrated in fig. 3, Fig. 6 is referred to, enterprise name character letter is generated in ellipse The specific method of breath can be:
1st, interior oval major semiaxis and semi-minor axis where enterprise name character information are calculated:According to enterprise's name in display parameters The character of title character information (prevents the character and elliptical coil weight in enterprise name character information with elliptical coil apart from A It is folded), with reference to known oval major axis and short axle, the curve map that camber line where enterprise name character information is formed can be calculated Shape, i.e., the major semiaxis C=of interior oval (because enterprise name character information need to be generated along ellipse inner side, therefore being referred to as interior oval) is (outward Transverse -2A)/2, semi-minor axis D=(outer ellipse short shaft -2A)/2;
2nd, the coordinate of each fixed point of arc length is preset in calculating on ellipse:Assuming that the default arc length is interior oval upper half Week, then by known interior oval major semiaxis C, the semi-perimeter starting point that can initialize interior ellipse is (- C, 0), by known major semiaxis Neighbor pixel is apart from E (presetted pixel point distance), it is known that the x coordinate of the interior oval next pixel of major semiaxis for (- C+E, 0) X=-C+E of the coordinate of the fixed point in, that is, corresponding on ellipse, point correspondence can be just calculated further according to oval normal equation Y-coordinate Y=(Math.sqrt ((1- (X*X)/Math.pow (C, 2)) * Math.pow (D, 2))), so as to draw it is interior ellipse on The coordinate of the fixed point;By cycle calculations, it is known that preset the coordinate (Xi, Yi) of each fixed point of arc length on interior ellipse;
3rd, the length of arc length is preset in calculating on ellipse:Assuming that the default arc length is the upper half on interior ellipse, by known Interior oval upper each fixed point coordinate (Xi, Yi), the air line distance=Math.sqrt of adjacent two fixed point can be calculated ((X1-X2) * (X1-X2)+(Y1-Y2) * (Y1-Y2)), it is all adjacent fixed in interior oval upper half to calculate by that analogy The air line distance of point, the air line distance of all consecutive points is added up, it is possible to calculate the approximate semi-perimeter of interior ellipse.Wherein, The length of enterprise name character information is approximate semi-perimeter;
4th, coordinate of each character on interior ellipse in enterprise name character information is calculated:According to known business name character Character boundary and interior oval semi-perimeter in number of characters, the display parameters of information, it is possible to calculate enterprise name character information In each character it is interior ellipse on target character spacing;The origin coordinates of character is in initialization enterprise name character information (- C, 0), with reference to character boundary, target word in interior oval major semiaxis, the number of characters of enterprise name character information, display parameters Symbol spacing, it is possible to calculate coordinate (Ni, Mi) of each character on interior ellipse in enterprise name character information;
5th, the tangent line radian of each character in enterprise name character information is calculated:Calculate each in enterprise name character information Tangent line radian=Math.atan (((D*D)/Mi-Mi)/Ni) of the character (Ni, Mi) in interior ellipse;
6th, enterprise is generated in ellipse according to the coordinate of each character in enterprise name character information and tangent line radian Name character information:Such as translate, rotate, drawString method of java are used in combination, enterprise name character Character in information is generated on interior ellipse one by one, and an enterprise name for half elliptic trend is finally presented.
Further, if the original character length of enterprise name character information is long, the semi-perimeter displaying on interior ellipse Not so much character, can be according to the character length of the enterprise name character information being calculated along with ellipse half cycle in approximate It is long, using elliptic coordinates point symmetry principle, other characters in enterprise name character information are mapped to interior oval lower half girth In coordinate, such as upper half girth coordinate points are (X, Y), then corresponding vertical lower half girth symmetric coordinates point is (X ,-Y).
504th, based on pre-set dimension, the typesetting parameter of duty paragraph character information is calculated according to preset algorithm, and join according to typesetting Number generates duty paragraph character information in ellipse;
In the present embodiment, after generating enterprise name character information in ellipse, pre-set dimension can be based on, according to default Algorithm calculates the typesetting parameter of duty paragraph character information, it is possible to duty paragraph character information is generated in ellipse according to typesetting parameter.
Based on the content illustrated in embodiment illustrated in fig. 4, Fig. 7 is referred to, enterprise name character letter is generated in ellipse The specific method of breath can be:
1st, the character length of duty paragraph character information is calculated:Duty paragraph character is calculated using the FontMetrics in java to believe The character length W of breath;
2nd, coordinate of the bebinning character of duty paragraph character information in ellipse is calculated:If duty paragraph character information is in ellipse In be centrally located, according to known character length W, and character height H, character duration M in character boundary in display parameters, Coordinate of the origin coordinates of duty paragraph character information in ellipse can be calculated for (- W/2+M/2,0);
3rd, the coordinate of the bebinning character according to duty paragraph character information generates duty paragraph character information in ellipse:Use DrawString methods, each character in duty paragraph character information is generated one by one.
505th, based on pre-set dimension, according to the typesetting parameter of preset algorithm calculating Invoice Seal character information, and according to Typesetting parameter generates Invoice Seal character information in ellipse;
In the present embodiment, after generating duty paragraph character information in ellipse, pre-set dimension can be based on, according to preset algorithm Calculate the typesetting parameter of Invoice Seal character information, it is possible to which Invoice Seal word is generated in ellipse according to typesetting parameter Symbol information.
Based on the content illustrated in embodiment illustrated in fig. 4, Fig. 8 is referred to, enterprise name character letter is generated in ellipse The specific method of breath can be:
1st, the character length of Invoice Seal character information is calculated:Invoice is calculated using the FontMetrics in java The character length W1 of special seal character information;
2nd, coordinate of the bebinning character of Invoice Seal character information in ellipse is calculated:If Invoice Seal character is believed Breath is centrally placed in the lower section of duty paragraph character information, and character row between duty paragraph character information and Invoice Seal character information away from It is 0, according to known character length W1, and character height H1, character duration M1 in character boundary in display parameters, with reference to The coordinate of the bebinning character of duty paragraph character information, can calculate the origin coordinates of Invoice Seal character information in ellipse Coordinate be (- W1/2+M1/2 ,-H/2-H1/2);
3rd, the coordinate of the bebinning character according to Invoice Seal character information generates Invoice Seal character in ellipse Information:Using drawString methods, each character in Invoice Seal character information is generated one by one.
It should be noted that the step 503, step 504, step 505 in the present embodiment are in oval generating process, Can also be further combined with corresponding display parameters respectively to enterprise name character information, duty paragraph character information, Invoice Seal Character information is adjusted correspondingly, and improves the adaptability of the E-seal.
It is understood that the step 503, step 504, step 505 in the present embodiment can also be performed in other sequences, For example, perform simultaneously, preset algorithm can be adjusted correspondingly according to actual needs, do not limited herein specifically.
For example, as shown in figure 9, enterprise name character information can be enterprise name, such as Heshan City's sand flat sunlight richness power business Business hotel, duty paragraph can be 44072519700101004001, with reference to the content that step 503 to step 505 is illustrated, wherein, enterprise Industry title may be located at the upper half of ellipse, and certain spacing is remained with oval sideline, and duty paragraph can be in ellipse Central horizontal axis on arrange, and Invoice Seal may be located at the lower section of duty paragraph and arranges between two parties.
506th, generation enterprise name character information, duty paragraph character information, Invoice Seal character are processed according to preset rules The ellipse of information, obtains electronic invoice special seal picture;
In the present embodiment, enterprise name character information, duty paragraph character information, Invoice Seal are generated in ellipse successively After character information, generation enterprise name character information, duty paragraph character information, Invoice Seal word can be processed according to preset rules The ellipse of symbol information, obtains electronic invoice special seal picture.
Specifically, the content based on step 206 explanation in embodiment illustrated in fig. 2, here is omitted for same section.
507th, electronic invoice special seal picture is exported.
Step 507 in the present embodiment is identical with the step 207 in embodiment illustrated in fig. 2, and here is omitted.
The generation method to the E-seal in the embodiment of the present invention is described above, below to the embodiment of the present invention In the generation system of E-seal be described, refer to Figure 10, the generation system one of E-seal in the embodiment of the present invention Individual embodiment includes:
Definition module 1001, for defining canvas interface;
First generation module 1002, for preset pattern of the generation with pre-set dimension in canvas interface;
Computing module 1003, for based on pre-set dimension, the typesetting parameter of target seal information being calculated according to preset algorithm;
Second generation module 1004, for generating target seal information in preset pattern according to typesetting parameter, obtains electricity Sub- seal picture.
Processing module 1005, the preset pattern for processing generation target seal information according to preset rules, obtains electronics Seal picture.
Further, in the present embodiment, system can also include:
Output module 1006, for exporting E-seal picture.
In some embodiments of the invention, computing module 1003, can further specifically for:
Obtain the typesetting pattern and display parameters of target seal information;
According to pre-set dimension, typesetting pattern and display parameters, the typesetting parameter of target seal information is calculated;
Wherein, display parameters include the back gauge between character types, character boundary, character pitch, character and preset pattern.
In some embodiments of the invention, on the one hand, the concrete application based on above-mentioned computing module 1003, computing module 1003, can also further specifically for:
Typesetting pattern is arc typesetting, target seal information place camber line is calculated according to pre-set dimension, display parameters and is formed Curvilinear figure in preset arc length length;
According to target character spacing, pre-set dimension, the word of the length, display parameters and target seal information of presetting arc length Symbol number, calculate target seal information in target character in preset pattern or the coordinate of curvilinear figure, according to target character spacing The length of default arc length, display parameters, number of characters are calculated, or target character spacing is character pitch;
The tangent line radian of target character in coordinate and target seal information is determined for typesetting parameter, according to tangent line radian Coordinate is calculated.
Specifically, the calculating of the length based on default arc length, computing module 1003 can also be specifically for:
The size ginseng of the curvilinear figure that the camber line according to where pre-set dimension, display parameters calculate target seal information is formed Number;
The coordinate of the pinpoint of arc length is preset in calculated curve figure according to dimensional parameters and presetted pixel point;
Coordinate according to pinpoint calculates the length of default arc length.
In some embodiments of the invention, on the other hand, based on the concrete application of above-mentioned computing module 1003, mould is calculated Block 1003, can also further specifically for:
Type-setting mode is horizontal typesetting, and the number of characters according to display parameters and target seal information calculates target seal letter The character length of breath;
Target character is in preset pattern in calculating target seal information according to character length, display parameters, pre-set dimension Coordinate is typesetting parameter.
Specifically, in some embodiments of the invention, based on the application of above-mentioned computing module 1003, system can also be wrapped Include:
Target seal information includes the first seal information and the second seal information of horizontal row version, and computing module 1003 is gone back Can be specifically for:
Display parameters, the number of characters of the first seal information according to the first seal information, and the second seal information is aobvious Show parameter, the number of characters of the second seal information, the character length of the first seal information and the word of the second seal information are calculated respectively Symbol length;
Character length, the display parameters of the first seal information, pre-set dimension according to the first seal information calculate first and print First coordinate of first character of chapter information in preset pattern;
Display parameters according to the first coordinate, the character length of the second seal information, the second seal information calculate second and print Second coordinate of second character of chapter information in preset pattern;
Determine that the first coordinate and the second coordinate are typesetting parameter.
Further, in some embodiments of the invention, the second generation module 1004, can also be specifically for:Root Target seal information is generated in preset pattern according to typesetting parameter and display parameters.
In some embodiments of the invention, processing module 1005, can be specifically for:
The preset pattern for generating target seal information is set to the picture compression form of background transparent, E-seal is obtained Picture.
It is understood that the concrete application scene based on E-seal, in the present embodiment, the first generation module 1002, Can be specifically for:
Ellipse of the generation with pre-set dimension in canvas interface;
Computing module 1003, can be specifically for:
Based on pre-set dimension, enterprise name character information, duty paragraph character information, invoice are calculated respectively according to preset algorithm special With the typesetting parameter of chapter character information;
Second generation module 1004, can be specifically for:
Enterprise name character information, duty paragraph character information, Invoice Seal word are generated in ellipse according to typesetting parameter Symbol information;
Processing module 1005, can be specifically for:
Generation enterprise name character information, duty paragraph character information, Invoice Seal character information are processed according to preset rules Preset pattern, obtain electronic invoice special seal picture;
Output module 1006, can be specifically for:
Output electronic invoice special seal picture.
It is apparent to those skilled in the art that, for convenience and simplicity of description, the system of foregoing description, The specific work process of device and unit, may be referred to the corresponding process in preceding method embodiment, will not be repeated here.
In several embodiments provided herein, it should be understood that disclosed system, apparatus and method can be with Realize by another way.For example, device embodiment described above is only schematical, for example, the unit Divide, only a kind of division of logic function there can be other dividing mode when actually realizing, for example multiple units or component Can combine or be desirably integrated into another system, or some features can be ignored, or do not perform.It is another, it is shown or The coupling each other for discussing or direct-coupling or communication connection can be the indirect couplings of device or unit by some interfaces Close or communicate to connect, can be electrical, mechanical or other forms.
The unit that is illustrated as separating component can be or may not be it is physically separate, it is aobvious as unit The part for showing can be or may not be physical location, you can with positioned at a place, or can also be distributed to multiple On NE.Some or all of unit therein can be according to the actual needs selected to realize the mesh of this embodiment scheme 's.
In addition, during each functional unit in each embodiment of the invention can be integrated in a processing unit, it is also possible to It is that unit is individually physically present, it is also possible to which two or more units are integrated in a unit.Above-mentioned integrated list Unit can both be realized in the form of hardware, it would however also be possible to employ the form of SFU software functional unit is realized.
If the integrated unit is to realize in the form of SFU software functional unit and as independent production marketing or use When, can store in a computer read/write memory medium.Based on such understanding, technical scheme is substantially The part for being contributed to prior art in other words or all or part of the technical scheme can be in the form of software products Embody, the computer software product is stored in a storage medium, including some instructions are used to so that a computer Equipment (can be personal computer, server, or network equipment etc.) performs the complete of each embodiment methods described of the invention Portion or part steps.And foregoing storage medium includes:USB flash disk, mobile hard disk, read-only storage (ROM, Read-Only Memory), random access memory (RAM, Random Access Memory), magnetic disc or CD etc. are various can store journey The medium of sequence code.
The above, the above embodiments are merely illustrative of the technical solutions of the present invention, rather than its limitations;Although with reference to preceding Embodiment is stated to be described in detail the present invention, it will be understood by those within the art that:It still can be to preceding State the technical scheme described in each embodiment to modify, or equivalent is carried out to which part technical characteristic;And these Modification is replaced, and does not make the spirit and scope of the essence disengaging various embodiments of the present invention technical scheme of appropriate technical solution.

Claims (16)

1. a kind of generation method of E-seal, it is characterised in that including:
Define canvas interface;
Preset pattern of the generation with pre-set dimension in the canvas interface;
Based on the pre-set dimension, the typesetting parameter of target seal information is calculated according to preset algorithm;
The target seal information is generated in the preset pattern according to the typesetting parameter;
The preset pattern of the generation target seal information is processed according to preset rules, E-seal picture is obtained.
2. the generation method of E-seal according to claim 1, it is characterised in that described based on the pre-set dimension, The typesetting parameter for calculating target seal information according to preset algorithm includes:
Obtain the typesetting pattern and display parameters of target seal information;
According to the pre-set dimension, the typesetting pattern and the display parameters, the typesetting ginseng of the target seal information is calculated Number;
Wherein, the display parameters are included between character types, character boundary, character pitch, character and the preset pattern Back gauge, alignment mode, character row away from.
3. the generation method of E-seal according to claim 2, it is characterised in that it is described according to the pre-set dimension, The typesetting pattern and the display parameters, the typesetting parameter for calculating the target seal information include:
The typesetting pattern is arc typesetting, and the target seal information is calculated according to the pre-set dimension, the display parameters The length of arc length is preset in the curvilinear figure that place camber line is formed;
According to target character spacing, the pre-set dimension, the length of the default arc length, the display parameters and the target The number of characters of seal information, calculates target character in the target seal information in the preset pattern or the curvilinear figure Coordinate, the target character spacing is to be calculated according to the length of the default arc length, the display parameters, the number of characters Arrive, or the target character spacing is the character pitch;
The tangent line radian of target character in the coordinate and the target seal information is determined for typesetting parameter, the tangent line arc Degree is to be calculated according to the coordinate.
4. the generation method of E-seal according to claim 3, it is characterised in that it is described according to the pre-set dimension, The length that the display parameters calculate default arc length in the curvilinear figure that camber line where the target seal information is formed includes:
The curvilinear figure that the camber line according to where the pre-set dimension, the display parameters calculate the target seal information is formed Dimensional parameters;
The seat of the pinpoint of default arc length in the curvilinear figure is calculated according to the dimensional parameters and presetted pixel point distance Mark;
Coordinate according to the pinpoint calculates the length of the default arc length.
5. the generation method of E-seal according to claim 2, it is characterised in that it is described according to the pre-set dimension, The typesetting pattern and the display parameters, the typesetting parameter for calculating the target seal information include:
The type-setting mode is horizontal typesetting, and the number of characters according to the display parameters and the target seal information calculates institute State the character length of target seal information;
According to target character in the character length, the display parameters, the pre-set dimension calculating target seal information It is typesetting parameter in the coordinate of the preset pattern.
6. the generation method of E-seal according to claim 5, it is characterised in that methods described also includes:
The target seal information includes the first seal information and the second seal information of horizontal row version, described according to the display The character length that the number of characters of parameter and the target seal information calculates the target seal information includes:
Display parameters, the number of characters of the first seal information according to the first seal information, and second seal The number of characters of the display parameters of information, the second seal information, calculate respectively the first seal information character length and The character length of the second seal information;
It is described that the target seal information is calculated described according to the character length, the display parameters, the pre-set dimension Character origin coordinates in preset pattern includes for typesetting parameter:
Character length, the display parameters of the first seal information according to the first seal information, the pre-set dimension meter Calculate first coordinate of first character in the preset pattern of the first seal information;
According to first coordinate, the character length of the second seal information, the second seal information display parameters meter Calculate second coordinate of second character in the preset pattern of the second seal information;
Determine that first coordinate and second coordinate are typesetting parameter.
7. the generation method of E-seal according to any one of claim 1 to 6, it is characterised in that described according to pre- If rule process generates the preset pattern of the target seal information, obtaining E-seal picture includes:
The preset pattern for generating the target seal information is set to the picture compression form of background transparent, E-seal is obtained Picture.
8. the generation method of E-seal according to claim 1, it is characterised in that the E-seal is electronic invoice Special seal, the preset pattern of the generation with pre-set dimension in the canvas interface includes:
Ellipse of the generation with pre-set dimension in the canvas interface;
It is described based on the pre-set dimension, the typesetting parameter for calculating target seal information according to preset algorithm includes:
Based on the pre-set dimension, enterprise name character information, duty paragraph character information, invoice are calculated respectively according to preset algorithm special With the typesetting parameter of chapter character information;
It is described that the target seal information is generated in the preset pattern according to the typesetting parameter, obtain E-seal picture Including:
The enterprise name character information, duty paragraph character information, invoice are generated in the ellipse according to the typesetting parameter Special seal character information;
The preset pattern that the generation target seal information is processed according to preset rules, obtaining E-seal picture includes:
The generation enterprise name character information, the duty paragraph character information, the Invoice Seal are processed according to preset rules The preset pattern of character information, obtains electronic invoice special seal picture.
9. the generation system of a kind of E-seal, it is characterised in that including:
Definition module, for defining canvas interface;
First generation module, for preset pattern of the generation with pre-set dimension in the canvas interface;
Computing module, for based on the pre-set dimension, the typesetting parameter of target seal information being calculated according to preset algorithm;
Second generation module, for generating the target seal information in the preset pattern according to the typesetting parameter, obtains To E-seal picture;
Processing module, the preset pattern for processing the generation target seal information according to preset rules, obtains E-seal Picture.
10. the generation system of E-seal according to claim 9, it is characterised in that the computing module is specific to use In:
Obtain the typesetting pattern and display parameters of target seal information;
According to the pre-set dimension, the typesetting pattern and the display parameters, the typesetting ginseng of the target seal information is calculated Number;
Wherein, the display parameters are included between character types, character boundary, character pitch, character and the preset pattern Back gauge, alignment mode, character row away from.
The generation system of 11. E-seals according to claim 10, it is characterised in that the computing module is also specific For:
The typesetting pattern is arc typesetting, and the target seal information is calculated according to the pre-set dimension, the display parameters The length of arc length is preset in the curvilinear figure that place camber line is formed;
According to target character spacing, the pre-set dimension, the length of the default arc length, the display parameters and the target The number of characters of seal information, calculates target character in the target seal information in the preset pattern or the curvilinear figure Coordinate, the target character spacing is to be calculated according to the length of the default arc length, the display parameters, the number of characters Arrive, or the target character spacing is the character pitch;
The tangent line radian of target character in the coordinate and the target seal information is determined for typesetting parameter, the tangent line arc Degree is to be calculated according to the coordinate.
The generation system of 12. E-seals according to claim 11, it is characterised in that the computing module is also specific For:
The curvilinear figure that the camber line according to where the pre-set dimension, the display parameters calculate the target seal information is formed Dimensional parameters;
The seat of the pinpoint of default arc length in the curvilinear figure is calculated according to the dimensional parameters and presetted pixel point distance Mark;
Coordinate according to the pinpoint calculates the length of the default arc length.
The generation system of 13. E-seals according to claim 10, it is characterised in that the computing module is specific to use In:
The type-setting mode is horizontal typesetting, and the number of characters according to the display parameters and the target seal information calculates institute State the character length of target seal information;
According to target character in the character length, the display parameters, the pre-set dimension calculating target seal information It is typesetting parameter in the coordinate of the preset pattern.
The generation system of 14. E-seals according to claim 13, it is characterised in that the system also includes:
The target seal information includes the first seal information and the second seal information of horizontal row version, and the computing module is gone back Specifically for:
Display parameters, the number of characters of the first seal information according to the first seal information, and second seal The number of characters of the display parameters of information, the second seal information, calculate respectively the first seal information character length and The character length of the second seal information;
Character length, the display parameters of the first seal information according to the first seal information, the pre-set dimension meter Calculate first coordinate of first character in the preset pattern of the first seal information;
According to first coordinate, the character length of the second seal information, the second seal information display parameters meter Calculate second coordinate of second character in the preset pattern of the second seal information;
Determine that first coordinate and second coordinate are typesetting parameter.
The generation system of 15. E-seal according to any one of claim 9 to 14, it is characterised in that the treatment Module, specifically for:
The preset pattern for generating the target seal information is set to the picture compression form of background transparent, E-seal is obtained Picture.
The generation system of 16. E-seals according to claim 9, it is characterised in that if the E-seal is electronics Invoice Seal, then first generation module, specifically for:
Ellipse of the generation with pre-set dimension in the canvas interface;
The computing module, specifically for:
Based on the pre-set dimension, enterprise name character information, duty paragraph character information, invoice are calculated respectively according to preset algorithm special With the typesetting parameter of chapter character information;
Second generation module, specifically for:
The enterprise name character information, duty paragraph character information, invoice are generated in the ellipse according to the typesetting parameter Special seal character information;
The processing module, specifically for:
The generation enterprise name character information, the duty paragraph character information, the Invoice Seal are processed according to preset rules The preset pattern of character information, obtains electronic invoice special seal picture.
CN201611091169.8A 2016-12-01 2016-12-01 The generation method and system of a kind of E-seal Pending CN106779590A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201611091169.8A CN106779590A (en) 2016-12-01 2016-12-01 The generation method and system of a kind of E-seal

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201611091169.8A CN106779590A (en) 2016-12-01 2016-12-01 The generation method and system of a kind of E-seal

Publications (1)

Publication Number Publication Date
CN106779590A true CN106779590A (en) 2017-05-31

Family

ID=58913494

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201611091169.8A Pending CN106779590A (en) 2016-12-01 2016-12-01 The generation method and system of a kind of E-seal

Country Status (1)

Country Link
CN (1) CN106779590A (en)

Cited By (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108109187A (en) * 2017-12-04 2018-06-01 泰康保险集团股份有限公司 E-seal generation method, device and electronic equipment
CN109733050A (en) * 2019-02-19 2019-05-10 大连声鹭科技有限公司 A kind of self-service self-service Zhang Fangfa processed that puts on record
CN110717738A (en) * 2019-10-12 2020-01-21 珠海优特物联科技有限公司 Seal management method and device and electronic equipment
CN110751139A (en) * 2019-09-16 2020-02-04 深圳市国信合成科技有限公司 Invoice seal identification method and device, computer equipment and storage medium
CN111881653A (en) * 2020-07-20 2020-11-03 江西金格科技股份有限公司 Method for positioning impressions in batch PDF (Portable document Format) documents
CN112035041A (en) * 2020-08-31 2020-12-04 北京字节跳动网络技术有限公司 Image processing method and device, electronic equipment and storage medium
CN112529643A (en) * 2020-12-21 2021-03-19 航天信息股份有限公司 Electronic invoice processing method and device, storage medium and electronic equipment
CN113033143A (en) * 2020-11-02 2021-06-25 成都红鼎云签科技有限公司 Automatic typesetting method for seal image data
CN113934335A (en) * 2021-09-27 2022-01-14 深圳法大大网络科技有限公司 Electronic seal generation method and device, computer equipment and storage medium
CN116704541A (en) * 2023-08-09 2023-09-05 易签链(深圳)科技有限公司 Method for manufacturing and using controlled signed electronic official seal

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103021006A (en) * 2011-09-22 2013-04-03 张国俊 Method for manufacturing electronic seal pattern model
CN104463553A (en) * 2013-09-22 2015-03-25 天津书生投资有限公司 Implementation method for dynamic electronic seal
CN104537318A (en) * 2014-12-30 2015-04-22 北京中科江南软件有限公司 Dynamic electronic seal generating system

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103021006A (en) * 2011-09-22 2013-04-03 张国俊 Method for manufacturing electronic seal pattern model
CN104463553A (en) * 2013-09-22 2015-03-25 天津书生投资有限公司 Implementation method for dynamic electronic seal
CN104537318A (en) * 2014-12-30 2015-04-22 北京中科江南软件有限公司 Dynamic electronic seal generating system

Cited By (14)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108109187A (en) * 2017-12-04 2018-06-01 泰康保险集团股份有限公司 E-seal generation method, device and electronic equipment
CN109733050A (en) * 2019-02-19 2019-05-10 大连声鹭科技有限公司 A kind of self-service self-service Zhang Fangfa processed that puts on record
CN110751139A (en) * 2019-09-16 2020-02-04 深圳市国信合成科技有限公司 Invoice seal identification method and device, computer equipment and storage medium
CN110717738A (en) * 2019-10-12 2020-01-21 珠海优特物联科技有限公司 Seal management method and device and electronic equipment
CN111881653A (en) * 2020-07-20 2020-11-03 江西金格科技股份有限公司 Method for positioning impressions in batch PDF (Portable document Format) documents
CN112035041B (en) * 2020-08-31 2022-05-31 北京字节跳动网络技术有限公司 Image processing method and device, electronic equipment and storage medium
CN112035041A (en) * 2020-08-31 2020-12-04 北京字节跳动网络技术有限公司 Image processing method and device, electronic equipment and storage medium
US11776209B2 (en) 2020-08-31 2023-10-03 Beijing Bytedance Network Technology Co., Ltd. Image processing method and apparatus, electronic device, and storage medium
CN113033143A (en) * 2020-11-02 2021-06-25 成都红鼎云签科技有限公司 Automatic typesetting method for seal image data
CN112529643A (en) * 2020-12-21 2021-03-19 航天信息股份有限公司 Electronic invoice processing method and device, storage medium and electronic equipment
CN112529643B (en) * 2020-12-21 2024-05-28 航天信息股份有限公司 Electronic invoice processing method and device, storage medium and electronic equipment
CN113934335A (en) * 2021-09-27 2022-01-14 深圳法大大网络科技有限公司 Electronic seal generation method and device, computer equipment and storage medium
CN116704541A (en) * 2023-08-09 2023-09-05 易签链(深圳)科技有限公司 Method for manufacturing and using controlled signed electronic official seal
CN116704541B (en) * 2023-08-09 2023-10-27 易签链(深圳)科技有限公司 Method for manufacturing and using controlled signed electronic official seal

Similar Documents

Publication Publication Date Title
CN106779590A (en) The generation method and system of a kind of E-seal
CN104239617B (en) Thermodynamic chart shows method and device
CN103617220B (en) Method and device for implementing mobile terminal 3D (three dimensional) model
CN106067185A (en) A kind of threedimensional model processing method and processing device
CN102156688B (en) Character transforming effect processing method and device
CN104900204B (en) Logic frame overlapping device and method based on FPGA
CN104658033A (en) Method and device for global illumination rendering under multiple light sources
CN107850985A (en) Halftoning is carried out to the object data of three-dimensional body
CN102360505B (en) Graphical verification code generation method
CN104899889B (en) A kind of video vectorization method based on tetrahedral grid
CN112002021A (en) Aggregation dotting visualization method and device based on unity3d
US20060202991A1 (en) System and a method for drawing development figures and a computer readable medium thereof
CN101789030A (en) Virtual geographical environment (VGE) symbolic model and map symbol sharing system and method based on same
CN101833592A (en) Graphic design method for hand-made paper craft
CN107203961A (en) A kind of method and electronic equipment of migration of expressing one's feelings
CN107562886A (en) A kind of method and device for generating photomap
CN106126214A (en) The determination method and device of text color on a kind of interface
CN109189524A (en) Image resource generation method and device
CN103839217A (en) Watermark image realization method
CN108171766A (en) A kind of image generating method that there are outline strokes and correct
CN106155991A (en) The preview graph of a kind of font packet generates method and system
CN109493401B (en) PowerPoint generation method, device and electronic equipment
CN109242949B (en) Intelligent 3D printing system and method
CN101930617B (en) Method for generating primitive pictures
CN102074030B (en) A kind of acquisition, the method for editing self-defined figure and subtitle graphic manufacturing system

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
RJ01 Rejection of invention patent application after publication
RJ01 Rejection of invention patent application after publication

Application publication date: 20170531