[go: up one dir, main page]

JP2005246796A - Printing apparatus and printing method therefor - Google Patents

Printing apparatus and printing method therefor Download PDF

Info

Publication number
JP2005246796A
JP2005246796A JP2004060961A JP2004060961A JP2005246796A JP 2005246796 A JP2005246796 A JP 2005246796A JP 2004060961 A JP2004060961 A JP 2004060961A JP 2004060961 A JP2004060961 A JP 2004060961A JP 2005246796 A JP2005246796 A JP 2005246796A
Authority
JP
Japan
Prior art keywords
page
page break
layout
analyzed
contents
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
Application number
JP2004060961A
Other languages
Japanese (ja)
Inventor
Susumu Saito
勧 齊藤
Hirotaka Akamatsu
裕隆 赤松
Shigeki Kazuma
茂樹 数馬
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Seiko Epson Corp
Original Assignee
Seiko Epson Corp
Priority date (The priority date 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 date listed.)
Filing date
Publication date
Application filed by Seiko Epson Corp filed Critical Seiko Epson Corp
Priority to JP2004060961A priority Critical patent/JP2005246796A/en
Publication of JP2005246796A publication Critical patent/JP2005246796A/en
Pending legal-status Critical Current

Links

Images

Landscapes

  • Editing Of Facsimile Originals (AREA)
  • Record Information Processing For Printing (AREA)

Abstract

【課題】 改ページ禁止の指定がなされたオブジェクトやそのグループに改ページが必要なときでも迅速にレイアウトする。
【解決手段】 改ページの必要性が判定され改ページする際(S406)、改ページの禁止が指定されているときには(S408)、それまでに解析した内容をメモリに一時的に記憶し(S410)、改ページして新たなページボックスを作成した後に記憶した内容を改ページ後に解析されたものとして反映し(S414,S416)、その後の解析を再開する(S418,S420)。この結果、改ページされた後に改めて解析し直すものに比して、迅速にレイアウトを作成することができる。
【選択図】 図7
PROBLEM TO BE SOLVED: To quickly lay out even when a page break is necessary for an object or its group for which page break prohibition is designated.
When the necessity of a page break is determined and a page break is made (S406), when page break prohibition is designated (S408), the contents analyzed so far are temporarily stored in a memory (S410). ), The contents stored after the page break is created and the new page box is created are reflected as analyzed after the page break (S414, S416), and the subsequent analysis is resumed (S418, S420). As a result, it is possible to create a layout more quickly than in the case of reanalyzing after a page break.
[Selection] Figure 7

Description

本発明は、印刷装置およびその印刷方法に関し、詳しくは、印刷可能なオブジェクトを階層的に記述した記述文書を解析して紙などの媒体に印刷する印刷装置およびその印刷方法に関する。   The present invention relates to a printing apparatus and a printing method therefor, and more particularly to a printing apparatus that analyzes a description document in which printable objects are hierarchically described and prints them on a medium such as paper and a printing method therefor.

従来、この種の印刷装置としては、SVG文書を解析して印刷するプリンタとHTML文書をSVG文書に変換するフォーマッティングサーバとにより構成されたプリンタシステムが提案されている(例えば、特許文献1参照)。このシステムでは、HTML文書を受け付けると、フォーマッティングサーバにより受け付けたHTML文書をSVG文書に変換し、この変換したSVG文書をプリンタで解析して印刷する。
特開2002−91726号公報(図1,第5頁)
Conventionally, as this type of printing apparatus, there has been proposed a printer system including a printer that analyzes and prints an SVG document and a formatting server that converts an HTML document into an SVG document (see, for example, Patent Document 1). . In this system, when an HTML document is received, the HTML document received by the formatting server is converted into an SVG document, and the converted SVG document is analyzed by a printer and printed.
JP 2002-91726 A (FIG. 1, page 5)

しかしながら、上述のプリンタシステムでは、プリンタとフォーマッティングサーバとから構成されていることから大型化し、家庭のリビングなどの限られたスペースに設置する場合には不向きである。また、HTML文書を受け付けたときには、フォーマッティングサーバによりSVG文書に変換すると共にこの変換したSVG文書を解析して印刷するから、変換や解析に時間を要し、迅速な印刷を行なうことができない。HTML文書に記述されたオブジェクトによっては印刷時に途中で改ページすることにより見づらくなるなどの不都合を生じるものもある。   However, since the above-described printer system is composed of a printer and a formatting server, the printer system is increased in size and is not suitable for installation in a limited space such as a living room. When an HTML document is received, it is converted into an SVG document by the formatting server and the converted SVG document is analyzed and printed. Therefore, it takes time for conversion and analysis, and rapid printing cannot be performed. Some objects described in the HTML document may cause inconvenience such as being difficult to see due to page breaks during printing.

本発明の印刷装置およびその印刷方法は、HTML文書やこれを拡張したXHTML文書などのような記述文書をより適切に解析して印刷することを目的の一つとする。また、本発明の印刷装置およびその印刷方法は、HTML文書やこれを拡張したXHTML文書などのような記述文書を解析して印刷する際に記述文書に記述されたオブジェクトのうち改ページ禁止の指定がなされたオブジェクトやオブジェクトのグループについては途中で改ページされないように印刷することを目的の一つとする。さらに、本発明の印刷装置およびその印刷方法は、改ページ禁止の指定がなされたオブジェクトやオブジェクトのグループを改ページなしにレイアウトする際であっても迅速にレイアウトすることを目的の一つとする。   An object of the printing apparatus and printing method of the present invention is to more appropriately analyze and print a descriptive document such as an HTML document or an XHTML document obtained by extending the HTML document. In addition, the printing apparatus and the printing method of the present invention specify page break prohibition among objects described in a description document when analyzing and printing a description document such as an HTML document or an XHTML document extended from the HTML document. One of the purposes is to print an object or a group of objects so that no page breaks occur during the process. Further, it is an object of the printing apparatus and the printing method of the present invention to quickly lay out an object or a group of objects for which page break prohibition is designated even when laying out without page break.

本発明の印刷装置およびその印刷方法は、上述の目的の少なくとも一部を達成するために以下の手段を採った。   The printing apparatus and printing method of the present invention employ the following means in order to achieve at least a part of the above object.

本発明の第1の印刷装置は、
印刷可能なオブジェクトを階層的に記述した記述文書を解析して紙などの媒体に印刷する印刷装置であって、
記述文書におけるオブジェクトの階層的な木構造と該オブジェクトの書式とを解析する構造書式解析手段と、
前記解析された木構造と書式とに基づいてオブジェクトを順次解析して配置する手法をもってレイアウトすることにより前記媒体へのページ毎のレイアウトを作成する際に、少なくとも一つのオブジェクトを含み改ページ禁止の指定がなされた改ページ禁止グループに属するオブジェクトについては、改ページが必要になるまでは該改ページ禁止グループに属するオブジェクトを順次解析して配置し、改ページが必要になったときには該改ページ禁止グループに属するオブジェクトのうち該改ページが必要になるまでに行なわれたオブジェクトの解析および配置を該改ページ後に行なわれたオブジェクトの解析および配置として適用すると共に該改ページが必要になったときに解析していたオブジェクト以降のオブジェクトを順次解析して配置することにより、ページ毎のレイアウトを作成するレイアウト作成手段と、
前記作成されたページ毎のレイアウトに基づいてオブジェクトをレイアウトして前記媒体に印刷する印刷実行手段と、
を備えることを要旨とする。
The first printing apparatus of the present invention includes:
A printing device that analyzes a description document that hierarchically describes printable objects and prints it on a medium such as paper,
A structure format analysis means for analyzing the hierarchical tree structure of the object in the description document and the format of the object;
When creating a layout for each page on the medium by laying out with a method of sequentially analyzing and arranging objects based on the analyzed tree structure and format, page breaks including at least one object are prohibited. For the objects belonging to the specified page break prohibition group, the objects belonging to the page break prohibition group are sequentially analyzed and arranged until a page break is required, and the page break is prohibited when a page break is required. When the analysis and arrangement of the objects performed before the page break is necessary among the objects belonging to the group are applied as the analysis and arrangement of the objects performed after the page break, and the page break is necessary Sequentially analyze and distribute objects after the object being analyzed By, the layout creating means for creating a layout for each page,
Print execution means for laying out an object based on the created layout for each page and printing on the medium;
It is a summary to provide.

この本発明の第1の印刷装置では、記述文書におけるオブジェクトの階層的な木構造とオブジェクトの書式とを解析し、この解析した木構造と書式とに基づいてオブジェクトを順次解析して配置する手法をもってレイアウトすることにより紙などの媒体へのページ毎のレイアウトを作成し、作成したページ毎のレイアウトに基づいてオブジェクトをレイアウトして紙などの媒体に印刷する。したがって、記述文書をより適切に解析して印刷することができる。しかも、少なくとも一つのオブジェクトを含み改ページ禁止の指定がなされた改ページ禁止グループに属するオブジェクトについては、改ページが必要になるまでは改ページ禁止グループに属するオブジェクトを順次解析して配置し、改ページが必要になったときには改ページ禁止グループに属するオブジェクトのうち改ページが必要になるまでに行なわれたオブジェクトの解析および配置を改ページ後に行なわれたオブジェクトの解析および配置として適用すると共に改ページが必要になったときに解析していたオブジェクト以降のオブジェクトを順次解析して配置するから、改ページ禁止グループに属するオブジェクトをグループ内で改ページを行なうことなくレイアウトすることができる。また、改ページが必要になるまでに行なわれたオブジェクトの解析および配置を改ページ後に行なわれたオブジェクトの解析および配置として適用するから、改ページ禁止グループに属するオブジェクトのレイアウトについても迅速に行なうことができる。   In the first printing apparatus of the present invention, a method of analyzing a hierarchical tree structure of an object and a format of an object in a description document, and sequentially analyzing and arranging the objects based on the analyzed tree structure and the format. The layout for each page on a medium such as paper is created by laying out the object, and the objects are laid out based on the created layout for each page and printed on the medium such as paper. Therefore, the description document can be analyzed and printed more appropriately. In addition, for objects belonging to a page break prohibition group that includes at least one object and page break prohibition is specified, objects belonging to the page break prohibition group are sequentially analyzed and arranged until a page break is required. When a page is required, the analysis and placement of objects that belong to the page break prohibition group before the page break is required are applied as the analysis and placement of the object after the page break and the page break Since the objects after the object that has been analyzed when it becomes necessary are sequentially analyzed and arranged, objects belonging to the page break prohibition group can be laid out without performing page breaks within the group. In addition, since the analysis and arrangement of the object performed before the page break is necessary are applied as the analysis and arrangement of the object performed after the page break, the layout of the objects belonging to the page break prohibition group can be quickly performed. Can do.

