亚洲欧美第一页_禁久久精品乱码_粉嫩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一区二区三区免费野_久草精品视频
日韩精品一区在线观看| 亚洲国产日韩a在线播放| 亚洲精品菠萝久久久久久久| 麻豆成人91精品二区三区| 国产不卡免费视频| 91精品国产高清一区二区三区 | 成人av资源网站| 日韩网站在线看片你懂的| 亚洲欧美色一区| 成人美女视频在线看| 精品欧美一区二区在线观看| 亚洲国产日韩在线一区模特| aa级大片欧美| 欧美高清在线视频| 国产曰批免费观看久久久| 欧美亚洲免费在线一区| 国产精品短视频| 国产99久久久国产精品| 久久蜜桃av一区二区天堂| 青青草国产成人av片免费| 色婷婷综合久久久久中文| 国产精品免费视频网站| 国产经典欧美精品| 久久久久久久久岛国免费| 精品一区二区三区久久久| 欧美美女直播网站| 亚洲国产日韩a在线播放性色| 色天天综合色天天久久| 中文字幕不卡在线| k8久久久一区二区三区| 国产精品高清亚洲| av电影在线观看一区| 国产精品色在线观看| 国产精品亚洲一区二区三区妖精| 精品三级av在线| 国产乱妇无码大片在线观看| 久久免费视频一区| 成人伦理片在线| 国产精品看片你懂得| 91色在线porny| 一区二区日韩av| 欧美日精品一区视频| 日韩精品一卡二卡三卡四卡无卡| 欧美日韩在线直播| 六月丁香婷婷久久| 国产日本欧美一区二区| 99久久久无码国产精品| 一区二区日韩电影| 日韩视频国产视频| 国产激情视频一区二区在线观看 | 欧美电影影音先锋| 热久久免费视频| 久久精品无码一区二区三区| 成人一区二区三区中文字幕| 亚洲欧美在线aaa| 欧美在线一区二区| 激情图片小说一区| 亚洲欧洲美洲综合色网| 欧美日韩综合在线免费观看| 国产主播一区二区三区| 亚洲天堂a在线| 91麻豆精品国产| 国产白丝精品91爽爽久久| 亚洲黄色av一区| 2019国产精品| 91黄色免费观看| 国产一区二区电影| 亚洲gay无套男同| 欧美激情一区二区三区不卡| 欧美亚洲综合久久| 国产一区二区免费视频| 亚洲一二三级电影| 国产网红主播福利一区二区| 欧美日韩视频在线一区二区| 国产精品亚洲第一区在线暖暖韩国| 亚洲欧美日韩中文播放| 精品精品欲导航| 色综合欧美在线视频区| 91官网在线观看| 麻豆久久久久久久| 亚洲小说春色综合另类电影| 久久久久久久精| 欧美一三区三区四区免费在线看| 成人久久久精品乱码一区二区三区| 亚洲影院在线观看| 国产免费成人在线视频| 日韩视频免费观看高清完整版| 色综合天天综合给合国产| 国产福利91精品一区二区三区| 日韩av午夜在线观看| 亚洲男人电影天堂| 日本一二三不卡| www成人在线观看| 欧美三级欧美一级| 一本大道av伊人久久综合| 国产一区激情在线| 麻豆精品在线看| 亚洲va韩国va欧美va精品| 亚洲人成在线观看一区二区| 久久精品水蜜桃av综合天堂| 欧美成人性福生活免费看| 在线视频观看一区| 99riav久久精品riav| 成人手机在线视频| 国产乱淫av一区二区三区| 久久国产精品99久久久久久老狼| 亚洲福利国产精品| 亚洲视频一二区| 中文在线一区二区| 日本一区二区电影| 国产精品久久久久久久久免费相片| xvideos.蜜桃一区二区| 日韩三级精品电影久久久| 欧美一级免费观看| 91精品国产综合久久国产大片 | 不卡av在线免费观看| 欧美日本在线观看| 欧美在线免费观看亚洲| 一道本成人在线| 91福利在线免费观看| 欧美亚洲精品一区| 欧美乱妇一区二区三区不卡视频| 欧美日韩另类一区| 91精品国产日韩91久久久久久| 91精品国产综合久久精品麻豆| 欧美亚洲另类激情小说| 56国语精品自产拍在线观看| 欧美一级片在线看| 久久影院视频免费| 中文字幕制服丝袜一区二区三区| 成人欧美一区二区三区小说| 亚洲精品免费播放| 日韩国产在线观看一区| 激情欧美日韩一区二区| 成人一道本在线| 91视视频在线观看入口直接观看www| 97aⅴ精品视频一二三区| 精品婷婷伊人一区三区三| 欧美一级夜夜爽| 日本一区免费视频| 亚洲一区二区精品3399| 九色|91porny| 色视频一区二区| 日韩一卡二卡三卡| 中文在线一区二区| 亚洲第一狼人社区| 国产高清在线观看免费不卡| 91小视频在线观看| 日韩三级视频在线观看| 国产精品麻豆视频| 麻豆国产精品一区二区三区| aaa国产一区| 欧美一区二区高清| 亚洲视频你懂的| 九九视频精品免费| 欧美在线一二三四区| 久久一留热品黄| 午夜伊人狠狠久久| av亚洲精华国产精华| 91精品国产综合久久久久久久久久| 久久九九全国免费| 日本亚洲最大的色成网站www| 成人av在线播放网址| 日韩视频一区二区三区在线播放| 国产精品久久网站| 免费观看91视频大全| 91美女片黄在线观看| 精品国产乱码久久久久久图片 | 亚洲成人先锋电影| 国产成人午夜99999| 欧美一区二区网站| 亚洲国产欧美另类丝袜| av一区二区三区黑人| 视频一区在线播放| 色婷婷综合五月| 国产精品久久久久三级| 国产一级精品在线| 欧美一区二区三区婷婷月色| 亚洲一区二区三区四区在线免费观看 | 亚洲激情自拍偷拍| 成人免费看片app下载| 久久久久久免费毛片精品| 日韩成人一级大片| 欧美日韩国产成人在线91| 一区二区在线电影| caoporn国产一区二区| 国产精品久久午夜| 成人黄色电影在线| 中文字幕在线视频一区| 国产凹凸在线观看一区二区| 久久精品夜色噜噜亚洲aⅴ| 国产综合久久久久久久久久久久| 日韩一区二区三区免费观看| 午夜日韩在线观看| 欧美日韩一区三区| 天天影视涩香欲综合网| 91精品中文字幕一区二区三区| 天天亚洲美女在线视频| 欧美夫妻性生活| 蜜桃av一区二区|