gtk3-0.14.5: Binding to the Gtk+ 3 graphical user interface library

Maintainergtk2hs-users@lists.sourceforge.net
Stabilityprovisional
Portabilityportable (depends on GHC)
Safe HaskellNone
LanguageHaskell98

Graphics.UI.Gtk.General.CssProvider

Contents

Description

CSS-like styling for widgets.

Synopsis

Description

CssProvider is an object implementing the StyleProvider interface. It is able to parse CSS-like input in order to style widgets.

Types

Enums

Constructors

cssProviderNew Source #

Arguments

:: IO CssProvider

A new CssProvider

Returns a newly created CssProvider

Methods

cssProviderGetDefault Source #

Arguments

:: IO CssProvider

The provider used for fallback styling

Returns the provider containing the style settings used as a fallback for all widgets.

cssProviderGetNamed Source #

Arguments

:: GlibString string 
=> string

name : A theme name

-> Maybe string

variant to load, for example, "dark"

-> IO (Maybe CssProvider)

a CssProvider with the theme loaded

Loads a theme from the usual theme paths

cssProviderLoadFromData Source #

Arguments

:: CssProviderClass cssProvider 
=> cssProvider

cssProvider : a CssProvider

-> Ptr CChar

_data : CSS data loaded in memory. [array length=length][element-type guint8]

-> Int

length : the length of _data in bytes, or -1 for NUL terminated strings. If length is not -1, the code will assume it is not NUL terminated and will potentially do a copy.

-> IO () 

Loads _data into cssProvider, making it clear any previously loaded information.

cssProviderLoadFromString Source #

Arguments

:: (CssProviderClass cssProvider, GlibString string) 
=> cssProvider

cssProvider : a CssProvider

-> string

css : CSS data loaded in memory.

-> IO () 

Loads css into cssProvider, making it clear any previously loaded information.

cssProviderLoadFromPath Source #

Arguments

:: (CssProviderClass cssProvider, GlibFilePath fp) 
=> cssProvider

cssProvider a CssProvider

-> fp

the path of a filename to load

-> IO () 

Loads the data contained in path into cssProvider, making it clear any previously loaded information

cssProviderToString Source #

Arguments

:: (CssProviderClass cssProvider, GlibString string) 
=> cssProvider

provider a CssProvider

-> IO string 

Convertes the provider into a string representation in CSS format.

Using cssProviderLoadFromString with the return value from this function on a new provider created with cssProviderNew will basically create a duplicate of this provider.

Orphan instances