こうした本発明の第1の印刷装置において、前記レイアウト作成手段は、前記改ページ禁止グループに属するオブジェクトを配置している途中で改ページが必要になったときには該改ページ禁止グループに属するオブジェクトのうち改ページ前に解析して配置したオブジェクトについては該改ページの前ページのレイアウトから削除する手段であるものとすることもできる。こうすれば、改ページの前後のページに同一内容がレイアウトされるのを抑止することができる。   In the first printing apparatus of the present invention, when the layout creation means needs a page break in the middle of arranging the objects belonging to the page break prohibition group, The object analyzed and arranged before the page break can be a means for deleting from the layout of the previous page of the page break. In this way, it is possible to prevent the same content from being laid out on the pages before and after the page break.

本発明の第2の印刷装置は、
印刷可能なオブジェクトを階層的に記述した記述文書を解析して紙などの媒体に印刷する印刷装置であって、
記述文書におけるオブジェクトの階層的な木構造と該オブジェクトの書式とを解析する構造書式解析手段と、
前記解析された木構造と書式とに基づいてオブジェクトを該オブジェクトの内容を順次解析して配置する手法をもってレイアウトすることにより前記媒体へのページ毎のレイアウトを作成する際に、前記オブジェクトのうち改ページ禁止の指定がなされた改ページ禁止オブジェクトについては、改ページが必要になるまでは該改ページ禁止オブジェクトの内容を順次解析して配置し、改ページが必要になったときには該改ページ禁止オブジェクトの内容のうち該改ページが必要になるまでに行なわれた内容の解析および配置を該改ページ後に行なわれた内容の解析および配置として適用すると共に該改ページが必要になったときに解析していた内容以降の内容を順次解析して配置することにより、ページ毎のレイアウトを作成するレイアウト作成手段と、
前記作成されたページ毎のレイアウトに基づいてオブジェクトをレイアウトして前記媒体に印刷する印刷実行手段と、
を備えることを要旨とする。
The second printing apparatus of the present invention is
A printing device that analyzes a description document that hierarchically describes printable objects and prints it on a medium such as paper,
A structure format analysis means for analyzing the hierarchical tree structure of the object in the description document and the format of the object;
When creating a layout for each page on the medium by laying out an object based on the analyzed tree structure and format by a method of sequentially analyzing and arranging the contents of the object, the object is modified. For a page break prohibition object for which page prohibition is specified, the contents of the page break prohibition object are sequentially analyzed and arranged until a page break is required, and when a page break is required, the page break prohibition object The analysis and arrangement of the contents performed before the page break is necessary are applied as the analysis and arrangement of the contents performed after the page break and are analyzed when the page break is necessary. A layout that creates a layout for each page by sequentially analyzing and arranging the contents after the previous contents And forming means,
Print execution means for laying out an object based on the created layout for each page and printing on the medium;
It is a summary to provide.

この本発明の第2の印刷装置では、記述文書におけるオブジェクトの階層的な木構造とオブジェクトの書式とを解析し、この解析した木構造と書式とに基づいてオブジェクトをオブジェクトの内容を順次解析して配置する手法をもってレイアウトすることにより紙などの媒体へのページ毎のレイアウトを作成し、作成したページ毎のレイアウトに基づいてオブジェクトをレイアウトして紙などの媒体に印刷する。したがって、記述文書をより適切に解析して印刷することができる。しかも、改ページ禁止の指定がなされた改ページ禁止オブジェクトについては、改ページが必要になるまでは改ページ禁止オブジェクトの内容を順次解析して配置し、改ページが必要になったときには改ページ禁止オブジェクトの内容のうち改ページが必要になるまでに行なわれた内容の解析および配置を改ページ後に行なわれた内容の解析および配置として適用すると共に改ページが必要になったときに解析していた内容以降の内容を順次解析して配置するから、改ページ禁止オブジェクトの途中で改ページを行なうことなくレイアウトすることができる。また、改ページが必要になるまでに行なわれた内容の解析および配置を改ページ後に行なわれた内容の解析および配置として適用するから、改ページ禁止オブジェクトのレイアウトについても迅速に行なうことができる。   In the second printing apparatus of the present invention, the hierarchical tree structure of the object and the format of the object in the description document are analyzed, and the contents of the object are sequentially analyzed based on the analyzed tree structure and the format. A layout for each page on a medium such as paper is created by laying out using a layout method, and objects are laid out based on the created layout for each page and printed on a medium such as paper. Therefore, the description document can be analyzed and printed more appropriately. In addition, for the page break prohibition object for which page break prohibition is specified, the contents of the page break prohibition object are sequentially analyzed and arranged until a page break is necessary, and page break is prohibited when a page break is required. The analysis and arrangement of the contents of the object before the page break is necessary are applied as the analysis and arrangement of the contents performed after the page break and are analyzed when the page break is necessary. Since the contents after the contents are sequentially analyzed and arranged, layout can be performed without performing a page break in the middle of a page break prohibited object. In addition, since the analysis and arrangement of the contents performed until the page break is necessary are applied as the contents analysis and arrangement performed after the page break, the layout of the page break prohibition object can be quickly performed.

こうした本発明の第2の印刷装置において、前記レイアウト作成手段は、前記改ページ禁止オブジェクトの内容を配置している途中で改ページが必要になったときには該改ページ禁止オブジェクトの内容のうち改ページ前に解析して配置した内容については該改ページの前ページのレイアウトから削除する手段であるものとすることもできる。こうすれば、改ページの前後のページに同一内容がレイアウトされるのを抑止することができる。   In such a second printing apparatus of the present invention, the layout creation means, when a page break is necessary during the placement of the contents of the page break prohibited object, the page break of the contents of the page break prohibited object. The contents analyzed and arranged before may be a means for deleting from the layout of the previous page of the page break. In this way, it is possible to prevent the same content from being laid out on the pages before and after the page break.

これら本発明の第1または第2の印刷装置において、前記レイアウト作成手段はレイアウトの作成が完了したページ毎に印刷実行指示を前記印刷実行手段に行なう手段であるものとすることもできるし、前記レイアウト作成手段は1ページ分のレイアウトの作成が完了した以降に印刷実行指示を前記印刷実行手段に行なう手段であるものとすることもできる。   In the first or second printing apparatus of the present invention, the layout creation means may be a means for giving a print execution instruction to the print execution means for each page for which layout creation has been completed. The layout creation means may be means for giving a print execution instruction to the print execution means after the creation of the layout for one page is completed.

また、本発明の第1または第2の印刷装置において、前記記述文書は、マークアップ言語により記述されてなるものとすることもできる。この場合、前記マークアップ言語はXHTML言語であるものとすることもできる。   In the first or second printing apparatus of the present invention, the description document can be described in a markup language. In this case, the markup language may be an XHTML language.

さらに、本発明の第1または第2の本発明の印刷装置において、前記オブジェクトは、テキスト,画像,表の少なくとも一つを含むものとすることもできるし、印刷装置はカラーインクジェットプリンタであるものとすることもできる。   Furthermore, in the printing apparatus according to the first or second aspect of the present invention, the object may include at least one of a text, an image, and a table, and the printing apparatus is a color inkjet printer. You can also.

本発明の第1の印刷方法は、
印刷可能なオブジェクトを階層的に記述した記述文書を解析して紙などの媒体に印刷する印刷装置における印刷方法であって、
(a)記述文書におけるオブジェクトの階層的な木構造と該オブジェクトの書式とを解析し、
(b)前記解析した木構造と書式とに基づいてオブジェクトを順次解析して配置する手法をもってレイアウトすることにより前記媒体へのページ毎のレイアウトを作成する際に、少なくとも一つのオブジェクトを含み改ページ禁止の指定がなされた改ページ禁止グループに属するオブジェクトについては、改ページが必要になるまでは該改ページ禁止グループに属するオブジェクトを順次解析して配置し、改ページが必要になったときには該改ページ禁止グループに属するオブジェクトのうち該改ページが必要になるまでに行なわれたオブジェクトの解析および配置を該改ページ後に行なわれたオブジェクトの解析および配置として適用すると共に該改ページが必要になったときに解析していたオブジェクト以降のオブジェクトを順次解析して配置することにより、ページ毎のレイアウトを作成し、
(c)前記作成したページ毎のレイアウトに基づいてオブジェクトをレイアウトして前記媒体に印刷する
ことを要旨とする。
The first printing method of the present invention includes:
A printing method in a printing apparatus that analyzes a description document in which printable objects are hierarchically described and prints on a medium such as paper,
(A) Analyzing the hierarchical tree structure of the object in the description document and the format of the object;
(B) When creating a layout for each page on the medium by laying out with a method of sequentially analyzing and arranging objects based on the analyzed tree structure and format, the page break includes at least one object. For the objects belonging to the page break prohibition group for which prohibition is specified, the objects belonging to the page break prohibition group are sequentially analyzed and arranged until a page break is necessary. Of the objects belonging to the page prohibition group, the analysis and arrangement of the object performed until the page break is necessary are applied as the analysis and arrangement of the object performed after the page break, and the page break is necessary. Analyze objects after the object that was being analyzed By arrangement, to create a layout for each page,
(C) The gist is to lay out an object based on the created layout for each page and print it on the medium.

