JP7397652B2 - Program, information processing device, and method - Google Patents

Program, information processing device, and method Download PDF

Info

Publication number
JP7397652B2
JP7397652B2 JP2019226799A JP2019226799A JP7397652B2 JP 7397652 B2 JP7397652 B2 JP 7397652B2 JP 2019226799 A JP2019226799 A JP 2019226799A JP 2019226799 A JP2019226799 A JP 2019226799A JP 7397652 B2 JP7397652 B2 JP 7397652B2
Authority
JP
Japan
Prior art keywords
print
printing
print setting
preview
application
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.)
Active
Application number
JP2019226799A
Other languages
Japanese (ja)
Other versions
JP2021096605A (en
Inventor
敬二 川嵜
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.)
Canon Inc
Original Assignee
Canon Inc
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 Canon Inc filed Critical Canon Inc
Priority to JP2019226799A priority Critical patent/JP7397652B2/en
Publication of JP2021096605A publication Critical patent/JP2021096605A/en
Priority to JP2023202187A priority patent/JP2024009336A/en
Application granted granted Critical
Publication of JP7397652B2 publication Critical patent/JP7397652B2/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Landscapes

  • Accessory Devices And Overall Control Thereof (AREA)
  • User Interface Of Digital Computer (AREA)

Description

本発明は、プログラム、情報処理装置、および方法に関する。特に、印刷機能を提供するアプリケーションに関するプログラム、情報処理装置、および方法に関する。 The present invention relates to a program, an information processing device, and a method. In particular, the present invention relates to a program, an information processing device, and a method related to an application that provides a printing function.

印刷装置の制御用ソフトウェアとしてホストコンピュータにインストールされたプリンタドライバを利用し、ホストコンピュータに接続された印刷装置に対して印刷を行う構成が一般に知られる。ホストコンピュータには、基本ソフトウェアであるオペレーティングシステム(OS)がインストールされており、プリンタドライバはそのOSの規定する仕様に従って構成され、OSから呼び出されて動作する。印刷装置を提供するベンダは、OSの仕様に適合するプリンタドライバを提供することにより、そのOSを用いてプリンタに印刷を指示する手段を提供することができる。 2. Description of the Related Art Generally known is a configuration in which a printer driver installed in a host computer is used as software for controlling the printing device, and printing is performed on a printing device connected to the host computer. An operating system (OS), which is basic software, is installed on the host computer, and a printer driver is configured according to specifications defined by the OS, and is called and operated by the OS. By providing a printer driver that conforms to the specifications of the OS, a vendor that provides a printing device can provide a means for instructing the printer to print using the OS.

印刷機能を有するアプリケーションは、プリンタドライバに対して印刷要求を発行することで、印刷装置に対する印刷を実現することができる。OSとしてMicrosoft(登録商標)のWindows(登録商標)を利用する場合、アプリケーションのアーキテクチャとしてWin32やWPFと呼ばれるアーキテクチャが利用される。Win32やWPFでは、印刷要求の発行のための手段として複数の方法が用意されている。例えば、Win32アプリケーションは、印刷要求を発行する際に、OSの提供する標準的な印刷用のダイアログを表示しても良いし、表示しなくても良い。また、Win32アプリケーションは、印刷設定を変更するためにプリンタドライバが提供するGUI(Graphical User Interface)を利用しても良いし、利用せずに直接印刷設定を変更しても良い。 An application having a print function can perform printing on a printing device by issuing a print request to a printer driver. When Windows (registered trademark) by Microsoft (registered trademark) is used as the OS, an architecture called Win32 or WPF is used as the application architecture. Win32 and WPF provide a plurality of methods for issuing a print request. For example, when a Win32 application issues a print request, it may or may not display a standard print dialog provided by the OS. Further, the Win32 application may use a GUI (Graphical User Interface) provided by the printer driver to change the print settings, or may directly change the print settings without using it.

近年、Windows(登録商標)において、UWP(Universal Windows Platform)アプリケーションと呼ばれる、新しいアプリケーションアーキテクチャが登場した。UWPアプリケーションからプリンタドライバに対して印刷要求を発行すると、MPD(Modern Print Dialog)というOS標準の印刷用ダイアログが表示される(特許文献1)。 In recent years, a new application architecture called a UWP (Universal Windows Platform) application has appeared in Windows (registered trademark). When a UWP application issues a print request to a printer driver, an OS standard print dialog called MPD (Modern Print Dialog) is displayed (Patent Document 1).

特開2017-194766号公報Japanese Patent Application Publication No. 2017-194766

このように、UWPアプリケーションでは、印刷要求時にMPDが表示されるため、アプリケーションの種類によらず、ユーザは統一的な操作感で印刷指示を行うことができる。一方、上記の印刷用ダイアログにおいて、印刷設定をより明確に反映したプレビュー表示が求められる。 In this way, in the UWP application, since the MPD is displayed when a print request is made, the user can issue a print instruction with a uniform operational feel, regardless of the type of application. On the other hand, in the above print dialog, a preview display that more clearly reflects the print settings is required.

本発明は、このような課題に鑑み、OS標準の印刷用ダイアログに、印刷設定をより明確に反映したプレビュー表示を行わせることができる技術を提供することを目的とする。 In view of these problems, an object of the present invention is to provide a technology that allows an OS standard print dialog to display a preview that more clearly reflects print settings.

上述のような課題を解決するため、本発明のプログラムの一態様は、情報処理装置が備えるOS上で動作するアプリケーションのプログラムであって、前記情報処理装置のコンピュータをユーザから印刷要求を受付ける第一の受付手段と、前記印刷要求に応じて表示された、前記OS標準の印刷設定ダイアログで指定された印刷設定情報を取得する取得手段と、印刷対象データと前記印刷設定情報とに基づいて、前記印刷設定ダイアログがプレビューを表示するためのプレビューデータを生成する第一の生成手段と、前記印刷設定ダイアログに前記プレビューデータを返却する返却手段と、として機能させる。 In order to solve the above problems, one aspect of the present invention is an application program that runs on an OS included in an information processing device, the program causing the computer of the information processing device to receive a print request from a user. one reception means; an acquisition means for acquiring print setting information specified in the OS standard print setting dialog displayed in response to the print request; and based on the print target data and the print setting information, The print settings dialog functions as a first generation unit that generates preview data for displaying a preview, and a return unit that returns the preview data to the print settings dialog.

本発明により、OS標準の印刷用ダイアログに、印刷設定をより明確に反映したプレビュー表示を行わせることが可能となる。 According to the present invention, it is possible to cause an OS standard print dialog to display a preview that more clearly reflects the print settings.

印刷システムのハードウェア構成を示すブロック図。FIG. 1 is a block diagram showing the hardware configuration of a printing system. 印刷システムのブロック構成図。A block configuration diagram of a printing system. 印刷指示を行う場合の画面を説明するための模式図。FIG. 3 is a schematic diagram for explaining a screen when issuing a print instruction. UWPアプリケーションの画面構成例。Example of screen configuration of UWP application. UWPアプリケーションの印刷処理初期化処理のフローチャート。5 is a flowchart of print processing initialization processing of a UWP application. 写真印刷モードの場合に表示されるMPDの印刷設定画面の例。An example of an MPD print setting screen displayed in photo print mode. ディスクレーベル印刷モードの場合に表示されるMPDの印刷設定画面の例。An example of the MPD print setting screen displayed in disc label print mode. UWPアプリケーションのパジネート処理のフローチャート。A flowchart of pagination processing of a UWP application. UWPアプリケーションのプレビュー生成処理のフローチャート。3 is a flowchart of preview generation processing of a UWP application. 非サポートプリンタが選択されたときのMPDの印刷設定画面の例。An example of the MPD print setting screen when an unsupported printer is selected. UWPアプリケーションの印刷データ生成処理のフローチャート。5 is a flowchart of print data generation processing of a UWP application. UWPアプリケーションの設定変更処理のフローチャート。5 is a flowchart of UWP application setting change processing. 図2のブロック間の動作の一例を示すシーケンス図。3 is a sequence diagram showing an example of operations between blocks in FIG. 2. FIG.

以下、添付図面を参照して本発明の好適な実施の形態を詳しく説明する。尚、以下の実施の形態は特許請求の範囲に係る本発明を限定するものでなく、また本実施の形態で説明されている特徴の組み合わせの全てが本発明の解決手段に必須のものとは限らない。なお、同一の構成要素には同一の参照番号を付して、説明を省略する。 Hereinafter, preferred embodiments of the present invention will be described in detail with reference to the accompanying drawings. It should be noted that the following embodiments do not limit the present invention according to the claims, and all combinations of features described in the present embodiments are not essential to the solution of the present invention. Not exclusively. In addition, the same reference numerals are given to the same component, and the description is omitted.

<実施形態1>
(印刷システムのハードウェア構成)
図1は、印刷システムのハードウェア構成を示すブロック図である。本図において、ホストコンピュータ101は、情報処理装置の一例であり、入力インタフェース110、CPU111、ROM112、RAM113、外部記憶装置114、出力インタフェース115、及び入出力インタフェース116を有する。また、入力インタフェース110には、キーボード118、ポインティングデバイス117などの入力デバイスが接続され、出力インタフェース115には、表示部119などの表示デバイスが接続されている。
<Embodiment 1>
(Hardware configuration of printing system)
FIG. 1 is a block diagram showing the hardware configuration of a printing system. In the figure, a host computer 101 is an example of an information processing device, and includes an input interface 110, a CPU 111, a ROM 112, a RAM 113, an external storage device 114, an output interface 115, and an input/output interface 116. Further, input devices such as a keyboard 118 and pointing device 117 are connected to the input interface 110, and display devices such as a display unit 119 are connected to the output interface 115.

ROM112には、後述したUWP(Universal Windows Platform)アプリケーションの印刷初期化のための初期化プログラムが格納される。外部記憶装置114には、アプリケーションプログラム群、オペレーティングシステム(OS)、プリンタドライバ、その他の各種のデータが格納されている。RAM113は、外部記憶装置114に格納された各種プログラムをCPU111が実行する際のワークメモリ等として使用される。 The ROM 112 stores an initialization program for initializing printing of a UWP (Universal Windows Platform) application, which will be described later. The external storage device 114 stores application programs, an operating system (OS), a printer driver, and other various data. The RAM 113 is used as a work memory etc. when the CPU 111 executes various programs stored in the external storage device 114.

なお、本実施形態では、CPU111が、ROM112に格納されたプログラムの手順に従って処理を行うことによって、ホストコンピュータ101における後述の機能及び後述するフローチャートに係る処理が実現される。プリンタなどの印刷装置102は、入出力インタフェース116を介して、ホストコンピュータ101と接続されている。本実施形態では、ホストコンピュータ101と印刷装置102が分かれて構成されるものとして説明を行うが、これらが一つの情報処理装置として構成されていてもよい。 Note that, in this embodiment, the CPU 111 performs processing according to the procedure of the program stored in the ROM 112, thereby realizing functions related to the later-described functions and flowcharts described later in the host computer 101. A printing device 102 such as a printer is connected to a host computer 101 via an input/output interface 116. In this embodiment, the host computer 101 and the printing device 102 are described as being configured separately, but they may be configured as a single information processing device.

