Embodiment
The embodiment of the present invention provides a kind of method of text message transmission and the method that text message shows.The embodiment of the present invention also provides the terminal of corresponding text message transmission and the terminal that text message shows.Below be elaborated respectively.
The embodiment of the present invention is encoded to UNICODE method and the terminal that method that information that the example explanation embodiment of the present invention improves transmits and terminal, information show, but realizing that principle and thought are not limited to and being applied to UNICODE coding of the embodiment of the present invention also can be applicable to the coded systems such as GB2312.
Embodiment one
This embodiment comprises at the text-string of conversion: the data bitmap of encoding of graphs and this figure in the process that information shows, directly converts the data bitmap of this figure to graphical content and shows and get final product.This embodiment converts user's editing graph to the text character string format of the data bitmap that comprises coding and figure, directly according to the data bitmap display graphics content in text-string, has realized transmission and the demonstration of user-defined figure when information shows.The embodiment of the present invention transmits by text-string and shows the User Defined figure, and the embodiment of the present invention is simple, easily realizes, and is not high to realizing demanding terminal, saving resource, and improve the user and experience.
For convenience, the terminal that the embodiment of the present invention transmits flow process with execution information is called information and transmits terminal, and the terminal of the information of execution flow for displaying is called Message Display Terminal.
Fig. 1 is that the information that the embodiment of the present invention provides transmits and demonstration embodiment one flow chart.
The information that step 101, collection user edit;
The graphical information that the user edits comprises: the user-defined figure that there is no standard code.
Step 102, the information that the user is edited convert text-string to;
The User Defined figure is converted to the text-string of the data bitmap that comprises coding and this figure.
The coding of user-defined figure specifically can be defined as: E000 to the F8FF section of Unicode coding, and this does not define any word, and the coding that can be used as the graphical information that there is no standard code uses, and is used for representing to be inserted into the graphic symbol in text.The form of expanded text character string is: graphic symbol encoded, is numbered respectively E000+n, and n=0,1,2,3 ...; First graphic symbol that namely inserts is encoded to E000, and second is encoded to E001, the like.
Fig. 2 is the first text character string format that the embodiment of the present invention provides.
The text character string format, from left to right, the Unicode coding of " XXXX " expression standard, E000, E001 are the codings of the graphical information that there is no standard code of insertion, " 0000 " is the terminating symbol of text character string encoding; The coding of the user-defined figure of storage in the remaining space of character string, and the data bitmap of this figure corresponding with it.The coding that the present embodiment text-string only carries user-defined figure with and data bitmap, " XXXX " of the Unicode coding of expression standard be empty or by the coding covering of user-defined figure; And the coding that the present embodiment text-string only carries user-defined figure with and data bitmap, the length of data bitmap is partly empty.
Data bitmap is: the graph data of this figure by pixel, vector representation.For example: dot matrix word library, dot matrix are a kind of forms of digitlization character library, and each font forms with black and white picture element matrix; Vector font library, vector font library are preserved is descriptor to each Chinese character, such as a stroke initial, stop coordinate, radius, radian etc.
Step 103, transmission text-string;
Text message transmits terminal execution in step 101, step 102 and step 103, completes the transmission of information, and text-string is sent to the text message display terminal by network, text message display terminal execution in step 104 and later step.
Step 104, reception text-string;
Text-string comprises: the data bitmap of the coding of User Defined figure and User Defined figure.The data bitmap of user-defined figure is: the graphical content of this graphical information by pixel, vector representation.For example: dot matrix word library, dot matrix are a kind of forms of digitlization character library, and each font forms with black and white picture element matrix; Vector font library, vector font library are preserved is descriptor to each Chinese character, such as a stroke initial, stop coordinate, radius, radian etc.Execution in step 106.
Step 105, show user-defined figure according to data bitmap;
Show user-defined figure according to the data bitmap that receives.
As one embodiment of the present of invention, the information of editing as the user also comprises: when having the text of standard code, the information that described step 102 is edited the user converts in text-string, the text-converted of further user being edited becomes text-string, has " XXXX " of the Unicode coding of expression standard in the text-string of the first form.
Accordingly, receive when comprising the text with standard code at the text message display terminal, the text display terminal before execution in step 105, execution in step also: search the local character library data bitmap corresponding with standard code according to the standard code of text; Step 105 shows the text with standard code simultaneously.
Because text and the user-defined figure simultaneously the user edited are changed and show, enlarge the text message transmission of the present embodiment proposition and the range of application of display packing.
As one embodiment of the present of invention, add the length of data bitmap in text-string, make text character string conveniently check in the process of storage and transmission and demonstration.
Embodiment two
This embodiment, in the transmitting procedure of text message, text-string includes only: the coding of user-defined figure and/or have the standard code of the text of standard code.When showing information, if there is not the data bitmap of above-mentioned coding correspondence in local character library, sends and ask for data bitmap message, then show that according to the data bitmap that gets corresponding user-defined figure is or/and text.The content that the present embodiment, text-string carry takies less Internet resources with respect to embodiment one minimizing, when encoding without this in the character library of text display terminal, sends and asks for data bitmap message corresponding to this coding, in order to show.And in the local character library of text display terminal storage, non-existent coding and the corresponding data bitmap of should encoding, expand local character library, keeps transmitting with text at any time the consistency of terminal data bitmap, conveniently transmission and the demonstration of user-defined figure or text.
Fig. 3 is the second embodiment flow chart that the information that provides of the embodiment of the present invention transmits and shows.
The information that step 201, collection user edit;
The graphical information that the user edits comprises: user-defined figure.
Step 202, the information that the user is edited convert text-string to;
The User Defined figure is converted to the text-string that comprises coding.
Wherein, the coding of user-defined figure specifically can be defined as: E000 to the F8FF section of Unicode coding, this section does not define any word, and the coding that can be used as the graphical information that there is no standard code uses, and is used for representing to be inserted into the graphic symbol in text.The form of expanded text character string is: graphic symbol encoded, is numbered respectively E000+n, and n=0,1,2,3 ...; First graphic symbol that namely inserts is encoded to E000, and second is encoded to E001, the like.
Fig. 4 is the second text character string format that the embodiment of the present invention provides.
The text character string format, from left to right, the Unicode coding of " XXXX " expression standard, " E000 " and " E001 " is the coding of the user-defined figure of insertion, " 0000 " is the terminating symbol of string encoding.The present embodiment text-string only carries user-defined coding, and " XXXX " field of the Unicode coding of expression standard be empty or by the coding covering of user-defined figure.
Step 203, transmission text-string.
Information transmits the transmission that terminal execution in step 201, step 202 and step 203 are completed information, and information exchange is crossed network and is sent to the text message display terminal, execution in step 203, step 204 and step 205.
Step 204, reception text-string;
Text-string comprises: the coding of User Defined figure.
Step 205, search coding in local character library;
Search the coding of user-defined figure and have the standard code of the text of standard code in local character library.If above-mentioned being coded in local character library exists, direct execution in step 206.
Step 206, show user-defined figure according to data bitmap;
According in local character library with the coding of user-defined figure.
As one embodiment of the present of invention, if the information that the user edits also comprises: the text with standard code; So, the text-converted that text message transmission terminal is further edited the user becomes text-string, has " XXXX " field of the Unicode coding of expression standard in the text-string of the second form.
Carry the coding of the text with standard code in the text-string that corresponding text message display terminal receives, the text message display terminal is searched the standard code of the text with standard code simultaneously in local character library, and shows the text with standard code according to data bitmap corresponding to the standard code that exists in local character library.
Because text and the user-defined figure simultaneously the user edited are changed and show, enlarge the text message transmission of the present embodiment proposition and the range of application of display packing.
As one embodiment of the present of invention, add the length of data bitmap in text-string, make text character string conveniently check in the process of storage and transmission and demonstration.
As one embodiment of the present of invention, or/and have the standard code of the text of standard code and do not exist in local character library, execution in step 207 at the coding of searching user-defined figure for the text message display terminal.The embodiment of the present invention provides step 207,208,209,210, guarantees that when there was not corresponding data bitmap in the local character library of text display terminal, the information of transmission can normally show, the range of application of expansion project and increase user's experience.
The message of data bitmap is asked in step 207, transmission;
The text message display terminal transmits terminal to text message and sends the message of asking for data bitmap.Text message transmits terminal execution in step 208, step 209.
Step 208, receive and to ask for the data bitmap of user-defined figure or/and have the message of data bitmap of the text of standard code;
The data bitmap of step 209, the user-defined figure of transmission is or/and have the data bitmap of the text of standard code;
Text message display terminal execution in step 210 and step 211.
The data bitmap of step 210, the user-defined figure of reception is or/and have the data bitmap of the text of standard code;
This data bitmap be with local character library in the data bitmap of non-existent coding graph of a correspondence information.Step 206, further the data bitmap according to the user-defined figure that receives shows user-defined figure and text or/and have the data bitmap of the text of standard code.
As one embodiment of the present of invention, for convenience of the data bitmap by this figure of coding lookup or text.
The text message that the embodiment of the present invention provides transmits and display packing also comprises:
Step 211, with the data bitmap of user-defined figure or/and have the coding of the data bitmap of text of standard code and user-defined figure or/and have the standard code corresponding stored of the text of standard code.
The data bitmap corresponding stored of the coding of user-defined figure and this user-defined figure has the standard code of text of standard code and the data bitmap corresponding stored of this text with standard code.Need to prove: information transmits at two terminal rooms, has conversation procedure between two terminals, and can there be certain hour in this conversation procedure; In the local character library of terminal storage, non-existent coding and corresponding data bitmap thereof, can exist in this conversation procedure.After this conversation end, in the local character library of terminal, the non-existent coding of script may be defined as the coding of the self-defining figure of New Consumers or text.The embodiment of the present invention also provides the terminal of using said method.
Embodiment three
When this embodiment text message transmits terminal for the first time to text message display terminal transmission text-string, adopt the first text character string format, the text message display terminal is preserved non-existent encoding of graphs and corresponding data bitmap thereof in local character library; When text message transmits terminal and again sends identical data bitmap corresponding to identical encoding of graphs, adopt the second text character string format, the text message display terminal is searched local character library, if the encoding of graphs and the corresponding data bitmap thereof that do not exist text-string to carry transmit terminal to text-string and send the message of asking for data bitmap.
When text information transmits terminal for the first time to text message display terminal transmission text-string, carry data bitmap, when again sending data bitmap corresponding to identical encoding of graphs, text-string no longer carries data bitmap, reduce the data bitmap translation burden that text message transmits terminal, and reduce the size of data of carrying of text-string, reduce in transmitting procedure taking too much bandwidth, thereby reduce network burden.
As shown in Figure 5, the embodiment of the present invention text message transmission that provides and embodiment three flow charts that are first;
Step 301, text message transmit terminal and gather the information that the user edits;
The graphical information that the user edits comprises: have the text of standard code and there is no the user-defined figure of standard code.
Step 302, text message transmit terminal and convert the information that the user edits to text-string;
Information according to the user who collects edits if only comprise the text with standard code, converts the text to the text-string that comprises standard code; If the information that the user edits includes only the user-defined figure that there is no standard code, the User Defined figure is converted to the text-string of the data bitmap that comprises coding and this figure; If the information that the user edits includes the text of standard code and there is no the user-defined figure of standard code, the information of this user being edited converts to and comprises: the coding that the text of standard code is arranged, and, the coding of User Defined figure and the data bitmap of this self-defined figure.
Wherein, the coding of user-defined figure specifically can be defined as: E000 to the F8FF section of Unicode coding, this does not define any word, and the coding that can be used as the graphical information that there is no standard code uses, and is used for representing to be inserted into the graphic symbol in text.The form of expanded text character string is: graphic symbol encoded, is numbered respectively E000+n, and n=0,1,2,3 ...; First graphic symbol that namely inserts is encoded to E000, and second is encoded to E001, the like.
This embodiment text message transmits terminal when the coding that transmits for the first time user-defined figure and corresponding data bitmap thereof, uses the first text character string format, carries the data bitmap of user-defined figure.When the coding that transmits for the second time identical user-defined figure and corresponding data bitmap thereof, uses text character string format shown in Figure 4, the text-string that text message transmits the terminal transmission includes only: the coding of user-defined figure.
Step 303, text message transmit terminal and send text-string;
Text-string is sent to the text message display terminal by network.
Step 304, text message display terminal receive text-string;
Execute this information of example text and transmit terminal when the coding that transmits for the first time user-defined figure and corresponding data bitmap thereof, the text-string of the reception during text message transmits comprises: the data bitmap of the coding of User Defined figure and User Defined figure.When the coding that transmits for the second time identical user-defined figure and corresponding data bitmap thereof, the text-string of the reception during text message transmits comprises: the coding of User Defined image.Simultaneously, the text-string that receives of text message display terminal also may comprise the coding of the figure with standard code.The data bitmap of the user-defined figure of text is: the graphical content of this graphical information by pixel, vector representation.For example: dot matrix word library, dot matrix are a kind of forms of digitlization character library, and each font forms with black and white picture element matrix; Vector font library, vector font library are preserved is descriptor to each Chinese character, such as a stroke initial, stop coordinate, radius, radian etc.
Step 305, text message display terminal are searched coding in local character library;
Search the coding of user-defined figure and have the standard code of the text of standard code in local character library.If above-mentioned being coded in local character library exists, direct execution in step 310.For the text-string of the employing the first form that receives, if above-mentioned coding has any coding not exist, execution in step 311, simultaneously execution in step 310.For the text-string of the employing the second form that receives, if above-mentioned coding has arbitrary coding not exist, execution in step 306.
Step 306, text message display terminal send the message of asking for data bitmap;
The text message display terminal transmits terminal to text message and sends the message of asking for data bitmap.
This data bitmap may be the data bitmap of user-defined figure, may be also data bitmap corresponding to non-existent standard code on the text display terminal.
Step 307, text message transmit terminal and receive and ask for the data bitmap of user-defined figure or/and have the message of data bitmap of the text of standard code;
Text message transmits terminal when converting user-defined figure to text-string, preserves the data bitmap of this user-defined figure.
Step 308, text message transmit terminal and send the data bitmap of user-defined figure or/and have the data bitmap of the text of standard code;
Step 309, text message display terminal receive the data bitmap of user-defined figure or/and have the data bitmap of the text of standard code;
This data bitmap be with local character library in the data bitmap of non-existent coding graph of a correspondence information.
Step 310, show that according to data bitmap user-defined figure is or/and text;
According in local character library with the coding of user-defined figure or/and have the data bitmap corresponding to standard code of the text of standard code, or transmit user-defined figure that data bitmap that terminal sends shows that in local character library, non-existent coding is corresponding or/and text according to text message.
Step 311, with the data bitmap of user-defined figure or/and have the coding of the data bitmap of text of standard code and user-defined figure or/and have the standard code corresponding stored of the text of standard code.
The data bitmap corresponding stored of the coding of user-defined figure and this user-defined figure has the standard code of text of standard code and the data bitmap corresponding stored of this text with standard code; Convenient data bitmap by this figure of coding lookup or text.
Need to prove: information transmits at two terminal rooms, has conversation procedure between two terminals, and can there be certain hour in this conversation procedure; In the local character library of terminal storage, non-existent coding and corresponding data bitmap thereof, can exist in this conversation procedure.After this conversation end, in the local character library of terminal, the non-existent coding of script may be defined as the coding of the self-defining figure of New Consumers or text.The embodiment of the present invention also provides the terminal of using said method.
Fig. 6 is that the information that provides of the embodiment of the present invention transmits first of terminal and implements illustration.
This embodiment converts user's editing graph to the text character string format of the data bitmap that comprises coding and figure, has realized the transmission of user-defined figure.The embodiment of the present invention transmits by text-string and shows the User Defined figure, and the embodiment of the present invention is simple, easily realizes, and is not high to realizing demanding terminal, saving resource, and improve the user and experience.
Text message transmits terminal and comprises:
Collecting unit 510 is used for gathering the information that the user edits, and the information that described user edits comprises: user-defined figure;
The first converting unit 521 is used for converting the user-defined figure of described collecting unit collection to text-string, and described text-string comprises: the coding of described user-defined figure and the data bitmap of described user-defined figure;
Transmitting element 530 is used for sending described text-string.
Further, described text transmission terminal also comprises: the second converting unit 522;
The information that the user that described collecting unit 510 gathers edits also comprises: the text with standard code;
Described the second converting unit 522, the text-converted that is used for described user is edited becomes text-string, and described text-string also comprises: the standard code of the text that described user edits.
This embodiment text transmits terminal increases by the second converting unit, the standard code of converting users editor's text simultaneously, text transmits terminal not only can be used for the self-defining figure of converting users, the standard code of text that simultaneously can the converting users editor increases the range of application that text transmits terminal.
According to embodiment of the method, the present invention also provides the second embodiment of the terminal of text message transmission.
Fig. 7 is that the text message that provides of the embodiment of the present invention transmits second of terminal and implements illustration;
Text message transmits the second embodiment of terminal with respect to embodiment one, the text-string that transmitting element sends includes only the coding of User Defined figure and has the coding of the text of standard code, when receive that the text display terminal sends ask for data bitmap message the time, just send data bitmap to the text display terminal.The content that the text-string that the terminal that transmits the present embodiment, text message transmits carries has reduced the Internet resources that take.
The terminal that a kind of text message transmits comprises:
Collecting unit 510 is used for gathering the information that the user edits, and the information that described user edits comprises: user-defined figure;
The first converting unit 521 is used for converting the user-defined figure of described collecting unit collection to text-string, and described text-string comprises: the coding of described user-defined figure;
Transmitting element 530 is used for sending described text-string.
Further, the terminal of described text message transmission also comprises: the second converting unit 522;
The information that the user that described collecting unit 510 gathers edits also comprises: the text with standard code;
Described the second converting unit 522, the user becomes text-string with the text-converted with standard code of described collecting unit collection, and described text-string also comprises: the standard code of the text that described user edits.
This embodiment text transmits terminal increases by the second converting unit, the standard code of converting users editor's text simultaneously, text transmits terminal not only can be used for the self-defining figure of converting users, the standard code of text that simultaneously can the converting users editor increases the range of application that text transmits terminal.
After text message transmission terminal will convert text-string to for editor's information, preserve simultaneously the data bitmap of user-defined figure.
Further, the terminal of described information transmission also comprises:
Message sink unit 540 be used for to receive the data bitmap of asking for described user-defined figure or/and the message of the data bitmap of described text with standard code;
Data transmission unit 550 is used for sending the data bitmap of described user-defined figure or/and described data bitmap with text of standard code.
According to the description of method, the terminal that the embodiment of the present invention provides text message to show.
Fig. 8 is that first of the text message display terminal that provides of the embodiment of the present invention is implemented illustration.
This embodiment information terminal directly according to the data bitmap display graphics content in text-string, has been realized the demonstration of user-defined figure when information shows.The embodiment of the present invention shows the User Defined figure by text-string, and the embodiment of the present invention is simple, easily realizes, and is not high to realizing demanding terminal, saving resource, and improve the user and experience.
The terminal that a kind of text message shows comprises:
Receiving element 610 is used for receiving text-string, and described text-string comprises: the coding of user-defined figure and the data bitmap of described user-defined figure;
Display unit 620 is used for showing described figure according to the data bitmap of described user-defined figure.
Further, described text message display terminal also comprises: search unit 630;
The text-string that described receiving element 610 receives also comprises: the standard code of the text that the user edits;
The local character library data bitmap corresponding with described standard code searched according to the standard code of described text in the described unit 630 of searching;
Described display unit 620 is used for searching the data bitmap that the unit finds and showing described text according to described.
The unit is searched in this embodiment text terminal increase before this, search simultaneously the standard code of the text that the user edits, the text display terminal not only can be used for showing user-defined figure, can show the standard code of the text that the user edits simultaneously, increases the range of application of text display terminal.
According to embodiment of the method, the present invention also provides the second embodiment of the terminal of text message demonstration.
Fig. 9 is that second of the text message display terminal that provides of the embodiment of the present invention is implemented illustration;
The second embodiment of text message display terminal is with respect to embodiment one, the text-string that receiving element receives includes only the coding of User Defined figure or/and have the coding of the text of standard code, when the coding that do not exist in local character library in text-string, message sending unit sends asks for data bitmap message, the content that text-string carries takies less Internet resources with respect to embodiment one minimizing.And data bitmap corresponding to non-existent coding in the local character library of the cell stores of text display terminal, maintenance and text transmit the consistency of terminal data bitmap at any time, transmission and the demonstration of convenient user-defined figure or text.
The terminal that a kind of text message shows comprises:
Receiving element 610 is used for receiving and deposits text-string, and described text-string comprises: user-defined encoding of graphs;
Search unit 630, be used for searching in local character library the coding of described user-defined figure;
Display unit 620 is used for when the local character library of being coded in of described user-defined figure exists, and the data bitmap of the coding correspondence of the described figure of foundation shows described user-defined figure.
Further, the text-string of described receiving element reception 610 also comprises: the text with standard code;
Described standard code with text of standard code is further searched in local character library in the described unit 630 of searching;
Described display unit when searching the unit and searching described standard code and exist, shows described text with standard code according to data bitmap corresponding to described standard code described in local character library.
Further, described text message display terminal also comprises:
Message sending unit 640, be used for searching the coding of described user-defined figure or/and described standard code with text of standard code does not exist in local character library in the described unit of searching, send the data bitmap of asking for described user-defined figure or/and the message of the data bitmap of described text with standard code;
Data receiver unit 650, be used for receiving described user-defined figure data bitmap or/described data bitmap with text of standard code;
Display unit 620, be used for according to the data bitmap of described user-defined figure or/described data bitmap with text of standard code shows that user-defined figure is or/and described text with standard code.
As one embodiment of the present of invention, message sending unit is asked for non-existent data bitmap in local character library, the data receiver unit receives this data bitmap, guarantee when there is not corresponding data bitmap in the local character library of text display terminal, the information that transmits can normally show, the range of application of expansion project and increase user's experience.
Further, described text message display terminal also comprises:
Memory cell 660, described search the unit search described user-defined figure coding or/and described standard code with text of standard code do not exist in local character library, described data receiver unit receive described user-defined figure data bitmap or/data bitmap of described text with standard code with the data bitmap of described user-defined figure or/and the coding of the data bitmap of described text with standard code and described user-defined figure or/and have the standard code corresponding stored of the text of standard code.
This embodiment text message display terminal increases memory cell, it is convenient when user-defined figure is used again, the text message display terminal can directly be searched the data bitmap that local character library is sought this user-defined figure, needn't send again the message of asking for data bitmap, reduce the terminal processes flow process, fast and easy shows text message.
The terminal that the above text message that the embodiment of the present invention is provided transmits and the method that shows and text message transmit and show is described in detail, used specific case herein principle of the present invention and execution mode are set forth, the explanation of above embodiment just is used for helping to understand method of the present invention and core concept thereof; Simultaneously, for one of ordinary skill in the art, according to thought of the present invention, all will change in specific embodiments and applications, in sum, this description should not be construed as limitation of the present invention.