StyleContext.addProvider

void addProvider(gtk.style_provider.StyleProvider provider, uint priority)

Adds a style provider to context, to be used in style construction.

Note that a style provider added by this function only affects the style of the widget to which context belongs. If you want to affect the style of all widgets, use [gtk.style_context.StyleContext.addProviderForDisplay].

Note

If both priorities are the same, a [gtk.style_provider.StyleProvider]

added through this function takes precedence over another added through [gtk.style_context.StyleContext.addProviderForDisplay].

Parameters

providera [gtk.style_provider.StyleProvider]
prioritythe priority of the style provider. The lower it is, the earlier it will be used in the style construction. Typically this will be in the range between [gtk.types.STYLE_PROVIDER_PRIORITY_FALLBACK] and [gtk.types.STYLE_PROVIDER_PRIORITY_USER]

Deprecated

Use style classes instead