(印刷システムのブロック構成)
図2は、印刷システムのブロック構成図である。ここでは、OS202としてMicrosoft(登録商標)のWindows(登録商標)8以降のOSを搭載したホストコンピュータ101を用い、V4プリンタドライバと呼ばれるアーキテクチャで動作する印刷システムを前提として説明する。
(Block configuration of printing system)
FIG. 2 is a block diagram of the printing system. Here, the explanation will be based on the premise that the host computer 101 is equipped with Microsoft (registered trademark)'s Windows (registered trademark) 8 or later OS as the OS 202, and is a printing system that operates with an architecture called a V4 printer driver.

図2に示すCPU111が、ROM112に格納されたプログラムを実行することによって、UWPアプリケーション201、OS202、WSDA205、およびプリンタドライバ206として機能する。 The CPU 111 shown in FIG. 2 functions as the UWP application 201, the OS 202, the WSDA 205, and the printer driver 206 by executing programs stored in the ROM 112.

UWPアプリケーション201は、印刷機能を有する印刷アプリケーションであり、画像、テキストなどを含む印刷対象データの閲覧、編集、移動、および削除の少なくとも何れかの操作や、ユーザの印刷要求を受付けることが可能なアプリケーションである。OS202は、MPD(Modern Print Dialog)203およびプリントマネージャ204を含む。MPD203は、印刷結果を画面上で確認できる印刷プレビュー機能と、基本的な印刷設定をユーザが選択可能な機能とを有する、アプリケーションによらず共通の印刷設定画面(印刷設定ダイアログ)である。なお、図2の例では、MPD203がOS202上で動作する例について記載しているが、これに限らず、MPD203がOS202の外部のアプリケーションとして存在してもよい。この場合でもMPD203は、OS標準の印刷用ダイアログであり、印刷の際にOS202により起動される。また、UWPアプリケーション201は図2において外部アプリケーションとして示しているが、OS上で動作してもよい。プリントマネージャ204は、OS202の機能であり、印刷設定を変更、確認するためのUWPアプリケーション201、MPD203、およびWSDA205から情報を取得し、プリンタドライバ206を介して印刷装置102に印刷を指示する。WSDA(Windows Store Device Application)205は印刷装置を提供するベンダ(以後、プリンタベンダ)が提供するプリンタドライバ206の機能を拡張するためのアプリケーションである。 The UWP application 201 is a printing application that has a printing function, and can perform at least one of viewing, editing, moving, and deleting print target data including images, text, etc., and can accept print requests from users. It is an application. The OS 202 includes an MPD (Modern Print Dialog) 203 and a print manager 204. The MPD 203 is a print settings screen (print settings dialog) that is common regardless of the application and has a print preview function that allows the print result to be checked on the screen, and a function that allows the user to select basic print settings. Note that although the example in FIG. 2 describes an example in which the MPD 203 operates on the OS 202, the present invention is not limited to this, and the MPD 203 may exist as an application external to the OS 202. Even in this case, the MPD 203 is an OS standard print dialog, and is activated by the OS 202 during printing. Further, although the UWP application 201 is shown as an external application in FIG. 2, it may operate on the OS. The print manager 204 is a function of the OS 202 and acquires information from the UWP application 201, MPD 203, and WSDA 205 for changing and confirming print settings, and instructs the printing apparatus 102 to print via the printer driver 206. WSDA (Windows Store Device Application) 205 is an application for extending the functionality of a printer driver 206 provided by a vendor (hereinafter referred to as a printer vendor) that provides a printing device.

ここで、図13を参照して、本実施形態に係るUWPアプリケーション201、MPD203、プリントマネージャ204、およびWSDA205が実行する一連の印刷処理の一例について説明する。 Here, with reference to FIG. 13, an example of a series of print processing executed by the UWP application 201, MPD 203, print manager 204, and WSDA 205 according to this embodiment will be described.

まず、S1301で、ユーザはUWPアプリケーション201の起動を指示する。起動を指示されたUWPアプリケーション201は、S1302で表示部119に画面を表示する。図3(A)に、印刷アプリケーションであるUWPアプリケーション201が提供する画面301の一例を示す。S1303において、ユーザからの印刷要求をUWPアプリケーション201が受付けると、S1304でプリントマネージャ204に通知を行う。なお、ブロック間の通信またはユーザから各ブロックへの指示は、各ブロック同士をつなぐ矢印で示しているが、OS202を介して行われてもよい。 First, in S1301, the user instructs to start the UWP application 201. The UWP application 201 that has been instructed to start displays a screen on the display unit 119 in S1302. FIG. 3A shows an example of a screen 301 provided by the UWP application 201, which is a print application. When the UWP application 201 accepts a print request from the user in S1303, it notifies the print manager 204 in S1304. Note that communication between blocks or instructions from the user to each block are shown by arrows connecting each block, but may be performed via the OS 202.

UWPアプリケーション201がユーザから印刷要求を受付けると、OS202の機能であるプリントマネージャ204により、S1305でMPD(印刷設定ダイアログ)203が起動される。また、プリントマネージャ204は、S1306で、UWPアプリケーション201に印刷設定情報を送信し、プレビューデータの生成要求を送信する。続いて、UWPアプリケーション201は、S1307で、プリントマネージャ204から取得した印刷設定情報と、UWPアプリケーションのコンテンツ(印刷対象データ)の少なくとも一部とに基づいてプレビューデータを生成する。続いて、UWPアプリケーション201はS1308でMPD203にプレビューデータを渡してプレビューデータの描画指示を行う。プレビューデータの生成処理については図9を参照して後述する。S1309で、MPD203は、プレビューデータを用いて図3(B)に示すMPDが提供する印刷設定画面302の表示を行う。この印刷設定画面302において、ユーザは、印刷に使用するプリンタドライバ206の選択を行うことができる。さらに、印刷設定画面302において、基本的な印刷設定を指示することもできる。 When the UWP application 201 receives a print request from a user, the print manager 204, which is a function of the OS 202, starts an MPD (print settings dialog) 203 in step S1305. Further, in step S1306, the print manager 204 transmits print setting information to the UWP application 201, and transmits a preview data generation request. Next, in step S1307, the UWP application 201 generates preview data based on the print setting information acquired from the print manager 204 and at least a portion of the content (data to be printed) of the UWP application. Next, in step S1308, the UWP application 201 passes the preview data to the MPD 203 and instructs the MPD 203 to draw the preview data. The preview data generation process will be described later with reference to FIG. In step S1309, the MPD 203 uses the preview data to display the print setting screen 302 provided by the MPD shown in FIG. 3(B). On this print setting screen 302, the user can select the printer driver 206 to be used for printing. Furthermore, basic print settings can be specified on the print settings screen 302.

さらに、S1310において、印刷設定画面302上でのユーザからの指示を受け、S1311で通知を受信したプリントマネージャ204は、S1312でWSDA205に起動指示を行う。起動指示を受けたWSDA205は、S1313において、詳細な印刷設定をユーザが選択可能な画面を起動する。具体的には、図3(B)の印刷設定画面302において「その他の設定」ボタン303が指定されると、図3(C)に示すWSDA205が提供する詳細設定画面304が表示される。この詳細設定画面304でユーザは更に詳細な印刷設定を指示することができる。なお、WSDA205が提供する詳細設定画面304内に表示されている原稿画像のように見える画像は、WSDAが元々備えているサンプル画像である。よって、UWPアプリケーションにより生成された描画データに基づくプレビュー画像ではなく、描画データが変わっても変化しないサンプル画像である。また、WSDA205は、MPDが提供する印刷設定画面302上でユーザがボタン303を指示した場合にのみ起動されるものであって、印刷設定時に必ず起動されるわけではない。 Further, in S1310, the print manager 204 receives an instruction from the user on the print setting screen 302, and receives a notification in S1311, and instructs the WSDA 205 to start up in S1312. In step S1313, the WSDA 205 that has received the activation instruction activates a screen from which the user can select detailed print settings. Specifically, when the "other settings" button 303 is designated on the print settings screen 302 in FIG. 3(B), a detailed settings screen 304 provided by the WSDA 205 shown in FIG. 3(C) is displayed. The user can instruct more detailed print settings on this detailed settings screen 304. Note that the image that looks like a document image displayed in the detailed setting screen 304 provided by the WSDA 205 is a sample image originally provided by the WSDA. Therefore, it is not a preview image based on drawing data generated by a UWP application, but a sample image that does not change even if the drawing data changes. Further, the WSDA 205 is activated only when the user instructs the button 303 on the print setting screen 302 provided by the MPD, and is not necessarily activated when setting the print settings.

続いて、S1314でユーザ操作によって詳細設定の変更指示を受信したWSDA205は、S1315に変更内容を通知する。すると、プリントマネージャ204は、S1316で変更した印刷設定情報を格納する。ここで、印刷設定を示す情報は、OSの定義する書式に基づきXML形式で記述されたものであり、PrintTicketと呼ばれるデータ内に含まれる。WSDA205はPrintTicketを参照及び変更することができるが、描画データ(紙面上に印刷を形成する元となる画像やテキスト情報等)を参照することはできない。なお、図13には図示されていないが、PrintTicketは、選択されたプリンタドライバ206によって生成される。また、プリンタドライバ206は、設定可能な機能と選択項目をOSの定義する書式に基づきXML形式で記述したPrintCapabilitiesを生成する機能も有する。WSDA205は、このPrintCapabilitiesに記述された情報に基づきユーザインタフェースを提供する。 Subsequently, the WSDA 205, which has received an instruction to change detailed settings through a user operation in S1314, notifies the details of the change in S1315. Then, the print manager 204 stores the print setting information changed in S1316. Here, the information indicating the print settings is written in XML format based on the format defined by the OS, and is included in data called PrintTicket. Although the WSDA 205 can refer to and change the PrintTicket, it cannot refer to drawing data (images, text information, etc. that are the source of printing on paper). Although not shown in FIG. 13, the PrintTicket is generated by the selected printer driver 206. The printer driver 206 also has a function of generating PrintCapabilities in which settable functions and selection items are described in an XML format based on a format defined by the OS. The WSDA 205 provides a user interface based on the information described in this PrintCapabilities.

続いて、プリントマネージャ204は、S1317で、更新した印刷設定を示す情報をUWPアプリケーション201に通知する。続いて、印刷設定を再取得したUWPアプリケーション201は、S1318~S1319で、S1307~S1308と同様にプレビューデータを生成し、MPD203に通知する。続いて、S1320で、MPD203は取得したプレビューデータに基づいて表示している画面を更新する。なお、印刷設定画面302において印刷設定が変更された場合も同様に、変更された設定がプリントマネージャ204に通知される。続いて、S1306~S1308と同様の処理によってUWPアプリケーション201はプレビューデータを生成し、S1309と同様の処理によって、MPD203に表示される画面を更新してもよい。 Next, in step S1317, the print manager 204 notifies the UWP application 201 of information indicating the updated print settings. Subsequently, in steps S1318 to S1319, the UWP application 201 that has reacquired the print settings generates preview data in the same manner as in steps S1307 to S1308, and notifies the MPD 203 of the generated preview data. Subsequently, in S1320, the MPD 203 updates the displayed screen based on the acquired preview data. Note that when the print settings are changed on the print settings screen 302, the print manager 204 is similarly notified of the changed settings. Subsequently, the UWP application 201 may generate preview data through processes similar to S1306 to S1308, and update the screen displayed on the MPD 203 through processes similar to S1309.