この本発明の第1の印刷方法では、記述文書におけるオブジェクトの階層的な木構造とオブジェクトの書式とを解析し、この解析した木構造と書式とに基づいてオブジェクトを順次解析して配置する手法をもってレイアウトすることにより紙などの媒体へのページ毎のレイアウトを作成し、作成したページ毎のレイアウトに基づいてオブジェクトをレイアウトして紙などの媒体に印刷する。したがって、記述文書をより適切に解析して印刷することができる。しかも、少なくとも一つのオブジェクトを含み改ページ禁止の指定がなされた改ページ禁止グループに属するオブジェクトについては、改ページが必要になるまでは改ページ禁止グループに属するオブジェクトを順次解析して配置し、改ページが必要になったときには改ページ禁止グループに属するオブジェクトのうち改ページが必要になるまでに行なわれたオブジェクトの解析および配置を改ページ後に行なわれたオブジェクトの解析および配置として適用すると共に改ページが必要になったときに解析していたオブジェクト以降のオブジェクトを順次解析して配置するから、改ページ禁止グループに属するオブジェクトをグループ内で改ページを行なうことなくレイアウトすることができる。また、改ページが必要になるまでに行なわれたオブジェクトの解析および配置を改ページ後に行なわれたオブジェクトの解析および配置として適用するから、改ページ禁止グループに属するオブジェクトのレイアウトについても迅速に行なうことができる。   In the first printing method of the present invention, a hierarchical tree structure of an object in a description document and an object format are analyzed, and objects are sequentially analyzed and arranged based on the analyzed tree structure and format. The layout for each page on a medium such as paper is created by laying out the object, and the objects are laid out based on the created layout for each page and printed on the medium such as paper. Therefore, the description document can be analyzed and printed more appropriately. In addition, for objects belonging to a page break prohibition group that includes at least one object and page break prohibition is specified, objects belonging to the page break prohibition group are sequentially analyzed and arranged until a page break is required. When a page is required, the analysis and placement of objects that belong to the page break prohibition group before the page break is required are applied as the analysis and placement of the object after the page break and the page break Since the objects after the object that has been analyzed when it becomes necessary are sequentially analyzed and arranged, objects belonging to the page break prohibition group can be laid out without performing page breaks within the group. In addition, since the analysis and arrangement of the object performed before the page break is necessary are applied as the analysis and arrangement of the object performed after the page break, the layout of the objects belonging to the page break prohibition group can be quickly performed. Can do.

本発明の第2の印刷方法は、
印刷可能なオブジェクトを階層的に記述した記述文書を解析して紙などの媒体に印刷する印刷装置における印刷方法であって、
(a)記述文書におけるオブジェクトの階層的な木構造と該オブジェクトの書式とを解析し、
(b)前記解析した木構造と書式とに基づいてオブジェクトを該オブジェクトの内容を順次解析して配置する手法をもってレイアウトすることにより前記媒体へのページ毎のレイアウトを作成する際に、前記オブジェクトのうち改ページ禁止の指定がなされた改ページ禁止オブジェクトについては、改ページが必要になるまでは該改ページ禁止オブジェクトの内容を順次解析して配置し、改ページが必要になったときには該改ページ禁止オブジェクトの内容のうち該改ページが必要になるまでに行なわれた内容の解析および配置を該改ページ後に行なわれた内容の解析および配置として適用すると共に該改ページが必要になったときに解析していた内容以降の内容を順次解析して配置することにより、ページ毎のレイアウトを作成し、
(c)前記作成したページ毎のレイアウトに基づいてオブジェクトをレイアウトして前記媒体に印刷する
ことを要旨とする。
The second printing method of the present invention includes:
A printing method in a printing apparatus that analyzes a description document in which printable objects are hierarchically described and prints on a medium such as paper,
(A) Analyzing the hierarchical tree structure of the object in the description document and the format of the object;
(B) When creating a layout for each page on the medium by laying out an object based on the analyzed tree structure and format by a method of sequentially analyzing and arranging the contents of the object, Among the page break prohibition objects for which page break prohibition is specified, the contents of the page break prohibition object are sequentially analyzed and arranged until a page break is necessary. When the analysis and arrangement of the contents of the prohibited object before the page break is necessary are applied as the analysis and arrangement of the contents performed after the page break and the page break is necessary Create a layout for each page by sequentially analyzing and arranging the contents after the analyzed contents,
(C) The gist is to lay out an object based on the created layout for each page and print it on the medium.

この本発明の第2の印刷方法では、記述文書におけるオブジェクトの階層的な木構造とオブジェクトの書式とを解析し、この解析した木構造と書式とに基づいてオブジェクトをオブジェクトの内容を順次解析して配置する手法をもってレイアウトすることにより紙などの媒体へのページ毎のレイアウトを作成し、作成したページ毎のレイアウトに基づいてオブジェクトをレイアウトして紙などの媒体に印刷する。したがって、記述文書をより適切に解析して印刷することができる。しかも、改ページ禁止の指定がなされた改ページ禁止オブジェクトについては、改ページが必要になるまでは改ページ禁止オブジェクトの内容を順次解析して配置し、改ページが必要になったときには改ページ禁止オブジェクトの内容のうち改ページが必要になるまでに行なわれた内容の解析および配置を改ページ後に行なわれた内容の解析および配置として適用すると共に改ページが必要になったときに解析していた内容以降の内容を順次解析して配置するから、改ページ禁止オブジェクトの途中で改ページを行なうことなくレイアウトすることができる。また、改ページが必要になるまでに行なわれた内容の解析および配置を改ページ後に行なわれた内容の解析および配置として適用するから、改ページ禁止オブジェクトのレイアウトについても迅速に行なうことができる。   In the second printing method of the present invention, the hierarchical tree structure of the object and the format of the object in the description document are analyzed, and the contents of the object are sequentially analyzed based on the analyzed tree structure and the format. A layout for each page on a medium such as paper is created by laying out using a layout method, and objects are laid out based on the created layout for each page and printed on a medium such as paper. Therefore, the description document can be analyzed and printed more appropriately. In addition, for the page break prohibition object for which page break prohibition is specified, the contents of the page break prohibition object are sequentially analyzed and arranged until a page break is necessary, and page break is prohibited when a page break is required. The analysis and arrangement of the contents of the object before the page break is necessary are applied as the analysis and arrangement of the contents performed after the page break and are analyzed when the page break is necessary. Since the contents after the contents are sequentially analyzed and arranged, layout can be performed without performing a page break in the middle of a page break prohibited object. In addition, since the analysis and arrangement of the contents performed until the page break is necessary are applied as the contents analysis and arrangement performed after the page break, the layout of the page break prohibition object can be quickly performed.

次に、本発明を実施するための最良の形態を実施例を用いて説明する。   Next, the best mode for carrying out the present invention will be described using examples.

図1は、本発明の一実施例としてのカラーインクジェットプリンタ20の構成の概略を示す構成図である。実施例のカラーインクジェットプリンタ20は、図示するように、コンピュータ10やデジタルテレビ12,デジタルカメラ14などと接続してデジタル画像(以下、画像という)の入力を司る入力インターフェース22と、入力インタフェース22に入力される画像の形式に基づいてデータの出力先を割り振る信号処理部24と、マークアップ言語としてのXHTML(eXtensible Hyper Text Markup Language)により記述されたXHTML文書を解析して要素の木構造としてのDOM(Document Object Model)ツリーを作成すると共にCSS(Cascading Style Sheets)により記述されたCSS文書を読み込んでスタイルオブジェクトを作成してメモリ50に書き込む解析部30と、解析部30により作成されたDOMツリーとスタイルオブジェクトとを用いてXHTML文書に記述された要素(オブジェクト)としての画像やテキストを印刷用の印刷用のページ毎にレイアウトしてページボックスとしてメモリ50に書き込むレイアウタ38と、レイアウタ38によりレイアウトして得られるページボックスを用いてRBGデータとしての印刷用画像を描画するレンダリングプラグイン(以下、RPIという)40と、描画されたRGB(Red Green Blue)データの印刷用画面をCMYK(Cyan Magenta Yellow Black)データに変換する色変換部42と、変換されたCMYKデータを誤差拡散処理などの画像処理を行なって2値化する2値化部44と、2値化されたCMYKの各データを図示しない印刷ヘッドを備える印刷実行部48にバンド単位で出力するために一時的にデータを蓄えるイメージバッファ46とを備える。   FIG. 1 is a configuration diagram showing an outline of the configuration of a color inkjet printer 20 as an embodiment of the present invention. As shown in the figure, the color inkjet printer 20 of the embodiment is connected to a computer 10, a digital television 12, a digital camera 14, and the like, and an input interface 22 that controls input of a digital image (hereinafter referred to as an image), and an input interface 22 Analyzing an XHTML document described in XHTML (eXtensible Hyper Text Markup Language) as a markup language by assigning an output destination of data based on the format of the input image, and as an element tree structure Creates a DOM (Document Object Model) tree and reads a CSS document described by CSS (Cascading Style Sheets) to create a style object and create a memory An image and text as an element (object) described in an XHTML document using the analysis unit 30 written in the data 50 and the DOM tree and style object created by the analysis unit 30 are laid out for each print page for printing. A layouter 38 to be written in the memory 50 as a page box, and a rendering plug-in (hereinafter referred to as RPI) 40 for rendering an image for printing as RBG data using a page box obtained by laying out by the layouter 38. The RGB (Red Green Blue) data printing screen is converted into CMYK (Cyan Magenta Yellow Black) data, and the converted CMYK data is binarized by image processing such as error diffusion processing. A binarization unit 44 and An image buffer 46 that temporarily stores data for outputting binarized CMYK data to a print execution unit 48 including a print head (not shown) in units of bands.

信号処理部24は、入力された信号が直ちに印刷可能な印刷用データの場合には印刷実行部48のイメージバッファ46にデータを出力し、RGBデータの場合にはメモリ50の印刷用画面格納領域に出力し、XHTML文書で記述されたファイルの場合には解析部30に出力する。   The signal processing unit 24 outputs the data to the image buffer 46 of the print execution unit 48 when the input signal is printable data that can be printed immediately, and the print screen storage area of the memory 50 when the input signal is RGB data. In the case of a file described in an XHTML document, it is output to the analysis unit 30.

解析部30は、XHTML文書の解析を指示することによりDOMツリーを作成するコア32と、コア32からの指示に基づいてXHTML文書を解析するXMLパーサー34と、作成されたDOMツリーのlinkタグ内の初期化処理により依頼されたCSS文書を解析するCSSプラグイン(以下、CSSPIという)36とから構成されている。CSSPI36は、CSS文書で記述されたファイルがXHTML文書に記述されているときにそのファイルを読み込んで解析し、スタイルオブジェクトを作成する。CSS文書で記述されたファイルについてはXHTML文書に記述されておらず、XHTML文書内に各要素に対してスタイル(書式や様式)が直接記述されているときには、コア32がスタイルを解析し、DOMツリーの要素の情報に加える。   The analysis unit 30 includes a core 32 that creates a DOM tree by instructing analysis of an XHTML document, an XML parser 34 that analyzes an XHTML document based on an instruction from the core 32, and a link tag of the created DOM tree. The CSS plug-in (hereinafter referred to as CSSI) 36 for analyzing the CSS document requested by the initialization process of FIG. The CSSI 36 reads and analyzes the file described in the CSS document when it is described in the XHTML document, and creates a style object. The file described in the CSS document is not described in the XHTML document, and when the style (format or style) is directly described for each element in the XHTML document, the core 32 analyzes the style, and the DOM. Add to tree element information.

