⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 gtk-high-level-printing-api.html

📁 最新gtk中文资料集
💻 HTML
📖 第 1 页 / 共 5 页
字号:
<td><p><span class="term"><span class="emphasis"><em>Returns</em></span>&#160;:</span></p></td><td> the default page setup </td></tr></tbody></table></div><p class="since">Since  2.10</p></div><hr><div class="refsect2" lang="en"><a name="id4130649"></a><h3><a name="gtk-print-operation-set-print-settings"></a>gtk_print_operation_set_print_settings ()</h3><a class="indexterm" name="id4130665"></a><pre class="programlisting">void                gtk_print_operation_set_print_settings                                                        (<a class="link" href="gtk-High-level-Printing-API.html#GtkPrintOperation">GtkPrintOperation</a> *op,                                                         <a class="link" href="GtkPrintSettings.html" title="GtkPrintSettings">GtkPrintSettings</a> *print_settings);</pre><p>Sets the print settings for <em class="parameter"><code>op</code></em>. This is typically used tore-establish print settings from a previous print operation,see <a class="link" href="gtk-High-level-Printing-API.html#gtk-print-operation-run"><code class="function">gtk_print_operation_run()</code></a>.</p><p></p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><p><span class="term"><em class="parameter"><code>op</code></em>&#160;:</span></p></td><td> a <a class="link" href="gtk-High-level-Printing-API.html#GtkPrintOperation"><span class="type">GtkPrintOperation</span></a></td></tr><tr><td><p><span class="term"><em class="parameter"><code>print_settings</code></em>&#160;:</span></p></td><td> <a class="link" href="GtkPrintSettings.html" title="GtkPrintSettings"><span class="type">GtkPrintSettings</span></a>, or <ahref="/usr/share/gtk-doc/html/liboil/liboil-liboiljunk.html#NULL:CAPS"><code class="literal">NULL</code></a></td></tr></tbody></table></div><p class="since">Since  2.10</p></div><hr><div class="refsect2" lang="en"><a name="id4130790"></a><h3><a name="gtk-print-operation-get-print-settings"></a>gtk_print_operation_get_print_settings ()</h3><a class="indexterm" name="id4130806"></a><pre class="programlisting"><a class="link" href="GtkPrintSettings.html" title="GtkPrintSettings">GtkPrintSettings</a>*   gtk_print_operation_get_print_settings                                                        (<a class="link" href="gtk-High-level-Printing-API.html#GtkPrintOperation">GtkPrintOperation</a> *op);</pre><p>Returns the current print settings. </p><p>Note that the return value is <ahref="/usr/share/gtk-doc/html/liboil/liboil-liboiljunk.html#NULL:CAPS"><code class="literal">NULL</code></a> until either <a class="link" href="gtk-High-level-Printing-API.html#gtk-print-operation-set-print-settings"><code class="function">gtk_print_operation_set_print_settings()</code></a> or <a class="link" href="gtk-High-level-Printing-API.html#gtk-print-operation-run"><code class="function">gtk_print_operation_run()</code></a> have been called.</p><p></p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><p><span class="term"><em class="parameter"><code>op</code></em>&#160;:</span></p></td><td> a <a class="link" href="gtk-High-level-Printing-API.html#GtkPrintOperation"><span class="type">GtkPrintOperation</span></a></td></tr><tr><td><p><span class="term"><span class="emphasis"><em>Returns</em></span>&#160;:</span></p></td><td> the current print settings of <em class="parameter"><code>op</code></em>.</td></tr></tbody></table></div><p class="since">Since  2.10</p></div><hr><div class="refsect2" lang="en"><a name="id4130927"></a><h3><a name="gtk-print-operation-set-job-name"></a>gtk_print_operation_set_job_name ()</h3><a class="indexterm" name="id4130943"></a><pre class="programlisting">void                gtk_print_operation_set_job_name    (<a class="link" href="gtk-High-level-Printing-API.html#GtkPrintOperation">GtkPrintOperation</a> *op,                                                         const <ahref="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gchar">gchar</a> *job_name);</pre><p>Sets the name of the print job. The name is used to identify the job (e.g. in monitoring applications like eggcups). </p><p>If you don't set a job name, GTK+ picks a default one by numbering successive print jobs.</p><p></p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><p><span class="term"><em class="parameter"><code>op</code></em>&#160;:</span></p></td><td> a <a class="link" href="gtk-High-level-Printing-API.html#GtkPrintOperation"><span class="type">GtkPrintOperation</span></a></td></tr><tr><td><p><span class="term"><em class="parameter"><code>job_name</code></em>&#160;:</span></p></td><td> a string that identifies the print job</td></tr></tbody></table></div><p class="since">Since  2.10</p></div><hr><div class="refsect2" lang="en"><a name="id4131037"></a><h3><a name="gtk-print-operation-set-n-pages"></a>gtk_print_operation_set_n_pages ()</h3><a class="indexterm" name="id4131053"></a><pre class="programlisting">void                gtk_print_operation_set_n_pages     (<a class="link" href="gtk-High-level-Printing-API.html#GtkPrintOperation">GtkPrintOperation</a> *op,                                                         <ahref="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint">gint</a> n_pages);</pre><p>Sets the number of pages in the document. </p><p>This <span class="emphasis"><em>must</em></span> be set to a positive numberbefore the rendering starts. It may be set in a <a class="link" href="gtk-High-level-Printing-API.html#GtkPrintOperation-begin-print"><span class="type">"begin-print"</span></a> signal hander.</p><p>Note that the page numbers passed to the <a class="link" href="gtk-High-level-Printing-API.html#GtkPrintOperation-request-page-setup"><span class="type">"request-page-setup"</span></a> and <a class="link" href="gtk-High-level-Printing-API.html#GtkPrintOperation-draw-page"><span class="type">"draw-page"</span></a> signals are 0-based, i.e. if the user chooses to print all pages, the last ::draw-page signal will be for page <em class="parameter"><code>n_pages</code></em> - 1.</p><p></p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><p><span class="term"><em class="parameter"><code>op</code></em>&#160;:</span></p></td><td> a <a class="link" href="gtk-High-level-Printing-API.html#GtkPrintOperation"><span class="type">GtkPrintOperation</span></a></td></tr><tr><td><p><span class="term"><em class="parameter"><code>n_pages</code></em>&#160;:</span></p></td><td> the number of pages</td></tr></tbody></table></div><p class="since">Since  2.10</p></div><hr><div class="refsect2" lang="en"><a name="id4131189"></a><h3><a name="gtk-print-operation-set-current-page"></a>gtk_print_operation_set_current_page ()</h3><a class="indexterm" name="id4131204"></a><pre class="programlisting">void                gtk_print_operation_set_current_page                                                        (<a class="link" href="gtk-High-level-Printing-API.html#GtkPrintOperation">GtkPrintOperation</a> *op,                                                         <ahref="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint">gint</a> current_page);</pre><p>Sets the current page.</p><p>If this is called before <a class="link" href="gtk-High-level-Printing-API.html#gtk-print-operation-run"><code class="function">gtk_print_operation_run()</code></a>, the user will be able to select to print only the current page.</p><p>Note that this only makes sense for pre-paginated documents.</p><p></p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><p><span class="term"><em class="parameter"><code>op</code></em>&#160;:</span></p></td><td> a <a class="link" href="gtk-High-level-Printing-API.html#GtkPrintOperation"><span class="type">GtkPrintOperation</span></a></td></tr><tr><td><p><span class="term"><em class="parameter"><code>current_page</code></em>&#160;:</span></p></td><td> the current page, 0-based</td></tr></tbody></table></div><p class="since">Since  2.10</p></div><hr><div class="refsect2" lang="en"><a name="id4131313"></a><h3><a name="gtk-print-operation-set-use-full-page"></a>gtk_print_operation_set_use_full_page ()</h3><a class="indexterm" name="id4131330"></a><pre class="programlisting">void                gtk_print_operation_set_use_full_page                                                        (<a class="link" href="gtk-High-level-Printing-API.html#GtkPrintOperation">GtkPrintOperation</a> *op,                                                         <ahref="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gboolean">gboolean</a> full_page);</pre><p>If <em class="parameter"><code>full_page</code></em> is <ahref="/usr/share/gtk-doc/html/glib/glib-Standard-Macros.html#TRUE:CAPS"><code class="literal">TRUE</code></a>, the transformation for the cairo context obtained from <a class="link" href="GtkPrintContext.html" title="GtkPrintContext"><span class="type">GtkPrintContext</span></a> puts the origin at the top left corner of the page (which may not be the top left corner of the sheet, depending on page orientation and the number of pages per sheet). Otherwise, the origin is at the top left corner of theimageable area (i.e. inside the margins).</p><p></p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><p><span class="term"><em class="parameter"><code>op</code></em>&#160;:</span></p></td><td> a <a class="link" href="gtk-High-level-Printing-API.html#GtkPrintOperation"><span class="type">GtkPrintOperation</span></a></td></tr><tr><td><p><span class="term"><em class="parameter"><code>full_page</code></em>&#160;:</span></p></td><td> <ahref="/usr/share/gtk-doc/html/glib/glib-Standard-Macros.html#TRUE:CAPS"><code class="literal">TRUE</code></a> to set up the <a class="link" href="GtkPrintContext.html" title="GtkPrintContext"><span class="type">GtkPrintContext</span></a> for the full page</td></tr></tbody></table></div><p class="since">Since  2.10 </p></div><hr><div class="refsect2" lang="en"><a name="id4131466"></a><h3><a name="gtk-print-operation-set-unit"></a>gtk_print_operation_set_unit ()</h3><a class="indexterm" name="id4131481"></a><pre class="programlisting">void                gtk_print_operation_set_unit        (<a class="link" href="gtk-High-level-Printing-API.html#GtkPrintOperation">GtkPrintOperation</a> *op,

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -