亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? glib-commandline-option-parser.html

?? glid編寫實例
?? HTML
?? 第 1 頁 / 共 5 頁
字號:
<html xmlns:cf="http://docbook.sourceforge.net/xmlns/chunkfast/1.0"><head><meta http-equiv="Content-Type" content="text/html; charset=US-ASCII"><title>Commandline option parser</title><meta name="generator" content="DocBook XSL Stylesheets V1.69.0"><link rel="start" href="index.html" title="GLib Reference Manual"><link rel="up" href="glib-utilities.html" title="GLib Utilities"><link rel="prev" href="glib-Shell-related-Utilities.html" title="Shell-related Utilities"><link rel="next" href="glib-Glob-style-pattern-matching.html" title="Glob-style pattern matching"><meta name="generator" content="GTK-Doc V1.4 (XML mode)"><link rel="stylesheet" href="style.css" type="text/css"><link rel="chapter" href="glib.html" title="GLib Overview"><link rel="chapter" href="glib-fundamentals.html" title="GLib Fundamentals"><link rel="chapter" href="glib-core.html" title="GLib Core Application Support"><link rel="chapter" href="glib-utilities.html" title="GLib Utilities"><link rel="chapter" href="glib-data-types.html" title="GLib Data Types"><link rel="chapter" href="tools.html" title="GLib Tools"><link rel="index" href="ix01.html" title="Index"><link rel="index" href="ix02.html" title="Index of deprecated symbols"><link rel="index" href="ix03.html" title="Index of new symbols in 2.2"><link rel="index" href="ix04.html" title="Index of new symbols in 2.4"><link rel="index" href="ix05.html" title="Index of new symbols in 2.6"></head><body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"><table class="navigation" width="100%" summary="Navigation header" cellpadding="2" cellspacing="2"><tr valign="middle"><td><a accesskey="p" href="glib-Shell-related-Utilities.html"><img src="left.png" width="24" height="24" border="0" alt="Prev"></a></td><td><a accesskey="u" href="glib-utilities.html"><img src="up.png" width="24" height="24" border="0" alt="Up"></a></td><td><a accesskey="h" href="index.html"><img src="home.png" width="24" height="24" border="0" alt="Home"></a></td><th width="100%" align="center">GLib Reference Manual</th><td><a accesskey="n" href="glib-Glob-style-pattern-matching.html"><img src="right.png" width="24" height="24" border="0" alt="Next"></a></td></tr></table><div class="refentry" lang="en"><a name="glib-Commandline-option-parser"></a><div class="titlepage"></div><div class="refnamediv"><table width="100%"><tr><td valign="top"><h2><span class="refentrytitle">Commandline option parser</span></h2><p>Commandline option parser &#8212; parses commandline options</p></td><td valign="top" align="right"></td></tr></table></div><div class="refsynopsisdiv"><h2>Synopsis</h2><pre class="synopsis">#include &lt;glib.h&gt;enum        <a href="glib-Commandline-option-parser.html#GOptionError">GOptionError</a>;#define     <a href="glib-Commandline-option-parser.html#G-OPTION-ERROR:CAPS">G_OPTION_ERROR</a><a href="glib-Basic-Types.html#gboolean">gboolean</a>    (<a href="glib-Commandline-option-parser.html#GOptionArgFunc">*GOptionArgFunc</a>)               (const <a href="glib-Basic-Types.html#gchar">gchar</a> *option_name,                                             const <a href="glib-Basic-Types.html#gchar">gchar</a> *value,                                             <a href="glib-Basic-Types.html#gpointer">gpointer</a> data,                                             <a href="glib-Error-Reporting.html#GError">GError</a> **error);            <a href="glib-Commandline-option-parser.html#GOptionContext">GOptionContext</a>;<a href="glib-Commandline-option-parser.html#GOptionContext">GOptionContext</a>* <a href="glib-Commandline-option-parser.html#g-option-context-new">g_option_context_new</a>        (const <a href="glib-Basic-Types.html#gchar">gchar</a> *parameter_string);void        <a href="glib-Commandline-option-parser.html#g-option-context-free">g_option_context_free</a>           (<a href="glib-Commandline-option-parser.html#GOptionContext">GOptionContext</a> *context);<a href="glib-Basic-Types.html#gboolean">gboolean</a>    <a href="glib-Commandline-option-parser.html#g-option-context-parse">g_option_context_parse</a>          (<a href="glib-Commandline-option-parser.html#GOptionContext">GOptionContext</a> *context,                                             <a href="glib-Basic-Types.html#gint">gint</a> *argc,                                             <a href="glib-Basic-Types.html#gchar">gchar</a> ***argv,                                             <a href="glib-Error-Reporting.html#GError">GError</a> **error);void        <a href="glib-Commandline-option-parser.html#g-option-context-set-help-enabled">g_option_context_set_help_enabled</a>                                            (<a href="glib-Commandline-option-parser.html#GOptionContext">GOptionContext</a> *context,                                             <a href="glib-Basic-Types.html#gboolean">gboolean</a> help_enabled);<a href="glib-Basic-Types.html#gboolean">gboolean</a>    <a href="glib-Commandline-option-parser.html#g-option-context-get-help-enabled">g_option_context_get_help_enabled</a>                                            (<a href="glib-Commandline-option-parser.html#GOptionContext">GOptionContext</a> *context);void        <a href="glib-Commandline-option-parser.html#g-option-context-set-ignore-unknown-options">g_option_context_set_ignore_unknown_options</a>                                            (<a href="glib-Commandline-option-parser.html#GOptionContext">GOptionContext</a> *context,                                             <a href="glib-Basic-Types.html#gboolean">gboolean</a> ignore_unknown);<a href="glib-Basic-Types.html#gboolean">gboolean</a>    <a href="glib-Commandline-option-parser.html#g-option-context-get-ignore-unknown-options">g_option_context_get_ignore_unknown_options</a>                                            (<a href="glib-Commandline-option-parser.html#GOptionContext">GOptionContext</a> *context);enum        <a href="glib-Commandline-option-parser.html#GOptionArg">GOptionArg</a>;enum        <a href="glib-Commandline-option-parser.html#GOptionFlags">GOptionFlags</a>;#define     <a href="glib-Commandline-option-parser.html#G-OPTION-REMAINING:CAPS">G_OPTION_REMAINING</a>            <a href="glib-Commandline-option-parser.html#GOptionEntry">GOptionEntry</a>;void        <a href="glib-Commandline-option-parser.html#g-option-context-add-main-entries">g_option_context_add_main_entries</a>                                            (<a href="glib-Commandline-option-parser.html#GOptionContext">GOptionContext</a> *context,                                             const <a href="glib-Commandline-option-parser.html#GOptionEntry">GOptionEntry</a> *entries,                                             const <a href="glib-Basic-Types.html#gchar">gchar</a> *translation_domain);            <a href="glib-Commandline-option-parser.html#GOptionGroup">GOptionGroup</a>;void        <a href="glib-Commandline-option-parser.html#g-option-context-add-group">g_option_context_add_group</a>      (<a href="glib-Commandline-option-parser.html#GOptionContext">GOptionContext</a> *context,                                             <a href="glib-Commandline-option-parser.html#GOptionGroup">GOptionGroup</a> *group);void        <a href="glib-Commandline-option-parser.html#g-option-context-set-main-group">g_option_context_set_main_group</a> (<a href="glib-Commandline-option-parser.html#GOptionContext">GOptionContext</a> *context,                                             <a href="glib-Commandline-option-parser.html#GOptionGroup">GOptionGroup</a> *group);<a href="glib-Commandline-option-parser.html#GOptionGroup">GOptionGroup</a>* <a href="glib-Commandline-option-parser.html#g-option-context-get-main-group">g_option_context_get_main_group</a>                                            (<a href="glib-Commandline-option-parser.html#GOptionContext">GOptionContext</a> *context);<a href="glib-Commandline-option-parser.html#GOptionGroup">GOptionGroup</a>* <a href="glib-Commandline-option-parser.html#g-option-group-new">g_option_group_new</a>            (const <a href="glib-Basic-Types.html#gchar">gchar</a> *name,                                             const <a href="glib-Basic-Types.html#gchar">gchar</a> *description,                                             const <a href="glib-Basic-Types.html#gchar">gchar</a> *help_description,                                             <a href="glib-Basic-Types.html#gpointer">gpointer</a> user_data,                                             <a href="glib-Datasets.html#GDestroyNotify">GDestroyNotify</a> destroy);void        <a href="glib-Commandline-option-parser.html#g-option-group-free">g_option_group_free</a>             (<a href="glib-Commandline-option-parser.html#GOptionGroup">GOptionGroup</a> *group);void        <a href="glib-Commandline-option-parser.html#g-option-group-add-entries">g_option_group_add_entries</a>      (<a href="glib-Commandline-option-parser.html#GOptionGroup">GOptionGroup</a> *group,                                             const <a href="glib-Commandline-option-parser.html#GOptionEntry">GOptionEntry</a> *entries);<a href="glib-Basic-Types.html#gboolean">gboolean</a>    (<a href="glib-Commandline-option-parser.html#GOptionParseFunc">*GOptionParseFunc</a>)             (<a href="glib-Commandline-option-parser.html#GOptionContext">GOptionContext</a> *context,                                             <a href="glib-Commandline-option-parser.html#GOptionGroup">GOptionGroup</a> *group,                                             <a href="glib-Basic-Types.html#gpointer">gpointer</a> data,                                             <a href="glib-Error-Reporting.html#GError">GError</a> **error);void        <a href="glib-Commandline-option-parser.html#g-option-group-set-parse-hooks">g_option_group_set_parse_hooks</a>  (<a href="glib-Commandline-option-parser.html#GOptionGroup">GOptionGroup</a> *group,                                             <a href="glib-Commandline-option-parser.html#GOptionParseFunc">GOptionParseFunc</a> pre_parse_func,                                             <a href="glib-Commandline-option-parser.html#GOptionParseFunc">GOptionParseFunc</a> post_parse_func);void        (<a href="glib-Commandline-option-parser.html#GOptionErrorFunc">*GOptionErrorFunc</a>)             (<a href="glib-Commandline-option-parser.html#GOptionContext">GOptionContext</a> *context,                                             <a href="glib-Commandline-option-parser.html#GOptionGroup">GOptionGroup</a> *group,                                             <a href="glib-Basic-Types.html#gpointer">gpointer</a> data,                                             <a href="glib-Error-Reporting.html#GError">GError</a> **error);void        <a href="glib-Commandline-option-parser.html#g-option-group-set-error-hook">g_option_group_set_error_hook</a>   (<a href="glib-Commandline-option-parser.html#GOptionGroup">GOptionGroup</a> *group,                                             <a href="glib-Commandline-option-parser.html#GOptionErrorFunc">GOptionErrorFunc</a> error_func);const <a href="glib-Basic-Types.html#gchar">gchar</a>* (<a href="glib-Commandline-option-parser.html#GTranslateFunc">*GTranslateFunc</a>)              (const <a href="glib-Basic-Types.html#gchar">gchar</a> *str,                                             <a href="glib-Basic-Types.html#gpointer">gpointer</a> data);void        <a href="glib-Commandline-option-parser.html#g-option-group-set-translate-func">g_option_group_set_translate_func</a>                                            (<a href="glib-Commandline-option-parser.html#GOptionGroup">GOptionGroup</a> *group,                                             <a href="glib-Commandline-option-parser.html#GTranslateFunc">GTranslateFunc</a> func,                                             <a href="glib-Basic-Types.html#gpointer">gpointer</a> data,                                             <a href="glib-Datasets.html#GDestroyNotify">GDestroyNotify</a> destroy_notify);void        <a href="glib-Commandline-option-parser.html#g-option-group-set-translation-domain">g_option_group_set_translation_domain</a>                                            (<a href="glib-Commandline-option-parser.html#GOptionGroup">GOptionGroup</a> *group,                                             const <a href="glib-Basic-Types.html#gchar">gchar</a> *domain);</pre></div><div class="refsect1" lang="en"><a name="id3063223"></a><h2>Description</h2><p>The GOption commandline parser is intended to be a simpler replacement for thepopt library. It supports short and long commandline options, as shown in the following example:</p><p><code class="literal">testtreemodel -r 1 --max-size 20 --rand --display=:1.0 -vb -- file1 file2</code></p><p>The example demonstrates a number of features of the GOption commandline parser</p><div class="itemizedlist"><ul type="disc"><li><p>  Options can be single letters, prefixed by a single dash. Multiple  short options can be grouped behind a single dash.</p></li><li><p>  Long options are prefixed by two consecutive dashes.</p></li><li><p>  Options can have an extra argument, which can be a number, a string or a filename.  For long options, the extra argument can be appended with an equals sign after the  option name.</p></li><li><p>  Non-option arguments are returned to the application as rest arguments.</p></li><li><p>  An argument consisting solely of two dashes turns off further parsing, any remaining  arguments (even those starting with a dash) are returned to the application as rest   arguments.</p></li></ul></div><p></p><p>Another important feature of GOption is that it can automatically generate nicelyformatted help output. Unless it is explicitly turned off with <a href="glib-Commandline-option-parser.html#g-option-context-set-help-enabled"><code class="function">g_option_context_set_help_enabled()</code></a>, GOption will recognize the <code class="option">--help</code>, <code class="option">-?</code>, <code class="option">--help-all</code>and <code class="option">--help-</code><em class="replaceable"><code>groupname</code></em> options (where <em class="replaceable"><code>groupname</code></em> is the name of a <a href="glib-Commandline-option-parser.html#GOptionGroup"><span class="type">GOptionGroup</span></a>) and write a text similar to the one shown in the following example to stdout.</p><div class="informalexample"><pre class="screen">Usage:  testtreemodel [OPTION...] - test tree model performanceHelp Options:  -?, --help               Show help options  --help-all               Show all help options  --help-gtk               Show GTK+ OptionsApplication Options:  -r, --repeats=N          Average over N repetitions  -m, --max-size=M         Test up to 2^M items  --display=DISPLAY        X display to use  -v, --verbose            Be verbose  -b, --beep               Beep when done     --rand                   Randomize the data</pre></div><p>GOption groups options in <a href="glib-Commandline-option-parser.html#GOptionGroup"><span class="type">GOptionGroup</span></a>s, which makes it easy toincorporate options from multiple sources. The intended use for this isto let applications collect option groups from the libraries it uses,add them to their <a href="glib-Commandline-option-parser.html#GOptionContext"><span class="type">GOptionContext</span></a>, and parse all options by a single callto <a href="glib-Commandline-option-parser.html#g-option-context-parse"><code class="function">g_option_context_parse()</code></a>. See <ahref="../gtk/gtk-General.html#gtk-get-option-group"><code class="function">gtk_get_option_group()</code></a> for an example.</p><p>If an option is declared to be of type string or filename, GOption takescare of converting it to the right encoding; strings are returned in UTF-8,filenames are returned in the GLib filename encoding.</p><p>Here is a complete example of setting up GOption to parse the examplecommandline above and produce the example help output.</p><div class="informalexample"><pre class="programlisting">static gint repeats = 2;static gint max_size = 8;static gboolean verbose = FALSE;static gboolean beep = FALSE;static gboolean rand = FALSE;static GOptionEntry entries[] = {  { "repeats", 'r', 0, G_OPTION_ARG_INT, &amp;repeats, "Average over N repetitions", "N" },  { "max-size", 'm', 0, G_OPTION_ARG_INT, &amp;max_size, "Test up to 2^M items", "M" },  { "verbose", 'v', 0, G_OPTION_ARG_NONE, &amp;verbose, "Be verbose", NULL },  { "beep", 'b', 0, G_OPTION_ARG_NONE, &amp;beep, "Beep when done", NULL },  { "rand", 0, 0, G_OPTION_ARG_NONE, &amp;rand, "Randomize the data", NULL },  { NULL }};int main (int argc, char *argv[]){  GError *error = NULL;  context = g_option_context_new ("- test tree model performance");  g_option_context_add_main_entries (context, entries, GETTEXT_PACKAGE);  g_option_context_add_group (context, gtk_get_option_group (TRUE));  g_option_context_parse (context, &amp;argc, &amp;argv, &amp;error);    /* ... */}</pre></div></div><div class="refsect1" lang="en"><a name="id3063435"></a><h2>Details</h2><div class="refsect2" lang="en"><a name="id3063440"></a><h3><a name="GOptionError"></a>enum GOptionError</h3><a class="indexterm" name="id3063451"></a><pre class="programlisting">typedef enum{  G_OPTION_ERROR_UNKNOWN_OPTION,  G_OPTION_ERROR_BAD_VALUE,  G_OPTION_ERROR_FAILED} GOptionError;</pre><p>Error codes returned by option parsing.</p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><span class="term"><code class="literal">G_OPTION_ERROR_UNKNOWN_OPTION</code></span></td><td>An option was not known to the parser.  This error will only be reported, if the parser hasn't been instructed  to ignore unknown options, see <a href="glib-Commandline-option-parser.html#g-option-context-set-ignore-unknown-options"><code class="function">g_option_context_set_ignore_unknown_options()</code></a>.</td></tr><tr><td><span class="term"><code class="literal">G_OPTION_ERROR_BAD_VALUE</code></span></td><td>A value couldn't be parsed.</td></tr><tr><td><span class="term"><code class="literal">G_OPTION_ERROR_FAILED</code></span></td><td>A <a href="glib-Commandline-option-parser.html#GOptionArgFunc"><span class="type">GOptionArgFunc</span></a> callback failed.</td></tr></tbody></table></div></div><hr><div class="refsect2" lang="en"><a name="id3063541"></a><h3><a name="G-OPTION-ERROR:CAPS"></a>G_OPTION_ERROR</h3><a class="indexterm" name="id3063552"></a><pre class="programlisting">#define G_OPTION_ERROR (g_option_error_quark ())</pre>

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
久久不见久久见免费视频7| 精品视频免费在线| 欧美群妇大交群中文字幕| 久久久91精品国产一区二区三区| 亚洲人成精品久久久久| 麻豆一区二区99久久久久| 色狠狠av一区二区三区| 久久久久亚洲综合| 免费久久精品视频| 日本韩国视频一区二区| 国产三级一区二区| 男女视频一区二区| 欧美日韩高清一区二区三区| 国产精品久久久久四虎| 国产亚洲婷婷免费| 欧美理论电影在线| 亚洲欧洲av一区二区三区久久| 麻豆精品视频在线观看免费| 色综合久久综合| 久久影院午夜论| 丝袜美腿亚洲色图| av欧美精品.com| 国产欧美精品一区二区三区四区| 日韩精品免费专区| 欧美精品自拍偷拍| 亚洲国产精品天堂| 在线视频国内自拍亚洲视频| 亚洲欧美偷拍三级| 91在线观看高清| 综合久久综合久久| 不卡av在线网| 国产精品国产三级国产专播品爱网| 激情伊人五月天久久综合| 4438x成人网最大色成网站| 亚洲国产另类av| 欧美久久久久久久久| 日本在线不卡视频| 日韩亚洲欧美在线观看| 蜜桃av一区二区在线观看 | 久久电影网电视剧免费观看| 欧美视频在线一区二区三区 | 国产农村妇女毛片精品久久麻豆| 国产在线精品免费av| 国产亚洲婷婷免费| 成人av在线资源网站| 亚洲视频一二区| 欧美性猛交xxxxxx富婆| 午夜精品国产更新| 日韩午夜精品电影| 成人午夜激情视频| 一区二区欧美视频| 91精品国产综合久久久久久久 | 国产精品电影一区二区三区| 91视频在线看| 五月天欧美精品| 欧美videos大乳护士334| 国产麻豆视频一区二区| 国产精品久久久久久久久免费桃花 | 日韩欧美国产电影| 国产在线精品免费| 一区二区三区在线视频观看58| 欧美绝品在线观看成人午夜影视| 韩国欧美国产一区| 亚洲手机成人高清视频| 日韩一二三区视频| 91看片淫黄大片一级在线观看| 亚洲国产日韩一区二区| 久久久久久久性| 在线精品视频一区二区| 国产一区二区三区日韩| 一区二区三区四区视频精品免费 | 尤物av一区二区| 精品国产乱码久久久久久久| caoporm超碰国产精品| 日韩国产精品91| 亚洲欧洲色图综合| 精品99999| 91成人免费在线视频| 国产成人综合视频| 日韩成人av影视| 亚洲精品视频在线观看网站| 欧美一区二区三区四区在线观看| 成人激情免费电影网址| 日本成人在线一区| 一区二区三区蜜桃网| 精品美女一区二区三区| 欧美亚洲免费在线一区| 大白屁股一区二区视频| 久久精品72免费观看| 亚洲一区二区五区| 国产欧美一区二区三区网站| 欧美成人欧美edvon| 欧美日韩一区二区三区在线| 99这里只有久久精品视频| 国内精品在线播放| 日本欧美久久久久免费播放网| 亚洲久草在线视频| 中文字幕在线不卡国产视频| 精品粉嫩超白一线天av| 欧美一区二区三区在线视频| 在线观看一区二区精品视频| 色综合天天在线| 成人精品视频一区二区三区| 久久se精品一区二区| 视频一区视频二区在线观看| 亚洲国产成人av好男人在线观看| 国产欧美精品在线观看| 久久久久国产精品免费免费搜索| 精品日韩av一区二区| 日韩欧美中文字幕精品| 欧美人体做爰大胆视频| 精品视频在线视频| 在线免费观看一区| 色噜噜狠狠成人中文综合| 欧洲精品中文字幕| 色综合久久精品| 欧美在线视频全部完| 91精品福利视频| 欧美日韩国产首页| 3d动漫精品啪啪| 日韩欧美国产成人一区二区| 欧美大度的电影原声| 精品日韩av一区二区| 国产三级精品在线| 国产精品欧美综合在线| 亚洲人成网站精品片在线观看 | 蜜臀久久久久久久| 美脚の诱脚舐め脚责91| 精品一区二区三区视频在线观看| 国产一区二区女| 国产成人aaa| 一本大道综合伊人精品热热| 欧美在线影院一区二区| 欧美一二区视频| 久久久电影一区二区三区| 国产精品成人一区二区艾草 | 精品一区免费av| 国产成人av在线影院| 色婷婷精品久久二区二区蜜臀av| 欧美写真视频网站| 精品少妇一区二区三区| 国产精品福利一区| 日本中文字幕不卡| 国产成人在线视频网址| 欧美艳星brazzers| 日韩你懂的在线播放| 中文字幕一区二区三区四区 | 亚洲精品免费看| 日韩激情av在线| 国产寡妇亲子伦一区二区| 色系网站成人免费| 日韩欧美在线1卡| 亚洲色图20p| 精品亚洲成a人| 色视频欧美一区二区三区| 精品国产一区二区三区久久影院| 国产精品免费人成网站| 日韩福利电影在线观看| 成人精品免费看| 91精品久久久久久蜜臀| 欧美高清在线一区| 日本欧美一区二区在线观看| 成人91在线观看| 精品蜜桃在线看| 亚洲国产精品久久一线不卡| 国产激情一区二区三区桃花岛亚洲| 色播五月激情综合网| 久久久久久久久久电影| 日本亚洲电影天堂| 91网址在线看| 中文字幕欧美激情一区| 美女免费视频一区二区| 欧美日本在线看| 亚洲欧洲制服丝袜| 成人丝袜视频网| 国产女同互慰高潮91漫画| 免费高清视频精品| 欧美亚洲一区三区| 亚洲三级免费电影| 成人动漫一区二区在线| 26uuu久久天堂性欧美| 青青草国产成人av片免费| 一本到不卡免费一区二区| 国产精品精品国产色婷婷| 国产麻豆成人传媒免费观看| 欧美一级片免费看| 五月激情综合色| 欧美三区在线视频| 亚洲精品第1页| 色欧美乱欧美15图片| 中文字幕一区二区三区视频| 国产999精品久久久久久| 久久美女高清视频| 国产一区激情在线| 久久久99久久| 成人激情视频网站| 国产精品久线观看视频| 成人免费高清在线| 中文字幕中文字幕中文字幕亚洲无线| 国产麻豆精品视频|