操作部60は、プリンタ正面に配置された液晶ディスプレイ61と、その横に設けられた二つの操作ボタン62と、内部にワンチップとして構成されたCPU63,ROM64,ディスプレイコントローラ(以下、LCDCという)65,メモリ66と、を備える。この操作部60により設定する内容としては、例えば、装着されている印刷用紙の種類やサイズ,インクの種類などであり、設定は、操作ボタン62の操作に基づいてROM64に予め記憶された処理プログラムが起動され、この処理プログラムにより液晶ディスプレイ61に表示されるメニューに従って行なわれる。例えば、用紙種類の設定の場合、メニューから用紙種類を選択し、液晶ディスプレイ61にトグルして表示される「普通紙」や「写真紙」などから選択することにより設定し、用紙サイズの設定の場合、メニューから用紙サイズを選択し、液晶ディスプレイ61にトグルして表示される「A4縦」や「B5縦」などから選択することにより設定するのである。こうして設定した内容は、メモリ66に書き込まれる。なお、実施例では、操作部60による設定を行なわなくても、デフォルトとして、例えば印刷用紙の種類としては「普通紙」,用紙サイズとしては「A4縦」,インクの種類としては「顔料系」などが設定されている。こうした操作部60による設定処理は、本発明の中核をなさないからこれ以上の説明については省略する。   The operation unit 60 includes a liquid crystal display 61 arranged in front of the printer, two operation buttons 62 provided on the side, a CPU 63, a ROM 64, a display controller (hereinafter referred to as LCDC) 65 configured as one chip inside. , And a memory 66. The contents set by the operation unit 60 include, for example, the type and size of the loaded printing paper, the type of ink, and the setting is a processing program stored in advance in the ROM 64 based on the operation of the operation button 62. Is started according to the menu displayed on the liquid crystal display 61 by this processing program. For example, in the case of setting the paper type, the paper size is selected from the menu and is set by selecting from “plain paper”, “photo paper”, etc. displayed by being toggled on the liquid crystal display 61. In this case, the paper size is selected from the menu and is set by selecting from “A4 portrait”, “B5 portrait”, etc. displayed by being toggled on the liquid crystal display 61. The contents set in this way are written into the memory 66. In the embodiment, even if the setting by the operation unit 60 is not performed, as a default, for example, “plain paper” as the type of printing paper, “A4 portrait” as the paper size, and “pigment type” as the ink type. Etc. are set. Since the setting process by the operation unit 60 does not form the core of the present invention, further description is omitted.

次に、こうして構成された実施例のカラーインクジェットプリンタ20の動作、特にXHTML文書を印刷する際の動作について説明する。図2は、解析部30により実行される解析レイアウト指示処理の一例を示すフローチャートである。この処理は所定時間毎(例えば、8msec毎)に繰り返し実行される。解析レイアウト指示処理が実行されると、まず、XHTML文書を特定するためのURL(Uniform Resouce Locator)の指定があるか否かを判定し(ステップS100)、URLの指定があるときにはそのURLをメモリ50に領域設定されたURL格納用バッファ領域に格納し(ステップS110)、URLの指定がないときには次の処理に進む。URL指定は、例えば、操作者がデジタルテレビ12で表示された印刷可能な項目のうちカラーインクジェットプリンタ20で印刷しようとする項目を選択したときデジタルテレビ12からのカラーインクジェットプリンタ20に出力されることにより行なうものとすることができるし、コンピュータ10から単にURLを選択してカラーインクジェットプリンタ20に印刷要求することによっても行なうことができる。なお、コンピュータ10からのURL指定では、コンピュータ10によってもXHTML文書の解析やレイアウト,色変換や2値化などを行なうことができるが、コンピュータ10によってはこうした処理を一切行なわず、URLだけをカラーインクジェットプリンタ20に送信する場合となる。   Next, the operation of the color ink jet printer 20 of the embodiment configured as described above, particularly the operation when printing an XHTML document will be described. FIG. 2 is a flowchart illustrating an example of the analysis layout instruction process executed by the analysis unit 30. This process is repeatedly executed every predetermined time (for example, every 8 msec). When the analysis layout instruction process is executed, first, it is determined whether or not a URL (Uniform Resource Locator) for specifying an XHTML document is specified (step S100). If a URL is specified, the URL is stored in the memory. 50 is stored in the URL storage buffer area set in the area 50 (step S110), and if no URL is designated, the process proceeds to the next process. The URL designation is output to the color inkjet printer 20 from the digital television 12 when the operator selects an item to be printed by the color inkjet printer 20 among the printable items displayed on the digital television 12. Or by simply selecting a URL from the computer 10 and making a print request to the color inkjet printer 20. In the URL designation from the computer 10, the XHTML document can be analyzed, laid out, color converted, binarized, etc. by the computer 10, but the computer 10 does not perform such processing at all, and only the URL is colored. In this case, the data is transmitted to the ink jet printer 20.