図3で示した印刷設定の後に、OS202のMPD203が提供する印刷設定画面302において、ユーザによって「印刷」ボタンが押下される(S1321)ものとする。続いて、MPD203は「印刷」ボタンの押下を印刷指示として受付け、MPD203は「印刷」ボタンが押下されたことをプリントマネージャ204に通知する(S1322)。通知を受けたプリントマネージャ204は、S1323において、UWPアプリケーション201に印刷用データ(文書データ)の生成を要求する。指示を受けたUWPアプリケーション201は、S1324で印刷用データを生成し、S1325でプリントマネージャ204に生成した印刷用データを送信する。プリントマネージャ204は、UWPアプリケーション201が生成した印刷用データと、前述のPrintTicketを元に、S1326で印刷データを生成する。この印刷コマンドは、XML Paper Specification(以後、XPS)という書式で記述されたXPS文書であってもよい。 It is assumed that after the print settings shown in FIG. 3, the user presses the "print" button on the print settings screen 302 provided by the MPD 203 of the OS 202 (S1321). Subsequently, the MPD 203 accepts the press of the "Print" button as a print instruction, and the MPD 203 notifies the print manager 204 that the "Print" button has been pressed (S1322). Upon receiving the notification, the print manager 204 requests the UWP application 201 to generate print data (document data) in S1323. Upon receiving the instruction, the UWP application 201 generates print data in S1324, and transmits the generated print data to the print manager 204 in S1325. The print manager 204 generates print data in S1326 based on the print data generated by the UWP application 201 and the aforementioned PrintTicket. This print command may be an XPS document written in a format called XML Paper Specification (hereinafter referred to as XPS).

OS202は、プリントマネージャ204が生成したXPS文書をスプールファイルとして格納する。プリンタドライバ206は、スプールファイルとして格納されたXPS文書をOS202から受け取り、XPS文書に含まれる印刷設定情報に従い、XPS文書を印刷装置102が解釈可能な印刷コマンドに変換し出力する。以上が、UWPアプリケーション201からの印刷の基本処理である。 The OS 202 stores the XPS document generated by the print manager 204 as a spool file. The printer driver 206 receives an XPS document stored as a spool file from the OS 202, converts the XPS document into a print command that can be interpreted by the printing apparatus 102, and outputs the converted command according to print setting information included in the XPS document. The above is the basic printing process from the UWP application 201.

(UWPアプリケーション201の画面構成の例)
図4は、画像を印刷する機能を有するUWPアプリケーション201の画面構成例を示す図である。UWPアプリケーション201の画面は、左側のメニュー画面401と、右側のメイン画面402により構成される。メニュー画面401には、選択ボタン403、編集ボタン404、印刷ボタン405が含まれる。ユーザにより選択ボタン403が押下されると、メイン画面402に、外部記憶装置114に保存されている画像の一覧が表示される。ユーザは、この画面上で、印刷したい任意数の画像を選択することができる。ここでは、2つの画像がユーザにより選択されたものとする。ユーザにより編集ボタン404が押下されると、メイン画面402に、選択した画像と、それを編集するための画面が表示される。ユーザは、この画面上で、選択した画像に対してトリミングや色味調整等の加工を施したり、任意のテキストを追加したりすることができる。ユーザにより、印刷ボタン405が押下されると、メイン画面402に、印刷を実行するための画面が表示される。図4のメイン画面402には、この印刷画面が表示されている。印刷画面には、印刷対象である、ユーザが選択し編集した画像406及び画像407が表示される。写真印刷ボタン408は、印刷対象を写真として印刷するためのボタンである。文書印刷ボタン409は、印刷対象を文書として印刷するためのボタンである。ディスクレーベル印刷ボタン410は、印刷対象を印刷可能なディスク上に印刷するためのボタンである。
(Example of screen configuration of UWP application 201)
FIG. 4 is a diagram showing an example of a screen configuration of a UWP application 201 having a function of printing images. The screen of the UWP application 201 is composed of a menu screen 401 on the left side and a main screen 402 on the right side. The menu screen 401 includes a selection button 403, an edit button 404, and a print button 405. When the user presses the selection button 403, a list of images stored in the external storage device 114 is displayed on the main screen 402. On this screen, the user can select any number of images that he or she wishes to print. Here, it is assumed that two images are selected by the user. When the user presses the edit button 404, the selected image and a screen for editing it are displayed on the main screen 402. On this screen, the user can perform processing such as trimming and color adjustment, and add arbitrary text to the selected image. When the user presses the print button 405, a screen for executing printing is displayed on the main screen 402. This print screen is displayed on the main screen 402 in FIG. The print screen displays an image 406 and an image 407 selected and edited by the user to be printed. The photo print button 408 is a button for printing the print target as a photo. A document print button 409 is a button for printing a print target as a document. The disc label print button 410 is a button for printing a print target on a printable disc.

(UWPアプリケーションの印刷初期化処理)
図5は、本印刷システムにおけるUWPアプリケーション201の印刷初期化処理のうち主要な処理フローを示した図である。以降、UWPアプリケーション201を、各処理の主体として説明することもあるが、実際には、対応するプログラムをCPU111が実行することで、対応する機能が実現されることになる。なお、全ての処理は必ずしも一つのプロセス上で逐次的に実行されるものではなく、一度OS側に処理が移り、再度OSから呼び出されるようなケースもあり得る。あくまでUWPアプリケーション201の主要な処理を、便宜的にわかりやすく示したフローである。
(UWP application print initialization process)
FIG. 5 is a diagram showing the main processing flow of the print initialization processing of the UWP application 201 in this printing system. Hereinafter, the UWP application 201 may be described as the main body of each process, but in reality, the corresponding functions are realized by the CPU 111 executing the corresponding programs. Note that all the processing is not necessarily executed sequentially in one process, and there may be cases where the processing is once transferred to the OS side and then called again from the OS. This is just a flow that shows the main processing of the UWP application 201 in an easy-to-understand manner for convenience.

図4の写真印刷ボタン408、文書印刷ボタン409、ディスクレーベル印刷ボタン410のいずれかがユーザにより押下されると、UWPアプリケーションは図5の印刷初期化処理を開始する。まず、UWPアプリケーション201は、印刷用イベントハンドラをプリントマネージャ204に登録する(S501)。これにより、プリントマネージャ204は、MPD203の画面表示や、プリンタドライバ206への印刷処理を実行するために必要な特定の事象(イベント)が発生した際に、UWPアプリケーション201の印刷用イベントハンドラの処理を呼び出す。印刷用イベントハンドラには、プレビューデータ生成処理、パジネート処理、印刷用データ生成処理の3つがある。UWPアプリケーション201のそれぞれのイベントハンドラ内の処理の詳細は後述する。次に、UWPアプリケーション201は、プリントマネージャ204に対し、印刷用UIの表示を指示する(S502)。次に、UWPアプリケーション201は、現在の印刷モードを判定する(S503)。 When the user presses any of the photo print button 408, document print button 409, and disc label print button 410 in FIG. 4, the UWP application starts the print initialization process in FIG. First, the UWP application 201 registers a printing event handler in the print manager 204 (S501). As a result, the print manager 204 performs processing in the print event handler of the UWP application 201 when a specific event necessary for displaying the screen of the MPD 203 or executing print processing for the printer driver 206 occurs. call. There are three types of print event handlers: preview data generation processing, paginate processing, and print data generation processing. Details of processing within each event handler of the UWP application 201 will be described later. Next, the UWP application 201 instructs the print manager 204 to display a printing UI (S502). Next, the UWP application 201 determines the current print mode (S503).

ユーザにより写真印刷ボタン408が押下された場合、UWPアプリケーション201は、印刷モードを写真印刷モードと判断し(S503で「写真撮影」)、S504に進む。本初期化処理において、UWPアプリケーション201は、MPD203に表示する印刷設定の種類を指定することができる。写真印刷モードでは、UWPアプリケーション201は、表示する印刷設定として、用紙サイズ、印刷の向き、用紙の種類、フチなし印刷、印刷部数、カラーモードを指定する(S504)。これにより、MPD203には、写真印刷に必要となる印刷設定のみが表示される事となり、ユーザが不適切な印刷設定を指定することを軽減でき、利便性が向上する。また、本初期化処理において、UWPアプリケーション201は、各印刷設定のデフォルトの選択値を指定することができる。写真印刷モードでは、UWPアプリケーション201は、用紙サイズのデフォルトの印刷設定値として、4x6を指定し(S505)、用紙の種類のデフォルトの印刷設定値として、写真用紙を指定する(S506)。このように、写真印刷で一般的に利用される設定値を予め指定しておくことで、ユーザが印刷設定を正しく指定しなかった場合の失敗印刷を軽減する事ができ、利便性が向上する。最後に、UWPアプリケーション201は、MPD上で印刷設定が変更された時に呼び出される設定変更イベントハンドラを登録する(S512)。UWPアプリケーション201の設定変更イベントハンドラの処理は後述する。以上が、写真印刷モードにおける、UWPアプリケーションの印刷初期化処理である。 When the user presses the photo print button 408, the UWP application 201 determines that the print mode is the photo print mode ("take photo" in S503), and proceeds to S504. In this initialization process, the UWP application 201 can specify the type of print settings to be displayed on the MPD 203. In the photo print mode, the UWP application 201 specifies paper size, print orientation, paper type, borderless printing, number of copies, and color mode as print settings to be displayed (S504). This allows the MPD 203 to display only the print settings necessary for photo printing, which reduces the user's need to specify inappropriate print settings and improves convenience. Further, in this initialization process, the UWP application 201 can specify default selection values for each print setting. In the photo print mode, the UWP application 201 specifies 4x6 as the default print setting value for the paper size (S505), and specifies photo paper as the default print setting value for the paper type (S506). In this way, by specifying settings commonly used for photo printing in advance, it is possible to reduce printing failures caused by users not specifying the print settings correctly, and improve convenience. . Finally, the UWP application 201 registers a settings change event handler that is called when print settings are changed on the MPD (S512). Processing of the setting change event handler of the UWP application 201 will be described later. The above is the print initialization process of the UWP application in the photo print mode.

図6は、写真印刷モードの場合に表示されるMPD203の印刷設定画面の一例を示す図である。印刷設定画面601には、印刷するプリンタを指定するプリンタ選択部602と、ユーザが印刷設定を指定可能な印刷設定部603とが表示される。印刷設定部603に表示される項目は、UWPアプリケーション201がS504で指定した印刷設定である。また、印刷設定画面601の起動時の印刷設定の初期値として、S505、S506で指定した選択値が選択されている。 FIG. 6 is a diagram showing an example of a print setting screen of the MPD 203 displayed in the photo print mode. A print setting screen 601 displays a printer selection section 602 for specifying a printer for printing, and a print setting section 603 for allowing the user to specify print settings. The items displayed in the print settings section 603 are the print settings specified by the UWP application 201 in S504. Furthermore, the selected values specified in S505 and S506 are selected as the initial values of the print settings when the print settings screen 601 is activated.

