JP2007102368A - Data file analysis device, data file editing device, data file analysis method, data file analysis program, data file editing method and data file editing program - Google Patents
Data file analysis device, data file editing device, data file analysis method, data file analysis program, data file editing method and data file editing program Download PDFInfo
- Publication number
- JP2007102368A JP2007102368A JP2005288947A JP2005288947A JP2007102368A JP 2007102368 A JP2007102368 A JP 2007102368A JP 2005288947 A JP2005288947 A JP 2005288947A JP 2005288947 A JP2005288947 A JP 2005288947A JP 2007102368 A JP2007102368 A JP 2007102368A
- Authority
- JP
- Japan
- Prior art keywords
- data
- character string
- data file
- file
- analysis result
- 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
- Machine Translation (AREA)
- Document Processing Apparatus (AREA)
Abstract
Description
本発明は、データファイル解析装置、データファイル編集装置、データファイル解析方法、データファイル解析プログラム、データファイル編集方法およびデータファイル編集プログラムに関する。 The present invention relates to a data file analysis device, a data file editing device, a data file analysis method, a data file analysis program, a data file editing method, and a data file editing program.
従来より、XML形式やXHTML形式などによって記述したデータファイルを画像処理ソフトなどのアプリケーションによって使用する場合、データファイルとアプリケーションとの間にいわゆるパーサと呼ばれるソフトウェアを介在させていた。パーサは、上記XML形式やXHTML形式などで記述されたファイルの内容を解析してアプリケーションが利用するのに適した形のデータに変換するものであり、アプリケーションは、同変換後のデータ(解析結果)をパーサから入力して所定のメモリに記録し、以後、かかる解析結果を参照して上記データファイルの内容を解釈し、所定の画像処理を実行していた。 Conventionally, when a data file described in XML format or XHTML format is used by an application such as image processing software, software called a parser is interposed between the data file and the application. The parser analyzes the contents of the file described in the XML format or the XHTML format and converts it into data in a form suitable for use by the application. The application uses the converted data (analysis result). ) Is input from the parser and recorded in a predetermined memory. Thereafter, the contents of the data file are interpreted with reference to the analysis result, and predetermined image processing is executed.
また関連する文献として、コントローラより送信された、表示文字列を記述したHTMLタグ付文字列を、HTMLパーサによって解析し、同HTMLタグ付文字列からディスプレイ上に表示する文字列を取り出す文字表示制御装置が知られている(例えば、特許文献1参照。)。
上述した従来のパーサは、解析元のファイルに各タグに対応して属性と属性値としての文字列とが記述されている場合、かかる属性値としての文字列自体を解析結果として抽出していた。そのため、アプリケーションがパーサから出力された解析結果を記録する際のメモリの消費が大きかった。かかる問題は、解析元のファイルに記述されている属性値の文字数が多い場合、より顕著となる。また、上記アプリケーションを備える携帯電話機など、もともと同アプリケーションの動作の際に使用可能なメモリ容量にかなりの制限がある機器においては、上記メモリの浪費は大きな問題であった。 The conventional parser described above extracts the character string itself as the attribute value as the analysis result when the attribute and the character string as the attribute value are described corresponding to each tag in the analysis source file. . For this reason, the memory consumption is large when the application records the analysis result output from the parser. Such a problem becomes more prominent when the number of characters of the attribute value described in the analysis source file is large. In addition, in a device such as a mobile phone having the application, which has a considerable limitation on the memory capacity that can be used when the application is operated, the waste of the memory is a serious problem.
また、上記従来の構成では、パーサの解析結果から得られた特定の文字列を他の文字列に書き換える場合も処理負担が非常に大きかった。つまり、特定の文字列を他の文字列に書き換える場合、上記ファイルに記述されている各文字列を対象として上記特定の文字列と一致するものを検索し上記ファイル中における同特定の文字列の記述位置を探すという処理が必要であったため、かかる検索処理に要する負担が大きく、その結果、文字列の書き換えを高速に実行することができなかった。
なお、上記文献においても、HTMLパーサはHTMLタグ付文字列に記述された文字列を抽出する構成であるため、上述したメモリの浪費および書き換え処理の高速化の困難性という課題は未解決のままである。
Further, in the above-described conventional configuration, the processing burden is very large even when a specific character string obtained from the analysis result of the parser is rewritten to another character string. In other words, when rewriting a specific character string to another character string, each character string described in the file is searched for a match with the specific character string, and the same character string in the file is searched. Since the process of searching for the description position was necessary, the burden required for such a search process was large, and as a result, the rewriting of the character string could not be executed at high speed.
Even in the above document, the HTML parser is configured to extract the character string described in the HTML-tagged character string, and thus the above-described problems of waste of memory and difficulty in speeding up the rewriting process remain unsolved. It is.
本発明は、上記課題に鑑みてなされたもので、データファイルの記述内容の読み出しや書き換え処理を少ないメモリ資源と処理時間とによって実現することの可能なデータファイル解析装置、データファイル編集装置、データファイル解析方法、データファイル解析プログラム、データファイル編集方法およびデータファイル編集プログラムを提供することを目的とする。 The present invention has been made in view of the above problems, and is a data file analysis device, a data file editing device, and a data file that can realize the reading and rewriting processing of the description contents of the data file with less memory resources and processing time. It is an object to provide a file analysis method, a data file analysis program, a data file editing method, and a data file editing program.
上記目的を達成するため、本発明にかかるデータファイル解析装置では、各データを文字列を含む状態にて記述したデータファイルを対象として解析を行う。かかるデータファイルは、所定の記憶媒体に記録されている場合には、同記憶媒体から読み出すことになり、他のコンピュータなどが保持している場合にはそのコンピュータから同データファイルの送信を受ける。そして、データファイル解析装置は上記解析により、文字列について、文字列のデータファイルにおける記述位置を特定するアドレス情報と、文字列の属性とを記録した解析結果データを生成する。そして、データファイル解析装置は、当該解析結果データを、上記データファイルを利用する所定のデータ処理手段、例えばデータファイルに記述されたデータを使用して所定の画像処理を実行するアプリケーション等に引き渡す。 In order to achieve the above object, the data file analysis apparatus according to the present invention analyzes a data file in which each data is described in a state including a character string. When such a data file is recorded on a predetermined storage medium, the data file is read out from the storage medium. When another computer holds the data file, the data file is transmitted from the computer. Then, the data file analysis apparatus generates analysis result data in which the address information for specifying the description position in the data file of the character string and the attribute of the character string are recorded by the above analysis. Then, the data file analysis apparatus delivers the analysis result data to a predetermined data processing unit that uses the data file, for example, an application that executes predetermined image processing using data described in the data file.
つまり本発明によれば、データファイル解析装置が、上記データファイルを解析して生成する解析結果データは、文字列のデータファイルにおける記述位置を特定するアドレス情報と、文字列の属性とを備える。そのため、解析結果データの情報量は、従来のパーサが上記のようなデータファイルの解析結果として属性値の文字列自体を抽出していた場合と比較して大きく低減され、その結果、データファイルを利用する側においては、解析結果データを記録するのに必要なメモリ資源を大きく節約することが可能となる。
ここで、上記文字列はその属性と共に、タグとして上記データ内に記述されているとしてもよい。かかる構成によれば、例えばXML形式やXHTML形式によって記述されたデータファイルを対象として上記解析を行い、上記解析結果データを生成することができる。
That is, according to the present invention, the analysis result data generated by the data file analysis apparatus analyzing the data file includes address information for specifying the description position in the data file of the character string and the attribute of the character string. Therefore, the amount of information of the analysis result data is greatly reduced compared to the case where the conventional parser has extracted the character string itself of the attribute value as the analysis result of the data file as described above. On the use side, it is possible to greatly save memory resources necessary for recording analysis result data.
Here, the character string may be described in the data as a tag together with its attribute. According to this configuration, for example, the analysis can be performed on a data file described in the XML format or the XHTML format, and the analysis result data can be generated.
上記データファイルは、各データを文字列を含む状態にて記述した形式のファイルであれば特に限定されないが、一つの具体例として、上記データファイルは、画像を印刷する際のレイアウトを規定するデータを記述したスクリプトファイルであるとしてもよい。つまり、印刷することを目的として作成された画像データが存在する場合、この画像の印刷時のレイアウトを規定したスクリプトファイルも存在し得る。そこで、かかるスクリプトファイルを対象として上記解析結果データを生成するとすれば、スクリプトファイルを使用する所定のデータ処理手段において、少ないメモリ資源によって当該解析結果データを記録することが可能となる。 The data file is not particularly limited as long as it is a file in a format in which each data is described including a character string. As one specific example, the data file is data defining a layout for printing an image. It may be a script file in which is described. That is, when there is image data created for the purpose of printing, there can also be a script file that defines the layout for printing this image. Therefore, if the analysis result data is generated for such a script file, the analysis result data can be recorded with a small amount of memory resources in a predetermined data processing means using the script file.
ここで、上記のようなデータファイルの解析処理を行う構成と、解析によって得られた解析結果データを取得しこれを使用する側の構成とを併せた発明をも把握することができる。つまり、上記解析結果データを生成するデータファイル解析手段に加え、データファイル解析手段から解析結果データを取得し、同解析結果データを参照することにより、上記データファイルに記述された所定の属性を示す文字列の記述位置を特定する文字列処理手段とを備えるとしてもよい。つまり、解析結果データには、文字列のアドレス情報と属性との組み合わせが記録されているため、文字列処理手段は、かかる組み合わせを参照することにより、データファイル中から所定の文字列の記述位置を特定して文字列を読み出すことができる。また、同読み出した文字列に基づく表示処理など、所定の画像処理を行うことができる。 Here, it is also possible to grasp an invention that combines the configuration for performing the data file analysis processing as described above and the configuration for acquiring and using the analysis result data obtained by the analysis. That is, in addition to the data file analysis unit that generates the analysis result data, the analysis result data is acquired from the data file analysis unit, and the predetermined attribute described in the data file is indicated by referring to the analysis result data. Character string processing means for specifying the description position of the character string may be provided. That is, since the combination of the address information and the attribute of the character string is recorded in the analysis result data, the character string processing means refers to such a combination to describe the predetermined character string in the data file. The character string can be read by specifying In addition, predetermined image processing such as display processing based on the read character string can be performed.
さらに、文字列処理手段は、所定の入力受付手段を介して、データファイルに記録されている各文字列のうち書き換え可能な文字列について、換わりとなる新たな文字列を取得した際に、解析結果データを参照して書き換えを行うとしてもよい。具体的には、解析結果データを参照してデータファイル中の書き換え対象となる文字列の記述位置を特定し、同特定した記述位置における文字列を上記新たな文字列によって書き換える。
つまり、従来であれば、データファイル中の文字列を書き換えるには、書き換え対象とした文字列をデータファイル中において検索する必要があったが、本発明では、解析結果データに記録されたアドレス情報によってデータファイル中における書き換え対象とした文字列の記述位置を直ちに特定できるため、上記書き換え処理を迅速に行うことができる。
Further, the character string processing means analyzes the rewritable character string among the character strings recorded in the data file via a predetermined input receiving means when acquiring a new character string to be replaced. Rewriting may be performed with reference to the result data. Specifically, the description position of the character string to be rewritten in the data file is specified with reference to the analysis result data, and the character string at the specified description position is rewritten with the new character string.
That is, conventionally, in order to rewrite a character string in a data file, it was necessary to search the data file for a character string to be rewritten. In the present invention, however, the address information recorded in the analysis result data Thus, the description position of the character string to be rewritten in the data file can be immediately identified, so that the rewriting process can be performed quickly.
さらに、上記文字列処理手段は、上記書き換え処理を行った後、必要に応じて解析結果データに記録してあるアドレス情報を変更するとしてもよい。つまり、データファイル中のある文字列を書き換えたことによって書き換え前後における文字数に変動が生じた場合、同変動に応じて、データファイル中における他の文字列の記述位置が変化する場合がある。そこで、上記文字列処理手段は、上記文字数の変動に応じて、解析結果データに記録された各文字列のアドレス情報のうち、上記データファイルにおいて書き換え対象とした文字列以降に記述されている他の文字列についてのアドレス情報を変更する。その結果、後に他の文字列について読み出しや書き換えを行うときにも解析結果データを参照すれば、当該他の文字列についての正しいアドレス情報を取得することができる。つまり、複数の文字列に対して繰り返し書き換えを行う場合でも、上記構成によれば書き換え処理全体を迅速に行うことができる。 Further, the character string processing means may change the address information recorded in the analysis result data as necessary after performing the rewriting process. In other words, when the number of characters before and after rewriting changes due to rewriting a certain character string in the data file, the description position of another character string in the data file may change according to the change. Therefore, the character string processing means may be described after the character string to be rewritten in the data file in the address information of each character string recorded in the analysis result data according to the variation in the number of characters. Change the address information for the string. As a result, correct address information for the other character string can be acquired by referring to the analysis result data when reading or rewriting the other character string later. That is, even when rewriting is repeatedly performed on a plurality of character strings, the entire rewriting process can be quickly performed according to the above configuration.
上述のデータファイル解析装置にかかる技術的思想は、その手順を実行すデータファイル解析方法の発明としても把握でき、請求項7にかかる発明は、上記データファイル解析装置と同様の作用及び効果を発揮する。同様に、データファイル解析装置にかかる技術的思想は、その手順をコンピュータに実行させるデータファイル解析プログラムの発明として把握することもでき、請求項8にかかる発明も、上記データファイル解析装置と同様の作用、効果を有する。 The technical idea relating to the data file analysis device described above can be grasped as an invention of a data file analysis method for executing the procedure, and the invention according to claim 7 exhibits the same operations and effects as the data file analysis device. To do. Similarly, the technical idea of the data file analysis apparatus can be grasped as an invention of a data file analysis program for causing a computer to execute the procedure, and the invention according to claim 8 is the same as that of the data file analysis apparatus. Has action and effect.
さらに、上述のデータファイル編集装置にかかる技術的思想は、その手順を実行すデータファイル編集方法の発明としても把握でき、請求項9にかかる発明は、上記データファイル編集装置と同様の作用及び効果を発揮する。同様に、データファイル編集装置にかかる技術的思想は、その手順をコンピュータに実行させるデータファイル編集プログラムの発明として把握することもでき、請求項10にかかる発明も、上記データファイル編集装置と同様の作用、効果を有する。
Further, the technical idea of the data file editing apparatus can be grasped as an invention of a data file editing method for executing the procedure, and the invention according to claim 9 has the same operations and effects as the data file editing apparatus. Demonstrate. Similarly, the technical idea of the data file editing apparatus can be grasped as an invention of a data file editing program for causing a computer to execute the procedure, and the invention according to
下記の順序に従って本発明の実施形態を説明する。
(1)携帯電話の構成
(2)パッケージファイルの構成
(3)パッケージファイルの編集処理
(4)まとめ
Embodiments of the present invention will be described in the following order.
(1) Mobile phone configuration (2) Package file configuration (3) Package file editing process (4) Summary
(1)携帯電話の構成
図1は、本発明の一実施形態にかかる携帯電話10のハードウェア構成を示すブロック図である。携帯電話10は、通話やデータ通信など種々の機能を実現しており、その機能の一部として画像処理を実施することで画像処理装置として機能する。また、携帯電話10は、本発明にかかるデータファイル解析装置およびデータファイル編集装置として機能する。携帯電話10は、リムーバブルメモリI/F11aと、表示部12と、入力ボタン13と、通信部14と、CPU15と、ROM16と、RAM17と、ワークメモリ19とを備えている。CPU15はバス18を介して各部に接続されており、ROM16,RAM17と協働して所定のプログラムを実行することができる。
(1) Configuration of Mobile Phone FIG. 1 is a block diagram showing a hardware configuration of a
表示部12は、携帯電話10に備えられたディスプレイであり、CPU15の制御によって各種の画像やUI等を表示することができる。入力ボタン13は、複数の押しボタンを含み、CPU15は、利用者による押しボタンの押し込み操作を受け付け、各種の入力情報を取得することができる。通信部14は、CPU15の制御によって図示しない基地局との無線通信を実行し通話やデータ通信を実行する。ワークメモリ19は、後述のパッケージファイル11bの編集処理を実行する際に生成されるデータベース等の記録に利用され、本実施形態では、例えばフラッシュメモリを用いる。
The
リムーバブルメモリI/F11aにはリムーバブルメモリ11を装着可能であり、CPU15は、リムーバブルメモリ11に対してデータを書き込み、また、リムーバブルメモリ11からデータを読み出すことが可能である。本実施形態では、リムーバブルメモリ11には、画像を印刷する際の同画像のレイアウトを記述したスクリプトファイル11b1と、レイアウトを編集する際に携帯電話10にて印刷のサムネイル画像を表示するためのサムネイルデータファイル11b2と、印刷を実行する際にプリンタにて参照される印刷用データを記述した印刷用データファイル11b3という複数のデータファイルを一つにパッケージ化したパッケージファイル11bが記録されている。パッケージファイル11bの詳細は後述する。
A
パッケージファイル11bは、携帯電話10にて画像の表示を行う前にリムーバブルメモリ11に記憶されていれば良く、携帯電話10はこのパッケージファイル11bを所定のサーバからダウンロードによって取得してもよいし、他の機器(例えばパーソナルコンピュータ)から取得してもよい。パッケージファイル11bに含まれる複数のファイルは印刷のために用意されたファイルであるとも言える。この印刷は、図示しないプリンタにリムーバブルメモリ11を装着し、パッケージファイル11bに基づいてプリンタが印刷処理を行うことによって実行される。
The
(2)パッケージファイルの構成
図2は、パッケージファイル11bの一例を示す図である。同図に示すように、パッケージファイル11bは、スクリプトファイル11b1と、サムネイルデータファイル11b2と、印刷用データファイル11b3とを所定の順序にて合体させて構成した一つのファイルである。
本実施形態では、パッケージファイル11bに基づく画像処理や同パッケージファイル11bの編集を携帯電話10において実行する際に、使用するメモリ資源の節約や処理スピードの高速化を実現する構成を提案している。
(2) Configuration of Package File FIG. 2 is a diagram illustrating an example of the
The present embodiment proposes a configuration that realizes saving of memory resources to be used and speeding up of processing when the
スクリプトファイル11b1は、印刷時のレイアウトを特定するための複数のパラメータデータを含むファイルであり、本実施形態では、XML形式またはXHTML形式を採用し、いわゆるタグを利用してレイアウトのパラメータを記述している。具体的には、スクリプトファイル11b1では、各タグによって、印刷用紙の種類(大きさ(A4,はがき,L版等)や品質(光沢紙、普通紙等)、印刷画像のレイアウト上に配置可能な文字枠の位置、文字枠の大きさ、文字枠内に含め得る文字の上限値(文字数)、文字の大きさ等を記述する。また、各文字枠に対する編集作業にて入力する文字を示すデータも記述可能になっている。 The script file 11b1 is a file including a plurality of parameter data for specifying a layout at the time of printing. In this embodiment, the XML format or the XHTML format is adopted, and a layout parameter is described using a so-called tag. ing. Specifically, in the script file 11b1, the type (size (A4, postcard, L plate, etc.) and quality (glossy paper, plain paper, etc.) of the printing paper, and the layout of the printing image can be arranged by each tag. Describes the position of the character frame, the size of the character frame, the upper limit of the number of characters that can be included in the character frame (number of characters), the size of the character, etc. Data indicating the characters entered in the editing operation for each character frame Can also be described.
図3は、スクリプトファイル11b1のデータ構造の一例を示している。
スクリプトファイル11b1は各行において、「<(左アンクルブラケット)」,「>(右アングルブラケット)」で左右を挟んだ状態にてデータを記述しており、本実施形態では、各行における<>で囲んだ文字列全体をタグと呼ぶ。各タグは、タグ名と、属性と、属性値とによって構成されている。同図における上からn1行目のタグを例に説明すると、「<」の次の位置に記載された文字列「meta」がタグ名であり、タグ名の後に記述された文字列「name」および「content」が属性であり、各属性の後に「”(ダブルクォーテイション)」で挟まれて記述された文字列「aaa」および「bbb」がそれぞれ対応する属性の属性値を示している。スクリプトファイル11b1においては、上記のレイアウトを特定する各データを各属性の属性値として文字列で記述している。
FIG. 3 shows an example of the data structure of the script file 11b1.
The script file 11b1 describes data in a state where the left and right are sandwiched between “<(left ankle bracket)” and “> (right angle bracket)” in each line. In this embodiment, the data is enclosed in <> in each line. The entire string is called a tag. Each tag includes a tag name, an attribute, and an attribute value. In the figure, the tag on the n1 line from the top will be described as an example. The character string “meta” described at the position next to “<” is the tag name, and the character string “name” described after the tag name. And “content” are attributes, and character strings “aaa” and “bbb” described by being sandwiched by “” (double quotation) ”after each attribute indicate attribute values of the corresponding attributes. In the script file 11b1, each piece of data specifying the layout is described as a character string as an attribute value of each attribute.
サムネイルデータファイル11b2は、携帯電話10の表示部12で表示可能な画素数で印刷対象の画像を表示するためのデータであり、本実施形態においてはEXIF形式を採用している(EXIFは社団法人電子情報技術産業協会の登録商標)。従って、SOI(Start of Image)マーカから始まり、EOI(End of Image)マーカで終わるファイルにおいて、予め決められたマーカやデータが含まれている。
The thumbnail data file 11b2 is data for displaying an image to be printed with the number of pixels that can be displayed on the
この形式において、本実施形態では、2つのサムネイルデータを含めてひとつのファイルにしている。つまり、一方のサムネイルデータをアプリケーションマーカ部分(図2にて「APP7」と示す部分。)に記述し、他方のサムネイルデータを圧縮データ部分(図2にて「圧縮データ」と示す部分、通常は圧縮画像データの本体が格納される。)に記述している。 In this format, in the present embodiment, a single file including two thumbnail data is provided. That is, one thumbnail data is described in the application marker portion (a portion indicated as “APP7” in FIG. 2), and the other thumbnail data is indicated as a compressed data portion (a portion indicated as “compressed data” in FIG. The main body of the compressed image data is stored).
上記2つのサムネイルデータは、アプリケーションマーカ部分に記述されたものが編集前の画像データ、圧縮データ部分に記述されたものが編集後の画像データであり、大きさ(画素数)は双方とも同じであり、双方ともJPEG形式で圧縮されている。ここで、編集前の画像データは、編集にて入力可能な文字についてはこれを含まない画像となっている。従って、編集前の画像データに基づいて画像を表示したときには、文字枠および文字枠に挿入され得る文字は表示されない。例えば、図2に示すように編集前の画像が、日の出の画像の背景に「あけましておめでとう」という文字を重ねた画像であるときには、図2の中央に示すように日の出の画像と「あけましておめでとう」という文字を表示するための画像が編集前の画像データになる(ここでいう「あけましておめでとう」の文字は、編集にて入力される文字ではない。)。 Of the above two thumbnail data, the image data described in the application marker part is the image data before editing, and the data described in the compressed data part is the image data after editing, both of which have the same size (number of pixels). Yes, both are compressed in JPEG format. Here, the image data before editing is an image that does not include characters that can be input by editing. Therefore, when an image is displayed based on the image data before editing, the character frame and characters that can be inserted into the character frame are not displayed. For example, as shown in FIG. 2, when the image before editing is an image in which the characters “Happy New Year” are superimposed on the background of the sunrise image, the sunrise image and “Happy New Year” as shown in the center of FIG. 2. The image for displaying the character is the image data before editing (the character “Happy New Year” here is not the character input by editing).
一方、編集後の画像データは、編集前の画像とともにレイアウト上に文字を配置した後の画像を示している。従って、編集後の画像データに基づいて画像を表示したときには、画像上の所定位置に設定されている文字枠位置に文字が挿入された状態の画像が表示される。例えば、後述の編集画面を介して「郵便番号」「住所」「名前」等の文字枠に対して何らかの文字を入力する編集を行った後には、その文字と編集前の画像が重畳され、「郵便番号」「住所」「名前」等の編集内容を含む画像が編集後の画像データになる。なお、携帯電話10によるパッケージファイル11bに対する編集を一回も行っていない段階では、編集前の画像データと編集後の画像データとはまったく同じデータである。
On the other hand, the image data after editing indicates an image after characters are arranged on the layout together with the image before editing. Therefore, when an image is displayed based on the edited image data, an image in which characters are inserted at a character frame position set at a predetermined position on the image is displayed. For example, after performing an edit to input some characters into a character frame such as “zip code”, “address”, “name”, etc. via an edit screen described later, the character and the image before editing are superimposed. An image including edited contents such as a zip code, an address, and a name becomes image data after editing. It should be noted that the image data before editing and the image data after editing are exactly the same data when the
(3)パッケージファイルの編集処理
図4は、携帯電話10による編集処理を示すフローチャートである。携帯電話10の利用者は、携帯電話10の入力ボタン13を操作して、ROM16に保存された編集プログラム(データファイル解析プログラムおよびデータファイル編集プログラムの内容を備える)を起動可能であり、当該編集プログラムによって図4に示す編集処理が実施される。当該フローを実行する前提として、リムーバブルメモリ11には、利用者の所望のパッケージファイル11b(パッケージファイルの数は任意である。)が記憶されている状態であるとする。つまり利用者は、入力ボタン13を操作して所定のサーバからのパッケージファイル11bのダウンロード等を行い、所望のパッケージファイル11bをリムーバブルメモリ11に記憶させる。
(3) Package File Editing Processing FIG. 4 is a flowchart showing editing processing by the
まず、ステップS(以下、ステップの表記を省略する。)200では、CPU15は、リムーバブルメモリ11に保存されているパッケージファイル11bの中から一つのパッケージファイル11bを選択する。この場合、携帯電話10の利用者は、入力ボタン13を操作してパッケージファイル11bの選択を行う。つまり、CPU15は、リムーバブルメモリ11にアクセスし、当該リムーバブルメモリ11に記憶されている複数のパッケージファイル11bを認識し、表示部12の表示を制御してそれらのいずれかを選択できるように選択肢を提供する。利用者は入力ボタン13によって所望のパッケージファイル11bを指示し、CPU15がその指示内容を取得すると、パッケージファイル11bの選択が確定する。
First, in step S (hereinafter, step notation is omitted) 200, the
次にCPU15は、上記選択したパッケージファイル11bにおけるサムネイルデータファイル11b2からサムネイルデータを抽出する。このとき、初編集と再編集とで表示対象となる画像は異なり、CPU15は、上記選択されたパッケージファイル11bの編集が再編集であるか否かを判別する(S205)。ここでは、再編集であるか否かを判別することができればよく、再編集であるか否かを判別するためのフラグ等をパッケージファイル11bに含めてもよいし、サムネイルデータファイル11b2に記述されている編集前の画像データと編集後の画像データを比較してもよいし、種々の構成を採用可能である。
Next, the
S205において、再編集ではないと判別されたときには、サムネイルデータファイル11b2のアプリケーションマーカ部分から編集前の画像データを取得する(S210)。ただし、再編集ではない場合は、編集前の画像データと編集後の画像データとは同一内容となっているため、S210においては、アプリケーションマーカ部分から画像データを取得することは必須ではなく、圧縮データ部分から編集後の画像データを取得するようにしてもよい。S205において、再編集であると判別されたときには、サムネイルデータファイル11b2の圧縮データ部分から編集後の画像データを取得する(S215)。
CPU15は、取得した画像データに基づいて表示部12にサムネイル画像を表示する(S220)。また、ここでは、画像の表示とともに編集開始指示を受け付けるためのUIも表示する。
If it is determined in S205 that it is not re-editing, image data before editing is acquired from the application marker portion of the thumbnail data file 11b2 (S210). However, if it is not re-editing, the image data before editing and the image data after editing have the same contents, and therefore in S210, it is not essential to acquire image data from the application marker portion, and compression is performed. Image data after editing may be acquired from the data portion. If it is determined in S205 that re-editing is performed, the edited image data is acquired from the compressed data portion of the thumbnail data file 11b2 (S215).
The
図5は、携帯電話10において編集を行う際に表示部12で表示する画面の例を示す図である。同図においては、再編集である場合に表示部12に表示されるサムネイル画像の例を(a)として示している。図5(a)においては、画面の中央に編集前の画像データに基づく画像が表示され、左下に編集開始指示を受け付けるための編集ボタンが表示されている。なお、かかる編集ボタンは、編集前の画像データに基づく画像を表示する場合でも表示される。編集後の画像データにおいては、図5(a)にて破線で示す文字枠において何らかの文字が表示される。なお、図5(a)では理解の容易のために文字枠を破線で示しているが、実際の表示画面において破線は表示されない。すなわち、編集前または編集後の画像データは印刷画像のプレビューであり、印刷時に文字枠は印刷しないため、文字枠を明示的に示していない。
FIG. 5 is a diagram illustrating an example of a screen displayed on the
また、図5(a)において左下に示す編集ボタンは入力ボタン13のいずれかに対応しており、CPU15は、この編集ボタンによる編集開始指示を受け付けたか否かを判別している(S225)。すなわち、図5(a)のような画面表示を行っている状態で、CPU15は上記編集ボタンに対応した入力ボタン13の操作を受け付けたか否かを判別している。
Further, the edit button shown in the lower left in FIG. 5A corresponds to one of the
S225にて編集開始指示を受け付けたと判別されたときには、CPU15は、S230において、上記選択したパッケージファイル11bに含まれるスクリプトファイル11b1を対象としたデータファイル解析処理を実行する。ここでいう解析処理とは、上述したようにタグを用いて記述されているスクリプトファイル11b1に基づいて、以後における編集画面の表示処理やレイアウト上に配置可能な文字の編集処理等の際に参照して好適なデータベース(DB)30を生成する処理を指す。
If it is determined in S225 that an editing start instruction has been received, the
図6は、CPU15がスクリプトファイル11b1を解析して生成したDB30を示している。
同図に示すように、DB30は、スクリプトファイル11b1の各行毎に、タグ名と、属性と、属性値のアドレス情報とを抽出して生成した情報テーブルである。DB30は、特許請求の範囲に言う解析結果データに対応する。図3のスクリプトファイル11b1に基づいてDB30を生成した場合、図6に示すように、n1行目のタグ名「meta」に対応した情報として、属性「name」とその属性値のアドレス情報「n1行目,12文字目」、および属性「content」とその属性値のアドレス情報「n1行目,26文字目」が記録される。また、n2行目のタグ名「住所」に対応した情報として、属性「Zipcode」とその属性値のアドレス情報「n2行目,13文字目」、および属性「Address」とその属性値のアドレス情報「n2行目,32文字目」が記録される。
FIG. 6 shows the DB 30 generated by the
As shown in the figure, the DB 30 is an information table generated by extracting the tag name, attribute, and attribute value address information for each line of the script file 11b1. The DB 30 corresponds to analysis result data referred to in the claims. When the DB 30 is generated based on the script file 11b1 of FIG. 3, as shown in FIG. 6, as the information corresponding to the tag name “meta” on the n1 line, the attribute “name” and the address information “n1” of the attribute value are included. "Line, 12th character", attribute "content", and address information "n1st line, 26th character" of the attribute value are recorded. Further, as information corresponding to the tag name “address” on the n2th line, the attribute “Zipcode” and the address information “n2th line, 13th character” of the attribute value, the attribute “Address” and the address information of the attribute value “N2 line, 32nd character” is recorded.
アドレス情報とは、スクリプトファイル11b1中での各属性値の文字列の記述位置を特定する情報である。より具体的には、属性値の文字列が何行目の何文字目に記述されているかを示す情報である。属性「name」の属性値「aaa」に注目すると、図3によればその文字列は、n1行目のタグにおいて、頭文字が12文字目(左アンクルブラケットの次から数えた場合。またスペースも1文字とする。)に記述されている。従って、属性「name」の属性値のアドレス情報は上記「n1行目,12文字目」となる。同様に、属性「content」の属性値「bbb」は、n1行目のタグにおいて頭文字が26文字目に記述されている。そのため、属性「content」の属性値のアドレス情報は上記「n1行目,26文字目」となる。 The address information is information that specifies the description position of the character string of each attribute value in the script file 11b1. More specifically, this is information indicating in what line and what character the character string of the attribute value is described. When attention is paid to the attribute value “aaa” of the attribute “name”, according to FIG. 3, the character string of the tag on the n1 line is the 12th initial character (when counted from the next of the left ankle bracket. Is also a single character). Therefore, the address information of the attribute value of the attribute “name” is the “n1th line, 12th character”. Similarly, the attribute value “bbb” of the attribute “content” is described with the first character as the 26th character in the tag on the n1th line. Therefore, the address information of the attribute value of the attribute “content” is the “n1st line, 26th character”.
むろん、図6に示すアドレス情報「n2行目,13文字目」は、属性「Zipcode」の属性値「123‐4567」の頭文字の記述位置であり、アドレス情報「n2行目,32文字目」は、属性「Address」の属性値「長野県塩尻市」の頭文字の記述位置である。
従って、アドレス情報に基づいてスクリプトファイル11b1からある属性の属性値を読み出す場合には、アドレス情報が指し示す位置から次の「”」の前まで連続する文字列を読み出せばよい。
Of course, the address information “line n2,
Therefore, when an attribute value of a certain attribute is read from the script file 11b1 based on the address information, a continuous character string from the position indicated by the address information to before the next “” ”may be read.
なお上記においてアドレス情報は、各属性値の文字列の頭文字の位置を定義しているが、かかる定義に限定されるものではない。ここで、各属性値の文字列は「”」によって前後を挟まれているので、アドレス情報は、属性の後の「=(イコール)」の後に記述されている「”」の位置を示すものとしてもよい。この場合、アドレス情報に基づいてある属性の属性値を読み出す場合には、アドレス情報が指し示す位置から次の「”」までの間に連続している文字列を読み出せばよい。
さらに、アドレス情報はスクリプトファイル11b1中での各属性値の文字列の記述位置を特定可能な情報であればよい。つまり、上記のように「何行目,何文字目」という情報形態に限る必要はなく、例えば、スクリプトファイル11b1の先頭文字(例えば、最上行の最も左の文字)から所定の走査順で数えて何文字目かを示す数字をアドレス情報としてもよい。
In the above, the address information defines the position of the initial character of the character string of each attribute value, but is not limited to such definition. Here, since the character string of each attribute value is sandwiched between “” ”, the address information indicates the position of“ ”” described after “= (equal)” after the attribute. It is good. In this case, when an attribute value of an attribute is read based on the address information, a character string continuous between the position indicated by the address information and the next “” ”may be read.
Furthermore, the address information may be information that can specify the description position of the character string of each attribute value in the script file 11b1. That is, it is not necessary to limit to the information form of “what line, what character” as described above, for example, counting in a predetermined scanning order from the first character (for example, the leftmost character on the top line) of the script file 11b1. The number indicating the number of characters may be used as the address information.
ここで、スクリプトファイル11b1を解析して上記のようなDB30を生成する処理について詳述する。図8は、S230における処理内容の一例をフローチャートにより示している。
S300においては、CPU15は、スクリプトファイル11b1の各行のうち検索対象とする一つの行(対象行)を設定する。基本的には、最上行から最下行に向かって順に設定していけばよいが、特定の順序に従ったりあるいはランダムな順序で一つの対象行を決定してもよい。
Here, the process of analyzing the script file 11b1 and generating the DB 30 as described above will be described in detail. FIG. 8 is a flowchart showing an example of the processing content in S230.
In S300, the
S310では、上記設定した対象行中に記述されている「<」の位置を特定する。対象行中の「<」の位置を特定することで、以後において、属性値の文字列の記述位置を特定することができる。
S320では、上記特定した「<」から右方向に向かって走査を行い、その行に記述されている属性を全て検索する。例えば、対象行がn1行目であれば、属性「name」および属性「content」の文字列が発見されることになる。S330では、属性を発見したか否か判断しており、発見を完了した場合に、S340の処理に進む。
In S310, the position of “<” described in the set target line is specified. By specifying the position of “<” in the target line, the description position of the character string of the attribute value can be specified thereafter.
In S320, scanning is performed from the specified “<” toward the right, and all attributes described in the line are searched. For example, if the target row is the n1th row, the character strings of the attribute “name” and the attribute “content” are found. In S330, it is determined whether or not the attribute has been found. When the discovery is completed, the process proceeds to S340.
S340においては、CPU15は、「<」の次の文字位置から上記発見した各属性に対応する属性値の頭文字位置(属性「name」に対応する属性値「aaa」の頭文字位置および、属性「content」に対応する属性値「bbb」の頭文字位置)までの文字数をそれぞれカウントする。
S350では、上記対象行のタグ名を取得する。n1行目であれば、タグ名「meta」の文字列を取得する。
以上の処理によって、ある対象行における、タグ名と属性と属性値の当該行における記述位置とが取得できたことになる。
In S340, the
In S350, the tag name of the target line is acquired. If it is the n1st line, the character string of the tag name “meta” is acquired.
Through the above processing, the tag name, the attribute, and the description position of the attribute value in the target line can be acquired.
S360では、CPU15は、スクリプトファイル11b1を構成する全行についてS350までの処理を行ったか否か判断し、未処理の行が残存する場合にはS300に戻り、対象行を変更した上でS350までの処理を繰り返す。一方、全行についてS350までの処理を行ったと判断した場合は、S370の処理に進む。
S370においては、CPU15は、上記の処理によって取得した各行についての情報を用いてDB30を構築する。つまり、各行毎にタグ名と属性と属性値のアドレス情報とを記録した図3に示すようなDB30を生成する。むろん、アドレス情報は、各行の行番号とS340においてカウントして得た記述位置によって構成する。
In S360, the
In S370, the
このように本発明では、タグを利用して属性と属性値との組み合わせによって印刷画像のレイアウトの各種パラメータを記述するスクリプトファイル11b1の解析結果として、属性とその属性値の文字列そのものとではなく、属性とその属性値のアドレス情報とを抽出し、それらによってDB30を構成する。ただし本実施形態では、DB30を生成する場合に、属性値としての文字列そのものを構成要素に加えることを完全に禁止しているわけではなく、ある条件の下、属性値の文字列についてもスクリプトファイル11b1から抽出しDB30に加えている。かかる条件については後述する。 As described above, according to the present invention, the analysis result of the script file 11b1 that describes various parameters of the layout of the print image by using the tag and the combination of the attribute and the attribute value is not the attribute and the character string itself of the attribute value. , Attributes and address information of the attribute values are extracted, and the DB 30 is constituted by them. However, in the present embodiment, when the DB 30 is generated, it is not completely prohibited to add the character string itself as the attribute value to the constituent element. Extracted from the file 11b1 and added to the DB 30. Such conditions will be described later.
S235においては、CPU15は、上記のように生成したDB30を所定の記録領域に保存する。本実施形態では、DB30はワークメモリ19に保存する。以降においては、CPU15は、DB30を参照することにより、スクリプトファイル11b1にアクセスすることが可能となる。
S240においては、CPU15は、スクリプトファイル11b1にアクセスして所定の編集画面を表示するために必要なデータを読み出し、同読み出したデータに基づいた編集画面の表示を同表示部12に実行させる。つまり、CPU15は、DB30を参照して各タブにおける属性と属性値のアドレス情報との対応関係を取得し、同対応関係に基づいて、スクリプトファイル11b1中から必要とする属性値を読み出し、同読み出した属性値に基づいて編集画面を表示させる。
In S235, the
In S240, the
CPU15は、編集画面を表示する際に、スクリプトファイル11b1から、各文字枠に対応した項目名を表示するためのデータである属性値や、各文字枠の文字数を規定したデータである属性値などを読み出すことにより、図5(b)に示すような編集画面を表示部12に表示させる。同図においては、編集画面は、画像に配置する文字を入力させるための複数の入力ボックスを、各入力ボックスの項目名とともに表示する。ここでは、「郵便番号」「住所」「名前」の各項目名とともに、郵便番号、住所、名前をそれぞれ入力させるための入力ボックスを表示している。
When the
なお、CPU15は、上記編集画面を表示させる場合、DB30を参照して属性「Zipcode」や属性「Address」など、編集画面の入力ボックスを介して入力される文字データに対応する属性について、アドレス情報を取得するとともに、同アドレス情報によってスクリプトファイル11b1に記述されている属性値を読み出し、同読み出した属性値の文字列に基づく表示を上記入力ボックス内に行う。本実施形態では、スクリプトファイル11b1の属性「Zipcode」や属性「Address」について、既に具体的な意味を持つ属性値が記述されている状態であるため、スクリプトファイル11b1は少なくとも一度は上記編集画面を介しての編集を施されている。従って、S240において表示する編集画面の各入力ボックスには、郵便番号「123‐4567」や住所「長野県塩尻市」などが表示される。なお、初編集前の状況では、CPU15は、空の入力ボックスを表示部12に表示させることになる。
When displaying the above editing screen, the
この編集画面において、CPU15は、入力ボタン13による入力ボックスの指示および文字の入力を受け付けており(S245)、また、入力ボタン13によって文字入力の終了指示がなされたか否かを判別している(S250)。本実施形態では、入力ボックスにおいて上記文字数を超える文字を受け付けないようにしており、これによって文字枠内に収まる範囲内で文字を編集できるようにしている。利用者が入力ボタン13の操作によって新たな郵便番号などを入力した場合、CPU15は、図5の(b)に示した入力ボックス中のそれまでの郵便番号等を消去し、新たな郵便番号等を同入力ボックスに表示する。
In this editing screen, the
S250にて文字入力の終了指示がなされたと判別されると、CPU15は、その時点で入力されていた各項目への文字にて入力内容を確定し、その入力内容を示す文字列(新たな文字列)によって、スクリプトファイル11b1中の書き換え可能な所定の属性値を更新する(S255)。かかる更新処理を行うに際しても、CPU15はDB30を参照する。すなわち、DB30を参照することにより、そのとき書き換え対象としている属性値のアドレス情報を属性との対応関係から認識し、そのアドレス情報によってスクリプトファイル11b1における書き換え対象としている属性値の記述位置を特定し、同特定した位置に記述されている属性値(文字列)を上記新たな文字列によって書き換える。
If it is determined in S250 that an instruction to end character input has been issued, the
例えば、図3に示した、スクリプトファイル11b1のタグ名「住所」の行に記述されている属性値を書き換える場合について説明する。スクリプトファイル11b1に記述されている各属性値は、携帯電話10の操作において書き換え可能なものと書き換え不能なものとがあるが、タグ名「住所」の行に記述されている二つの属性値はいずれも、上記編集画面を介した入力作業によって書き換え可能な部類に属する。
For example, a case where the attribute value described in the tag name “address” line of the script file 11b1 shown in FIG. 3 is rewritten will be described. Each attribute value described in the script file 11b1 may be rewritable or non-rewritable in the operation of the
上記編集画面を介して、新たな郵便番号が入力された場合、CPU15は、DB30を参照して、タグ名「住所」における属性「Zipcode」に対応して記録されているアドレス情報「n2行目,13文字目」を取得し、このアドレス情報によってスクリプトファイル11b1中の一つの位置を特定する。その結果、n2行目における「<」の次から数えて13文字目の位置が特定できるため、同特定した位置から「”」が記述されている位置の前まで連続する文字列(この場合、123‐4567)を、新たな郵便番号(例えば、456‐78900)を示す文字列によって書き換える。
When a new zip code is input via the editing screen, the
また、上記編集画面を介して、新たな住所が入力された場合、CPU15は、DB30を参照して、タグ名「住所」における属性「Address」に対応して記録されているアドレス情報「n2行目,32文字目」を取得し、このアドレス情報によってスクリプトファイル11b1中の一つの位置を特定する。ただしこの場合、同じ行に記述されている属性「Zipcode」の属性値が既に書き換えられている。そのため、かかる書き換えによって属性「Zipcode」の属性値の文字数が変動している場合(例えば、1文字増加している場合)には、CPU15は、その変動数に応じてアドレス情報のうち文字数を表す箇所を変更(32に1を足す)し、同変更後のアドレス情報によって位置を特定する。その結果、属性「Address」の属性値の文字列の頭文字位置が正確に特定できるため、同特定した位置から「”」が記述されている位置の前まで連続する文字列(この場合、長野県塩尻市)を、新たな住所(例えば、東京都新宿区)を示す文字列によって書き換える。
In addition, when a new address is input via the editing screen, the
S260では、CPU15は、上記文字列の書き換えに応じてアドレス情報の変更の必要が生じた場合に、DB30に記録してあるアドレス情報を更新する。つまり、上記のように書き換え対象とした属性値としての文字列の書き換え前後における文字数が変動した場合には、同じ行であってその文字列以後に記述されている他の属性値としての文字列の記述位置がずれることとなる。そのため、かかるずれに応じて、DB30に記録している所定の属性値のアドレス情報を更新する(アドレス情報のうち文字数を表す箇所の数字を増減させる)。かかる更新をすることで、以降においてDB30を参照した場合に、スクリプトファイル11b1中に記述されている各属性値の記述位置を正確に特定することができる。
In S260, the
S265では、上記スクリプトファイル11b1の書き換えに応じて、サムネイルデータファイル11b2の内容を書き換える。すなわち、スクリプトファイル11b1は画像のレイアウトを規定しており、上述のようなスクリプトファイル11b1の更新により、携帯電話10において表示すべきサムネイル画像のレイアウトも変更されることになる。そこで、S265においては、CPU15は、編集後の画像データを作成し、同生成した編集後の画像データによってサムネイルデータファイル11b2を一部更新する。
In S265, the contents of the thumbnail data file 11b2 are rewritten in accordance with the rewriting of the script file 11b1. That is, the script file 11b1 defines the image layout, and the thumbnail image layout to be displayed on the
S265における処理を詳述すると以下のようになる。CPU15は、サムネイルデータファイル11b2のアプリケーションマーカ部分から編集前の画像データを読み出すとともに、DB30を参照して取得した各属性とアドレス情報とをもとに、スクリプトファイル11b1にアクセスし、同スクリプトファイル11b1から、文字枠の位置、各文字枠への入力文字、文字の大きさ、印刷用紙の大きさ等の内容を示すデータを読み出す。これらのデータはそれぞれに、所定の属性に対応付けられて属性値としてスクリプトファイル11b1に記述されている。
The process in S265 will be described in detail as follows. The
このように必要な情報を読み出したら、CPU15は、上記画像データ上における各文字枠の位置を特定し、この特定した位置に上記編集画面を介して受け付けた各文字枠への入力文字を配置する。このとき、配置する文字については、スクリプトファイル11b1に記述していた上記文字の大きさ(フォントサイズ)を所定の縮小比(印刷用紙の大きさと表示部12が表示する画像のサイズとの比)で縮小した大きさにて配置する。この結果、上記編集画面を介して入力した文字が適正な大きさで適正な位置に配置された場合の画像のプレビュー画像が作成されることになるので、この画像データを新たな編集後の画像データとし、上記サムネイルデータファイル11b2を更新する(サムネイルデータファイル11b2の圧縮データ部分に既に記録してある編集後の画像データを新たな編集後の画像データによって書き換える。)。
When the necessary information is read out in this way, the
なお、スクリプトファイル11b1に記述されている属性値は、図6の「aaa」の表示のように、DB30にも記述する場合がある。本発明では、DB30には属性値自体は記録しないのが基本であるが、書き換え対象とはならず読み出し専用であるという条件と文字数自体がある基準数よりも少ないという条件とのいずれか一方または両方を備える属性値については、例外的に、DB30に記録することを許容している。つまり、読み出されるだけの属性値であれば、同読み出しの際にDB30を参照した後にスクリプトファイル11b1にアクセスする手順が無駄であるため、DB30に記録しておき、読み出しにかかる時間を短縮する。また、文字数が少ない属性値であればワークメモリ19の浪費という問題も少ないため、DB30に記録してもよい。DB30に記録されている属性値については、上記においてスクリプトファイル11b1から属性値を読み出すとしている場面においても、CPU15はDB30から読み出すものとする。
さらには、上記のような書き換え対象とはならず読み出し専用の属性値については、DB30にその文字列自体を記録するとともに、そのアドレス情報は記録しないとしても良い。
Note that the attribute value described in the script file 11b1 may also be described in the DB 30 as shown by “aaa” in FIG. In the present invention, the attribute value itself is basically not recorded in the DB 30, but either one of the condition that the attribute value itself is not a rewriting target and is read-only and the number of characters itself is less than a certain reference number or An attribute value having both is exceptionally permitted to be recorded in the DB 30. In other words, if the attribute value is just read, the procedure for accessing the script file 11b1 after referring to the DB 30 at the time of the read is useless, so it is recorded in the DB 30 to shorten the time required for reading. Further, if the attribute value has a small number of characters, the problem of wasting the
Furthermore, for the read-only attribute value that is not subject to rewriting as described above, the character string itself may be recorded in the DB 30 and the address information may not be recorded.
以上の処理により、スクリプトファイル11b1とサムネイルデータファイル11b2の更新が終了する。なお、印刷用データファイル11b3についても、スクリプトファイル11b1とサムネイルデータファイル11b2の更新内容に応じて、その内容を更新するとしてもよい。 With the above processing, the update of the script file 11b1 and the thumbnail data file 11b2 is completed. The contents of the print data file 11b3 may be updated according to the update contents of the script file 11b1 and the thumbnail data file 11b2.
S270においては、CPU15は、入力ボタン13を介して、パッケージファイル11bに対する編集処理を繰り返す指示(再編集指示)を受け付けたか否か判断する。つまり、上記編集画面を表示して各項目に対する文字の入力を受付てスクリプトファイル11b1とサムネイルデータファイル11b2の更新を済ませた後に、再度、同じパッケージファイル11bを選択した状態にて利用者が上記編集を希望した場合には上記再編集指示が入力されるため、CPU15は、同再編集指示に応じてS215以下の処理を繰り返す。S270において、再編集指示を受け付けたと判断されない場合は、当該フローチャートを終了する。
In S <b> 270, the
図7は、サムネイル画像の変移の様子を説明するための説明図である。
同図(a)においては、一度も編集を行っていないときの画像を表示している表示部12の画面を示している。この画面は、S205にて再編集であると判別されなかったときにS220にて表示される画面であり、サムネイルデータファイル11b2における編集前の画像データに基づいて表示される画面を示している。
FIG. 7 is an explanatory diagram for explaining the transition of thumbnail images.
FIG. 4A shows a screen of the
図7(b)は、この編集前の画像データについてS225〜S265の処理に基づいて編集を行った後に表示部12に表示される画面を示している。すなわち、一旦編集を行った後に、再度の編集を行う場合、S215にて編集後の画像データが取得されるので、表示部12には編集後の画像が表示される。
FIG. 7B shows a screen displayed on the
以上のように、編集前には図7(a)が表示されることによって、利用者は画像が未編集であることを容易に判定することができるし、編集後には図7(b)が表示されることによって、利用者は画像が編集済みであることを容易に判定することができる。
図7(c)は、図7(b)に示す状態から更に再編集を行った場合に表示部12にて表示される画面を示している。この場合、S225〜S265の処理によって、受け付けた文字をサムネイル画像に配置した状態の画像データが作成されることになるが、このとき、上述したようにS265において、サムネイルデータファイル11b2から編集前の画像データを抽出し、この画像データに対して上記縮小後の文字を配置する。従って、この編集の直前に、編集後の画像が図7(b)のようになっていたとしても、図7(b)にて配置されている文字を削除し、また、配置前の画像を再描画することなく、単に編集前の画像に上記縮小後の文字を配置するのみで新たな編集後の画像データを作成することができる。
As described above, FIG. 7A is displayed before editing, so that the user can easily determine that the image has not been edited, and FIG. 7B is displayed after editing. By being displayed, the user can easily determine that the image has been edited.
FIG. 7C shows a screen displayed on the
(4)まとめ
このように本発明においては、携帯電話10におけるパッケージファイル11bの編集処理に際し、同パッケージファイル11bの一部を構成するスクリプトファイル11b1を解析して、各タグ毎に属性とその属性値のアドレス情報とを抽出してDB30を生成し、このDB30をワークメモリ19に保存するとした。よって、従来のパーサが行っていたような、各タグ毎の属性とその属性値の文字列そのものを抽出してメモリに記録していた場合と比較して、ワークメモリ19におけるメモリ資源の消費を大きく低減することができる。
(4) Summary As described above, in the present invention, when editing the
特に、スクリプトファイル11b1に記述されている属性値の文字数が多い場合には、これを直接にワークメモリ19に記録することはメモリ資源の消費が大きくなってしまうが、本発明の構成を用いることで、もともとリソースの少ない携帯電話10という機器において、確実にメモリ消費の抑制を図ることができる。
In particular, when the number of characters of the attribute value described in the script file 11b1 is large, recording this directly in the
また、上記編集においてスクリプトファイル11b1のある文字列(属性値)を書き換える場合、従来においては、スクリプトファイル11b1の中から書き換え対象とした文字列と一致するものを探す検索処理を実行する必要があり、かかる検索処理はCPU15にとって大きな負担であった。しかし本発明では、上記のような検索処理は不要であり、DB30に記録したアドレス情報に基づいて、スクリプトファイル11b1中の書き換え対象とした文字列を直ちに特定できるため、同書き換え処理を格段に高速化することができる。
Further, when a character string (attribute value) in the script file 11b1 is rewritten in the above editing, conventionally, it is necessary to execute a search process for searching the script file 11b1 for a character string that matches the character string to be rewritten. Such search processing is a heavy burden on the
10…携帯電話、11…リムーバブルメモリ、11a…リムーバブルメモリI/F、11b…パッケージファイル、11b1…スクリプトファイル、11b2…サムネイルデータファイル、11b3…印刷用データファイル、12…表示部、13…入力ボタン、14…通信部、15…CPU、16…ROM、17…RAM、19…ワークメモリ、30…データベース(DB)
DESCRIPTION OF
Claims (10)
上記データファイル解析手段から解析結果データを取得するとともに、同解析結果データを参照することにより、上記データファイルに記述された所定の属性を示す文字列の記述位置を特定し同特定した記述位置から文字列を読み出す文字列処理手段とを備えることを特徴とするデータファイル編集装置。 By analyzing a data file in which each data is described including a character string, address information for specifying the description position in the data file of the character string and the attribute of the character string are obtained. Data file analysis means for generating recorded analysis result data;
The analysis result data is obtained from the data file analysis means, and by referring to the analysis result data, the description position of the character string indicating the predetermined attribute described in the data file is specified and the specified description position is used. A data file editing device comprising character string processing means for reading a character string.
上記解析結果データを取得して同解析結果データを参照することにより、上記データファイルに記述された所定の属性を示す文字列の記述位置を特定し同特定した記述位置から文字列を読み出すことを特徴とするデータファイル編集方法。 By analyzing a data file in which each data is described including a character string, address information for specifying the description position in the data file of the character string and the attribute of the character string are obtained. Generate the recorded analysis result data,
By obtaining the analysis result data and referring to the analysis result data, the description position of the character string indicating the predetermined attribute described in the data file is specified, and the character string is read from the specified description position. Characteristic data file editing method.
上記解析結果データを取得して同解析結果データを参照することにより、上記データファイルに記述された所定の属性を示す文字列の記述位置を特定し同特定した記述位置から文字列を読み出す機能とをコンピュータに実行させることを特徴とするデータファイル編集プログラム。 By analyzing a data file in which each data is described including a character string, address information for specifying the description position in the data file of the character string and the attribute of the character string are obtained. A function to generate recorded analysis result data;
A function of acquiring the analysis result data and referring to the analysis result data to specify a description position of a character string indicating a predetermined attribute described in the data file and to read the character string from the specified description position; A data file editing program for causing a computer to execute.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2005288947A JP2007102368A (en) | 2005-09-30 | 2005-09-30 | Data file analysis device, data file editing device, data file analysis method, data file analysis program, data file editing method and data file editing program |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2005288947A JP2007102368A (en) | 2005-09-30 | 2005-09-30 | Data file analysis device, data file editing device, data file analysis method, data file analysis program, data file editing method and data file editing program |
Publications (1)
Publication Number | Publication Date |
---|---|
JP2007102368A true JP2007102368A (en) | 2007-04-19 |
Family
ID=38029269
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
JP2005288947A Pending JP2007102368A (en) | 2005-09-30 | 2005-09-30 | Data file analysis device, data file editing device, data file analysis method, data file analysis program, data file editing method and data file editing program |
Country Status (1)
Country | Link |
---|---|
JP (1) | JP2007102368A (en) |
Cited By (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP2010250434A (en) * | 2009-04-13 | 2010-11-04 | Canon Inc | Apparatus and method for processing information, program, and storage medium |
-
2005
- 2005-09-30 JP JP2005288947A patent/JP2007102368A/en active Pending
Cited By (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP2010250434A (en) * | 2009-04-13 | 2010-11-04 | Canon Inc | Apparatus and method for processing information, program, and storage medium |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN1162790C (en) | Data communications | |
AU719368B2 (en) | Font sharing system and method, and recording medium storing program for executing font sharing method | |
JP2004139466A (en) | Electronic document printing program, and electronic document printing system | |
KR20090033377A (en) | Data processing system, image display device and program thereof | |
JP2006120107A (en) | Recording medium for recording image information and printing information therefor, and recording device for the medium | |
JP2009048450A (en) | Document management program and thumbnail display method | |
US20070083811A1 (en) | Contents editor and method of editing contents using the same | |
JP2003037812A5 (en) | ||
JP3963614B2 (en) | Data communication system and server and client computer constituting data communication system | |
JP2008077171A (en) | Data distribution device, data display device, data distribution method, data display method, data distribution program, data display program and recording medium with the same program recorded thereon | |
JP5077105B2 (en) | Image processing apparatus, image processing program, and image processing system | |
JP2007102368A (en) | Data file analysis device, data file editing device, data file analysis method, data file analysis program, data file editing method and data file editing program | |
JP2007104128A (en) | Image processing apparatus, mobile phone, image processing method, and image processing program | |
JP2007074136A (en) | Layout editing device, method, and program, and server | |
JP6353261B2 (en) | Information processing apparatus, control method, and program | |
JP2010224659A (en) | Information processing device, information processing method, program and storage medium | |
US20090287733A1 (en) | Method for preparing prepress image data | |
JP2004145736A (en) | Character recognition device, character recognition data output method, program and recording medium | |
JP6962352B2 (en) | Information processing equipment, recording systems, and programs | |
JP2018075777A (en) | Program executed by information processing terminal and information processing system | |
JP7318457B2 (en) | Control program, control method, and control system | |
JP2007102291A (en) | Data file creating device, data file creating method, data file creating program, data structure and data file editing device | |
JP2018067856A (en) | Program run by information processing terminal and information processing terminal | |
JP6810719B2 (en) | Information processing equipment, recording systems, and programs | |
JP2001282516A (en) | User interface device and recording medium recording program for the device |