続いて、メモリ50のURL格納用バッファ領域にURLが格納されているか否かを判定すると共に(ステップS120)、XHTML文書を現在解析中であるか否かを判定する(ステップS130)。XHTML文書を現在解析中であるか否かの判定は、この解析レイアウト指示処理と同時に並列に解析部30自信によって行なっているか否かを判定することにより、例えば解析開始時と解析終了時にフラグ操作するものとすればフラグを調べることにより行なうことができる。URLが格納されており、現在XHTML文書の解析中ではないときには、メモリ50のURL格納用バッファ領域に格納されている最初のURLを読み出してそのURLにより特定されるXHTML文書の解析を開始し(ステップS140)、URLが格納されていないときやURLが格納されていても現在XHTML文書を解析している最中のときには次の処理に進む。XHTML文書の解析は、図3に例示する解析処理に基づいて行なわれる。この解析処理ではURLにより特定されるXHTML文書が解析されてDOMツリーが作成され、XHTML文書に記述されたCSS文書を解析してスタイルオブジェクトが作成され、関連付けられてメモリ50のDOMツリー用格納領域とスタイルオブジェクト用格納領域とに記憶される。このとき、DOMツリーには識別情報としてDOMツリーIDが付与され、スタイルオブジェクトには識別情報としてスタイルオブジェクトIDが付与される。解析処理の詳細については後述する。   Subsequently, it is determined whether or not the URL is stored in the URL storage buffer area of the memory 50 (step S120), and whether or not the XHTML document is currently being analyzed is determined (step S130). Whether or not the XHTML document is currently being analyzed is determined by determining whether or not the analysis unit 30 is confident in parallel with the analysis layout instruction processing, for example, at the start of analysis and at the end of analysis. If so, this can be done by checking the flag. When the URL is stored and the XHTML document is not currently being analyzed, the first URL stored in the URL storage buffer area of the memory 50 is read and analysis of the XHTML document specified by the URL is started ( In step S140, when the URL is not stored or when the XHTML document is currently being analyzed even if the URL is stored, the process proceeds to the next process. The analysis of the XHTML document is performed based on the analysis process illustrated in FIG. In this analysis processing, the XHTML document specified by the URL is analyzed to create a DOM tree, the CSS document described in the XHTML document is analyzed to create a style object, and the DOM tree storage area in the memory 50 is associated with the analysis. And the style object storage area. At this time, a DOM tree ID is assigned as identification information to the DOM tree, and a style object ID is assigned to the style object as identification information. Details of the analysis processing will be described later.

次に、レイアウタ38によってレイアウトが行なわれている最中であるか否かを判定し(ステップS150)、レイアウタ38によるレイアウトが行なわれていないときにはメモリ50のDOMツリー用格納領域に格納されたDOMツリーのうち最初のDOMツリーをDOMツリーIDを用いて指定してレイアウタ38にレイアウト開始指示を出力し(ステップS160)、この解析レイアウト指示処理を終了し、レイアウタ38によってレイアウトが行なわれている最中であるときにはレイアウト開始指示を出力せずに解析レイアウト指示処理を終了する。ここで、レイアウタ38によってレイアウトが行なわれている最中であるか否かの判定は、レイアウタ38からレイアウト終了の信号を入力したか否かにより行なうことができる。レイアウト終了の信号に受信についてはレイアウタ38の処理を説明する際に詳述する。   Next, it is determined whether the layout is being performed by the layouter 38 (step S150). When the layout is not performed by the layouter 38, the DOM stored in the DOM tree storage area of the memory 50 is determined. The first DOM tree in the tree is designated using the DOM tree ID, and a layout start instruction is output to the layouter 38 (step S160). This analysis layout instruction process is terminated, and the layout layout 38 is being executed. When it is in the middle, the analysis layout instruction process is terminated without outputting the layout start instruction. Here, whether or not the layout is being performed by the layouter 38 can be determined based on whether or not a layout end signal is input from the layouter 38. The reception of the layout end signal will be described in detail when the processing of the layouter 38 is described.

こうした解析レイアウト指示処理は、前述したように繰り返し実行されるから、解析部30ではURLが指定される毎にXHTML文書の解析中であるか否かに拘わらずに指定されたURLをメモリ50のURL格納用バッファ領域に格納する。また、メモリ50のURL格納用バッファ領域にURLが格納されているときには、レイアウタ38によるレイアウトの実行中であるか否かに拘わらずにXHTML文書の解析を順次行なう。従って、メモリ50のURL格納用バッファ領域には複数のURLが格納される場合が生じ、DOMツリー用格納領域に複数のDOMツリーが格納される場合が生じ、スタイルオブジェクト用格納領域に複数のスタイルオブジェクトが格納される場合が生じる。実施例では、複数のURLを格納することができるようにURL格納用バッファ領域が設定されており、複数のDOMツリーを格納することができるようにDOMツリー用格納領域が設定されており、複数のスタイルオブジェクトを格納することができるようにスタイルオブジェクト用格納領域が設定されている。   Since such an analysis layout instruction process is repeatedly executed as described above, every time the URL is specified in the analysis unit 30, the specified URL is stored in the memory 50 regardless of whether or not the XHTML document is being analyzed. Store in the URL storage buffer area. When a URL is stored in the URL storage buffer area of the memory 50, XHTML documents are sequentially analyzed regardless of whether the layout by the layouter 38 is being executed. Accordingly, a plurality of URLs may be stored in the URL storage buffer area of the memory 50, a plurality of DOM trees may be stored in the DOM tree storage area, and a plurality of styles may be stored in the style object storage area. An object may be stored. In the embodiment, a URL storage buffer area is set so that a plurality of URLs can be stored, and a DOM tree storage area is set so that a plurality of DOM trees can be stored. A style object storage area is set so that the style object can be stored.

次に、解析部30により実行される解析処理について説明する。解析処理は、前述したように図3に例示するフローチャートに基づいて行なわれる。説明の容易のために具体例として図4に例示するXHTML文書を用いて説明する。解析レイアウト指示処理によりURLを指定して解析開始の指示がなされると、URLにより特定されるXHTML文書を読み出し(ステップS200)、読み出したXHTML文書を解析してDOMツリーを作成する(ステップS210)。このとき、作成するDOMツリーには識別情報としてDOMツリーID(例えば、URLにDOMを付して作成したIDなど)を付与する。XHTML文書の読み出しは、具体的には、コア32がURLを指定してXMLパーサー34に解析依頼することによりXMLパーサー34が行なう。XHTML文書の解析およびDOMツリーの作成は、具体的には、XMLパーサー34がXHTML文書を最初から順に解析して各要素を作成すると共にDOMツリーに登録することにより行なう。なお、要素の作成はコア32に対して行ない、要素の登録はメモリ50のDOMツリー用格納領域に関連付けて格納することにより行なう。図4に例示したXHTML文書を解析して作成されたDOMツリーを図5に示す。   Next, analysis processing executed by the analysis unit 30 will be described. The analysis process is performed based on the flowchart illustrated in FIG. 3 as described above. For ease of explanation, a specific example will be described using the XHTML document illustrated in FIG. When a URL is specified by the analysis layout instruction process and an analysis start instruction is given, the XHTML document specified by the URL is read (step S200), and the read XHTML document is analyzed to create a DOM tree (step S210). . At this time, a DOM tree ID (for example, an ID created by adding a DOM to a URL) is assigned as identification information to the DOM tree to be created. Specifically, the XHTML document is read by the XML parser 34 when the core 32 designates a URL and requests an analysis to the XML parser 34. Specifically, the analysis of the XHTML document and the creation of the DOM tree are performed by the XML parser 34 analyzing the XHTML document from the beginning in order to create each element and register it in the DOM tree. The element is created for the core 32, and the element is registered by associating it with the DOM tree storage area of the memory 50. FIG. 5 shows a DOM tree created by analyzing the XHTML document illustrated in FIG.

こうしてDOMツリーを作成すると、XHTML文書に指定されたCSS文書を読み出し(ステップS220)、読み込出したCSS文書を解析してスタイルオブジェクトを作成する(ステップS230)。CSS文書の読み出しは、具体的には、DOMツリーのlinkタグ内の初期化処理内の依頼により依頼されたCSSPI36が行なう。CSS文書の解析およびスタイルオブジェクトの作成は、具体的には、CSSPI36がCSS文書を最初から順に解析して各ルールをメモリ50のスタイルオブジェクト用格納領域に格納することにより行なう。図4の例では、XHTML文書内で直接スタイルについては記述されており、CSS文書の指定がないため、スタイルオブジェクトは作成されない。   When the DOM tree is created in this way, the CSS document designated as the XHTML document is read (step S220), and the read CSS document is analyzed to create a style object (step S230). Specifically, the CSS document 36 is read by the request in the initialization process in the link tag of the DOM tree. Specifically, the CSS document is analyzed and the style object is created by the CSSI 36 analyzing the CSS document in order from the beginning and storing each rule in the storage area for the style object in the memory 50. In the example of FIG. 4, the style is described directly in the XHTML document, and no CSS object is specified, so no style object is created.

こうしてDOMツリーとスタイルオブジェクトが作成されると、作成したDOMツリーとスタイルオブジェクトの関連付け処理を実行し(ステップS240)、URL格納用バッファ領域から解析の対象のURLを削除して(ステップS250)、解析処理を終了する。   When the DOM tree and style object are created in this way, the created DOM tree and style object are associated with each other (step S240), and the URL to be analyzed is deleted from the URL storage buffer area (step S250). End the analysis process.

次に、レイアウタ38の処理について説明する。図6は、解析部30によりDOMツリーを指定してレイアウト開始指示がなされたときにレイアウタ38により実行されるレイアウト描画指示処理の一例を示すフローチャートである。レイアウト描画指示処理が実行されると、レイアウタ38は、まず、指定されたDOMツリーに基づいてレイアウトを開始する(ステップS300)。レイアウトは、図7に例示するレイアウト処理により実行される。説明の都合上、ここで、レイアウト処理について説明する。   Next, processing of the layouter 38 will be described. FIG. 6 is a flowchart showing an example of a layout drawing instruction process executed by the layouter 38 when the analysis unit 30 designates a DOM tree and gives a layout start instruction. When the layout drawing instruction process is executed, the layouter 38 first starts layout based on the designated DOM tree (step S300). The layout is executed by the layout process illustrated in FIG. For convenience of explanation, layout processing will be described here.

レイアウト処理では、レイアウタ38は、まず、DOMツリーの各要素に対してその要素の特性に従って要素ボックスを作成する(ステップS400)。例えば、要素が画像であればイメージボックスを作成し、要素がテキストであればテキストボックスを作成するのである。続いて、第1ページに対応するページボックスを作成し(ステップS402)、そのページボックスの下にbodyタグ内の要素ボックスをレイアウトできなくなるまで順にレイアウトする(ステップS404〜S424)。要素ボックスのレイアウトは、まず、要素ボックスを解析し(ステップS404)、改ページの必要性を判定する(ステップS406)。こうした解析と改行の必要性の判定は、要素ボックスがテキストのときには、そのサイズや背景色などを解析し、文字毎にそのサイズに基づいて対象となっている行に配置し、配置できないときには改行して配置し、改行の際に改ページが必要であるか否かを判定することにより行ない、要素ボックスが画像のときには、そのサイズや背景色などを解析し、対象となっている行の縦のサイズを画像のサイズとしたときに配置可能か否かにより改行の必要性を判定することにより行ない、要素ボックスが表組みのときには、表組みを構成する各セルの横サイズを計算して表組みの幅を決定し、セルを行毎に組み、セルを行に組み込む際に改ページの必要性を判定することにより行なう。解析の結果、改ページが不要であれば、解析した要素ボックスをレイアウトして(ステップS422)、次の要素ボックスの存在を判定する(ステップS424)。   In the layout process, the layouter 38 first creates an element box for each element of the DOM tree according to the characteristics of the element (step S400). For example, if the element is an image, an image box is created, and if the element is text, a text box is created. Subsequently, a page box corresponding to the first page is created (step S402), and the element box in the body tag is sequentially laid out under the page box until it cannot be laid out (steps S404 to S424). In the layout of the element box, first, the element box is analyzed (step S404), and the necessity of a page break is determined (step S406). This analysis and the necessity of line breaks are determined by analyzing the size and background color when the element box is text, placing each character on the target line based on its size, and if the line cannot be placed If the element box is an image, the size and background color are analyzed, and the vertical line of the target line is analyzed. When the element box is a table set, the horizontal size of each cell that composes the table set is calculated. This is done by determining the width of the combination, assembling the cells for each row, and determining the necessity of a page break when incorporating the cells into the row. If a page break is unnecessary as a result of the analysis, the analyzed element box is laid out (step S422), and the presence of the next element box is determined (step S424).

改ページが必要と判定されたときには、改ページが禁止されているか否かを判定する(ステップS408)。改ページ禁止の判定は、例えば、図4の例では、bodyタグの下、2行目のtableタグ中に下線を付した「pege−break−inside:avoid」により指定される。この例では、tableタグにより解析されて配置される表組み内での改ページが禁止される。改ページが禁止されていないときには、改ページが必要と判定されるまでに解析して配置した内容についてレイアウトし(ステップS409)、改ページが禁止されているときには、それまでに解析した内容を一時的にメモリ50に記憶し(ステップS410)、次ページのページボックスを作成する(ステップS412)。そして、改ページの必要性が判定されるまでに解析した内容をメモリ50に一時的に記憶したときには解析した内容を改ページ後に行なったものとして反映する(ステップS414,S416)。なお、改ページが禁止されていないときには、改ページされる前にそれまでに解析した内容については前ページにレイアウトされている。そして、解析途中であるか否かを判定し(ステップS418)、解析途中であるときには解析を再開する(ステップS420)。そして、改ページ後に解析した内容をレイアウトし(ステップS422)、次の要素ボックスの存在を判定する(ステップS424)。図4のXHTML文書の例では、図8に示すように、画像(イメージ)がレイアウトされ、その後、tableタグに対応する要素ボックスを解析して表組みしている最中(表組みの3行目を解析する際)に改ページの必要性が判定され、改ページが禁止されているため、それまでに解析された内容(表組みの2行目まで)がメモリ50に一時的に記憶され、改ページ後にメモリ50に記憶された内容(表組みの2行目まで)が反映され、表組みの3行目以降がその後に解析されてレイアウトされることになる。即ち、第1ページには画像(イメージ)だけがレイアウトされ、第2ページには表組みのすべてがレイアウトされることになる。図9に具体例のDOMツリーを用いてレイアウトした際の各ページのページボックスを示す。   When it is determined that a page break is necessary, it is determined whether or not page break is prohibited (step S408). For example, in the example of FIG. 4, the page break prohibition determination is specified by “peg-break-inside: void” underlined in the table tag in the second row under the body tag. In this example, a page break is prohibited in a table set analyzed and arranged by the table tag. When page breaks are not prohibited, the contents analyzed and arranged until it is determined that page breaks are necessary are laid out (step S409). When page breaks are prohibited, the contents analyzed so far are temporarily stored. Then, it is stored in the memory 50 (step S410), and a page box for the next page is created (step S412). When the analyzed contents until the necessity of page break is determined are temporarily stored in the memory 50, the analyzed contents are reflected as having been performed after the page break (steps S414 and S416). When page breaks are not prohibited, the contents analyzed up to that point before page breaks are laid out on the previous page. Then, it is determined whether or not analysis is in progress (step S418). When analysis is in progress, analysis is resumed (step S420). Then, the contents analyzed after the page break are laid out (step S422), and the presence of the next element box is determined (step S424). In the example of the XHTML document in FIG. 4, as shown in FIG. 8, an image (image) is laid out, and then the element box corresponding to the table tag is analyzed and tabulated (three rows of the table tab) When the eye is analyzed), the necessity of a page break is determined, and page breaks are prohibited. Therefore, the contents analyzed so far (up to the second line of the table) are temporarily stored in the memory 50. The contents (up to the second line of the table set) stored in the memory 50 after the page break are reflected, and the third and subsequent lines of the table set are subsequently analyzed and laid out. That is, only images (images) are laid out on the first page, and all tables are laid out on the second page. FIG. 9 shows a page box of each page when laying out using a specific example DOM tree.