図5のフローの説明に戻る。ユーザにより文書印刷ボタン409が押下された場合(S503で「文書印刷」)、UWPアプリケーション201は、印刷モードを文書印刷モードと判断し、S507に進む。文書印刷モードでは、UWPアプリケーション201は、表示する印刷設定として、用紙サイズ、印刷の向き、両面印刷、シート毎のページ数、印刷部数、カラーモードを指定する(S507)。次に、UWPアプリケーション201は、用紙サイズのデフォルトの印刷設定値として、レターを指定し(S508)、用紙の種類のデフォルトの印刷設定値として、普通紙を指定する(S509)。このように、写真印刷同様、文書印刷で一般的に利用される印刷設定、及び初期値を指定しておくことで、ユーザの失敗印刷を軽減する事ができ、利便性が向上する。最後に、UWPアプリケーション201は、写真印刷モードの時と同様にS512の処理を実行する。以上が、文書印刷モードにおける、UWPアプリケーションの印刷初期化処理である。 Returning to the explanation of the flow in FIG. 5. When the user presses the document print button 409 (“document print” in S503), the UWP application 201 determines the print mode to be the document print mode, and proceeds to S507. In the document print mode, the UWP application 201 specifies paper size, print orientation, double-sided printing, number of pages per sheet, number of copies to be printed, and color mode as print settings to be displayed (S507). Next, the UWP application 201 specifies letter as the default print setting value for the paper size (S508), and specifies plain paper as the default print setting value for the paper type (S509). In this way, similarly to photo printing, by specifying print settings and initial values that are commonly used in document printing, it is possible to reduce user printing failures and improve convenience. Finally, the UWP application 201 executes the process of S512 in the same way as in the photo print mode. The above is the print initialization process of the UWP application in the document print mode.

ユーザによりディスクレーベル印刷ボタン410が押下された場合(S503で「ディスクレーベル印刷」)、UWPアプリケーション201は、印刷モードをディスクレーベル印刷モードと判断し、S510に進む。ディスクレーベル印刷モードでは、UWPアプリケーション201は、表示する印刷設定として、用紙サイズ、用紙の種類を指定する(S510)。ディスクレーベル印刷で指定すべき用紙サイズや用紙の種類は、プリンタベンダが独自に定義するものであり、UWPアプリケーション201は、このような印刷設定値を、本初期化処理内で指定することはできない。従って、ディスクレーベル印刷モードでは、UWPアプリケーション201は、用紙サイズや用紙の種類の初期値を指定する事無く、S512の処理を実行し、処理を終了する。 When the user presses the disc label print button 410 ("disc label print" in S503), the UWP application 201 determines the print mode to be the disc label print mode, and proceeds to S510. In the disc label print mode, the UWP application 201 specifies the paper size and paper type as print settings to be displayed (S510). The paper size and paper type that should be specified for disc label printing are uniquely defined by the printer vendor, and the UWP application 201 cannot specify such print setting values within this initialization process. . Therefore, in the disc label printing mode, the UWP application 201 executes the process of S512 without specifying the initial values of the paper size and paper type, and ends the process.

図7は、ディスクレーベル印刷モードの場合に表示されるMPD203の印刷設定画面の一例を示す図である。印刷設定画面701の印刷設定部703に表示される項目は、UWPアプリケーション201がS510で指定した印刷設定である。 FIG. 7 is a diagram showing an example of a print setting screen of the MPD 203 displayed in the disc label print mode. The items displayed in the print setting section 703 of the print setting screen 701 are the print settings specified by the UWP application 201 in S510.

上述の処理により、MPD203が表示する印刷設定画面には、ユーザがUWPアプリケーション201で指定した印刷目的に必要な印刷設定のみが表示されると共に、好適な印刷設定の初期値が設定される。これにより、ユーザが不適切な印刷設定を変更する事を軽減することができ、ユーザビリティが向上する。なお、図5で説明した3つの印刷モードや、それぞれの印刷モードが選択されたときに表示する印刷設定やその初期値は一例であって、これに限定されるものではない。 Through the above-described processing, only the print settings necessary for the print purpose specified by the user in the UWP application 201 are displayed on the print settings screen displayed by the MPD 203, and initial values of suitable print settings are set. This reduces the possibility of the user changing inappropriate print settings, and improves usability. Note that the three print modes explained in FIG. 5, the print settings displayed when each print mode is selected, and their initial values are examples, and the present invention is not limited thereto.

<UWPアプリケーションのパジネート処理>
図8は、UWPアプリケーション201がS501で登録したイベントハンドラのうちの、パジネート処理の内容を示すフローチャートである。以降、UWPアプリケーション201を、各処理の主体として説明することもあるが、実際には、対応するプログラムをCPU111が実行することで、対応する機能が実現されることになる。
<Paginate processing for UWP applications>
FIG. 8 is a flowchart showing the contents of the pagination process among the event handlers registered by the UWP application 201 in S501. Hereinafter, the UWP application 201 may be described as the main body of each process, but in reality, the corresponding functions are realized by the CPU 111 executing the corresponding programs.

このパジネート処理は、MPD203上でユーザが印刷設定を変更した場合等にプリントマネージャ204から呼び出される。MPD上で指定されている印刷設定は、プリントマネージャ204からUWPアプリケーション201に渡される。まず、UWPアプリケーション201は、プリントマネージャ204から渡される、用紙サイズ、及び印刷可能領域をRAM113に保存する(S801)。用紙サイズは、MPD203上でユーザにより選択されたもので、Letterや4x6等の設定値が存在する。印刷可能領域は、用紙サイズの中で、印刷装置102が印刷可能な領域の原点、及びそのサイズを示す情報である。この情報は、MPD203上でユーザにより選択された印刷設定情報を元に、プリントマネージャ204が、プリンタドライバ206に問い合わせることで返却されるPrintCapabilitiesに含まれる。アプリケーションは、このPrintCapabilitiesから得た印刷可能領域に収まるように描画データを形成することで、印刷装置が変更されても、それぞれの印刷装置の所望する印刷可能領域内に収まる最適な印刷を実現することができる。また、UWPアプリケーション201は、プリントマネージャ204から渡されたその他の印刷設定をRAM113に保存する(S802)。 This pagination process is called by the print manager 204 when the user changes the print settings on the MPD 203 . The print settings specified on the MPD are passed from the print manager 204 to the UWP application 201. First, the UWP application 201 stores the paper size and printable area passed from the print manager 204 in the RAM 113 (S801). The paper size is selected by the user on the MPD 203, and there are setting values such as Letter and 4x6. The printable area is information indicating the origin and size of an area that can be printed by the printing apparatus 102 within the paper size. This information is included in PrintCapabilities returned by the print manager 204 inquiring the printer driver 206 based on print setting information selected by the user on the MPD 203 . By forming the drawing data so that it fits within the printable area obtained from this PrintCapabilities, the application achieves optimal printing that fits within the desired printable area of each printing device even if the printing device is changed. be able to. Further, the UWP application 201 stores other print settings passed from the print manager 204 in the RAM 113 (S802).

次に、UWPアプリケーション201は、印刷可能領域が規定のサイズか否かを判断する(S803)。規定のサイズであった場合、UWPアプリケーション201は、現在、MPD203で選択されているドライバがサポートドライバである旨をRAM113に保存する(S804)。規定のサイズでは無かった場合、UWPアプリケーション201は、現在、MPD203で選択されているドライバがサポートドライバでない旨をRAM113に保存する(S805)。前述の通り、印刷可能領域は、印刷装置102の種類により異なるため、この値が特定の値か否かによって、印刷装置102が特定の印刷装置であるか否か、例えばUWPアプリケーション201がサポートする対象か否かを判断することできる。UWPアプリケーション201は、この情報を利用することによって、MPD203で選択されたプリンタドライバがサポート対象か否かに応じて、処理を変えることができる。この処理は後述する。なお、ここでは、印刷装置、及びプリンタドライバがサポート対象か否かを判断するために、印刷可能領域を利用したが、プリンタドライバを特定可能なその他の情報を元に判断してもよい。最後に、UWPアプリケーション201は、今回の印刷における合計のページ数を、プリントマネージャ204に指定する(S806)。例えば図4のように2枚の画像の印刷を行う場合は、合計のページ数は2となる。以上がUWPアプリケーション201のパジネート処理の内容である。 Next, the UWP application 201 determines whether the printable area is a specified size (S803). If the size is the specified size, the UWP application 201 stores information to the effect that the driver currently selected by the MPD 203 is a supported driver in the RAM 113 (S804). If the size is not the specified size, the UWP application 201 stores in the RAM 113 that the driver currently selected by the MPD 203 is not a supported driver (S805). As described above, the printable area differs depending on the type of printing device 102, so depending on whether this value is a specific value, it is possible to determine whether the printing device 102 is a specific printing device, for example, if the UWP application 201 supports it. It is possible to judge whether it is a target or not. By using this information, the UWP application 201 can change processing depending on whether the printer driver selected by the MPD 203 is supported. This process will be described later. Although the printable area is used here to determine whether the printing device and printer driver are supported, the determination may be made based on other information that can identify the printer driver. Finally, the UWP application 201 specifies the total number of pages for the current printing to the print manager 204 (S806). For example, when printing two images as shown in FIG. 4, the total number of pages is two. The above is the content of the pagination process of the UWP application 201.

(UWPアプリケーションのプレビュー生成処理)
図9は、UWPアプリケーション201がS501で登録したイベントハンドラのうちの、プレビュー生成処理の内容を示すフローチャートである。以降、UWPアプリケーション201を、各処理の主体として説明することもあるが、実際には、対応するプログラムをCPU111が実行することで、対応する機能が実現されることになる。
(UWP application preview generation process)
FIG. 9 is a flowchart showing the details of preview generation processing of the event handlers registered by the UWP application 201 in S501. Hereinafter, the UWP application 201 may be described as the main body of each process, but in reality, the corresponding functions are realized by the CPU 111 executing the corresponding programs.

このプレビュー生成処理は、MPD203上に印刷結果の概要を示す印刷プレビューを表示するために、プリントマネージャ204から呼び出される。まず、UWPアプリケーション201は、プリントマネージャから要求ページ番号を取得する(S901)。UWPアプリケーション201は、このページ番号の印刷プレビューをプリントマネージャ204に返却する必要がある。そうすることで、MPD203上に、ユーザが指定したページの印刷プレビューが正しく表示される。次に、UWPアプリケーション201は、プリントマネージャ204から渡される印刷設定中のカラーモードがモノクロであるかを判断する(S902)。カラーモードがカラーであるとUWPアプリケーション201が判定した場合(S902でNo)、S901で取得した要求ページ番号に対応する印刷コンテンツをCanvasオブジェクト上に描画する(S903)。例えば、図4のような2つの画像を印刷するケースにおいて、S901で取得する要求ページ番号が2であった場合、2枚目の画像407をCanvasオブジェクト上に描画する。UWPアプリケーション201が実現したい印刷によって、例えばS801で取得した印刷可能領域に、画像407をフィットさせる形で描画する等しても良い。S902の判定がYes、すなわちカラーモードがモノクロであった場合は、S901で取得した要求ページ番号に対応する印刷コンテンツをモノクロ化してCanvasオブジェクト上に描画する(S903)。このように構成することで、MPD203上の印刷プレビューは、カラーモードがカラーとなっている場合はカラーで、カラーモードがモノクロとなっている場合はモノクロで表示される。これにより、ユーザはMPD203上で、より実際の印刷結果に近い印刷プレビューを確認することができる。 This preview generation process is called by the print manager 204 in order to display a print preview showing an overview of the print result on the MPD 203. First, the UWP application 201 obtains a requested page number from the print manager (S901). The UWP application 201 needs to return the print preview of this page number to the print manager 204. By doing so, the print preview of the page specified by the user is correctly displayed on the MPD 203. Next, the UWP application 201 determines whether the color mode in the print settings passed from the print manager 204 is monochrome (S902). If the UWP application 201 determines that the color mode is color (No in S902), print content corresponding to the requested page number acquired in S901 is drawn on the Canvas object (S903). For example, in the case of printing two images as shown in FIG. 4, if the requested page number acquired in S901 is 2, the second image 407 is drawn on the Canvas object. Depending on the printing that the UWP application 201 wants to achieve, for example, the image 407 may be drawn in a form that fits into the printable area acquired in S801. If the determination in S902 is Yes, that is, the color mode is monochrome, the print content corresponding to the requested page number obtained in S901 is converted to monochrome and drawn on the Canvas object (S903). With this configuration, the print preview on the MPD 203 is displayed in color when the color mode is set to color, and in monochrome when the color mode is set to monochrome. This allows the user to check a print preview that is closer to the actual print result on the MPD 203.

