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

📄 gparamspec.sgml

📁 This GLib version 2.16.1. GLib is the low-level core library that forms the basis for projects such
💻 SGML
📖 第 1 页 / 共 2 页
字号:
the transformed @dest_value complied to @pspec without modifications.See also g_value_type_transformable(), g_value_transform() andg_param_value_validate().</para>@pspec:             a valid #GParamSpec@src_value:         souce #GValue@dest_value:        destination #GValue of correct type for @pspec@strict_validation: %TRUE requires @dest_value to conform to @pspec without modifications@Returns:           %TRUE if transformation and validation were successful,                    %FALSE otherwise and @dest_value is left untouched.<!-- ##### FUNCTION g_param_values_cmp ##### --><para>Compares @value1 with @value2 according to @pspec, and return -1, 0 or +1,if @value1 is found to be less than, equal to or greater than @value2, respectively.</para>@pspec:   a valid #GParamSpec@value1:  a #GValue of correct type for @pspec@value2:  a #GValue of correct type for @pspec@Returns: -1, 0 or +1, for a less than, equal to or greater than result<!-- ##### FUNCTION g_param_spec_get_name ##### --><para>Returns the name of a #GParamSpec.</para>@pspec: a valid #GParamSpec@Returns: the name of @pspec.<!-- ##### FUNCTION g_param_spec_get_nick ##### --><para>Returns the nickname of a #GParamSpec.</para>@pspec: a valid #GParamSpec@Returns: the nickname of @pspec.<!-- ##### FUNCTION g_param_spec_get_blurb ##### --><para>Returns the short description of a #GParamSpec.</para>@pspec: a valid #GParamSpec@Returns: the short description of @pspec.<!-- ##### FUNCTION g_param_spec_get_qdata ##### --><para>Gets back user data pointers stored via g_param_spec_set_qdata().</para>@pspec: a valid #GParamSpec@quark: a #GQuark, naming the user data pointer@Returns: the user data pointer set, or %NULL<!-- ##### FUNCTION g_param_spec_set_qdata ##### --><para>Sets an opaque, named pointer on a #GParamSpec. The name is specified through a #GQuark (retrieved e.g. via g_quark_from_static_string()), and the pointer can be gotten back from the @pspec with g_param_spec_get_qdata().Setting a previously set user data pointer, overrides (frees)the old pointer set, using %NULL as pointer essentiallyremoves the data stored.</para>@pspec: the #GParamSpec to set store a user data pointer@quark: a #GQuark, naming the user data pointer@data: an opaque user data pointer<!-- ##### FUNCTION g_param_spec_set_qdata_full ##### --><para>This function works like g_param_spec_set_qdata(), but in addition, a <literal>void (*destroy) (gpointer)</literal> function may be specified which is called with @data as argument when the @pspec is finalized, or the data is being overwritten by a call to g_param_spec_set_qdata() with the same @quark.</para>@pspec:   the #GParamSpec to set store a user data pointer@quark:   a #GQuark, naming the user data pointer@data:    an opaque user data pointer@destroy: function to invoke with @data as argument, when @data needs to          be freed<!-- ##### FUNCTION g_param_spec_steal_qdata ##### --><para>Gets back user data pointers stored via g_param_spec_set_qdata() and removes the @data from @pspec without invoking it's destroy() function (if any was set).Usually, calling this function is only required to updateuser data pointers with a destroy notifier.</para>@pspec: the #GParamSpec to get a stored user data pointer from@quark: a #GQuark, naming the user data pointer@Returns: the user data pointer set, or %NULL<!-- ##### FUNCTION g_param_spec_get_redirect_target ##### --><para>If the paramspec redirects operations to another paramspec,returns that paramspec. Redirect is used typically forproviding a new implementation of a property in a derivedtype while preserving all the properties from the parenttype. Redirection is established by creating a propertyof type #GParamSpecOverride. See g_object_class_override_property()for an example of the use of this capability.</para>@pspec: a #GParamSpec@Returns: paramspec to which requests on this paramspec should  be redirected, or %NULL if none.@Since: 2.4<!-- ##### FUNCTION g_param_spec_internal ##### --><para>Creates a new #GParamSpec instance.</para><para>A property name consists of segments consisting of ASCII letters anddigits, separated by either the '-' or '_' character. The firstcharacter of a property name must be a letter. Names which violate theserules lead to undefined behaviour. </para><para>When creating and looking up a #GParamSpec, either separator can be used, but they cannot be mixed. Using '-' is considerably more efficient and in fact required when using property names as detail strings for signals.</para>@param_type: the #GType for the property; must be derived from #G_TYPE_PARAM@name: the canonical name of the property@nick: the nickname of the property@blurb: a short description of the property@flags: a combination of #GParamFlags@Returns: a newly allocated #GParamSpec instance<!-- ##### STRUCT GParamSpecTypeInfo ##### --><para>This structure is used to provide the type system with the informationrequired to initialize and destruct (finalize) a parameter's class andinstances thereof.The initialized structure is passed to the g_param_type_register_static() The type system will perform a deep copy of this structure, so it's memory does not need to be persistent across invocation of g_param_type_register_static().</para>@instance_size: Size of the instance (object) structure.@n_preallocs: Prior to GLib 2.10, it specified the number of pre-allocated (cached) instances to reserve memory for (0 indicates no caching). Since GLib 2.10, it is ignored, since instances are allocated with the <link linkend="glib-Memory-Slices">slice allocator</link> now.@instance_init: Location of the instance initialization function (optional).@value_type: The #GType of values conforming to this #GParamSpec@finalize: The instance finalization function (optional).@value_set_default: Resets a @value to the default value for @pspec   (recommended, the default is g_value_reset()), see   g_param_value_set_default().@value_validate: Ensures that the contents of @value comply with the   specifications set out by @pspec (optional), see   g_param_value_set_validate().@values_cmp: Compares @value1 with @value2 according to @pspec   (recommended, the default is memcmp()), see g_param_values_cmp().<!-- ##### FUNCTION g_param_type_register_static ##### --><para>Registers @name as the name of a new static type derived from#G_TYPE_PARAM. The type system uses the information contained in the#GParamSpecTypeInfo structure pointed to by @info to manage the #GParamSpec type and its instances. </para>@name: 0-terminated string used as the name of the new #GParamSpec type.@pspec_info: The #GParamSpecTypeInfo for this #GParamSpec type.@Returns: The new type identifier.<!-- ##### STRUCT GParamSpecPool ##### --><para>A #GParamSpecPool maintains a collection of #GParamSpec<!-- -->s which can bequickly accessed by owner and name. The implementation of the #GObject propertysystem uses such a pool to store the #GParamSpecs of the properties all objecttypes. </para><!-- ##### FUNCTION g_param_spec_pool_new ##### --><para>Creates a new #GParamSpecPool.</para><para>If @type_prefixing is %TRUE, lookups in the newly created pool willallow to specify the owner as a colon-separated prefix of the property name, like "GtkContainer:border-width". This feature is deprecated, so you should always set @type_prefixing to %FALSE.</para>@type_prefixing: Whether the pool will support type-prefixed property names.@Returns: a newly allocated #GParamSpecPool.<!-- ##### FUNCTION g_param_spec_pool_insert ##### --><para>Inserts a #GParamSpec in the pool.</para>@pool: a #GParamSpecPool.@pspec: the #GParamSpec to insert@owner_type: a #GType identifying the owner of @pspec<!-- ##### FUNCTION g_param_spec_pool_remove ##### --><para>Removes a #GParamSpec from the pool.</para>@pool: a #GParamSpecPool@pspec: the #GParamSpec to remove<!-- ##### FUNCTION g_param_spec_pool_lookup ##### --><para>Looks up a #GParamSpec in the pool.</para>@pool: a #GParamSpecPool@param_name: the name to look for@owner_type: the owner to look for@walk_ancestors: If %TRUE, also try to find a #GParamSpec with @param_name   owned by an ancestor of @owner_type.@Returns: The found #GParamSpec, or %NULL if no matching #GParamSpec was found.<!-- ##### FUNCTION g_param_spec_pool_list ##### --><para>Gets an array of all #GParamSpec<!-- -->s owned by @owner_type in the pool. </para>@pool: a #GParamSpecPool@owner_type: the owner to look for@n_pspecs_p: return location for the length of the returned array@Returns: a newly allocated array containing pointers to all   #GParamSpec<!-- -->s owned by @owner_type in the pool<!-- ##### FUNCTION g_param_spec_pool_list_owned ##### --><para>Gets an #GList of all #GParamSpec<!-- -->s owned by @owner_type in the pool. </para>@pool: a #GParamSpecPool@owner_type: the owner to look for@Returns: a #GList of all #GParamSpec<!-- -->s owned by @owner_type in   the pool#GParamSpec<!-- -->s.

⌨️ 快捷键说明

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