Detailed description of the invention
Below with reference to the accompanying drawings and in conjunction with the embodiments, the present invention is described in detail.See Fig. 1, including:
S11: the base map of the page formed objects of foundation and file;
S12: draw described figure on described base map according to the description object of the block of each figure in described file;Wherein, described figure includes pel and/or image;
S13: the base map described drafting obtained is as the bottom of the described page.
The method of the embodiment of the present invention, compared with prior art, it is not necessary to multiple description objects of the block of multiple figures are written to file, uses base map to replace multiple description objects in file, reduces the data volume of file.
Preferably, also include: during the content showing described file, the page shows described base map.
The file of the present invention can be the e-files such as pdf, cebx or ps, when e-file shows in computer, multimedia tablet device or similar terminal, directly show base map on the page, avoid the description object of the figure resolved on base map, shorten the time of display full content, improve the experience of user.
Preferably, also include: there is the description object of the block occured simultaneously according to word and figure, described base map is drawn word and the figure of the described block existing and occuring simultaneously.
With figure, the block occured simultaneously is existed for word, also according to the description object of these blocks, base map is drawn word and the figure of block.In the file generated, without the description object that the content on base map is corresponding, reduce the data volume of file.It addition, when terminal demonstration, directly display base map, decrease the description object of parsing, improve the processing speed of terminal demonstration full content.When being transmitted the e-file in embodiment by network, owing to the data volume of e-file reduces, the transmission speed of e-file can be improve, reduce offered load.
Preferably, also include: according to the word of described drafting, create corresponding description object;The description object of described establishment and the alphabetic character identical with the word of described drafting are write described file.
For ease of the word in the file of user's locating and displaying, the alphabetic character on base map is written in file, it is simple to user search word.
Preferably, also include: according to the description object of described establishment, on the position of the word drawn at described base map, place identical described alphabetic character.Described alphabetic character is transparent.
During user search word, the alphabetic character of character layer on base map can be retrieved.Each alphabetic character is identical with the word drawn on base map, and position is corresponding.It addition, word shows with the form of transparency 100%.Word on base map will not be played and block by alphabetic character, thus do not affects and read the word drawn on base map.
Preferably, see Fig. 2, during making e-file, it may include following steps:
S21: collect the block of the page;
Collect each block of the page of software for composing.
S22: the block of collection is divided into 3 classes;
A class belongs to the bottom, including pel and/or image block;B class belongs to the last layer of base map, including character block, when there is two-layer, it is possible to be referred to as top layer.C class includes the character block of open and flatization, including the character block of the alphabetic character identical with the word drawn on base map.
S23: the output first kind and the 3rd class are to ground floor;
The content of the first kind and the block of the 3rd class is exported ground floor, i.e. on the base map as page bottom.
According to the first kind and the description object of the block of the 3rd class, base map is drawn the content of the block of the first kind and the 3rd class.
S24: output Equations of The Second Kind;
The description object of the block of Equations of The Second Kind is exported e-file.
S25: output the 3rd class;
Placeholder corresponding for the word of the block of the 3rd class and description object thereof are exported file.
The manufacturing process of file described in detail above, for the process that each block on the page in type-setting document carries out classifying be can be found in Fig. 3, including:
S31: obtain the attribute of current block;
S32: whether be character block according to attributive judgment;
If it is, perform S33;If it is not, then perform S34;
S33: if not character block, it is judged that whether this block intersects with other block and be located below;If it is, perform S35;If it is not, then perform S36;
S34: determine that this block belongs to A class block;
S35: determine that this block belongs to C class block;
S36: determine that this block belongs to B class block;
Whether intersected with other block by the attribute of above-mentioned piece and block, so that it is determined that go out the classification of block ownership.In the attribute of block, whether record block has word, pel and/or image, the most overlapping with the content of other block, such as: the position of certain content of two blocks overlaps, and the content of a block is word, and another be image, it is determined that overlap.
The process that the content of the block of classification writes file is seen Fig. 4, Fig. 5, sees Fig. 4, including:
S41: create compatible equipment and compatible bitmap and initialize;
Creating and make the compatible equipment of e-file with base map, this compatible equipment is software environment, the environment of compatibility block formula software for composing;Create for the compatible bitmap as base map, device parameter is set, such as window logic scope, mapped mode etc..
S42: transparent color shop fixtures;
In compatible equipment, a kind of transparent color of definition, passes through paintbrush brush layer of transparent background color on bitmap by this color.
S43: in obtaining this page all of piece;
S44: determine whether block, if it is, perform S45;If it is not, then perform S46;
S46: obtain bitmap and background transparent data;
S47: the image in output current bitmap is to e-file;
S45: obtain the information of this block;
S48: judge whether this block belongs to the first kind;If it is, perform S50;If it is not, then perform S49;
S49: judge whether this block belongs to the 3rd class;If it is, perform S50;If it is not, then perform S44;
S50: this block is exported equipment.
By above-mentioned steps by all of piece of output to the software environment making e-file, block is converted to description object, on base map, draws the content of block, i.e. drawing image on bitmap according to description object.In S47, according to certain file format requirements, the image drawn is written to file, and full full page is set, i.e. with page formed objects on base map.Bitmap is embedded in the page of file.
For the block of word, the process of output sees Fig. 5, including:
S51: all of piece of the page of acquisition file;
S52: judge whether also block;If it is not, then terminate;If it is, perform S53.
S53: obtain the information of this block;
S54: judge whether this block belongs to Equations of The Second Kind, if it is, perform S56;If it is not, then perform S55;
S55: judge whether this block belongs to the 3rd class;If it is, perform S57;If it is not, then perform S52;
S56: this block is exported file;
By character block transformation description object, output to file;Perform S52;
The placeholder of S57: output character;
The alphabetic character identical with the word drawn on base map is exported file, exports corresponding description object simultaneously.The alphabetic character of output is loaded on the page by placeholder, and alphabetic character is transparent, so, can be easy to the word content on user search base map, the most not block word on base map.
By above-mentioned steps, produce the e-file of two-layer, be positioned at the base map of bottom, be positioned at the word on upper strata.When electronic equipment shows the content of file, display base map, and resolve the description object of word, base map shows the word in word and placeholder.Owing to decreasing the time resolving part description object, shorten the time of full content displayed on the terminals.
The present invention also provides for a kind of document handling apparatus, sees Fig. 6, including:
Set up module 61, for setting up the base map of the page formed objects with file;
First drafting module 62, for drawing described figure described foundation on the base map that module 61 is set up according to the description object of the block of each figure in described file;Wherein, described figure includes pel and/or image;
Module 63 is set, for described first drafting module 62 is drawn the base map that the obtains bottom as the described page.
Use base map to replace multiple description objects of the block of multiple figures in file, reduce the data volume of file.Time displayed on the terminals, on the page, directly show base map, it is to avoid multiple description objects of the block of the multiple figure of parsing, shorten the time of display full content, improve the experience of user.
Preferably, device also includes:
Second drafting module 64, for there is the description object of the block occured simultaneously according to word and figure, draws word and the figure drawing the described block existing and occuring simultaneously on base map at described first drafting module 62.
Preferably, device also includes:
Writing module 65, for the word according to described drafting, creates corresponding description object;The description object of described establishment and the alphabetic character identical with the word of described drafting are write described file;It is additionally operable to the base map write file drawn by the first drafting module 62.
Preferably, device also includes:
Display module 66, for during the content showing described file, shows the base map that described first drafting module 62 is drawn on the page;On the position of the word drawn at described base map, place the described alphabetic character identical with the word drawn that said write module 65 is written in file.
Obviously, those skilled in the art should be understood that, each module of the above-mentioned present invention or each step can realize with general calculating device, they can concentrate on single calculating device, or it is distributed on the network that multiple calculating device is formed, alternatively, they can realize with calculating the executable program code of device, thus, can be stored in storing in device and be performed by calculating device, or they are fabricated to respectively each integrated circuit modules, or the multiple modules in them or step are fabricated to single integrated circuit module realize.So, the present invention is not restricted to the combination of any specific hardware and software.
The foregoing is only the preferred embodiments of the present invention, be not limited to the present invention, for a person skilled in the art, the present invention can have various modifications and variations.All within the spirit and principles in the present invention, any modification, equivalent substitution and improvement etc. made, should be included within the scope of the present invention.