次に、UWPアプリケーション201は、MPD203で選択されているプリンタドライバがサポートされているドライバか否かを判断する(S905)。この判断は、S804、及びS805でRAM上に保存された情報を元になされる。非サポートドライバであると判断した場合、UWPアプリケーション201は、サポートドライバが選択されていないため、印刷が続行可能ではない旨を示すエラーメッセージをCanvasオブジェクト上に描画する(S906)。続いて、UWPアプリケーション201は、プリントマネージャ204に、要求ページのページデータとして生成したCanvasを渡す(S915)。 Next, the UWP application 201 determines whether the printer driver selected by the MPD 203 is a supported driver (S905). This determination is made based on the information stored on the RAM in S804 and S805. If it is determined that the driver is an unsupported driver, the UWP application 201 draws an error message on the Canvas object indicating that printing cannot be continued because no supported driver has been selected (S906). Subsequently, the UWP application 201 passes the Canvas generated as page data of the requested page to the print manager 204 (S915).

このようなプレビュー生成処理によりMPD203が生成する印刷設定画面を図10に示す。印刷設定画面1001上では、プリンタ選択部1002にPrinter Bが選択されている。ここでは、Printer Bは、UWPアプリケーション201にサポートされていないドライバ(非サポートドライバ)であるとする。印刷設定画面1001上の印刷プレビュー領域1003には、UWPアプリケーション201がS906で描画した、サポートドライバが選択されておらず、印刷が続行不可能である旨を示すエラーメッセージが描画された印刷プレビューが表示される。印刷設定画面上のプリンタ選択部は、MPD203により自動的に表示されるものであり、OS202にインストールされている全てのプリンタドライバが列挙される。従って、UWPアプリケーション201は、通常、特定のプリンタドライバに対してのみ印刷を許可するように構成することができない。しかしながら、本実施形態においては、UWPアプリケーション201の処理によって、非サポートドライバが選択された場合に、そのプリンタが非サポートである旨をMPD203上の印刷プレビューに表示することでユーザに報知することができる。また、後述する処理により、UWPアプリケーション201は、非サポートドライバが選択された状態でユーザが印刷を指示しても、印刷に失敗するよう制御する。これらの処理によって、UWPアプリケーション201は、MPD203で全てのプリンタドライバが選択可能に構成される場合であっても、特定のプリンタドライバに対してのみ印刷可能に構成すると共に、そのことを正しくユーザに伝えることができる。UWPアプリケーション201は、前述の処理により、MPD203が生成する印刷設定画面の表示内容をある程度コントロールすることができるが、MPD203が処理をしている最中に、独自のポップアップウィンドウを表示することはできない。そのような条件下であっても、本実施形態のUWPアプリケーション201は、印刷プレビュー領域1003に表示するためのCanvasオブジェクトにメッセージを描画する事で、ユーザにエラー等の情報を伝える事ができる。なお、MPD203の処理中にUWPアプリケーション203が独自のポップアップウィンドウを表示できる場合、印刷が続行不可能である旨を示すエラーメッセージは、印刷プレビューとは異なる形態、例えばポップアップウィンドウで通知されてもよい。 FIG. 10 shows a print setting screen generated by the MPD 203 through such preview generation processing. On the print setting screen 1001, Printer B is selected in the printer selection field 1002. Here, it is assumed that Printer B is a driver that is not supported by the UWP application 201 (unsupported driver). In the print preview area 1003 on the print settings screen 1001, there is a print preview drawn by the UWP application 201 in S906 with an error message indicating that no support driver has been selected and printing cannot be continued. Is displayed. The printer selection section on the print setting screen is automatically displayed by the MPD 203, and all printer drivers installed in the OS 202 are listed. Therefore, the UWP application 201 cannot normally be configured to permit printing only to a specific printer driver. However, in this embodiment, when an unsupported driver is selected through the processing of the UWP application 201, the user is notified that the printer is unsupported by displaying it on the print preview on the MPD 203. can. Furthermore, through the process described below, the UWP application 201 controls so that even if the user instructs printing with an unsupported driver selected, printing will fail. Through these processes, even if the MPD 203 is configured to allow selection of all printer drivers, the UWP application 201 configures the MPD 203 to allow printing only to a specific printer driver, and correctly informs the user of this fact. I can tell you. The UWP application 201 can control the display contents of the print setting screen generated by the MPD 203 to some extent through the processing described above, but it cannot display its own pop-up window while the MPD 203 is processing. . Even under such conditions, the UWP application 201 of this embodiment can convey information such as errors to the user by drawing a message on a canvas object to be displayed in the print preview area 1003. Note that if the UWP application 203 can display its own pop-up window during processing of the MPD 203, the error message indicating that printing cannot be continued may be notified in a form different from the print preview, for example, in a pop-up window. .

図9のフローチャートの説明に戻る。S905で、MPD203で選択されているドライバがサポートドライバであると判断した場合、UWPアプリケーション201は、印刷モードがディスク印刷モードであるか否かを判定する(S907)。S907の判定は、S503と同じ方法で判定される。ディスク印刷モードであると判断した場合、UWPアプリケーション201は、S908からS910までのディスク印刷用の処理を実行する。まず、UWPアプリケーション201は、Canvas上でディスクの印刷可能領域以外の領域を、半透明の白で塗りつぶす(S908)。このような加工によって、プレビュー領域からユーザが印刷可能領域とそれ以外の領域とを識別することができる。次に、UWPアプリケーション201は、印刷設定がディスク印刷用の設定になっているかを判断する(S909)。具体的には、S801やS802でRAM上に保存した印刷設定において、用紙サイズがディスクレーベルを示すものになっているか等を確認する。S908で印刷設定がディスク印刷用になっていないと判断した場合、UWPアプリケーション201は、印刷要求で指定された印刷モードと、印刷設定との間に禁則関係が生じているため、印刷の続行が不可能であると判定する。そのため、印刷が続行不可能であることを示すエラーメッセージをCanvasに描画する(S910)。 Returning to the explanation of the flowchart in FIG. 9. If it is determined in S905 that the driver selected by the MPD 203 is a supported driver, the UWP application 201 determines whether the print mode is the disc print mode (S907). The determination in S907 is made in the same manner as in S503. If it is determined that the disc printing mode is selected, the UWP application 201 executes disc printing processing from S908 to S910. First, the UWP application 201 fills the area other than the printable area of the disc with semi-transparent white on the canvas (S908). Such processing allows the user to distinguish between printable areas and other areas from the preview area. Next, the UWP application 201 determines whether the print settings are for disc printing (S909). Specifically, in the print settings saved on the RAM in S801 and S802, it is checked whether the paper size indicates the disc label. If it is determined in step S908 that the print settings are not set for disc printing, the UWP application 201 is unable to continue printing because there is a prohibited relationship between the print mode specified in the print request and the print settings. It is determined that it is impossible. Therefore, an error message indicating that printing cannot be continued is drawn on the canvas (S910).

S908からS910の処理を実施したCanvasを、S907でプリントマネージャ204に渡したときに、MPD203が生成する印刷設定画面について図7を用いて説明する。MPD203が生成する印刷設定画面701上の印刷プレビュー704では、ディスクレーベルの印刷可能領域以外の領域、すなわち中心部分とディスクレーベルの外形より外側の領域が半透明の白で塗りつぶされた状態になる。これにより、ユーザは、印刷対象がディスクレーベル上で所望する位置やサイズで印刷されるか、欠けることが無いか、を確認することができる。また、703で示されるように、用紙サイズ及び用紙の種類に正しくディスクレーベル用の設定が為されていない場合、印刷プレビュー704上に、印刷モードと印刷設定とに禁則関係が生じ、印刷が続行不可能であることを示すエラーメッセージが表示される。また、後述する処理により、UWPアプリケーション201は、このエラーメッセージが表示される条件下でユーザが印刷を指示しても、描画データを返さず、エラーメッセージを返す。既に述べたように、ディスクレーベル印刷で指定すべき用紙サイズや用紙の種類は、プリンタベンダが独自に定義するものであり、UWPアプリケーション201は、このような選択値を、図5で示す初期化処理内で指定することはできない。つまり、UWPアプリケーション201は、MPD203が生成する印刷設定画面において、あらかじめディスクレーベル印刷に適した用紙サイズ、用紙の種類を選択するように制御することはできない。本実施形態では、前述のような処理によって、ユーザはディスクレーベル印刷に適した印刷設定が指定されていないことを知ることができ、また不適切な印刷設定の状態では印刷を続行することができない。これにより、ディスクレーベル印刷時のユーザビリティを向上すると共に、印刷設定ミスによる失敗印刷を防ぐことができる。なお、MPD203が処理をしている最中にUWPアプリケーション203が独自のポップアップウィンドウを表示でき、印刷モードと印刷設定とに禁則関係が生じている場合、印刷を続行するか否かを問い合わせるポップアップメッセージを表示してもよい。この場合、ユーザが印刷を続行するよう指示した場合には印刷用データをプリントマネージャ204に渡し、印刷をキャンセルするよう指示した場合にはエラーメッセージを返してもよい。 The print setting screen generated by the MPD 203 when the Canvas subjected to the processes from S908 to S910 is passed to the print manager 204 in S907 will be described with reference to FIG. In the print preview 704 on the print setting screen 701 generated by the MPD 203, the area other than the printable area of the disc label, that is, the center part and the area outside the outer shape of the disc label, is filled with translucent white. This allows the user to check whether the print target will be printed at the desired position and size on the disc label, and whether there will be any defects. Furthermore, as shown in 703, if the paper size and paper type are not correctly set for disc labels, a prohibited relationship will appear between the print mode and print settings on the print preview 704, and printing will continue. An error message is displayed indicating that this is not possible. Furthermore, through the process described below, the UWP application 201 does not return drawing data but returns an error message even if the user instructs printing under conditions where this error message is displayed. As already mentioned, the paper size and paper type that should be specified for disc label printing are defined independently by the printer vendor, and the UWP application 201 uses these selection values in the initialization process shown in FIG. It cannot be specified within the process. In other words, the UWP application 201 cannot control the print setting screen generated by the MPD 203 to select in advance a paper size and paper type suitable for disc label printing. In this embodiment, the process described above allows the user to know that print settings suitable for disc label printing are not specified, and printing cannot be continued with inappropriate print settings. . This improves usability when printing disc labels, and prevents printing failures due to print setting errors. Note that the UWP application 203 can display its own pop-up window while the MPD 203 is processing, and if there is a prohibited relationship between the print mode and print settings, a pop-up message asking whether to continue printing will be displayed. may be displayed. In this case, if the user instructs to continue printing, print data may be passed to the print manager 204, and if the user instructs to cancel printing, an error message may be returned.

