glib/auto/constants.rs
1// This file was generated by gir (https://github.com/gtk-rs/gir)
2// from gir-files (https://github.com/gtk-rs/gir-files)
3// DO NOT EDIT
4
5use crate::{GStr, ffi};
6
7/// The set of uppercase ASCII alphabet characters.
8/// Used for specifying valid identifier characters
9/// in #GScannerConfig.
10#[doc(alias = "G_CSET_A_2_Z")]
11pub static CSET_A_2_Z: &GStr = unsafe { GStr::from_utf8_with_nul_unchecked(ffi::G_CSET_A_2_Z) };
12/// The set of ASCII digits.
13/// Used for specifying valid identifier characters
14/// in #GScannerConfig.
15#[doc(alias = "G_CSET_DIGITS")]
16pub static CSET_DIGITS: &GStr = unsafe { GStr::from_utf8_with_nul_unchecked(ffi::G_CSET_DIGITS) };
17/// The set of lowercase ASCII alphabet characters.
18/// Used for specifying valid identifier characters
19/// in #GScannerConfig.
20#[doc(alias = "G_CSET_a_2_z")]
21pub static CSET_a_2_z: &GStr = unsafe { GStr::from_utf8_with_nul_unchecked(ffi::G_CSET_a_2_z) };
22/// The name of the main group of a desktop entry file, as defined in the
23/// [Desktop Entry Specification](https://specifications.freedesktop.org/desktop-entry-spec/latest/).
24///
25/// Consult the specification for more
26/// details about the meanings of the keys below.
27#[doc(alias = "G_KEY_FILE_DESKTOP_GROUP")]
28pub static KEY_FILE_DESKTOP_GROUP: &GStr =
29 unsafe { GStr::from_utf8_with_nul_unchecked(ffi::G_KEY_FILE_DESKTOP_GROUP) };
30/// A key under `GLib::KEY_FILE_DESKTOP_GROUP`, whose value is a string list
31/// giving the available application actions.
32#[doc(alias = "G_KEY_FILE_DESKTOP_KEY_ACTIONS")]
33pub static KEY_FILE_DESKTOP_KEY_ACTIONS: &GStr =
34 unsafe { GStr::from_utf8_with_nul_unchecked(ffi::G_KEY_FILE_DESKTOP_KEY_ACTIONS) };
35/// A key under `GLib::KEY_FILE_DESKTOP_GROUP`, whose value is a list
36/// of strings giving the categories in which the desktop entry
37/// should be shown in a menu.
38#[doc(alias = "G_KEY_FILE_DESKTOP_KEY_CATEGORIES")]
39pub static KEY_FILE_DESKTOP_KEY_CATEGORIES: &GStr =
40 unsafe { GStr::from_utf8_with_nul_unchecked(ffi::G_KEY_FILE_DESKTOP_KEY_CATEGORIES) };
41/// A key under `GLib::KEY_FILE_DESKTOP_GROUP`, whose value is a localized
42/// string giving the tooltip for the desktop entry.
43#[doc(alias = "G_KEY_FILE_DESKTOP_KEY_COMMENT")]
44pub static KEY_FILE_DESKTOP_KEY_COMMENT: &GStr =
45 unsafe { GStr::from_utf8_with_nul_unchecked(ffi::G_KEY_FILE_DESKTOP_KEY_COMMENT) };
46/// A key under `GLib::KEY_FILE_DESKTOP_GROUP`, whose value is a boolean
47/// set to true if the application is D-Bus activatable.
48#[doc(alias = "G_KEY_FILE_DESKTOP_KEY_DBUS_ACTIVATABLE")]
49pub static KEY_FILE_DESKTOP_KEY_DBUS_ACTIVATABLE: &GStr =
50 unsafe { GStr::from_utf8_with_nul_unchecked(ffi::G_KEY_FILE_DESKTOP_KEY_DBUS_ACTIVATABLE) };
51/// A key under `GLib::KEY_FILE_DESKTOP_GROUP`, whose value is a string
52/// giving the command line to execute.
53///
54/// It is only valid for desktop entries with the `Application` type.
55#[doc(alias = "G_KEY_FILE_DESKTOP_KEY_EXEC")]
56pub static KEY_FILE_DESKTOP_KEY_EXEC: &GStr =
57 unsafe { GStr::from_utf8_with_nul_unchecked(ffi::G_KEY_FILE_DESKTOP_KEY_EXEC) };
58/// A key under `GLib::KEY_FILE_DESKTOP_GROUP`, whose value is a localized
59/// string giving the generic name of the desktop entry.
60#[doc(alias = "G_KEY_FILE_DESKTOP_KEY_GENERIC_NAME")]
61pub static KEY_FILE_DESKTOP_KEY_GENERIC_NAME: &GStr =
62 unsafe { GStr::from_utf8_with_nul_unchecked(ffi::G_KEY_FILE_DESKTOP_KEY_GENERIC_NAME) };
63/// A key under `GLib::KEY_FILE_DESKTOP_GROUP`, whose value is a boolean
64/// stating whether the desktop entry has been deleted by the user.
65#[doc(alias = "G_KEY_FILE_DESKTOP_KEY_HIDDEN")]
66pub static KEY_FILE_DESKTOP_KEY_HIDDEN: &GStr =
67 unsafe { GStr::from_utf8_with_nul_unchecked(ffi::G_KEY_FILE_DESKTOP_KEY_HIDDEN) };
68/// A key under `GLib::KEY_FILE_DESKTOP_GROUP`, whose value is a localized
69/// string giving the name of the icon to be displayed for the desktop
70/// entry.
71#[doc(alias = "G_KEY_FILE_DESKTOP_KEY_ICON")]
72pub static KEY_FILE_DESKTOP_KEY_ICON: &GStr =
73 unsafe { GStr::from_utf8_with_nul_unchecked(ffi::G_KEY_FILE_DESKTOP_KEY_ICON) };
74/// A key under `GLib::KEY_FILE_DESKTOP_GROUP`, whose value is a string list
75/// giving the available intents.
76///
77/// Intents are defined in the [Intents Specification](https://specifications.freedesktop.org/intent-apps/latest/).
78#[cfg(feature = "v2_92")]
79#[cfg_attr(docsrs, doc(cfg(feature = "v2_92")))]
80#[doc(alias = "G_KEY_FILE_DESKTOP_KEY_IMPLEMENTS")]
81pub static KEY_FILE_DESKTOP_KEY_IMPLEMENTS: &GStr =
82 unsafe { GStr::from_utf8_with_nul_unchecked(ffi::G_KEY_FILE_DESKTOP_KEY_IMPLEMENTS) };
83/// A key under `GLib::KEY_FILE_DESKTOP_GROUP`, whose value is a list
84/// of strings giving the MIME types supported by this desktop entry.
85#[doc(alias = "G_KEY_FILE_DESKTOP_KEY_MIME_TYPE")]
86pub static KEY_FILE_DESKTOP_KEY_MIME_TYPE: &GStr =
87 unsafe { GStr::from_utf8_with_nul_unchecked(ffi::G_KEY_FILE_DESKTOP_KEY_MIME_TYPE) };
88/// A key under `GLib::KEY_FILE_DESKTOP_GROUP`, whose value is a localized
89/// string giving the specific name of the desktop entry.
90#[doc(alias = "G_KEY_FILE_DESKTOP_KEY_NAME")]
91pub static KEY_FILE_DESKTOP_KEY_NAME: &GStr =
92 unsafe { GStr::from_utf8_with_nul_unchecked(ffi::G_KEY_FILE_DESKTOP_KEY_NAME) };
93/// A key under `GLib::KEY_FILE_DESKTOP_GROUP`, whose value is a list of
94/// strings identifying the environments that should not display the
95/// desktop entry.
96#[doc(alias = "G_KEY_FILE_DESKTOP_KEY_NOT_SHOW_IN")]
97pub static KEY_FILE_DESKTOP_KEY_NOT_SHOW_IN: &GStr =
98 unsafe { GStr::from_utf8_with_nul_unchecked(ffi::G_KEY_FILE_DESKTOP_KEY_NOT_SHOW_IN) };
99/// A key under `GLib::KEY_FILE_DESKTOP_GROUP`, whose value is a boolean
100/// stating whether the desktop entry should be shown in menus.
101#[doc(alias = "G_KEY_FILE_DESKTOP_KEY_NO_DISPLAY")]
102pub static KEY_FILE_DESKTOP_KEY_NO_DISPLAY: &GStr =
103 unsafe { GStr::from_utf8_with_nul_unchecked(ffi::G_KEY_FILE_DESKTOP_KEY_NO_DISPLAY) };
104/// A key under `GLib::KEY_FILE_DESKTOP_GROUP`, whose value is a list of
105/// strings identifying the environments that should display the
106/// desktop entry.
107#[doc(alias = "G_KEY_FILE_DESKTOP_KEY_ONLY_SHOW_IN")]
108pub static KEY_FILE_DESKTOP_KEY_ONLY_SHOW_IN: &GStr =
109 unsafe { GStr::from_utf8_with_nul_unchecked(ffi::G_KEY_FILE_DESKTOP_KEY_ONLY_SHOW_IN) };
110/// A key under `GLib::KEY_FILE_DESKTOP_GROUP`, whose value is a string
111/// containing the working directory to run the program in.
112///
113/// It is only valid for desktop entries with the `Application` type.
114#[doc(alias = "G_KEY_FILE_DESKTOP_KEY_PATH")]
115pub static KEY_FILE_DESKTOP_KEY_PATH: &GStr =
116 unsafe { GStr::from_utf8_with_nul_unchecked(ffi::G_KEY_FILE_DESKTOP_KEY_PATH) };
117/// A key under `GLib::KEY_FILE_DESKTOP_GROUP`, whose value is a boolean
118/// stating whether the application supports the
119/// [Startup Notification Protocol Specification](https://specifications.freedesktop.org/startup-notification-spec/latest/).
120#[doc(alias = "G_KEY_FILE_DESKTOP_KEY_STARTUP_NOTIFY")]
121pub static KEY_FILE_DESKTOP_KEY_STARTUP_NOTIFY: &GStr =
122 unsafe { GStr::from_utf8_with_nul_unchecked(ffi::G_KEY_FILE_DESKTOP_KEY_STARTUP_NOTIFY) };
123/// A key under `GLib::KEY_FILE_DESKTOP_GROUP`, whose value is string
124/// identifying the WM class or name hint of a window that the application
125/// will create, which can be used to emulate
126/// [Startup Notification](https://specifications.freedesktop.org/startup-notification-spec/latest/)
127/// with older applications.
128#[doc(alias = "G_KEY_FILE_DESKTOP_KEY_STARTUP_WM_CLASS")]
129pub static KEY_FILE_DESKTOP_KEY_STARTUP_WM_CLASS: &GStr =
130 unsafe { GStr::from_utf8_with_nul_unchecked(ffi::G_KEY_FILE_DESKTOP_KEY_STARTUP_WM_CLASS) };
131/// A key under `GLib::KEY_FILE_DESKTOP_GROUP`, whose value is a boolean
132/// stating whether the program should be run in a terminal window.
133///
134/// It is only valid for desktop entries with the `Application` type.
135#[doc(alias = "G_KEY_FILE_DESKTOP_KEY_TERMINAL")]
136pub static KEY_FILE_DESKTOP_KEY_TERMINAL: &GStr =
137 unsafe { GStr::from_utf8_with_nul_unchecked(ffi::G_KEY_FILE_DESKTOP_KEY_TERMINAL) };
138/// A key under `GLib::KEY_FILE_DESKTOP_GROUP`, whose value is a string
139/// giving the file name of a binary on disk used to determine if the
140/// program is actually installed.
141///
142/// It is only valid for desktop entries with the `Application` type.
143#[doc(alias = "G_KEY_FILE_DESKTOP_KEY_TRY_EXEC")]
144pub static KEY_FILE_DESKTOP_KEY_TRY_EXEC: &GStr =
145 unsafe { GStr::from_utf8_with_nul_unchecked(ffi::G_KEY_FILE_DESKTOP_KEY_TRY_EXEC) };
146/// A key under `GLib::KEY_FILE_DESKTOP_GROUP`, whose value is a string
147/// giving the type of the desktop entry.
148///
149/// Usually `GLib::KEY_FILE_DESKTOP_TYPE_APPLICATION`,
150/// `GLib::KEY_FILE_DESKTOP_TYPE_LINK`, or
151/// `GLib::KEY_FILE_DESKTOP_TYPE_DIRECTORY`.
152#[doc(alias = "G_KEY_FILE_DESKTOP_KEY_TYPE")]
153pub static KEY_FILE_DESKTOP_KEY_TYPE: &GStr =
154 unsafe { GStr::from_utf8_with_nul_unchecked(ffi::G_KEY_FILE_DESKTOP_KEY_TYPE) };
155/// A key under `GLib::KEY_FILE_DESKTOP_GROUP`, whose value is a string
156/// giving the URL to access.
157///
158/// It is only valid for desktop entries with the `Link` type.
159#[doc(alias = "G_KEY_FILE_DESKTOP_KEY_URL")]
160pub static KEY_FILE_DESKTOP_KEY_URL: &GStr =
161 unsafe { GStr::from_utf8_with_nul_unchecked(ffi::G_KEY_FILE_DESKTOP_KEY_URL) };
162/// A key under `GLib::KEY_FILE_DESKTOP_GROUP`, whose value is a string
163/// giving the version of the Desktop Entry Specification used for
164/// the desktop entry file.
165#[doc(alias = "G_KEY_FILE_DESKTOP_KEY_VERSION")]
166pub static KEY_FILE_DESKTOP_KEY_VERSION: &GStr =
167 unsafe { GStr::from_utf8_with_nul_unchecked(ffi::G_KEY_FILE_DESKTOP_KEY_VERSION) };
168/// The value of the `GLib::KEY_FILE_DESKTOP_KEY_TYPE`, key for desktop
169/// entries representing applications.
170#[doc(alias = "G_KEY_FILE_DESKTOP_TYPE_APPLICATION")]
171pub static KEY_FILE_DESKTOP_TYPE_APPLICATION: &GStr =
172 unsafe { GStr::from_utf8_with_nul_unchecked(ffi::G_KEY_FILE_DESKTOP_TYPE_APPLICATION) };
173/// The value of the `GLib::KEY_FILE_DESKTOP_KEY_TYPE`, key for desktop
174/// entries representing directories.
175#[doc(alias = "G_KEY_FILE_DESKTOP_TYPE_DIRECTORY")]
176pub static KEY_FILE_DESKTOP_TYPE_DIRECTORY: &GStr =
177 unsafe { GStr::from_utf8_with_nul_unchecked(ffi::G_KEY_FILE_DESKTOP_TYPE_DIRECTORY) };
178/// The value of the `GLib::KEY_FILE_DESKTOP_KEY_TYPE`, key for desktop
179/// entries representing links to documents.
180#[doc(alias = "G_KEY_FILE_DESKTOP_TYPE_LINK")]
181pub static KEY_FILE_DESKTOP_TYPE_LINK: &GStr =
182 unsafe { GStr::from_utf8_with_nul_unchecked(ffi::G_KEY_FILE_DESKTOP_TYPE_LINK) };
183/// If a long option in the main group has this name, it is not treated as a
184/// regular option. Instead it collects all non-option arguments which would
185/// otherwise be left in `argv`. The option must be of type
186/// [`OptionArg::Callback`][crate::OptionArg::Callback], [`OptionArg::StringArray`][crate::OptionArg::StringArray]
187/// or [`OptionArg::FilenameArray`][crate::OptionArg::FilenameArray].
188///
189///
190/// Using [`OPTION_REMAINING`][crate::OPTION_REMAINING] instead of simply scanning `argv`
191/// for leftover arguments has the advantage that GOption takes care of
192/// necessary encoding conversions for strings or filenames.
193#[doc(alias = "G_OPTION_REMAINING")]
194pub static OPTION_REMAINING: &GStr =
195 unsafe { GStr::from_utf8_with_nul_unchecked(ffi::G_OPTION_REMAINING) };
196/// The standard delimiters, used in `strdelimit()`.
197#[doc(alias = "G_STR_DELIMITERS")]
198pub static STR_DELIMITERS: &GStr =
199 unsafe { GStr::from_utf8_with_nul_unchecked(ffi::G_STR_DELIMITERS) };
200/// A value that can be passed as an option to `test_init()`.
201///
202/// Creates a unique temporary directory for each unit test and uses sets
203/// XDG directories to point into subdirectories of it for the duration of
204/// the unit test. The directory tree is cleaned up after the test finishes
205/// successfully.
206///
207/// Note that this doesn’t take effect until `test_run()` is called,
208/// so calls to (for example) [`home_dir()`][crate::home_dir()] will return the
209/// system-wide value when made in a test program’s main() function.
210///
211/// The following functions will return subdirectories of the temporary directory
212/// when this option is used. The specific subdirectory paths in use are not
213/// guaranteed to be stable API — always use a getter function to retrieve them.
214///
215/// - [`home_dir()`][crate::home_dir()]
216/// - [`user_cache_dir()`][crate::user_cache_dir()]
217/// - [`system_config_dirs()`][crate::system_config_dirs()]
218/// - [`user_config_dir()`][crate::user_config_dir()]
219/// - [`system_data_dirs()`][crate::system_data_dirs()]
220/// - [`user_data_dir()`][crate::user_data_dir()]
221/// - [`user_state_dir()`][crate::user_state_dir()]
222/// - [`user_runtime_dir()`][crate::user_runtime_dir()]
223///
224/// The subdirectories may not be created by the test harness; as with normal
225/// calls to functions like [`user_cache_dir()`][crate::user_cache_dir()], the caller must
226/// be prepared to create the directory if it doesn’t exist.
227#[cfg(feature = "v2_60")]
228#[cfg_attr(docsrs, doc(cfg(feature = "v2_60")))]
229#[doc(alias = "G_TEST_OPTION_ISOLATE_DIRS")]
230pub static TEST_OPTION_ISOLATE_DIRS: &GStr =
231 unsafe { GStr::from_utf8_with_nul_unchecked(ffi::G_TEST_OPTION_ISOLATE_DIRS) };
232/// A value that can be passed as an option to `test_init()`.
233///
234/// If this option is given, assertions will not abort the process, but
235/// call `test_fail()`. Equivalent to `test_set_nonfatal_assertions()`.
236#[cfg(feature = "v2_84")]
237#[cfg_attr(docsrs, doc(cfg(feature = "v2_84")))]
238#[doc(alias = "G_TEST_OPTION_NONFATAL_ASSERTIONS")]
239pub static TEST_OPTION_NONFATAL_ASSERTIONS: &GStr =
240 unsafe { GStr::from_utf8_with_nul_unchecked(ffi::G_TEST_OPTION_NONFATAL_ASSERTIONS) };
241/// A value that can be passed as an option to `test_init()`.
242///
243/// If this option is given, `test_init()` will not call `set_prgname()`.
244#[cfg(feature = "v2_84")]
245#[cfg_attr(docsrs, doc(cfg(feature = "v2_84")))]
246#[doc(alias = "G_TEST_OPTION_NO_PRGNAME")]
247pub static TEST_OPTION_NO_PRGNAME: &GStr =
248 unsafe { GStr::from_utf8_with_nul_unchecked(ffi::G_TEST_OPTION_NO_PRGNAME) };
249/// Generic delimiters characters as defined in
250/// [RFC 3986](https://tools.ietf.org/html/rfc3986). Includes `:/?#[]@`.
251#[doc(alias = "G_URI_RESERVED_CHARS_GENERIC_DELIMITERS")]
252pub static URI_RESERVED_CHARS_GENERIC_DELIMITERS: &GStr =
253 unsafe { GStr::from_utf8_with_nul_unchecked(ffi::G_URI_RESERVED_CHARS_GENERIC_DELIMITERS) };
254/// Subcomponent delimiter characters as defined in
255/// [RFC 3986](https://tools.ietf.org/html/rfc3986). Includes `!$&'()*+,;=`.
256#[doc(alias = "G_URI_RESERVED_CHARS_SUBCOMPONENT_DELIMITERS")]
257pub static URI_RESERVED_CHARS_SUBCOMPONENT_DELIMITERS: &GStr = unsafe {
258 GStr::from_utf8_with_nul_unchecked(ffi::G_URI_RESERVED_CHARS_SUBCOMPONENT_DELIMITERS)
259};