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

📄 gdk-general.html

📁 最新gtk中文资料集
💻 HTML
📖 第 1 页 / 共 4 页
字号:
<ahref="/usr/share/gtk-doc/html/gtk/gtk-General.html#gtk-init"><code class="function">gtk_init()</code></a>, <ahref="/usr/share/gtk-doc/html/gtk/gtk-General.html#gtk-init-check"><code class="function">gtk_init_check()</code></a>, <a class="link" href="gdk-General.html#gdk-init"><code class="function">gdk_init()</code></a>, or <a class="link" href="gdk-General.html#gdk-init-check"><code class="function">gdk_init_check()</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>argc</code></em>&#160;:</span></p></td><td> the number of command line arguments.</td></tr><tr><td><p><span class="term"><em class="parameter"><code>argv</code></em>&#160;:</span></p></td><td> the array of command line arguments.</td></tr></tbody></table></div><p class="since">Since  2.2</p></div><hr><div class="refsect2" lang="en"><a name="id3045758"></a><h3><a name="gdk-get-display-arg-name"></a>gdk_get_display_arg_name ()</h3><a class="indexterm" name="id3045770"></a><pre class="programlisting">const <ahref="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gchar">gchar</a>*        gdk_get_display_arg_name            (void);</pre><p>Gets the display name specified in the command line arguments passedto <a class="link" href="gdk-General.html#gdk-init"><code class="function">gdk_init()</code></a> or <a class="link" href="gdk-General.html#gdk-parse-args"><code class="function">gdk_parse_args()</code></a>, if any.</p><p></p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><p><span class="term"><span class="emphasis"><em>Returns</em></span>&#160;:</span></p></td><td> the display name, if specified explicitely, otherwise <ahref="/usr/share/gtk-doc/html/liboil/liboil-liboiljunk.html#NULL:CAPS"><code class="literal">NULL</code></a>  this string is owned by GTK+ and must not be modified or freed.</td></tr></tbody></table></div><p class="since">Since  2.2</p></div><hr><div class="refsect2" lang="en"><a name="id3045842"></a><h3><a name="gdk-set-locale"></a>gdk_set_locale ()</h3><a class="indexterm" name="id3045852"></a><pre class="programlisting"><ahref="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gchar">gchar</a>*              gdk_set_locale                      (void);</pre><p>Initializes the support for internationalization by calling the <code class="function"><code class="function">setlocale()</code></code>system call. This function is called by <ahref="/usr/share/gtk-doc/html/gtk/gtk-General.html#gtk-set-locale"><code class="function">gtk_set_locale()</code></a> and so GTK+applications should use that instead.</p><p>The locale to use is determined by the <code class="envar">LANG</code> environment variable,so to run an application in a certain locale you can do something like this:</p><div class="informalexample"><pre class="programlisting">  export LANG="fr"  ... run application ...</pre></div><p></p><p>If the locale is not supported by X then it is reset to the standard "C"locale.</p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><p><span class="term"><span class="emphasis"><em>Returns</em></span>&#160;:</span></p></td><td>the resulting locale.</td></tr></tbody></table></div></div><hr><div class="refsect2" lang="en"><a name="id3045930"></a><h3><a name="gdk-set-sm-client-id"></a>gdk_set_sm_client_id ()</h3><a class="indexterm" name="id3045941"></a><pre class="programlisting">void                gdk_set_sm_client_id                (const <ahref="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gchar">gchar</a> *sm_client_id);</pre><p>Sets the <code class="literal">SM_CLIENT_ID</code> property on the application's leader window so thatthe window manager can save the application's state using the X11R6 ICCCMsession management protocol.</p><p>See the X Session Management Library documentation for more information onsession management and the Inter-Client Communication Conventions Manual(ICCCM) for information on the <code class="literal">WM_CLIENT_LEADER</code> property. (Both documents are part of the X Window System distribution.)</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>sm_client_id</code></em>&#160;:</span></p></td><td> the client id assigned by the session manager when the   connection was opened, or <ahref="/usr/share/gtk-doc/html/liboil/liboil-liboiljunk.html#NULL:CAPS"><code class="literal">NULL</code></a> to remove the property.</td></tr></tbody></table></div></div><hr><div class="refsect2" lang="en"><a name="id3046016"></a><h3><a name="gdk-exit"></a>gdk_exit ()</h3><a class="indexterm" name="id3046028"></a><pre class="programlisting">void                gdk_exit                            (<ahref="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint">gint</a> error_code);</pre><div class="warning" style="margin-left: 0.5in; margin-right: 0.5in;"><h3 class="title">Warning</h3><p><code class="literal">gdk_exit</code> is deprecated and should not be used in newly-written code.</p></div><p>Exits the application using the <code class="function"><code class="function">exit()</code></code> system call.</p><p>This routine is provided mainly for backwards compatibility, since it used toperform tasks necessary to exit the application cleanly. Those tasks are nowperformed in a function which is automatically called on exit (via the useof <ahref="/usr/share/gtk-doc/html/glib/glib-Miscellaneous-Utility-Functions.html#g-atexit"><code class="function">g_atexit()</code></a>).</p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><p><span class="term"><em class="parameter"><code>error_code</code></em>&#160;:</span></p></td><td>the error code to pass to the <code class="function"><code class="function">exit()</code></code> call.</td></tr></tbody></table></div></div><hr><div class="refsect2" lang="en"><a name="id3046123"></a><h3><a name="gdk-notify-startup-complete"></a>gdk_notify_startup_complete ()</h3><a class="indexterm" name="id3046136"></a><pre class="programlisting">void                gdk_notify_startup_complete         (void);</pre><p>Indicates to the GUI environment that the application has finishedloading. If the applications opens windows, this function isnormally called after opening the application's initial set ofwindows.</p><p>GTK+ will call this function automatically after opening the first<ahref="/usr/share/gtk-doc/html/gtk/GtkWindow.html"><span class="type">GtkWindow</span></a> unless <ahref="/usr/share/gtk-doc/html/gtk/GtkWindow.html#gtk-window-set-auto-startup-notification"><code class="function">gtk_window_set_auto_startup_notification()</code></a> is called to disable that feature.</p><p></p><p class="since">Since  2.2</p></div><hr><div class="refsect2" lang="en"><a name="id3046188"></a><h3><a name="gdk-notify-startup-complete-with-id"></a>gdk_notify_startup_complete_with_id ()</h3><a class="indexterm" name="id3046203"></a><pre class="programlisting">void                gdk_notify_startup_complete_with_id (const <ahref="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gchar">gchar</a> *startup_id);</pre><p>Indicates to the GUI environment that the application has finishedloading, using a given identifier.</p><p>GTK+ will call this function automatically for <ahref="/usr/share/gtk-doc/html/gtk/GtkWindow.html"><span class="type">GtkWindow</span></a> with customstartup-notification identifier unless<ahref="/usr/share/gtk-doc/html/gtk/GtkWindow.html#gtk-window-set-auto-startup-notification"><code class="function">gtk_window_set_auto_startup_notification()</code></a> is called to disablethat feature.</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>startup_id</code></em>&#160;:</span></p></td><td> a startup-notification identifier, for which notification             process should be completed</td></tr></tbody></table></div><p class="since">Since  2.12</p></div><hr><div class="refsect2" lang="en"><a name="id3046280"></a><h3><a name="gdk-get-program-class"></a>gdk_get_program_class ()</h3><a class="indexterm" name="id3046290"></a><pre class="programlisting">const char*         gdk_get_program_class               (void);</pre><p>Gets the program class. Unless the program class has explicitlybeen set with <a class="link" href="gdk-General.html#gdk-set-program-class"><code class="function">gdk_set_program_class()</code></a> or with the <code class="option">--class</code> commandline option, the default value is the program name (determined with <ahref="/usr/share/gtk-doc/html/glib/glib-Miscellaneous-Utility-Functions.html#g-get-prgname"><code class="function">g_get_prgname()</code></a>) with the first character converted to uppercase. </p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><p><span class="term"><span class="emphasis"><em>Returns</em></span>&#160;:</span></p></td><td>the program class.</td></tr></tbody></table></div></div><hr><div class="refsect2" lang="en"><a name="id3046348"></a><h3><a name="gdk-set-program-class"></a>gdk_set_program_class ()</h3><a class="indexterm" name="id3046358"></a><pre class="programlisting">void                gdk_set_program_class               (const char *program_class);</pre><p>Sets the program class. The X11 backend uses the program class to setthe class name part of the <code class="literal">WM_CLASS</code> property ontoplevel windows; see the ICCCM.</p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><p><span class="term"><em class="parameter"><code>program_class</code></em>&#160;:</span></p></td><td>a string.</td></tr></tbody></table></div></div><hr><div class="refsect2" lang="en"><a name="id3046407"></a><h3><a name="gdk-get-display"></a>gdk_get_display ()</h3><a class="indexterm" name="id3046417"></a><pre class="programlisting"><ahref="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gchar">gchar</a>*              gdk_get_display                     (void);</pre><p>Gets the name of the display, which usually comes from the <code class="envar">DISPLAY</code>environment variable or the <code class="option">--display</code> command line option.</p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><p><span class="term"><span class="emphasis"><em>Returns</em></span>&#160;:</span></p></td><td>the name of the display.</td></tr></tbody></table></div></div><hr><div class="refsect2" lang="en"><a name="id3046458"></a><h3><a name="gdk-flush"></a>gdk_flush ()</h3><a class="indexterm" name="id3046468"></a><pre class="programlisting">void                gdk_flush                           (void);</pre>

⌨️ 快捷键说明

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