Summary of the invention
At problems of the prior art, the implementation method and the system that the purpose of this invention is to provide a kind of pre-typesetting, in pre-determined stroke of version zone, enter the composing piece that is used for occupy-place by this method and system, attributes such as size according to the predefined font of composing piece, font size, line-spacing and composing piece, automatically calculate the alphabetic character quantity that can enter material in the composing piece, and between composing piece ID and material ID, set up corresponding relation, material enters in the composing piece automatically then, thereby realize layout and material editor's co-operating, flexible.
For achieving the above object, the technical solution used in the present invention is: a kind of implementation method of pre-typesetting comprises the steps:
(1) when computing machine is set type, enter the composing piece in space of a whole page one layout region, the user is provided with the attribute of composing piece as required, the attribute of described composing piece comprises about the size, position, font, font size, word space, line space, the world of composing piece the width of cloth and adjusts mode automatically, wherein, adjustment mode automatically comprises automatic change and from dynamic deformation;
(2) set up related between composing piece and the material;
(3) carry out walkthrough: related according between composing piece in the step (2) and the material, the user can select set type piece walkthrough or material walkthrough as required;
During composing piece walkthrough, the property calculation of the composing piece that space of a whole page manager is set according to user in the step (1) piece that goes out to set type allows the scope W of the size of the material that enters, and feed back to the material management device, the property calculation of the composing piece that the material management device is set according to user in the step (1) goes out the big or small H of material itself, and while material management device judges that the big or small H of material itself is whether in scope W; If H in scope W, then directly enters next step, if H not in scope W, then material management device prompting W is not complementary with H, the user can delete material according to this information and add processing; Described composing piece allows the scope W of the size of the material that enters to be meant the interval range of (W1-W2), if W1 is composing piece last column when only arranging an alphabetic character, other row is when all arranging language of the Manchus word character, and the composing piece that space of a whole page manager calculates allows the material size that enters; W2 is meant when composing piece last column row language of the Manchus word, and when other row was also all arranged language of the Manchus word, space of a whole page manager calculated the composing piece and allows the material size that enters;
During the material walkthrough, the material management device is according to the attribute of the composing piece of user's setting in the step (1), calculate the big or small H of material itself, and feed back to space of a whole page manager, the property calculation of the composing piece that space of a whole page manager is set according to user in the step (1) piece that goes out to set type allows the scope W of the size of the material that enters, and according to the big or small H of material itself, if H is in the scope of W, then directly enter step (4), if H is not in the scope of W, then space of a whole page manager calculates the difference between W and the H, if H, then calculates the peaked difference of H and W greater than the maximal value of W; If H less than the minimum value among the W, then calculates the difference of H and W minimum value, the preferred sequence of the composing tile height set according to this difference and user of space of a whole page manager and width and the setting range adjusted size of piece of setting type then;
(4) the formal composing: material flow in the composing piece, if the material size with the composing block size when inconsistent, the composing piece is adjusted automatically according to the automatic adjustment mode of setting in the step (1), adjustment finishes, processing finishes.
Further, described composing piece is meant the closed region of the material that can enter literal, figure, image, OLE piece or its mixing composition in the space of a whole page, the shape of this packaging area can be polygon-shaped, its size, angle, the equal scalable in position, and can preserve the default attribute that enters material, described default attribute comprises line-spacing, font, font size;
Further, described material is the typesetting data that literal, figure, image, OLE piece or its mixing are formed;
Further, described material size is represented with the alphabetic character number of material, the alphabetic character number is meant that the number of words in the material adds figure, image, OLE piece etc. is converted into the summation of the number of literal according to its size according to the attribute of composing piece setting that the attribute of described composing piece setting comprises font, font size, word space and line space;
Further, in the step (2), when setting up related between composing piece and the material, concrete grammar is: set up the corresponding relation between composing piece ID and the material ID;
Further, in step (1) and (4), described composing piece when dynamic deformation is meant that material flows into the composing piece, width of cloth attribute is constant about the font of composing piece, font size, word space, line space, the world, the composing piece is adjusted the size of composing piece automatically according to the size of material, promptly the set type height or the width of piece carry out according to priority and the setting range set during adjustment; The automatic change of described composing piece is meant that the size of composing piece remains unchanged, the composing piece is adjusted width of cloth attribute about font, font size, word space, line space, the world automatically according to the size of the material that needs enter, and carries out according to priority and the setting range set during adjustment;
Further, in the step (4), when material flowed into the composing piece, the attribute that material is set according to the composing piece flowed in this composing piece, if there is the typesetting data that has defined the composing attribute in the material, then this typesetting data flows in the composing piece with its composing attribute; Usually material all is not have attribute, i.e. not Set Font, font size, line-spacing etc., but the user is in order to reach the effect that highlights sometimes, can set special composing attribute to the partial content of material, as title is set is the font or the font size of appointment, and these composing attributes still keep its original composing attribute when material flows into the composing piece;
Further, in the step (4), after the composing piece was automatically adjusted, if the size of the size of composing piece and material still is not complementary, then the content that the user can the manual adjustment material or the attribute of composing piece flowed into material then again.
A kind of realization system of pre-typesetting, this system comprises:
1) space of a whole page manager: be used for the management of space of a whole page composing piece, can preserve the composing piece attribute that the user sets, comprise the size of composing piece position, composing piece and the automatic adjustment mode of composing piece; The piece that can go out to set type according to the property calculation of composing piece allows the scope W of the size of the material that enters, and feeds back to the material management device; Space of a whole page manager can be accepted the feedback of material management device, and according to the big or small H of material itself, if H is in the scope of W, then directly formally set type, if H is not in the scope of W, then space of a whole page manager calculates the difference between W and the H, if H, then calculates the peaked difference of H and W greater than the maximal value of W; If H less than the minimum value among the W, then calculates the difference of H and W minimum value, the set type adjusted size of piece of the composing tile height that space of a whole page manager is set according to this difference and user and the preferred sequence of width and setting range;
2) material management device: be in charge of the material that is drained in the composing piece, and can go out the size of material, and feed back to space of a whole page manager according to the property calculation of composing piece; The material management device can be accepted the feedback of space of a whole page manager, and whether the big or small H that judges material itself in the composing piece allows the scope W of size of the material that operation enters, and as H not in the scope at W, prompting W and H are not complementary;
3) association manager is used to set up and preserve related between composing piece and the material.
Effect of the present invention is: adopt method and system of the present invention, in one layout region, enter the composing piece that is used for occupy-place, by setting up the corresponding relation of composing piece and material, the material related content all is quantified as the alphabetic character number, according to predefined composing piece attribute, material is entered the space of a whole page, realized layout and material editor's co-operating mode, and the renewal of material does not influence space of a whole page layout, increased the accuracy rate of typesetting data, but enlarge the operating space of layout, particularly good effect is arranged for composings such as timely news.
Embodiment
The invention will be further described below in conjunction with specification drawings and specific embodiments.
Embodiment 1
Adopt the implementation method of a kind of pre-typesetting of the present invention to finish, as shown in Figure 1, specifically may further comprise the steps:
Step 1, when computing machine is set type, enter the composing piece in space of a whole page one layout region, the user is provided with the attribute 11 of composing piece as required, the attribute of described composing piece is meant information such as width of cloth and adjustment mode automatically about the size, position, font, font size, word space, line space, the world of composing piece, wherein, adjustment mode automatically comprises automatic change and from dynamic deformation; Described composing piece is meant the closed region of the material that can enter literal, figure, image, OLE piece or its mixing composition in the space of a whole page, the shape of this packaging area can be polygon-shaped, its size, angle, the equal scalable in position, and can preserve the default attribute that enters material such as line-spacing, font, font size etc.;
In present embodiment, at first the user enters the composing piece as shown in Figure 3 on the space of a whole page, and this composing piece is a rectangle; The user is provided with the attribute information of composing piece as required, information such as the width of cloth and adjustment mode automatically about the size, position, font, font size, word space, line space, the world of piece of promptly setting type, be specially: the size of composing piece is 10.2*11.05CM, and the position occupy space of a whole page central authorities; Line space: 1.5 times of line-spacings; Font: the Song typeface; Font size: 14pt; The width of cloth is about the world: before the section: 0pt, section back: 0pt, character pitch: 0.3pt, first trip indentation: 0.55cm, text block back gauge: upper and lower, left and right are 2pt; If when picture, OLE piece or figure etc. are arranged, specify its concrete type-setting mode simultaneously, the composing format of designated pictures is in the present embodiment: embedded; The adjustment mode of composing piece is from dynamic deformation, and the user set the priority of composing piece when dynamic deformation and was this moment: the composing tile height is composing piece width then; Setting range is: height adjustment range ± 2.0cm, width adjustment scope ± 0.5cm;
In the practical operation, the composing piece can be other shape such as circle or triangle and other shape, if the composing piece is other outer shape of rectangle, elder generation sets type after other shape is divided into rectangle again when then setting type;
Step 2, set up related 12 between composing piece and the material; Promptly set up the composing piece and need enter corresponding relation between the material in this composing piece, both are mapped by setting up related between composing piece ID and the material ID;
Material is meant the typesetting data that literal, figure, image, OLE piece or its mixing are formed, and in present embodiment, material is made up of literal and picture, and picture as shown in Figure 4;
The particular content of literal is: People's Bank of China decision: adjust financial institution's Renminbi basic interest rates on deposits and loans from Dec 21st, 2007, term deposit benchmark interest rate brings up to 4.14% by existing 3.87%, raises 0.27 percentage point; One term loan benchmark interest rate brings up to 7.47% by existing 7.29%, raises 0.18 percentage point; The corresponding adjustment of benchmark interest rate of depositing, provide a loan of other each class.Individual's public accumalation fund for housing construction loan interest rate remain unchanged (concrete level is seen attached list).This time adjust and help preventing that economic growth from transferring to overheatedly by fast, prevent that price from developing into tangible currency inflation by structural rise.The enforcement of this policy, though the amount that deposit is adjusted is not high, loan interest rate does not improve, and is therefore bigger to the civic psychological impact, thereby can stimulate civic common reserve fund consumer psychology to a certain extent.
Usually material all is not have attribute, i.e. not Set Font, font size, line-spacing etc., but the user is in order to reach the effect that highlights sometimes, can set special composing attribute to the partial content of material, in present embodiment, the user is in order to highlight, and typesetting data character " 3.87% " and " 4.14% " defined the composing attribute of the inclination of its font; These composing attributes still keep its original composing attribute when material flows into the composing piece in step (4);
Step 3, carry out walkthrough: related according between the composing piece of setting up in the step 2 and the material, the user can clearly understand the material content that the composing piece will enter, this moment user's can select according to actual needs to set type piece walkthrough or material walkthrough;
During composing piece walkthrough, the property calculation of the composing piece that space of a whole page manager is set according to user in the step (1) piece that goes out to set type allows the scope W of the size of the material that enters, and feed back to the material management device, the property calculation of the composing piece that the material management device is set according to user in the step (1) goes out the big or small H of material itself, and while material management device judges that the big or small H of material itself is whether in scope W; If H in scope W, then directly enters next step, if H not in scope W, then material management device prompting W is not complementary with H, the user can delete material according to this information and add processing; Described composing piece allows the scope W of the size of the material that enters to be meant the interval range of (W1-W2), if W1 is composing piece last column when only arranging an alphabetic character, other row is when all arranging language of the Manchus word character, and the composing piece that space of a whole page manager calculates allows the material size that enters; W2 is meant when composing piece last column row language of the Manchus word, and when other row was also all arranged language of the Manchus word, space of a whole page manager calculated the composing piece and allows the material size that enters;
In present embodiment, owing to set up related between composing piece and the material, the user clearly understands the detailed content that enters the material in the composing piece 31, be text described in the step 2 and picture as shown in Figure 4, the user thinks that the material content is many, and the composing piece is relatively little, therefore, the user has selected composing piece walkthrough, under this kind situation, space of a whole page manager is according to the attribute (size of the piece of promptly setting type of the composing piece of user's setting in the step (1), the position, font, font size, word space, line space, the width of cloth and automatic information such as adjustment mode about the world) to calculate scope that this composing piece allows the size of the material that enters be that the scope of alphabetic character number is between 253 to 273 number field (when last column is only arranged an alphabetic character in the piece if promptly set type, when other row was all arranged language of the Manchus word character, the material size that the composing piece that space of a whole page manager calculates allows to enter was 253 characters for W1; When composing piece last column row language of the Manchus word, when other row is also all arranged language of the Manchus word, it is 273 characters for W2 that space of a whole page manager calculates the material size that the composing piece allows to enter), and give the material management device with this information feedback, the size that the property calculation of the composing piece that the material management device is set according to user in the step (1) goes out material itself is that the alphabetic character number is 370, and its Chinese version accounts for 265; Picture accounts for 105, simultaneously, the material management device judges relatively whether 370 be included between 253 to 273 number field, but 370 of the sizes of material are not included between 253 to 273 number field in the present embodiment, then material management device prompting composing piece and material size are not complementary, the user can delete that to make its material size As soon as possible Promising Policy should the composing piece allow the scope of the size of the material that enters be the scope of alphabetic character number according to this information to material, it is the last word (that is: enforcement of this policy that the user has deleted the literal in the material shown in the step 2 that the user receives after the information 65 literal of material deletion, though the amount that deposit is adjusted is not high, but loan interest rate does not improve, therefore bigger to the civic psychological impact, thus civic common reserve fund consumer psychology can be stimulated to a certain extent.), the size of material becomes 305 alphabetic characters like this, enters step 4;
Material in the present embodiment has literal, picture is also arranged, the material management device is when calculating material big or small, literal is very simple, the number of characters that directly calculates literal is 265, when picture was converted into alphabetic character, computing method were: according to the size of picture itself, and the attribute of setting according to the composing piece that this picture will enter (being font, font size, word space, line space) is converted into the alphabetic character number that need take; The alphabetic character number that takies of picture in the present embodiment is 105 as a result, picture in the present embodiment in the material is provided with as can be known according to the attribute of composing piece, and the picture layout mode is an embedded type, in fact the picture format is divided into embedded, floating type, different mode such as formula on every side, if it is floating type, then needn't calculate the character that picture takies, because this moment, picture floated on the literal top, do not take the typesetting space of literal; Therefore be different for its its shared alphabetic character number of composing piece property calculation of same picture according to correspondence;
Be that material is many in the present embodiment, be complementary in order to make material and composing piece, so deleted partial content; Certainly, if the material text is fewer, the user can select to add the part material; By the layout that has satisfied the composing space of a whole page of the very big degree of above-mentioned walkthrough process, promptly material mates the attribute specification of corresponding composing piece;
In the present embodiment, the user has selected composing piece walkthrough when walkthrough, in fact, can not change if the user determines the content of this material, but the size of composing piece can change, and obviously selects this moment the material walkthrough more appropriate.During the material walkthrough, the material management device is according to the attribute of the composing piece of user's setting in the step (1), the big or small H that calculates material itself is 370 alphabetic characters, and feed back to space of a whole page manager, the property calculation of the composing piece that space of a whole page manager is set according to user in the step (1) goes out to set type, and to allow the scope W of the size of the material that enters be between 253 to 273 number field to piece, big or small H according to material itself, if H is in the scope of W, then directly enter step 4, if H is not in the scope of W, then space of a whole page manager calculates the difference between W and the H, if H, then calculates the peaked difference of H and W greater than the maximal value of W; If H is less than the minimum value among the W, then calculate the difference of H and minimum value, the composing tile height set according to this difference and user of space of a whole page manager and the preferred sequence and the setting range of width are carried out adjusted size then, in the present embodiment, if the user sets the priority of composing piece: the height of only adjusting the composing piece, (height of the piece of promptly setting type can increase by 6 row at most to its height adjustment range when increasing for ± 6 times of row height, the height minus of composing piece can reduce by 6 row at most after a little while), because the big or small H (370) of material itself allows (273) 87 characters of greatest measure of the size of the material that enters more than the composing piece, therefore the space of a whole page manager line number that will calculate these 87 characters and should increase when entering in the composing piece height of setting type, be that 5 times of row are high as can be known after the calculating, therefore the height with the composing piece has increased by 5 times of sizes that row is high, to adapt to the size of material; So also can tentatively realize setting type being complementary of piece and material;
Step 4, the formal composing: material flow in the composing piece, if during not of uniform size the causing of the size of material and composing piece, the composing piece is adjusted automatically according to the automatic adjustment mode of setting in the step (1), and adjustment finishes, the processing end;
In present embodiment, during formal the composing, material is flow in the composing piece, comprise literal and picture in this material, the attribute that this material is set according to the composing piece flows in this composing piece, but defined the inclination composing attribute of font in the word content of material for typesetting data character " 3.87% " and " 4.14% ", therefore typesetting data " 3.87% " and " 4.14% " flow in the composing piece according to the font inclination attribute of its setting, picture size remains unchanged, other textual materials flows into according to the attribute of composing piece, as shown in Figure 5;
As shown in Figure 5, after material flow into the composing piece in the present embodiment, because during composing piece walkthrough, the operation of deleting of material does not make its satisfied composing piece allow the scope of the size of the material that enters, under this material still still can not set type in the composing piece, because, the alphabetic character that the composing piece can be set type is 253 to 273 characters, and the size of material is 305 characters, for above-mentioned material is all entered in the composing piece, owing to determine in the step 1 that the automatic adjustment mode of composing piece is from dynamic deformation, the piece of promptly setting type keeps line-spacing, font, attributes such as font size are constant, the size that the alphabetic character quantity of the material that the composing piece enters according to needs is adjusted the composing piece automatically promptly the set type height or the width of piece, carry out according to priority and the setting range set when the height of automatic adjustment composing piece or width, priority and setting range are set in step 1, therefore, the composing piece is keeping line-spacing, font, under the constant situation of attributes such as font size, (be that priority is: the composing tile height is composing piece width then according to the setting range of setting in the step 1 and adjustment order; Setting range is: height adjustment range ± 2.0cm, and the width adjustment scope ± 0.5cm), the composing piece is adjusted it automatically and highly is 11.7cm, width is 11.23cm, adjusts the back material and all enters in the composing piece, and both just adapt to, composing finishes, and processing finishes, as shown in Figure 6; Certainly, in the practical operation, still do not match with material after the piece of can setting type is automatically adjusted, the content that this moment, the user can the manual modification material or the attribute of composing piece allow material flow into again, then till satisfaction.
Example example 2
The present embodiment difference from Example 1 is that in the step 1, the automatic adjustment mode that the user sets the composing piece is change automatically, and the preferred sequence and the setting range of the automatic change of user's appointment are simultaneously: priority: font size, font, and line-spacing remains unchanged; Setting range is font size: 10pt-14pt, font: the Song typeface, regular script, black matrix, imitation Song-Dynasty-style typeface;
In the step 4 when material flow in the composing piece, as shown in Figure 5, composing piece and material can't be complementary, at this moment, the composing piece is according to the i.e. change automatically of the composing piece adjustment mode that sets, priority and setting range according to the adjustment of composing piece, under the big or small constant situation that promptly keeps 10.2*11.05CM that keeps the composing piece, it is 12pt that the composing piece is adjusted into textual materials font size automatically, font is the Song typeface, and line-spacing is 1.5 times of line-spacings, and picture size is constant, this moment, all the composing material entered in the composing piece, as shown in Figure 7.
As can be seen from the above-described embodiment, walkthrough process among the present invention can be dwindled the gap between composing piece and the material greatly, but can not guarantee fully consistent with actual composing effect, on the basis of walkthrough, automatic adjustment through composing piece in the step 4, the effect that piece and material mate mutually then can realize setting type, even not exclusively mate sometimes, its deviation is also very little, support that the user revises by hand, great advantage of the present invention obviously is can the batch processing material, and layout personnel and material editorial staff co-operating simultaneously can realize setting type easily and fast.
Embodiment 3
A kind of realization system of pre-typesetting, as shown in Figure 2, this system comprises:
1) space of a whole page manager 21: be used for the management of space of a whole page composing piece, can preserve composing piece attribute, composing piece position, the size of composing piece and the information such as automatic adjustment mode of composing piece that the user sets; The piece that can go out to set type according to the property calculation of composing piece allows the size of the material that enters, and feeds back to the material management device; Space of a whole page manager can be accepted the feedback of material management device, calculates the size that should possess when the composing piece enters this material according to the size of this material;
2) the material management device 22: be in charge of the material that is drained in the composing piece, and can go out the size of material according to the property calculation of composing piece, and feed back to space of a whole page manager; The material management device can be accepted the feedback of space of a whole page manager, when the material size that allows to enter when the size of finding material and composing piece is not complementary, provides information;
3) association manager 23, are used to set up and preserve related between composing piece and the material.
The present invention is the method and the device of the quick walkthrough of a kind of space of a whole page, be not limited to the embodiment described in the embodiment according to method of the present invention, those skilled in the art's technical scheme according to the present invention draws other embodiment, belongs to technological innovation scope of the present invention equally.