こうしてすべての要素ボックスをレイアウトすると、指定されたDOMツリーをメモリ50のDOMツリー用格納領域から削除して(ステップS426)、レイアウト処理を終了する。このように、レイアウト処理を終了するときに用いたDOMツリーをメモリ50のDOMツリー用格納領域から削除することにより、DOMツリー用格納領域に不要なDOMツリーが格納された状態が継続されるのを回避することができる。この結果、解析部30によって作成される新たなDOMツリーの格納領域を確保することができる。   When all the element boxes are laid out in this way, the designated DOM tree is deleted from the DOM tree storage area of the memory 50 (step S426), and the layout process is terminated. As described above, by deleting the DOM tree used when the layout process is completed from the DOM tree storage area of the memory 50, the state where the unnecessary DOM tree is stored in the DOM tree storage area is continued. Can be avoided. As a result, a storage area for a new DOM tree created by the analysis unit 30 can be secured.

レイアウト描画指示処理(図6)の説明に戻る。レイアウトを開始すると、最初のページ分のレイアウトが完了するのを待って(ステップS310)、レイアウトが完了したページを指定してRPI40に描画開始指示を出力する(ステップS320)。ページ分のレイアウトが完了したか否かの判定は、次ページに対応するページボックスが作成されたか否かにより、1ページだけしかないときにはレイアウト処理が終了したか否かにより行なうことができる。描画開始指示されたRPI40は、図10に例示する描画処理を実行し、ページボックスに従ってテキストや画像をメモリ50の印刷用画像格納領域を用いてRGBデータとして描画し(ステップS500)、描画が終了したときに色変換部42に色変換指示を出力すると共に(ステップS510)、描画終了をレイアウタ38に出力する(ステップS520)。なお、画像の描画については、画像ファイルを読み出し、ファイル形式によっては展開等を行なって描画する。図11に具体例の印刷結果の一例を示す。   Returning to the description of the layout drawing instruction process (FIG. 6). When the layout is started, it waits for the layout of the first page to be completed (step S310), specifies the page for which the layout has been completed, and outputs a drawing start instruction to the RPI 40 (step S320). Whether or not the layout for the page has been completed can be determined based on whether or not the page box corresponding to the next page has been created and whether or not the layout processing has been completed when there is only one page. The RPI 40 instructed to start drawing executes the drawing process illustrated in FIG. 10, and draws text and images as RGB data using the print image storage area of the memory 50 according to the page box (step S500), and the drawing ends. When this is done, a color conversion instruction is output to the color conversion unit 42 (step S510), and a drawing end is output to the layouter 38 (step S520). For image drawing, an image file is read and, depending on the file format, is developed and drawn. FIG. 11 shows an example of a print result of a specific example.

描画開始指示を出力した後はそのページの描画が終了するのを待って(ステップS330)、そのページに対応するページボックスを削除する(ステップS340)。このように、ページの描画が終了する毎にそのページに対応するページボックスを削除することにより、ボックス用格納領域に不要なページボックスが格納された状態が継続されるのを回避することができる。こうしてページボックスを削除すると、次ページがあるか否かを判定し(ステップS350)、次ページがあるときにはステップS310の処理に戻る。即ち、次ページに対するページ分のレイアウトが完了しているか否かを判定し、レイアウトが完了していないときには完了するまで待ってレイアウトが完了したページを指定してRPI40に描画開始指示を出力するのである。こうしてすべてのページを描画し、次ページがなくなると、レイアウト終了を解析部30に出力して(ステップS360)、レイアウト描画指示処理を終了する。このように、レイアウタ38からレイアウト終了の信号を解析部30に出力することにより、解析部30は、レイアウタ38によるレイアウトの最中であるか否かを判定することができる。   After outputting the drawing start instruction, it waits for the drawing of the page to end (step S330), and deletes the page box corresponding to the page (step S340). In this way, by deleting the page box corresponding to the page every time drawing of the page is completed, it is possible to avoid the state where unnecessary page boxes are stored in the box storage area. . When the page box is deleted in this way, it is determined whether or not there is a next page (step S350). If there is a next page, the process returns to step S310. That is, it is determined whether or not the layout for the next page has been completed. If the layout has not been completed, the process waits until the layout is completed, specifies the page for which the layout has been completed, and outputs a drawing start instruction to the RPI 40. is there. When all pages are drawn in this way and there is no next page, the end of layout is output to the analysis unit 30 (step S360), and the layout drawing instruction processing is ended. In this way, by outputting a layout end signal from the layouter 38 to the analysis unit 30, the analysis unit 30 can determine whether the layout by the layouter 38 is in progress.

図12に他の具体例のXHTML文書を示し、図13に図12の具体例のDOMツリーの一例を示し、図14に図12の具体例のレイアウトを解析している様子を示し、図15に図12の具体例の印刷結果の一例を示す。図12の具体例では、bodyタグの下、4行目のpタグ中に下線を付した「pege−break−inside:avoid」が記載されることにより、このpタグ内における改ページが禁止される。このpタグ内には、図13のDOMツリーに示すように、3個の画像(img)の要素ボックスが作成されているから、3個の画像のいずれかで改ページの必要性が判定されると、3個すべての画像が改ページ後にレイアウトされることになる。例えば、図14に示すように、3個目の画像(img3)に改ページの必要性が判定されると、図15に示すように、すべての画像(img1〜img3)が改ページ後に配置されることになる。   FIG. 12 shows an XHTML document of another specific example, FIG. 13 shows an example of the DOM tree of the specific example of FIG. 12, FIG. 14 shows how the layout of the specific example of FIG. Shows an example of the print result of the specific example of FIG. In the specific example of FIG. 12, “page-break-side: void” with an underline in the p tag on the fourth line below the body tag is described, thereby preventing page breaks in the p tag. The In this p tag, as shown in the DOM tree of FIG. 13, element boxes of three images (img) are created, and the necessity of a page break is determined in one of the three images. Then, all three images are laid out after the page break. For example, as shown in FIG. 14, when the necessity for a page break is determined for the third image (img3), all the images (img1 to img3) are arranged after the page break as shown in FIG. Will be.

以上説明した実施例のカラーインクジェットプリンタ20によれば、改ページの禁止が指定されているときには、改ページの必要性が判定されるまでに解析した内容を一時的にメモリ50に記憶し、この記憶した内容を改ページ後のものとして適用し、その後の解析を続行するから、改ページ後に新たに解析し直す場合に比して、迅速にレイアウトを作成することができる。この結果、XHTML文書を迅速に解析して印刷することができる。しかも、改ページの禁止の指定は、オブジェクト毎に行なうこともできるし、複数のオブジェクトを含むグループに対しても行なうことができる。   According to the color ink jet printer 20 of the embodiment described above, when prohibition of page break is designated, the analyzed contents are temporarily stored in the memory 50 until the necessity of page break is determined. Since the stored contents are applied as after page break and the subsequent analysis is continued, a layout can be created more quickly than in the case of newly re-analyzing after page break. As a result, the XHTML document can be quickly analyzed and printed. In addition, the designation of page break prohibition can be performed for each object or for a group including a plurality of objects.

また、実施例のカラーインクジェットプリンタ20によれば、URLが指定される毎にXHTML文書の解析中であるか否かに拘わらずに指定されたURLをメモリ50のURL格納用バッファ領域に格納することができる。また、メモリ50のURL格納用バッファ領域にURLが格納されているときには、レイアウタ38によるレイアウトの実行中であるか否かに拘わらずにXHTML文書の解析を順次行なうことができる。この結果、レイアウタ38によるレイアウトの実行中であるか否かに拘わらず、URLの指定を格納し、URLにより特定されるXHTML文書を読み込んで解析することができる。したがって、印刷を完了する毎にURLにより特定されるXHTML文書を読み込んで解析して印刷するものに比して、迅速に解析して印刷することができる。   Further, according to the color inkjet printer 20 of the embodiment, every time a URL is specified, the specified URL is stored in the URL storage buffer area of the memory 50 regardless of whether the XHTML document is being analyzed. be able to. Further, when the URL is stored in the URL storage buffer area of the memory 50, the XHTML document can be sequentially analyzed regardless of whether the layout is being executed by the layouter 38 or not. As a result, regardless of whether the layout is being executed by the layouter 38, the designation of the URL can be stored, and the XHTML document specified by the URL can be read and analyzed. Therefore, each time printing is completed, the XHTML document specified by the URL is read, analyzed, and printed more quickly than when it is printed.

ここで、実施例のカラーインクジェットプリンタ20では、XMLパーサー34が構造書式解析手段に相当し、レイアウタ38がレイアウト作成手段に相当し、RPI40と色変換部42と2値化部44とイメージバッファ46と印刷実行部48とが印刷実行手段に相当する。   Here, in the color inkjet printer 20 of the embodiment, the XML parser 34 corresponds to the structure format analysis means, the layouter 38 corresponds to the layout creation means, the RPI 40, the color conversion unit 42, the binarization unit 44, and the image buffer 46. And the print execution unit 48 correspond to print execution means.

実施例のカラーインクジェットプリンタ20では、改ページの禁止の指定をオブジェクト毎に行なうことができるだけでなく、複数のオブジェクトを含むグループに対しても行なうことができるものとしたが、改ページの禁止の指定は、オブジェクト毎にだけしか行なうことができないものとしたり、少なくとも一つのオブジェクトを含むグループに対してだけしか行なうことができないものとしてもよい。   In the color ink jet printer 20 of the embodiment, not only the prohibition of page breaks can be specified for each object but also a group including a plurality of objects. The designation may be performed only for each object, or may be performed only for a group including at least one object.