図9の説明に戻る。S907で印刷モードがディスク印刷ではない場合、またはS910の処理の後、UWPアプリケーション201は、S805でRAM上に保存した印刷設定において両面印刷がONになっているかを確認する(S911)。両面印刷がONの場合(S911でYes)、UWPアプリケーション201は、Canvas上に両面印刷であることを示すオブジェクトを描画する(S912)。例えば、UWPアプリケーション201は、Canvasの右下に、ページの端がめくれているように見える画像を挿入する。このようなCanvasをプリントマネージャ204に渡すことで、MPD203が生成する印刷設定画面において、両面印刷がONになっている場合にのみ、ページの端がめくれるような印刷プレビューが表示される。これにより、ユーザは、裏面にも印刷する両面印刷がONかOFFかを、印刷プレビュー上で直観的に認識することができる。 Returning to the explanation of FIG. 9. If the print mode is not disk printing in S907, or after the process in S910, the UWP application 201 checks whether double-sided printing is turned on in the print settings saved in the RAM in S805 (S911). When double-sided printing is ON (Yes in S911), the UWP application 201 draws an object indicating double-sided printing on the canvas (S912). For example, the UWP application 201 inserts an image that looks like the edge of the page is turned over at the bottom right of the Canvas. By passing such a Canvas to the print manager 204, a print preview in which the edges of the page are turned over is displayed on the print setting screen generated by the MPD 203 only when double-sided printing is turned on. Thereby, the user can intuitively recognize on the print preview whether double-sided printing, which also prints on the back side, is ON or OFF.

両面印刷がOFFの場合(S911でNo)またはS912の処理の後、UWPアプリケーション201は、S805でRAM上に保存した印刷設定においてフチなし印刷がONになっているかを確認する(S913)。フチなし印刷がONであるとUWPアプリケーション201が判定した場合(S913でYes)、UWPアプリケーション201は、Canvas上でフチなしはみ出し領域を半透明の白で塗りつぶす(S914)。通常、プリンタドライバ206は、フチなし印刷を実現する場合、プリンタドライバ206の能力情報を示すPrintCapabilities上において、用紙サイズ全体を印刷可能領域とする。このようなPrintCapabilitiesを元に、アプリケーションは用紙サイズ全体に印刷コンテンツを配置する。プリンタドライバ206、及び印刷装置102は、用紙サイズ全体に配置されたコンテンツをわずかに拡大し、実際の用紙サイズに対してはみ出して印刷することにより、フチなし印刷を実現する。従って、印刷装置102が生成する印刷物において、アプリケーションが生成した印刷コンテンツは、全ての辺がわずかに欠けて印刷される。UWPアプリケーション201は、S914において、この欠ける領域(フチなしはみ出し領域)を半透明の白で塗りつぶす。なお、このフチなしはみ出し領域のサイズは、プリンタドライバ206及び印刷装置102により異なる。UWPアプリケーションは、サポートドライバのフチなしはみ出し領域のサイズを予め保持しておくか、或いはS801で保存する印刷可能領域情報等から決定する。 If double-sided printing is OFF (No in S911) or after the process in S912, the UWP application 201 checks whether borderless printing is ON in the print settings saved in the RAM in S805 (S913). If the UWP application 201 determines that borderless printing is ON (Yes in S913), the UWP application 201 fills the borderless protruding area on the Canvas with translucent white (S914). Normally, when realizing borderless printing, the printer driver 206 sets the entire paper size as a printable area on PrintCapabilities indicating capability information of the printer driver 206. Based on such PrintCapabilities, the application arranges print content over the entire paper size. The printer driver 206 and the printing device 102 realize borderless printing by slightly enlarging the content placed on the entire paper size and printing it beyond the actual paper size. Therefore, in the printed matter generated by the printing apparatus 102, the print content generated by the application is printed with slight defects on all sides. In S914, the UWP application 201 fills in this missing area (borderless protruding area) with translucent white. Note that the size of this borderless protruding area differs depending on the printer driver 206 and printing device 102. The UWP application holds the size of the borderless protruding area of the support driver in advance, or determines it from the printable area information saved in S801.

UWPアプリケーション201は、フチなし印刷がOFFであると判定した場合(S913でNo)またはS914の処理の後、プリントマネージャ204に要求ページのページデータとして生成したCanvasを渡し(S915)、処理を終了する。S914の処理によりMPD203が生成する印刷設定画面について図6を用いて説明する。MPD203が生成する印刷設定画面601上では、フチなし印刷としてオンが選択されている。印刷プレビュー603には、S914の処理により、印刷コンテンツのうち、フチなしはみ出し領域が、薄く表示される。これにより、ユーザは、フチなし印刷時に欠ける領域を印刷前に確認することができるため、失敗印刷を軽減することができる。 If the UWP application 201 determines that borderless printing is OFF (No in S913) or after the process in S914, the UWP application 201 passes the Canvas generated as the page data of the requested page to the print manager 204 (S915), and ends the process. do. The print setting screen generated by the MPD 203 through the process of S914 will be described using FIG. 6. On the print setting screen 601 generated by the MPD 203, on is selected as borderless printing. In the print preview 603, the borderless protruding area of the print content is displayed in a lighter color due to the process of S914. This allows the user to check the area that will be missing during borderless printing before printing, thereby reducing the number of printing failures.

以上がUWPアプリケーション201のプレビュー生成処理である。通常、UWPアプリケーションのプレビュー生成処理は、印刷するコンテンツをそのままの形でプリントマネージャ204に返却するが、本実施形態では、指定されている印刷設定に応じたプレビュー用の加工を施した上で返却する。それにより、MPD203が生成する印刷設定画面上において、指定された印刷設定がより視覚的に反映された印刷プレビューを提供することができる。また、本実施形態におけるUWPアプリケーションは、印刷プレビュー用の加工を利用して、適切な印刷設定が指定されていないことをユーザに報知し、失敗印刷を軽減することができる。さらに、本実施形態におけるUWPアプリケーションは、印刷プレビュー用の加工を利用して、非サポートドライバが選択された時に、印刷できないことをユーザに報知することができる。これにより、UWPアプリケーションを、特定のプリンタドライバ専用の印刷アプリケーションとして構成することができる。 The above is the preview generation process of the UWP application 201. Normally, the preview generation process of a UWP application returns the content to be printed to the print manager 204 as is, but in this embodiment, the content is processed for preview according to the specified print settings and then returned. do. Thereby, it is possible to provide a print preview that more visually reflects the specified print settings on the print settings screen generated by the MPD 203. Further, the UWP application in this embodiment can use print preview processing to notify the user that appropriate print settings have not been specified, thereby reducing failed printing. Further, the UWP application in this embodiment can notify the user that printing is not possible when an unsupported driver is selected by using print preview processing. Thereby, the UWP application can be configured as a print application dedicated to a specific printer driver.

<UWPアプリケーションの印刷データ生成処理>
図11は、UWPアプリケーション201がS501で登録したイベントハンドラのうちの、印刷データ生成処理の内容を示すフローチャートである。以降、UWPアプリケーション201を、各処理の主体として説明することもあるが、実際には、対応するプログラムをCPU111が実行することで、対応する機能が実現されることになる。
<Print data generation process of UWP application>
FIG. 11 is a flowchart showing the contents of print data generation processing among the event handlers registered by the UWP application 201 in S501. Hereinafter, the UWP application 201 may be described as the main body of each process, but in reality, the corresponding functions are realized by the CPU 111 executing the corresponding programs.

この印刷データ生成処理は、MPD203上でユーザが印刷を指示した場合に、プリントマネージャ204から呼び出される。まず、UWPアプリケーション201は、S804及びS805でRAM113上に保存した情報を元に、これから印刷を行うプリンタドライバがサポートドライバであるか否かを判断する(S1101)。サポートドライバでなかった場合、UWPアプリケーション201は、プリントマネージャ204に対し、エラーを返却する(S1102)。この処理により、UWPアプリケーション201は、サポートされていないドライバが選択された状態でユーザが印刷を指示した場合であっても、印刷しないように構成する事ができる。 This print data generation process is called by the print manager 204 when a user instructs printing on the MPD 203 . First, the UWP application 201 determines whether the printer driver that will perform printing from now on is a support driver based on the information stored in the RAM 113 in S804 and S805 (S1101). If the driver is not a supported driver, the UWP application 201 returns an error to the print manager 204 (S1102). Through this processing, the UWP application 201 can be configured not to print even if the user instructs printing with an unsupported driver selected.

次に、UWPアプリケーション201は、印刷モードがディスク印刷モードであるか否かを判定する(S1103)。S1103の判定は、S503と同じ方法で判定される。ディスク印刷モードであると判断した場合、UWPアプリケーション201は、S801やS802でRAM上に保存した印刷設定において、用紙サイズや用紙種類がディスクレーベル印刷を示すものになっているかを確認する(S1104)。印刷モードがディスク印刷であって、印刷設定がディスク印刷ではない場合(S1103がYesかつS1104がNo)の場合、UWPアプリケーション201は、プリントマネージャ204に対しエラーを返却し(S1102)、処理を終了する。この処理により、UWPアプリケーション201は、ディスクレーベル印刷が正しく実行されないと判断した場合に、印刷を中止するよう構成することができる。 Next, the UWP application 201 determines whether the print mode is the disc print mode (S1103). The determination in S1103 is made in the same manner as in S503. If it is determined that the disc printing mode is selected, the UWP application 201 checks whether the paper size and paper type indicate disc label printing in the print settings saved in the RAM in S801 and S802 (S1104). . If the print mode is disc printing and the print setting is not disc printing (S1103 is Yes and S1104 is No), the UWP application 201 returns an error to the print manager 204 (S1102) and ends the process. do. Through this process, the UWP application 201 can be configured to stop printing if it is determined that disc label printing cannot be executed correctly.

UWPアプリケーション201が、印刷モードはディスク印刷ではないと判定した場合(S1103がNo)または印刷設定はディスク印刷であると判定した場合(S1104がYes)、UWPアプリケーション201は処理をS1105に進める。UWPアプリケーション201は、S1105からS1110までの処理を、印刷の合計ページ数分繰り返す。S1106で、UWPアプリケーション201は、現在のページ番号に対応する印刷コンテンツをCanvasに描画する。次に、UWPアプリケーション201は、印刷モードがディスク印刷モードであるか否かを判定する(S1107)。ディスク印刷モードである場合(S1107でYes)、UWPアプリケーション201は、Canvas上でディスクの印刷可能領域以外を白で塗りつぶす(S1108)。ディスク印刷モードではない場合(S1107でNo)は、UWPアプリケーション201は、処理をS1109に進める。このように構成することで、印刷装置102が、ディスクレーベルの外側の領域に不正な印刷を行う事を防ぐことができる。次に、UWPアプリケーション201は、作成したCanvasをPrintDocumentに追加する(S1109)。PrintDocumentは、印刷文書全体を示すオブジェクトである。以上のような、S1106からS1109までの処理を、印刷の合計ページ数分繰り返す。UWPアプリケーション201は、プレビュー生成処理のS907で生成したCanvasをキャッシュとしてRAM113上に保存しておき、S1106からS1108までの処理をスキップし、生成済みのCanvasを利用するよう構成しても良い。これにより、無駄な処理をスキップし、高速に印刷処理を実行することができる。但し、プレビュー用の特殊加工であるS908やS910等の処理を施している場合は、UWPアプリケーション201は、生成済みのCanvasは利用せず、S1106からS1108までの処理で印刷用に再生成する。 If the UWP application 201 determines that the print mode is not disc printing (No in S1103) or if the print setting is determined to be disc printing (Yes in S1104), the UWP application 201 advances the process to S1105. The UWP application 201 repeats the processes from S1105 to S1110 for the total number of pages to be printed. In S1106, the UWP application 201 draws the print content corresponding to the current page number on the canvas. Next, the UWP application 201 determines whether the print mode is the disc print mode (S1107). If the disc print mode is selected (Yes in S1107), the UWP application 201 fills in white on the canvas other than the printable area of the disc (S1108). If it is not the disc print mode (No in S1107), the UWP application 201 advances the process to S1109. With this configuration, it is possible to prevent the printing device 102 from performing unauthorized printing on the outside area of the disc label. Next, the UWP application 201 adds the created Canvas to PrintDocument (S1109). PrintDocument is an object that represents the entire print document. The above-described processes from S1106 to S1109 are repeated for the total number of pages to be printed. The UWP application 201 may be configured to store the Canvas generated in S907 of the preview generation process as a cache on the RAM 113, skip the processes from S1106 to S1108, and use the generated Canvas. Thereby, unnecessary processing can be skipped and printing processing can be executed at high speed. However, if special processing for previewing, such as S908 or S910, is performed, the UWP application 201 does not use the generated Canvas, but regenerates it for printing in the processes from S1106 to S1108.

