CN101847138A - Method for fine adjustment of strokes of font - Google Patents
Method for fine adjustment of strokes of font Download PDFInfo
- Publication number
- CN101847138A CN101847138A CN200910129839A CN200910129839A CN101847138A CN 101847138 A CN101847138 A CN 101847138A CN 200910129839 A CN200910129839 A CN 200910129839A CN 200910129839 A CN200910129839 A CN 200910129839A CN 101847138 A CN101847138 A CN 101847138A
- Authority
- CN
- China
- Prior art keywords
- font
- stroke
- strokes
- stroke data
- horizontal
- 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
Links
Images
Landscapes
- Controls And Circuits For Display Device (AREA)
Abstract
The invention relates to a method for the fine adjustment of strokes of a font, which enables a complicated font not to produce connected fuzzy strokes after being zoomed. In the process of producing a font, a font engine firstly calculates missing space for two adjacent strokes of the font based on stroke data of the font; then, the font engine obtains the fine adjustment information of the font, and calculates optimal space allocation based on the missing space and the fine adjustment information to produce a stroke fine adjustment value of the font; and finally, the font is outputted based on the stroke data of the font and the stroke fine adjustment value.
Description
Technical field
The present invention relates to a kind of method that produces font, relate in particular to a kind of method of finely tuning the stroke of font.
Background technology
Scalable font because of the restriction in space, and produces the fuzzy situation of stroke when producing small character, cause the bad of font.The fine setting technology major part of font because the number of words of Irving's font is few, can add a large amount of refinement information, to produce high-quality Irving's font with Ou Yuwei master (as the fine setting technology of TrueType font) at present.Yet if use this class technology on Chinese font, just very inapplicable, except meeting expends many manpowers, the data volume of font also can be too big, is not suitable for embedded system.
Please refer to Fig. 1, Fig. 1 produces the process flow diagram of font for prior art.The method that prior art produces font comprises the following step:
Step 110: the stroke data of yi word pattern is provided, and stroke data comprises the stroke identification code of each stroke and the reference position of each stroke;
Step 120: export this font some strokes;
Step 130: whether all strokes of judging this font are exported, if all strokes are exported, then carry out steps 150, if also have stroke not export, then carry out steps 140;
Step 140: the stroke data according to this font produces stroke, then carry out step 120;
Step 150: finish this font of output.
Please refer to Fig. 2, produce the fuzzy synoptic diagram of stroke when Fig. 2 is prior art convergent-divergent font.Font " storehouse " 200 has comprised six horizontal pens 1~6, and font is when convergent-divergent, and because of the restriction in space, the stroke of font can be connected together, and produces the fuzzy situation of stroke.When the horizontal stroke of font straight pen the more, and font is contracted more hour, the situation that stroke is fuzzy is just more serious.In addition, when font was exaggerated, the width of stroke also amplified thereupon, so when font is exaggerated, still exist the problem that insufficient space links to each other stroke.Size in font " storehouse " 200 is 12 * 12 o'clock, horizontal pen has 3 places to link to each other, in size is 13 * 13 o'clock, horizontal pen has 2 places to link to each other, and is 14 * 14 o'clock in size, and horizontal pen has 1 place to link to each other, in size is 15 * 15 o'clock, horizontal pen has 1 place to link to each other, and is 16 * 16 o'clock in size, and horizontal pen has 1 place to link to each other.
From the above, produce scalable font, when being scaled the font of big or small 12x12 of being or 16x16 etc. with prior art, because of the restriction in space, the stroke of font can be connected together, and produces the fuzzy situation of stroke, the bad that causes font causes the obstacle in the reading.
Summary of the invention
Therefore, a purpose of the present invention is to provide a kind of method of finely tuning the stroke of font, to solve the above problems.
The invention provides a kind of method of finely tuning the stroke of font, comprise: the stroke data that yi word pattern is provided; Calculate the space that adjacent two strokes of this font are lacked according to this stroke data; Obtain the refinement information of this font; Calculate the optimal spatial distribution according to this space that lacks and this refinement information, to produce the stroke trim values of this font; And export this font according to the stroke data and the stroke trim values of this font.
Description of drawings
Fig. 1 produces the process flow diagram of font for prior art.
When being prior art convergent-divergent font, Fig. 2 produces the fuzzy synoptic diagram of stroke.
Fig. 3 finely tunes the process flow diagram of method of the stroke of font for the present invention.
Fig. 4 is the synoptic diagram of the stroke data of font " pasture ".
Fig. 5 is the synoptic diagram that font " storehouse " is scaled big or small 12x12.
Fig. 6 is the table of comparisons of horizontal stroke trim values of font " storehouse ".
Fig. 7 is 12 * 12 sizes of font " storehouse " and the table of comparisons of a horizontal stroke position of 256 * 256 sizes.
Fig. 8 divides into groups to finely tune the process flow diagram of method of a horizontal stroke stroke of font for the present invention.
Fig. 9 is the synoptic diagram of an embodiment of a horizontal stroke stroke of grouping fine setting font.
Figure 10 is the synoptic diagram that subtracts the routine word of pen rule.
Figure 11 is the synoptic diagram of various fonts.
Figure 12 is the synoptic diagram of the non-font of being made up of stroke " two " the method according to this invention fine setting font.
[main element symbol description]
110~150 steps
200,500,510,520,710 fonts " storehouse "
1~6 stroke
310~390 steps
400 fonts " pasture "
401~405 strokes
810~890 steps
910 fonts " prison "
920 radicals " speech "
931,932 horizontal pens
941 radicals " mouth "
942 radicals " in "
943 radicals " field "
944 radicals " order "
951~954 various fonts
960,970 fonts " two "
961~967,971~977 horizontal pens
Embodiment
Please refer to Fig. 3, Fig. 3 finely tunes the process flow diagram of the stroke of font for the present invention.In the font of being made up of stroke, the stroke data of each font comprises the identification code of each stroke and the reference position of each stroke, and the present invention is by adding simple refinement information in stroke data.Therefore, when font engine (font engine) when producing this font according to stroke data, can adjust the stroke space of this font according to this refinement information, make complicated font behind convergent-divergent, also can not produce continuous fuzzy strokes, have the font of high-quality stroke with generation.The method that the present invention finely tunes the stroke of font comprises the following step:
Step 310: the stroke data of yi word pattern is provided, and stroke data comprises the stroke identification code of each stroke and the reference position of each stroke;
Step 320: calculate the space that adjacent two strokes of this font are lacked according to this stroke data, adjacent two strokes comprise adjacent two horizontal pen and adjacent two straight pens, when adjacent two strokes link to each other, represent to lack a mikey between these adjacent two strokes;
Step 330: the refinement information that obtains this font, writing down the spendable fine setting instruction of this font in the refinement information, for example, the fine setting instruction " delete " that merges the fine setting instruction " merge " of two strokes and delete a stroke can produce two mikeys, and the fine setting instruction of fine setting instruction " movedown " that a stroke is moved down and fine setting instruction " move up " that a stroke is moved up can produce a mikey;
Step 340: according to stroke the optimal spatial of the space that lacked and this refinement information position that calculates this each stroke of font distribute;
Step 350: the stroke trim values that produces each stroke of this font;
Step 360: export this font some strokes;
Step 370: whether all strokes of judging this font are exported, if all strokes are exported, then carry out steps 390, if also have stroke not export, then carry out steps 380;
Step 380: stroke data and stroke trim values according to this font produce stroke, then carry out steps 360;
Step 390: finish this font of output.
According to step 310, the stroke data of font comprises the stroke identification code of each stroke and the reference position of each stroke.When the font engine produces font according to the stroke data of font, obtain the stroke data of desire output font in regular turn, as shown in the table:
Please refer to Fig. 4, Fig. 4 is the synoptic diagram of the stroke data of font " pasture " 400.Font " pasture " 400 comprises first stroke 401 to the 5th strokes 405, and circle is represented the starting point of stroke, and the stroke data of font " pasture " 400 is as shown in the table:
|
The stroke identification code | Starting point |
The |
??612 | ??(72,11) |
The |
??7661 | ??(52,55) |
The |
??3 | ??(52,132) |
|
The stroke identification code | Starting point |
The |
??90 | ??(108,94) |
The |
??2337 | ??(52,94) |
Please refer to Fig. 5 to Fig. 7, Fig. 5 is the synoptic diagram that font " storehouse " 500 is scaled big or small 12x12, Fig. 6 is the table of comparisons of horizontal stroke trim values of font " storehouse " 500, and Fig. 7 is 12 * 12 sizes of font " storehouse " 500 and the table of comparisons of a horizontal stroke position of 256 * 256 sizes.In the embodiment of Fig. 5 to Fig. 7, finely tune the method for the stroke of font with font " storehouse " 500 explanation the present invention.As shown in Figure 5, font " storehouse " 510 is scaled the size of 12x12 according to prior art, 520 the method according to this invention of font " storehouse " are scaled the size of 12x12, clearly, font " storehouse " 520 has been improved the fuzzy strokes that horizontal pen 1,2,3 links to each other and horizontal pen 4,5 links to each other of font " storehouse " 510.According to step 320,, represent that this adjacent two horizontal pen for linking to each other, so the horizontal pen 1,2,3 of font " storehouse " 510 links to each other and horizontal pen 4,5 links to each other, has lacked three mikeys when the position of adjacent two horizontal pens is a consecutive hours.According to step 330, the refinement information of font " storehouse " 500 comprises fine setting instruction " move down ", fine setting instruction " move up " and fine setting instruction " merge ".Wherein, horizontal pen 4,5 can utilize fine setting instruction " merge " to merge into a horizontal pen, to produce two mikeys, subtract a rule will illustrate as after.In addition, horizontal pen 6 can utilize fine setting instruction " move down " to move down, to produce a mikey.Therefore, font " storehouse " 510 utilizes fine setting instruction " merge " to add that fine setting instruction " move down " produces three mikeys.
According to step 340 and step 350, calculate the optimal spatial of the position of horizontal pen 1 to 6 and distribute.As shown in Figure 6, horizontal pen 1 remains on Y4, and horizontal pen 2 moves on to Y6 by Y5, and horizontal pen 3 moves on to Y8 by Y6, and horizontal pen 4 moves on to Y10 by Y8, and horizontal pen 5 moves on to Y10 by Y9, and horizontal pen 6 moves on to Y12 by Y11.Therefore, the stroke trim values of font " storehouse " 520 is (0,1,2,2,1,1).To step 390, the font engine can be according to the stroke data and the stroke trim values output font " storehouse " 520 of font " storehouse " 500 according to step 360.In addition, as shown in Figure 7, horizontal pen 1 to the 6 process method of the present invention of font " storehouse " 500 corresponds to the position of font " storehouse " 520, and other strokes of font " storehouse " 500 will correspond to the position of font " storehouse " 520 according to the position of font " storehouse " 710.For example, in the stroke of the Y156 to Y185 of font " storehouse " 710, will correspond to the Y10 in " storehouse " 520.
Please refer to Fig. 8 and Fig. 9, Fig. 8 divides into groups to finely tune the process flow diagram of a horizontal stroke stroke of font for the present invention, and Fig. 9 is the synoptic diagram of an embodiment of a horizontal stroke stroke of grouping fine setting font.As shown in Figure 9, the part that font " prison " 910 needs most fine setting is a horizontal stroke stroke of radical " speech " 920, but if horizontal stroke pen 931,932 is finely tuned with radical " speech " 920, then horizontal pen 931,932 can be to radical " speech " 920 generation interference, as (A) partly shown in.The method that the present invention finely tunes a horizontal stroke stroke of font also comprises the following step:
Step 810: beginning;
Step 820: a next horizontal stroke that obtains yi word pattern;
Step 830: judge whether this horizontal stroke stroke is the last horizontal stroke of this a font stroke;
Step 840: should a horizontal stroke stroke and the stroke of a grouping compare, with the overlapping part of the stroke of finding out this horizontal stroke stroke and this grouping;
Step 850: whether the overlapping part of judging two strokes is greater than a preset value, if the part that overlaps then carry out step 860 greater than this preset value, if the part that overlaps is not more than this preset value, then carry out step 870;
Step 860: this horizontal stroke is added the grouping that overlapping is arranged;
Step 870: increase a new grouping;
Step 880: the grouping of the horizontal stroke of arrangement, every group is arranged according to a horizontal stroke number;
Step 890: finish.
According to step 840, a horizontal stroke stroke of radical " speech " 920 will form one first grouping, and horizontal stroke stroke of horizontal pen 931 and this first grouping part that do not overlap is so can set up one second grouping.Horizontal pen 932 has the overlapping part with the second horizontal pen of radical " speech " 920, but the part that should overlap is less than preset value, so horizontal pen 932 also can be set up one the 3rd grouping.Therefore, the horizontal pen of font " prison " 910 is divided into three groups of processing, and the horizontal pen of radical " speech " 920 can finely not tuned with horizontal pen 931,932, can obtain preferable result, shown in (B) part.
Please refer to Figure 10, Figure 10 is the synoptic diagram that subtracts the routine word of pen rule.The present invention is by adding simple refinement information in stroke data, so the font engine when producing font, can be adjusted the stroke space of this font according to refinement information, wherein refinement information is writing down the spendable fine setting instruction of this font.Yet when adding refinement information in the stroke data of yi word pattern, this font must meet and subtracts the pen rule, just can add the fine setting instruction of a stroke of two strokes that merge font or deletion font, instructs " delete " as fine setting instruction " merge " and fine setting.As shown in figure 10 three can subtract the radicals of pen, include radical " mouth " 941 in the font, and engaging with the horizontal stroke of the following horizontal pen of radical " mouth " 941 and below is one; Include in the font radical " in " 942, with radical " in " 942 go up horizontal pen engages with the horizontal pen of top be one or with radical " in " 942 following horizontal pen and the horizontal stroke of below engage is one; Include radical " field " 943 in the font, engaging with the horizontal pen of top with the horizontal pen of going up of radical " field " 943 is one or to engage with the horizontal stroke of the following horizontal pen of radical " field " 943 and below be one.
Please refer to Figure 11, Figure 11 is the synoptic diagram of various fonts.In the above-described embodiments, with horizontal method of font " storehouse " 500 explanation fine setting fonts, same method also can be used for adjusting the straight pen of font, shown in font " just " 951.The method that the present invention finely tunes the stroke of font can be calculated this font according to the stroke data of font in space that adjacent two strokes of vertical direction and horizontal direction are lacked, adjust the allocation of space of the horizontal pen of font according to the space that vertical direction lacked, adjust the allocation of space of the straight pen of font according to the space that horizontal direction lacked.In addition, GTG word or other font also can utilize method of the present invention to finely tune.For example, 952 curve or oblique lines at non-horizontal stroke pen or straight pen of GTG word use the GTG effects, as long as horizontal stroke pen or straight pen are treated as single GTG, just can utilize method of the present invention to finely tune basically.In addition, the method for the stroke of fine setting font of the present invention also can be used for simplified font 953 and Japan word 954.
Please refer to Figure 12, Figure 12 is the synoptic diagram of the non-font of being made up of stroke " two " 960 the method according to this invention fine setting font.Font " two " 960 are by the formed font of the housing of closed curve, yet the font engine can be judged seven horizontal pens 961~967 of font " two " 960 easily.According to subtracting pen rule, include radical " order " 944 in the font, engaging with the horizontal pen of horizontal pen in radical " order " 944 and top or below is one, or the second horizontal pen in the middle of the radical " order " 944 is removed, during first horizontal stroke is put.Therefore, when the non-font of being made up of stroke " two " 960 is scaled font " two " 970, seven horizontal pens 961~967 that the font engine had before broken and font " two " 960, again according to subtracting the pen rule, use fine setting instruction " merge " that stroke 963 and stroke 964 are merged into horizontal pen 974, the optimal spatial that calculates the position of six horizontal pens 971~977 is at last distributed, and produces font " two " 970.
In sum, the invention provides a kind of method of finely tuning the stroke of font, make complicated font behind convergent-divergent, can not produce continuous fuzzy strokes.When producing yi word pattern, the yi word pattern engine at first calculates the space that adjacent two strokes of this font are lacked according to the stroke data of this font.Then, this font engine is obtained the refinement information of this font, and calculates the optimal spatial distribution according to this space that lacks and this refinement information, to produce the stroke trim values of this font.At last, export this font according to the stroke data and the stroke trim values of this font.The present invention finely tunes the method for stroke of font by adding simple stroke trim values, not only can be used for the font be made up of stroke, and produces the font with high-quality stroke.In addition, method of the present invention also can be used for the non-font of being made up of stroke, and by judging the horizontal pen or the straight pen of font, the method according to this invention is finely tuned the horizontal pen of font or the position of straight pen again, improves the quality of font.
The above only is the preferred embodiments of the present invention, and all equalizations of doing according to claims of the present invention change and modify, and all should belong to covering scope of the present invention.
Claims (13)
1. method of finely tuning the stroke of font comprises:
The stroke data of yi word pattern is provided;
Calculate the space that adjacent two strokes of this font are lacked according to this stroke data;
Obtain the refinement information of this font;
Calculate the optimal spatial distribution according to this space that lacks and this refinement information, to produce the stroke trim values of this font; And
Stroke data and stroke trim values according to this font are exported this font.
2. the method for claim 1 wherein provides the stroke data of this font to comprise:
The stroke identification code of each stroke of this font is provided; And
The reference position of each stroke of this font is provided.
3. the method for claim 1, wherein the space that adjacent two strokes lacked of calculating this font according to this stroke data is for calculating this font in space that adjacent two strokes of a first direction and a second direction are lacked according to this stroke data.
4. the method for claim 1, wherein this refinement information comprises a fine setting instruction.
5. method as claimed in claim 4, wherein this fine setting instruction comprises merging two strokes, a stroke is moved down, a stroke is moved up and deletes a stroke.
6. the method for claim 1 also comprises:
Whether the overlapping part of judging these adjacent two strokes is greater than a preset value.
7. method as claimed in claim 6 also comprises:
When this overlaps partly greater than this preset value, the refinement information of these adjacent two strokes is handled together.
8. method as claimed in claim 6 also comprises:
When this overlapping part is not more than this preset value, the refinement information grouping of these adjacent two strokes is handled.
9. the method for claim 1 also comprises:
In the stroke data of this font, add this refinement information.
10. method as claimed in claim 9 wherein adds this refinement information and subtracts pen rule this refinement information of adding in the stroke data of this font according to one in the stroke data of this font.
11. method as claimed in claim 9 wherein obtains the refinement information that obtains this font in the stroke data of refinement information by this font of this font.
12. the method for claim 1, the stroke data that this font wherein is provided is for providing the stroke data of a GTG font.
13. the method for claim 1, it provides the stroke data of this font to comprise provides the stroke data of roman Chinese font, a simplified form of Chinese Character font and a Japanese font.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN200910129839A CN101847138A (en) | 2009-03-26 | 2009-03-26 | Method for fine adjustment of strokes of font |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN200910129839A CN101847138A (en) | 2009-03-26 | 2009-03-26 | Method for fine adjustment of strokes of font |
Publications (1)
Publication Number | Publication Date |
---|---|
CN101847138A true CN101847138A (en) | 2010-09-29 |
Family
ID=42771762
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN200910129839A Pending CN101847138A (en) | 2009-03-26 | 2009-03-26 | Method for fine adjustment of strokes of font |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN101847138A (en) |
Cited By (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN102955765A (en) * | 2011-08-22 | 2013-03-06 | 文鼎科技开发股份有限公司 | Method for finely adjusting Chinese characters according to font sizes and Chinese character fine adjustment system |
TWI847748B (en) * | 2023-06-06 | 2024-07-01 | 白永松 | System and method for chinese character font size adjustment |
-
2009
- 2009-03-26 CN CN200910129839A patent/CN101847138A/en active Pending
Cited By (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN102955765A (en) * | 2011-08-22 | 2013-03-06 | 文鼎科技开发股份有限公司 | Method for finely adjusting Chinese characters according to font sizes and Chinese character fine adjustment system |
CN102955765B (en) * | 2011-08-22 | 2015-11-25 | 文鼎科技开发股份有限公司 | Method for finely adjusting Chinese characters according to font sizes and Chinese character fine adjustment system |
TWI847748B (en) * | 2023-06-06 | 2024-07-01 | 白永松 | System and method for chinese character font size adjustment |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN101290632B (en) | Input method for user words participating in intelligent word-making and input method system | |
CN106527940B (en) | Handwriting determining method and device | |
CN110633518B (en) | Simple parameterization unit type curtain wall material classification statistical method based on BIM | |
CN103971586B (en) | electronic map generating method and device | |
CN205139996U (en) | Intelligence advertisement design system | |
CN106547433A (en) | Written handwriting determines method and device | |
CN100555312C (en) | Utilize charcter topology information to carry out the method and apparatus of the handwriting recognition of aftertreatment | |
CN101847138A (en) | Method for fine adjustment of strokes of font | |
CN106558033A (en) | Binary Images Processing method based on morphological dilations erosion algorithm | |
CN102270197A (en) | Touch translation system and method thereof | |
CN106125963A (en) | On a kind of equipment without pressure sensitivity former person's handwriting Handwriting Signature System and the former person's handwriting of PDF document hand-written sign method | |
CN101354747B (en) | Method and apparatus for recognizing hand-written symbol | |
CN103106313A (en) | Method for sequentially reconstructing rolled pieces | |
CN101452368B (en) | Hand-written character input method | |
CN106406560A (en) | Method and system for outputting vector fonts of mechanical engineering characters in desktop operation system | |
CN110349238B (en) | Brush pen small regular script rendering method | |
CN102013109A (en) | Method and device for beautifying cursive style of handwritten Chinese characters | |
CN104484512A (en) | Pattern generation method based on AUTOCAD in PDMS (plant design management system) | |
CN101996309A (en) | Method and relevant device for identifying and transforming stroke contour | |
CN104182520B (en) | The implementation method of Hanzi font library is automatically generated using part | |
CN100568164C (en) | A kind of digital keyboard Chinese character input method that is used for embedded device | |
CN107609593B (en) | Three-dimensional space handwritten character dimension reduction method based on longest track projection | |
CN113723345B (en) | Domain self-adaptive pedestrian re-identification method based on style conversion and joint learning network | |
CN103744533A (en) | Thirty Chinese character component input method | |
CN103942543A (en) | Image recognition method and device |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
C06 | Publication | ||
PB01 | Publication | ||
C10 | Entry into substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
C12 | Rejection of a patent application after its publication | ||
RJ01 | Rejection of invention patent application after publication |
Open date: 20100929 |