実施例のカラーインクジェットプリンタ20では、メモリ50のURL格納用バッファ領域にURLが格納されているときには、メモリ50のDOMツリー用格納領域に格納されているDOMツリーの数に拘わらずに、XHTML文書の解析を順次行なうものとしたが、メモリ50のDOMツリー用格納領域に格納されているDOMツリーが所定数のときには所定数未満となるまで次のXHTML文書の解析を保留するものとしてもよい。所定数としては例えば値2とすることができる。こうすれば、メモリ50のDOMツリー用格納領域を小さくすることができる。   In the color inkjet printer 20 of the embodiment, when the URL is stored in the URL storage buffer area of the memory 50, the XHTML document is used regardless of the number of DOM trees stored in the DOM tree storage area of the memory 50. However, when the number of DOM trees stored in the DOM tree storage area of the memory 50 is a predetermined number, the analysis of the next XHTML document may be suspended until the number becomes less than the predetermined number. For example, the predetermined number may be 2. In this way, the storage area for the DOM tree in the memory 50 can be reduced.

実施例のカラーインクジェットプリンタ20では、メモリ50のURL格納用バッファ領域にURLが格納されているときには、XHTML文書の解析を終了次第、直ちに次のXHTML文書を解析するものとしたが、XHTML文書の解析を終了した以降であれば如何なるタイミングで次のXHTML文書を解析するものとしてもよい。   In the color inkjet printer 20 of the embodiment, when the URL is stored in the URL storage buffer area of the memory 50, the analysis of the XHTML document is immediately performed upon completion of the analysis of the XHTML document. After the analysis is completed, the next XHTML document may be analyzed at any timing.

実施例のカラーインクジェットプリンタ20では、URLが指定される毎にXHTML文書の解析中であるか否かに拘わらずに指定されたURLをメモリ50のURL格納用バッファ領域に格納すると共にメモリ50のURL格納用バッファ領域にURLが格納されているときにはレイアウタ38によるレイアウトの実行中であるか否かに拘わらずにXHTML文書の解析を順次行なうものとしたが、レイアウトの実行中などの印刷処理を実行しているときにはXHTML文書の解析を行なわないものとしてもよい。この場合、URLの受け付けも印刷処理が終了したときに行なうものとしても差し支えない。   In the color inkjet printer 20 of the embodiment, every time a URL is specified, the specified URL is stored in the URL storage buffer area of the memory 50 regardless of whether the XHTML document is being analyzed or not. When the URL is stored in the URL storage buffer area, the XHTML document is sequentially analyzed regardless of whether the layout is being executed by the layouter 38. However, the printing process such as the execution of the layout is performed. During execution, the XHTML document may not be analyzed. In this case, the URL may be accepted when the printing process is completed.

実施例のカラーインクジェットプリンタ20では、記述文書としてXHTMLにより記述されたXHTML文書を解析して印刷するものとしたが、他のマークアップ言語により記述された記述文書を解析して印刷するものとしてもよい。また、マークアップ言語以外の言語により記述された文書を解析して印刷するものとしても差し支えない。   In the color inkjet printer 20 of the embodiment, an XHTML document described in XHTML is analyzed and printed as a description document. However, a description document described in another markup language may be analyzed and printed. Good. In addition, a document described in a language other than the markup language may be analyzed and printed.

実施例のカラーインクジェットプリンタ20では、入力インターフェース22に接続される機器としてコンピュータ10やデジタルテレビ12やデジタルカメラ14などを記載したが、如何なる機器を接続するものとしても差し支えない。   In the color inkjet printer 20 of the embodiment, the computer 10, the digital television 12, the digital camera 14, and the like are described as devices connected to the input interface 22, but any device may be connected.

実施例では、XHTML文書を解析して印刷する本発明の印刷装置としてカラーインクジェットプリンタを用いたが、カラーレーザプリンタやモノクロのインジェットプリンタやレーザプリンタなどの種々のプリンタを用いるものとしてもよい。   In the embodiment, a color inkjet printer is used as the printing apparatus of the present invention for analyzing and printing an XHTML document. However, various printers such as a color laser printer, a monochrome inkjet printer, and a laser printer may be used.

以上、本発明を実施するための最良の形態について実施例を用いて説明したが、本発明はこうした実施例に何等限定されるものではなく、本発明の要旨を逸脱しない範囲内において、種々なる形態で実施し得ることは勿論である。   The best mode for carrying out the present invention has been described with reference to the embodiments. However, the present invention is not limited to these embodiments, and various modifications can be made without departing from the gist of the present invention. Of course, it can be implemented in the form.

実施例のカラーインクジェットプリンタ20の構成を例示する構成図。1 is a configuration diagram illustrating a configuration of a color inkjet printer 20 according to an embodiment. 解析レイアウト指示処理の一例を示すフローチャート。The flowchart which shows an example of an analysis layout instruction | indication process. 解析処理の一例を示すフローチャート。The flowchart which shows an example of an analysis process. 具体例のXHTML文書の一例を示す説明図。Explanatory drawing which shows an example of the XHTML document of a specific example. 具体例のDOMツリーの一例を示す説明図。Explanatory drawing which shows an example of the DOM tree of a specific example. レイアウト描画指示処理の一例を示すフローチャート。6 is a flowchart illustrating an example of a layout drawing instruction process. レイアウト処理の一例を示すフローチャート。The flowchart which shows an example of a layout process. 具体例における改ページの必要性を説明する説明図。Explanatory drawing explaining the necessity of a page break in a specific example. 具体例のページボックスの一例を示す説明図。Explanatory drawing which shows an example of the page box of a specific example. 描画処理の一例を示すフローチャート。The flowchart which shows an example of a drawing process. 具体例の印刷結果の一例を示す説明図。Explanatory drawing which shows an example of the printing result of a specific example. 他の具体例のXHTML文書の一例を示す説明図。Explanatory drawing which shows an example of the XHTML document of another specific example. 他の具体例のDOMツリーの一例を示す説明図。Explanatory drawing which shows an example of the DOM tree of another specific example. 他の具体例における改ページの必要性を説明する説明図。Explanatory drawing explaining the necessity of a page break in another specific example. 他の具体例の印刷結果の一例を示す説明図。Explanatory drawing which shows an example of the printing result of another specific example.

符号の説明Explanation of symbols

10 コンピュータ、12 デジタルテレビ、14 デジタルカメラ、20 カラーインクジェットプリンタ、22 入力インターフェース、24 信号処理部、30 解析部、32 コア、34 XMLパーサー、36 CSSPI、38 レイアウタ、40 RPI、42 色変換部、44 2値化部、46 イメージバッファ、48 印刷実行部、50 メモリ、60 操作部、61 液晶ディスプレイ、62 操作ボタン、63 CPU、64 ROM、65 ディスプレイコントローラ(LCDC)、66 メモリ。   10 computers, 12 digital televisions, 14 digital cameras, 20 color inkjet printers, 22 input interfaces, 24 signal processing units, 30 analysis units, 32 cores, 34 XML parsers, 36 CSSPIs, 38 layouters, 40 RPIs, 42 color conversion units, 44 binarization unit, 46 image buffer, 48 print execution unit, 50 memory, 60 operation unit, 61 liquid crystal display, 62 operation button, 63 CPU, 64 ROM, 65 display controller (LCDC), 66 memory.

Claims (12)