最後に、UWPアプリケーション201は、PrintDocumentの作成完了を指示し、作成したPrintDocumentをプリントマネージャ204に返却し(S1111)、図11の処理を終了する。以上が、UWPアプリケーション201の印刷データ生成処理である。 Finally, the UWP application 201 instructs to complete the creation of the PrintDocument, returns the created PrintDocument to the print manager 204 (S1111), and ends the process in FIG. 11. The above is the print data generation process of the UWP application 201.

このように、本実施形態におけるUWPアプリケーション201は、特定の条件下でプリントマネージャ204にエラーを返却することで印刷処理を中断するよう構成する。これにより、不適切な印刷設定による印刷ミスを軽減すると共に、特定のプリンタドライバ専用の印刷アプリケーションとして構成することができる。また、UWPアプリケーション201は、印刷データ生成処理において、プレビュー生成処理で生成するプレビュー用のCanvasとは異なる印刷用のCanvasを生成する。これにより、UWPアプリケーション201は、S908やS910のようなプレビュー専用の描画が含まれない、正しい印刷要求をプリンタドライバ206に対して発行することができる。 In this way, the UWP application 201 in this embodiment is configured to interrupt print processing by returning an error to the print manager 204 under specific conditions. As a result, printing errors due to inappropriate print settings can be reduced, and the printing application can be configured exclusively for a specific printer driver. Furthermore, in the print data generation process, the UWP application 201 generates a print canvas different from the preview canvas generated in the preview generation process. As a result, the UWP application 201 can issue a correct print request to the printer driver 206 that does not include preview-only drawings such as those in S908 and S910.

<UWPアプリケーションの設定変更処理>
図12は、本印刷システムにおけるUWPアプリケーション201の設定変更処理のうち主要な処理フローを示した図である。以降、UWPアプリケーション201を、各処理の主体として説明することもあるが、実際には、対応するプログラムをCPU111が実行することで、対応する機能が実現されることになる。この設定変更処理は、UWPアプリケーション201がS512で登録した設定変更イベントハンドラの処理である。
<UWP application settings change process>
FIG. 12 is a diagram showing the main processing flow of the setting change processing of the UWP application 201 in this printing system. Hereinafter, the UWP application 201 may be described as the main body of each process, but in reality, the corresponding functions are realized by the CPU 111 executing the corresponding programs. This setting change process is the process of the setting change event handler registered by the UWP application 201 in S512.

この設定変更処理は、MPD203上でユーザが印刷設定を変更した場合に、プリントマネージャ204から呼び出される。UWPアプリケーション201は、MPD203上で変更された設定が用紙種類であるかを確認する(S1201)。変更された設定情報は、プリントマネージャ204から渡される。変更された設定がメディアタイプではない場合(S1201でNo)、UWPアプリケーション201は、MPD203上で変更された設定が両面印刷であるかを確認する(S1202)。同様に、変更された設定が両面印刷設定ではない場合(S1202でNo)、UWPアプリケーション201は、MPD203上で変更された設定がカラーモードであるかを確認する(S1203)。S1201、S1202、S1203の何れかがYesの場合、UWPアプリケーション201は、プリントマネージャ204に対し、印刷プレビューの再描画を指示する(S1204)。こうすることで、プリントマネージャは、UWPアプリケーションのパジネート処理(図8)及びプレビュー生成処理(図9)を呼び出すため、結果としてMPD203上の印刷プレビューが再描画される。以上が、UWPアプリケーション201の、設定変更処理である。 This setting change process is called by the print manager 204 when the user changes the print settings on the MPD 203. The UWP application 201 checks whether the changed setting on the MPD 203 is the paper type (S1201). The changed setting information is passed from the print manager 204. If the changed setting is not the media type (No in S1201), the UWP application 201 checks whether the changed setting on the MPD 203 is double-sided printing (S1202). Similarly, if the changed settings are not double-sided printing settings (No in S1202), the UWP application 201 checks whether the changed settings on the MPD 203 are color mode (S1203). If any of S1201, S1202, and S1203 is Yes, the UWP application 201 instructs the print manager 204 to redraw the print preview (S1204). In this way, the print manager calls the pagination process (FIG. 8) and preview generation process (FIG. 9) of the UWP application, and as a result, the print preview on the MPD 203 is redrawn. The above is the setting change process of the UWP application 201.

例えば、通常、用紙種類が変更されても、MPD203上に表示される印刷プレビューは変化しないため、印刷プレビューの再描画は必要ない。しかし、本実施形態において、UWPアプリケーション201は、MPD203上に表示される印刷プレビューの利便性を向上させるため、プレビュー用の特殊な描画を施してもよい。図12に示す設定変更処理を実行することで、用紙種類が変更された場合等について、プレビューの再描画処理を確実に実行することができる。 For example, normally, even if the paper type is changed, the print preview displayed on the MPD 203 does not change, so there is no need to redraw the print preview. However, in this embodiment, the UWP application 201 may perform special drawing for preview in order to improve the convenience of the print preview displayed on the MPD 203. By executing the setting change process shown in FIG. 12, it is possible to reliably execute the preview redraw process when the paper type is changed.

以上のように、本実施形態において、UWPアプリケーション201は、プレビュー生成処理と印刷データ生成処理で異なるデータを生成する。これにより、正しい印刷結果を担保しながら、印刷結果を直観的に理解しやすい印刷プレビューをMPD203上に表示することができる。さらに、UWPアプリケーション201は、印刷設定やプリンタドライバの種類を判定し、印刷が続行できないことをユーザに報知すると共に、印刷が指示されたとしても印刷が実行されないよう制御する。以上のような処理により、MPD203を経由して印刷されるUWPアプリケーションのアーキテクチャにおいて、MPD203上での印刷設定の利便性を向上することができる。また、UWPアプリケーションを特定のプリンタドライバ専用のアプリケーションとして構成することができる。 As described above, in this embodiment, the UWP application 201 generates different data in preview generation processing and print data generation processing. Thereby, a print preview that is easy to intuitively understand the print result can be displayed on the MPD 203 while ensuring a correct print result. Further, the UWP application 201 determines the print settings and the type of printer driver, notifies the user that printing cannot be continued, and controls the user so that printing is not executed even if printing is instructed. Through the above-described processing, it is possible to improve the convenience of print settings on the MPD 203 in the architecture of a UWP application that prints via the MPD 203. Further, the UWP application can be configured as an application dedicated to a specific printer driver.

なお、本実施形態におけるUWPアプリケーション201は、写真印刷、文書印刷、ディスクレーベル印刷の3つの印刷モードを持つが、これ以外のモードを持つよう構成可能なことは言うまでもない。さらに、UWPアプリケーション201は、カラーモード、両面印刷、用紙サイズ、用紙種類等の印刷設定を判定して、プレビュー生成処理を行うが、それ以外の印刷設定にも応用可能であることは言うまでもない。例えば、UWPアプリケーション201は、割り付け印刷が指定されていることを検知した場合に、割り付け処理を施したプレビューを生成する等しても良い。 Note that the UWP application 201 in this embodiment has three print modes: photo printing, document printing, and disc label printing, but it goes without saying that it can be configured to have other modes. Further, the UWP application 201 determines print settings such as color mode, double-sided printing, paper size, paper type, etc. and performs preview generation processing, but it goes without saying that it can be applied to other print settings as well. For example, when the UWP application 201 detects that layout printing is specified, it may generate a preview that has been subjected to layout processing.

<その他の実施形態>
上述した実施形態は、以下の処理を実行することによっても実行される。すなわち、前述した実施形態の機能を実現するソフトウェアのプログラムコードを記録した記録媒体を、システムあるいは装置に供給する。そして、そのシステムあるいは装置のコンピュータ(またはCPUまたはMPU)が記録媒体に格納されたプログラムコードを読み出し実行する。これによって、上述した目的を達成することができる。この場合、記憶媒体から読み出されたプログラムコード自体が前述した実施形態の機能を実現することとなり、そのプログラムコードを記憶した記憶媒体は本発明を構成することになる。
<Other embodiments>
The embodiment described above is also executed by performing the following processing. That is, a recording medium recording a software program code that implements the functions of the embodiments described above is supplied to the system or device. Then, the computer (or CPU or MPU) of the system or device reads and executes the program code stored on the recording medium. Thereby, the above-mentioned purpose can be achieved. In this case, the program code itself read from the storage medium will implement the functions of the embodiments described above, and the storage medium that stores the program code will constitute the present invention.

プログラムコードを供給するための記憶媒体としては、例えば、フレキシブルディスク、ハードディスク、光ディスク、光磁気ディスク、CD-ROM、CD-R、磁気テープ、不揮発性のメモリカード、ROM、DVDなどを用いることができる。 As the storage medium for supplying the program code, for example, a flexible disk, hard disk, optical disk, magneto-optical disk, CD-ROM, CD-R, magnetic tape, nonvolatile memory card, ROM, DVD, etc. can be used. can.

また、コンピュータが読み出したプログラムコードを実行することにより、前述した実施例の機能が実現されるだけでない。そのプログラムコードの指示に基づき、コンピュータ上で稼動しているOSなどが実際の処理の一部または全部を行い、その処理によって前述した実施例の機能が実現される場合も含まれる。 Further, by executing the program code read by the computer, not only the functions of the above-described embodiments are realized. This also includes a case where an OS running on the computer performs part or all of the actual processing based on the instructions of the program code, and the functions of the above-described embodiments are realized by the processing.

さらに、記憶媒体から読み出されたプログラムコードが、コンピュータに挿入された機能拡張ボードやコンピュータに接続された機能拡張ユニットに備わるメモリに書きこまれてもよい。そして、そのプログラムコードの指示に基づき、その機能拡張ボードや機能拡張ユニットに備わるCPUなどが実際の処理の一部または全部を行ってもよい。その処理によって前述した実施形態の機能が実現される。 Furthermore, the program code read from the storage medium may be written into a memory included in a function expansion board inserted into the computer or a function expansion unit connected to the computer. Based on instructions from the program code, a CPU included in the function expansion board or function expansion unit may perform part or all of the actual processing. Through this processing, the functions of the embodiments described above are realized.

101:ホストコンピュータ、102:印刷装置、201:UWPアプリケーション、202:OS、203:MPD、204:プリントマネージャ、205:WSDA、206:プリンタドライバ 101: host computer, 102: printing device, 201: UWP application, 202: OS, 203: MPD, 204: print manager, 205: WSDA, 206: printer driver

