ThemingEngine.registerProperty

Registers a property so it can be used in the CSS file format, on the CSS file the property will look like "-${@name_space}-${property_name}". being ${property_name} the given to @pspec. @name_space will usually be the theme engine name.

For any type a @parse_func may be provided, being this function used for turning any property value (between “:” and “;”) in CSS to the #GValue needed. For basic types there is already builtin parsing support, so %NULL may be provided for these cases.

Engines must ensure property registration happens exactly once, usually GTK+ deals with theming engines as singletons, so this should be guaranteed to happen once, but bear this in mind when creating #GtkThemeEngines yourself.

In order to make use of the custom registered properties in the CSS file, make sure the engine is loaded first by specifying the engine property, either in a previous rule or within the same one. |[ * { engine: someengine; -SomeEngine-custom-property: 2; } ]|

More...
class ThemingEngine
static
void
registerProperty

Parameters

nameSpace string

namespace for the property name

parseFunc GtkStylePropertyParser

parsing function to use, or %NULL

pspec ParamSpec

the #GParamSpec for the new property

Detailed Description

Deprecated: Code should use the default properties provided by CSS.

Meta