印刷可能なオブジェクトを階層的に記述した記述文書を解析して紙などの媒体に印刷する印刷装置であって、
記述文書におけるオブジェクトの階層的な木構造と該オブジェクトの書式とを解析する構造書式解析手段と、
前記解析された木構造と書式とに基づいてオブジェクトを順次解析して配置する手法をもってレイアウトすることにより前記媒体へのページ毎のレイアウトを作成する際に、少なくとも一つのオブジェクトを含み改ページ禁止の指定がなされた改ページ禁止グループに属するオブジェクトについては、改ページが必要になるまでは該改ページ禁止グループに属するオブジェクトを順次解析して配置し、改ページが必要になったときには該改ページ禁止グループに属するオブジェクトのうち該改ページが必要になるまでに行なわれたオブジェクトの解析および配置を該改ページ後に行なわれたオブジェクトの解析および配置として適用すると共に該改ページが必要になったときに解析していたオブジェクト以降のオブジェクトを順次解析して配置することにより、ページ毎のレイアウトを作成するレイアウト作成手段と、
前記作成されたページ毎のレイアウトに基づいてオブジェクトをレイアウトして前記媒体に印刷する印刷実行手段と、
を備える印刷装置。
A printing device that analyzes a description document that hierarchically describes printable objects and prints it on a medium such as paper,
A structure format analysis means for analyzing the hierarchical tree structure of the object in the description document and the format of the object;
When creating a layout for each page on the medium by laying out with a method of sequentially analyzing and arranging objects based on the analyzed tree structure and format, page breaks including at least one object are prohibited. For the objects belonging to the specified page break prohibition group, the objects belonging to the page break prohibition group are sequentially analyzed and arranged until a page break is required, and the page break is prohibited when a page break is required. When the analysis and arrangement of the objects performed before the page break is necessary among the objects belonging to the group are applied as the analysis and arrangement of the objects performed after the page break, and the page break is necessary Sequentially analyze and distribute objects after the object being analyzed By, the layout creating means for creating a layout for each page,
Print execution means for laying out an object based on the created layout for each page and printing on the medium;
A printing apparatus comprising:
前記レイアウト作成手段は、前記改ページ禁止グループに属するオブジェクトを配置している途中で改ページが必要になったときには該改ページ禁止グループに属するオブジェクトのうち改ページ前に解析して配置したオブジェクトについては該改ページの前ページのレイアウトから削除する手段である請求項1記載の印刷装置。   The layout creation means, when an object belonging to the page break prohibition group is placed, when a page break is required, among the objects belonging to the page break prohibition group, the object analyzed and arranged before the page break 2. The printing apparatus according to claim 1, which is means for deleting from the layout of the previous page of the page break. 印刷可能なオブジェクトを階層的に記述した記述文書を解析して紙などの媒体に印刷する印刷装置であって、
記述文書におけるオブジェクトの階層的な木構造と該オブジェクトの書式とを解析する構造書式解析手段と、
前記解析された木構造と書式とに基づいてオブジェクトを該オブジェクトの内容を順次解析して配置する手法をもってレイアウトすることにより前記媒体へのページ毎のレイアウトを作成する際に、前記オブジェクトのうち改ページ禁止の指定がなされた改ページ禁止オブジェクトについては、改ページが必要になるまでは該改ページ禁止オブジェクトの内容を順次解析して配置し、改ページが必要になったときには該改ページ禁止オブジェクトの内容のうち該改ページが必要になるまでに行なわれた内容の解析および配置を該改ページ後に行なわれた内容の解析および配置として適用すると共に該改ページが必要になったときに解析していた内容以降の内容を順次解析して配置することにより、ページ毎のレイアウトを作成するレイアウト作成手段と、
前記作成されたページ毎のレイアウトに基づいてオブジェクトをレイアウトして前記媒体に印刷する印刷実行手段と、
を備える印刷装置。
A printing device that analyzes a description document that hierarchically describes printable objects and prints it on a medium such as paper,
A structure format analysis means for analyzing the hierarchical tree structure of the object in the description document and the format of the object;
When creating a layout for each page on the medium by laying out an object based on the analyzed tree structure and format by a method of sequentially analyzing and arranging the contents of the object, the object is modified. For a page break prohibition object for which page prohibition is specified, the contents of the page break prohibition object are sequentially analyzed and arranged until a page break is required, and when a page break is required, the page break prohibition object The analysis and arrangement of the contents performed before the page break is necessary are applied as the analysis and arrangement of the contents performed after the page break and are analyzed when the page break is necessary. A layout that creates a layout for each page by sequentially analyzing and arranging the contents after the previous contents And forming means,
Print execution means for laying out an object based on the created layout for each page and printing on the medium;
A printing apparatus comprising:
前記レイアウト作成手段は、前記改ページ禁止オブジェクトの内容を配置している途中で改ページが必要になったときには該改ページ禁止オブジェクトの内容のうち改ページ前に解析して配置した内容については該改ページの前ページのレイアウトから削除する手段である請求項2記載の印刷装置。   The layout creation means, when a page break is necessary during the placement of the contents of the page break prohibition object, the contents analyzed and arranged before the page break among the contents of the page break prohibition object 3. The printing apparatus according to claim 2, wherein the printing apparatus is means for deleting from the layout of the previous page of the page break. 前記レイアウト作成手段は、レイアウトの作成が完了したページ毎に印刷実行指示を前記印刷実行手段に行なう手段である請求項1ないし4いずれか記載の印刷装置。   5. The printing apparatus according to claim 1, wherein the layout creation unit is a unit that issues a print execution instruction to the print execution unit for each page for which layout creation has been completed. 前記レイアウト作成手段は、1ページ分のレイアウトの作成が完了した以降に印刷実行指示を前記印刷実行手段に行なう手段である請求項1ないし5いずれか記載の印刷装置。   The printing apparatus according to claim 1, wherein the layout creation unit is a unit that issues a print execution instruction to the print execution unit after the creation of a layout for one page is completed. 前記記述文書は、マークアップ言語により記述されてなる請求項1ないし6いずれか記載の印刷装置。   The printing apparatus according to claim 1, wherein the description document is described in a markup language. 前記マークアップ言語は、XHTML言語である請求項7記載の印刷装置。   The printing apparatus according to claim 7, wherein the markup language is an XHTML language. 前記オブジェクトは、テキスト,画像,表の少なくとも一つを含む請求項1ないし8いずれか記載の印刷装置。   The printing apparatus according to claim 1, wherein the object includes at least one of a text, an image, and a table. カラーインクジェットプリンタである請求項1ないし9いずれか記載の印刷装置。   The printing apparatus according to claim 1, which is a color inkjet printer. 印刷可能なオブジェクトを階層的に記述した記述文書を解析して紙などの媒体に印刷する印刷装置における印刷方法であって、
(a)記述文書におけるオブジェクトの階層的な木構造と該オブジェクトの書式とを解析し、
(b)前記解析した木構造と書式とに基づいてオブジェクトを順次解析して配置する手法をもってレイアウトすることにより前記媒体へのページ毎のレイアウトを作成する際に、少なくとも一つのオブジェクトを含み改ページ禁止の指定がなされた改ページ禁止グループに属するオブジェクトについては、改ページが必要になるまでは該改ページ禁止グループに属するオブジェクトを順次解析して配置し、改ページが必要になったときには該改ページ禁止グループに属するオブジェクトのうち該改ページが必要になるまでに行なわれたオブジェクトの解析および配置を該改ページ後に行なわれたオブジェクトの解析および配置として適用すると共に該改ページが必要になったときに解析していたオブジェクト以降のオブジェクトを順次解析して配置することにより、ページ毎のレイアウトを作成し、
(c)前記作成したページ毎のレイアウトに基づいてオブジェクトをレイアウトして前記媒体に印刷する
印刷方法。
A printing method in a printing apparatus that analyzes a description document in which printable objects are hierarchically described and prints on a medium such as paper,
(A) Analyzing the hierarchical tree structure of the object in the description document and the format of the object;
(B) When creating a layout for each page on the medium by laying out with a method of sequentially analyzing and arranging objects based on the analyzed tree structure and format, the page break includes at least one object. For the objects belonging to the page break prohibition group for which prohibition is specified, the objects belonging to the page break prohibition group are sequentially analyzed and arranged until a page break is necessary. Of the objects belonging to the page prohibition group, the analysis and arrangement of the object performed until the page break is necessary are applied as the analysis and arrangement of the object performed after the page break, and the page break is necessary. Analyze objects after the object that was being analyzed By arrangement, to create a layout for each page,
(C) A printing method in which an object is laid out based on the created layout for each page and printed on the medium.
印刷可能なオブジェクトを階層的に記述した記述文書を解析して紙などの媒体に印刷する印刷装置における印刷方法であって、
(a)記述文書におけるオブジェクトの階層的な木構造と該オブジェクトの書式とを解析し、
(b)前記解析した木構造と書式とに基づいてオブジェクトを該オブジェクトの内容を順次解析して配置する手法をもってレイアウトすることにより前記媒体へのページ毎のレイアウトを作成する際に、前記オブジェクトのうち改ページ禁止の指定がなされた改ページ禁止オブジェクトについては、改ページが必要になるまでは該改ページ禁止オブジェクトの内容を順次解析して配置し、改ページが必要になったときには該改ページ禁止オブジェクトの内容のうち該改ページが必要になるまでに行なわれた内容の解析および配置を該改ページ後に行なわれた内容の解析および配置として適用すると共に該改ページが必要になったときに解析していた内容以降の内容を順次解析して配置することにより、ページ毎のレイアウトを作成し、
(c)前記作成したページ毎のレイアウトに基づいてオブジェクトをレイアウトして前記媒体に印刷する
印刷方法。
A printing method in a printing apparatus that analyzes a description document in which printable objects are hierarchically described and prints on a medium such as paper,
(A) Analyzing the hierarchical tree structure of the object in the description document and the format of the object;
(B) When creating a layout for each page on the medium by laying out an object based on the analyzed tree structure and format by a method of sequentially analyzing and arranging the contents of the object, Among the page break prohibition objects for which page break prohibition is specified, the contents of the page break prohibition object are sequentially analyzed and arranged until a page break is necessary. When the analysis and arrangement of the contents of the prohibited object before the page break is necessary are applied as the analysis and arrangement of the contents performed after the page break and the page break is necessary Create a layout for each page by sequentially analyzing and arranging the contents after the analyzed contents,
(C) A printing method in which an object is laid out based on the created layout for each page and printed on the medium.
JP2004060961A 2004-03-04 2004-03-04 Printing apparatus and printing method therefor Pending JP2005246796A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2004060961A JP2005246796A (en) 2004-03-04 2004-03-04 Printing apparatus and printing method therefor

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2004060961A JP2005246796A (en) 2004-03-04 2004-03-04 Printing apparatus and printing method therefor

Publications (1)

Publication Number Publication Date
JP2005246796A true JP2005246796A (en) 2005-09-15

Family

ID=35027748

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2004060961A Pending JP2005246796A (en) 2004-03-04 2004-03-04 Printing apparatus and printing method therefor

Country Status (1)

Country Link
JP (1) JP2005246796A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2011068060A (en) * 2009-09-28 2011-04-07 Brother Industries Ltd Printer and program

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2011068060A (en) * 2009-09-28 2011-04-07 Brother Industries Ltd Printer and program
US8743412B2 (en) 2009-09-28 2014-06-03 Brother Kogyo Kabushiki Kaisha Printing device which prints first object and second object on the same page

Similar Documents

Publication Publication Date Title
JP2005131915A (en) Printing apparatus, printing method, and program for printing apparatus
JP4298362B2 (en) Information processing apparatus and print preview display method
US8634100B2 (en) Image forming apparatus for detecting index data of document data, and control method and program product for the same
US20050128516A1 (en) Document processing apparatus and document processing method
US20090204888A1 (en) Document processing apparatus, document processing method, and storage medium
CN101951452A (en) Printing state set device, method, system and storage medium
US20160219164A1 (en) Image processing device, image processing method, and image forming system
US20050036170A1 (en) Image processing apparatus and image forming apparatus
JP4438380B2 (en) Printing apparatus, printing method, and program for printing apparatus
JP2008311930A (en) Image processing apparatus, image processing method, computer program, and storage medium
JP5031788B2 (en) Printing apparatus and program
JP2010055582A (en) Printing system, printer and terminal device constituting the printing system
JP2005208723A (en) Printing apparatus and medium type setting method
JP4449398B2 (en) Printing apparatus, printing method, and program for printing apparatus
JP2005246796A (en) Printing apparatus and printing method therefor
US9253343B2 (en) Information processing apparatus, control method, and storage medium for providing a preview and/or display of a main display document generated from all parts of a print document
US20060092454A1 (en) Printing device and printing method
JP5915091B2 (en) Image forming apparatus, image forming system, output image data processing method, program, and recording medium
JP2005208809A (en) Document analysis apparatus and method, program for document analysis apparatus, and printing apparatus
JP4599950B2 (en) Processing apparatus and processing method
US20060092447A1 (en) Printing device and corresponding printing method used therein
JP4165366B2 (en) Document analysis apparatus and method, program for document analysis apparatus, and printing apparatus
JP2005111711A (en) Printing apparatus, printing method, and program for printing apparatus
JP2005208810A (en) Document analysis apparatus and method, program for document analysis apparatus, and printing apparatus
US8913294B2 (en) Image processing apparatus and image processing system