Claims (13)

情報処理装置が備えるOSの上で動作するアプリケーションのプログラムであって、
前記情報処理装置のコンピュータを
ユーザから印刷要求を受付ける第一の受付手段と、
前記印刷要求に応じて表示された、前記OSの標準の印刷設定ダイアログで指定された印刷設定情報を取得する取得手段と、
印刷対象データと前記印刷設定情報とに基づいて、前記印刷設定ダイアログがプレビューを表示するためのプレビューデータを生成する第一の生成手段と、
前記印刷設定ダイアログに前記プレビューデータを返却する返却手段と、
として機能させることを特徴とするプログラム。
An application program running on an OS included in an information processing device,
a first receiving means for receiving a print request from a user;
acquisition means for acquiring print setting information specified in a standard print setting dialog of the OS displayed in response to the print request;
a first generating means for generating preview data for displaying a preview in the print setting dialog based on the print target data and the print setting information;
a return means for returning the preview data to the print setting dialog;
A program characterized by functioning as
情報処理装置のコンピュータを、前記印刷設定ダイアログを介して受け付けた印刷指示に応じて、前記印刷対象データに基づいて印刷用データを生成する第二の生成手段としてさらに機能させることを特徴とする請求項1に記載のプログラム。 A claim characterized in that the computer of the information processing device further functions as a second generation means for generating print data based on the print target data in response to a print instruction received via the print setting dialog. The program described in Section 1. 情報処理装置のコンピュータを、前記印刷設定情報に含まれる印刷設定で印刷が続行可能であるか否かを判断する判断手段としてさらに機能させることを特徴とする請求項1または2に記載のプログラム。 3. The program according to claim 1, further causing a computer of the information processing apparatus to function as a determining means for determining whether printing can be continued with the print settings included in the print settings information. 前記判断手段は、前記印刷設定情報に含まれるプリンタドライバを示す情報に基づいて印刷が続行可能であるか否かを判断することを特徴とする、請求項3に記載のプログラム。 4. The program according to claim 3, wherein the determining means determines whether printing can be continued based on information indicating a printer driver included in the print setting information. 情報処理装置のコンピュータを、
前記印刷要求に対応する印刷設定をユーザから受け付ける第二の受付手段としてさらに機能させることを特徴とする請求項3または4に記載のプログラム。
The computer of the information processing equipment,
5. The program according to claim 3, further causing the program to function as a second receiving means for receiving print settings corresponding to the print request from a user.
前記判断手段は、前記取得手段で取得した前記印刷設定情報と、前記第二の受付手段で受け付けた印刷設定との間に禁則関係がない場合に印刷が続行可能であると判断することを特徴とする請求項5に記載のプログラム。 The determination means determines that printing can be continued if there is no prohibitive relationship between the print setting information acquired by the acquisition means and the print settings accepted by the second reception means. The program according to claim 5. 印刷が続行不可能であると前記判断手段が判断した場合に、
前記第一の生成手段は印刷が続行不可能であることを示すエラーメッセージを含む前記プレビューデータを生成することを特徴とする請求項3から6のいずれか1項に記載のプログラム。
When the determining means determines that printing cannot be continued,
7. The program according to claim 3, wherein the first generating means generates the preview data including an error message indicating that printing cannot be continued.
前記判断手段は、印刷が続行不可能であると判断した場合に、印刷用データの生成要求に対し、エラーを返却することを特徴とする、請求項3から7のいずれか1項に記載のプログラム。 8. The method according to claim 3, wherein the determining means returns an error in response to a print data generation request when determining that printing cannot be continued. program. 前記第一の生成手段は、印刷可能領域とそれ以外の領域とを識別できるような加工を施した前記プレビューデータを生成することを特徴とする、請求項1から8の何れか1項に記載のプログラム。 9. The first generating means generates the preview data processed so as to distinguish between a printable area and other areas. program. 前記第一の生成手段は、前記取得手段が取得した前記印刷設定情報に基づいて、印刷装置で実行される印刷処理に対応する加工を施した前記プレビューデータを生成することを特徴とする、請求項1から9の何れか1項に記載のプログラム。 The first generation means generates the preview data that has been processed in accordance with the printing process executed by the printing device, based on the print setting information acquired by the acquisition means. The program described in any one of Items 1 to 9. 情報処理装置のコンピュータを、前記印刷設定情報の変更があるか確認する確認手段としてさらに機能させ、
前記取得手段は、前記確認手段が前記印刷設定情報の変更があることを確認した場合に、前記印刷設定ダイアログから印刷設定情報を再取得することを特徴とする、請求項1から10の何れか1項に記載のプログラム。
further causing the computer of the information processing device to function as a confirmation means for confirming whether or not the print setting information has been changed;
11. The acquisition means re-acquires the print setting information from the print setting dialog when the confirmation means confirms that the print setting information has been changed. The program described in Section 1.
OS上で動作するアプリケーションのプログラムを備える情報処理装置であって、前記プログラムを実行することによって、
ーザから印刷要求を受付ける受付手段と
記印刷要求に応じて表示された前記OSの標準の印刷設定ダイアログで指定された印刷設定情報を取得する第一の取得手段と
刷対象データと前記印刷設定情報とに基づいて、前記印刷設定ダイアログがプレビューを表示するためのプレビューデータを生成する第一の生成手段と
記印刷設定ダイアログに前記プレビューデータを返却する返却手段と、
として機能することを特徴とする情報処理装置。
An information processing device comprising an application program running on an OS, and by executing the program,
a reception means for accepting a print request from a user ;
a first acquisition means for acquiring print setting information specified in a standard print setting dialog of the OS displayed in response to the print request ;
a first generating means for generating preview data for displaying a preview in the print setting dialog based on the print target data and the print setting information ;
a return means for returning the preview data to the print setting dialog;
An information processing device characterized by functioning as an information processing device.
OS上で動作するアプリケーションのプログラムを実行する情報処理装置によって実行される方法であって、
ユーザから印刷要求を受付ける受付工程と、
前記印刷要求に応じて表示された前記OSの標準の印刷設定ダイアログで指定された印刷設定情報を取得する第一の取得工程と、
印刷対象データと前記印刷設定情報とに基づいて、前記印刷設定ダイアログがプレビューを表示するためのプレビューデータを生成する第一の生成工程と、
前記印刷設定ダイアログに前記プレビューデータを返却する返却工程と、
を含むことを特徴とする方法。
A method executed by an information processing device that executes an application program running on an OS, the method comprising:
a reception process of accepting a print request from a user;
a first acquisition step of acquiring print setting information specified in a standard print setting dialog of the OS displayed in response to the print request;
a first generation step of generating preview data for the print setting dialog to display a preview based on the print target data and the print setting information;
a return step of returning the preview data to the print settings dialog;
A method characterized by comprising:
JP2019226799A 2019-12-16 2019-12-16 Program, information processing device, and method Active JP7397652B2 (en)

Priority Applications (2)

Application Number Priority Date Filing Date Title
JP2019226799A JP7397652B2 (en) 2019-12-16 2019-12-16 Program, information processing device, and method
JP2023202187A JP2024009336A (en) 2019-12-16 2023-11-29 Program, information processing device and method

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2019226799A JP7397652B2 (en) 2019-12-16 2019-12-16 Program, information processing device, and method

Related Child Applications (1)

Application Number Title Priority Date Filing Date
JP2023202187A Division JP2024009336A (en) 2019-12-16 2023-11-29 Program, information processing device and method

Publications (2)

Publication Number Publication Date
JP2021096605A JP2021096605A (en) 2021-06-24
JP7397652B2 true JP7397652B2 (en) 2023-12-13

Family

ID=76431962

Family Applications (2)

Application Number Title Priority Date Filing Date
JP2019226799A Active JP7397652B2 (en) 2019-12-16 2019-12-16 Program, information processing device, and method
JP2023202187A Pending JP2024009336A (en) 2019-12-16 2023-11-29 Program, information processing device and method

Family Applications After (1)

Application Number Title Priority Date Filing Date
JP2023202187A Pending JP2024009336A (en) 2019-12-16 2023-11-29 Program, information processing device and method

Country Status (1)

Country Link
JP (2) JP7397652B2 (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN117270800B (en) * 2023-11-20 2024-02-06 浙江口碑网络技术有限公司 Data processing method and device

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2010149465A (en) 2008-12-26 2010-07-08 Brother Ind Ltd Printer and printing method
JP2019074906A (en) 2017-10-16 2019-05-16 キヤノン株式会社 program
JP2019160050A (en) 2018-03-15 2019-09-19 キヤノン株式会社 Program and information processing device

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2010149465A (en) 2008-12-26 2010-07-08 Brother Ind Ltd Printer and printing method
JP2019074906A (en) 2017-10-16 2019-05-16 キヤノン株式会社 program
JP2019160050A (en) 2018-03-15 2019-09-19 キヤノン株式会社 Program and information processing device

Also Published As

Publication number Publication date
JP2021096605A (en) 2021-06-24
JP2024009336A (en) 2024-01-19

Similar Documents

Publication Publication Date Title
US9681018B2 (en) Information processing device and non-transitory computer-readable medium storing instructions for print control
KR101064065B1 (en) Information processing apparatus, control method, and storage medium
JP7500657B2 (en) PROGRAM AND INFORMATION PROCESSING APPARATUS
JP2007220043A (en) Print controlling program, print controlling device, and print controlling method
JP5704834B2 (en) Information processing apparatus, control method, and program
JP6222953B2 (en) Information processing apparatus, method, and program
JP2024009336A (en) Program, information processing device and method
JP2023001176A (en) Information processing device and program
JP5495597B2 (en) PRINT CONTROL METHOD, PRINT CONTROL DEVICE, AND PROGRAM
JP2020087297A (en) Program and control method
JP2023178377A (en) Program and control method
JP4810332B2 (en) Information processing apparatus, print setting method, storage medium, program
US20050254079A1 (en) Printing apparatus and method enabled to save print option and print document file
JP2024052771A (en) Information processing device, control method, and program
JP2020004241A (en) Information processing device, control method, and program
JP2015118570A (en) Information processing method and sheet size setting method
JP7110631B2 (en) Information processing device, information processing system, and program
US8270014B2 (en) Printing method, recordable medium recorded with a program to execute the method and host apparatus
JP5152243B2 (en) Data structure of print program, print control device, and print setting information
JP4313974B2 (en) Print control program, print control method, and information processing apparatus
JP2006190152A (en) Method for setting printing condition initial value, program, and information processor
JP2020140396A (en) Program and print controller and control method
JP7066518B2 (en) Program and control method
JP2023041245A (en) Information processing apparatus, control method of information processing apparatus, and program
JP2024018592A (en) Information processing apparatus, method, and program

Legal Events

Date Code Title Description
RD01 Notification of change of attorney

Free format text: JAPANESE INTERMEDIATE CODE: A7421

Effective date: 20210103

A521 Request for written amendment filed

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20210113

A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20221209

A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20230718

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20230810

A521 Request for written amendment filed

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20231010

TRDD Decision of grant or rejection written
A01 Written decision to grant a patent or to grant a registration (utility model)

Free format text: JAPANESE INTERMEDIATE CODE: A01

Effective date: 20231102

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20231201

R151 Written notification of patent or utility model registration

Ref document number: 7397652

Country of ref document: JP

Free format text: JAPANESE INTERMEDIATE CODE: R151