CSS-like styling for widgets, implementing the StyleProvider base class.  
 More...
|  | 
| virtual | ~CssProvider () | 
|  | 
| GtkCssProvider* | gobj () | 
|  | Provides access to the underlying C GObject.  More... 
 | 
|  | 
| const GtkCssProvider* | gobj () const | 
|  | Provides access to the underlying C GObject.  More... 
 | 
|  | 
| GtkCssProvider* | gobj_copy () | 
|  | Provides access to the underlying C instance. The caller is responsible for unrefing it. Use when directly setting fields in structs.  More... 
 | 
|  | 
| Glib::ustring | to_string () const | 
|  | Convertes the provider into a string representation in CSS format.  More... 
 | 
|  | 
| bool | load_from_data (const std::string& data) | 
|  | Loads data into this css provider, making it clear any previously loaded information.  More... 
 | 
|  | 
| bool | load_from_file (const Glib::RefPtr< const Gio::File >& file) | 
|  | Loads the data contained in file into css_provider, making it clear any previously loaded information.  More... 
 | 
|  | 
| bool | load_from_path (const std::string& path) | 
|  | Loads the data contained in path into css_provider, making it clear any previously loaded information.  More... 
 | 
|  | 
| virtual | ~StyleProvider () | 
|  | 
| GtkStyleProvider* | gobj () | 
|  | Provides access to the underlying C GObject.  More... 
 | 
|  | 
| const GtkStyleProvider* | gobj () const | 
|  | Provides access to the underlying C GObject.  More... 
 | 
|  | 
CSS-like styling for widgets, implementing the StyleProvider base class. 
It is able to parse CSS-like input in order to style widgets.
An application can cause GTK+ to parse a specific CSS style sheet by calling load_from_file() and adding the provider with StyleContext::add_provider() or StyleContext::add_provider_for_screen(). In addition, certain files will be read when GTK+ is initialized. See the GtkCssProvider documentation for details of these default files and details of the stylesheets.
- Since gtkmm 3.0:
  
  | 
        
          | virtual Gtk::CssProvider::~CssProvider | ( |  | ) |  |  | virtual | 
 
 
  
  | 
        
          | Gtk::CssProvider::CssProvider | ( |  | ) |  |  | protected | 
 
 
Returns the provider containing the style settings used as a fallback for all widgets. 
- Returns
- The provider used for fallback styling. This memory is owned by GTK+, and you must not free it. 
 
 
Loads a theme from the usual theme paths. 
- Parameters
- 
  
    | name | A theme name. |  | variant | Variant to load, for example, "dark", or 0for the default. |  
 
- Returns
- A Gtk::CssProvider with the theme loaded. This memory is owned by GTK+, and you must not free it. 
 
 
  
  | 
        
          | static GType Gtk::CssProvider::get_type | ( |  | ) |  |  | static | 
 
Get the GType for this class, for use with the underlying GObject type system. 
 
 
  
  | 
        
          | GtkCssProvider* Gtk::CssProvider::gobj | ( |  | ) |  |  | inline | 
 
Provides access to the underlying C GObject. 
 
 
  
  | 
        
          | const GtkCssProvider* Gtk::CssProvider::gobj | ( |  | ) | const |  | inline | 
 
Provides access to the underlying C GObject. 
 
 
      
        
          | GtkCssProvider* Gtk::CssProvider::gobj_copy | ( |  | ) |  | 
      
 
Provides access to the underlying C instance. The caller is responsible for unrefing it. Use when directly setting fields in structs. 
 
 
      
        
          | bool Gtk::CssProvider::load_from_data | ( | const std::string & | data | ) |  | 
      
 
Loads data into this css provider, making it clear any previously loaded information. 
- Parameters
- 
  
    | data | CSS data loaded in memory. |  
 
- Returns
- True if the data could be loaded. 
 
 
Loads the data contained in file into css_provider, making it clear any previously loaded information. 
- Parameters
- 
  
    | file | File pointing to a file to load. |  
 
- Returns
- true. The return value is deprecated and- falsewill only be returned for backwards compatibility reasons if an error is not- 0and a loading error occured. To track errors while loading CSS, connect to the GtkCssProvider::parsing-error signal.
 
 
      
        
          | bool Gtk::CssProvider::load_from_path | ( | const std::string & | path | ) |  | 
      
 
Loads the data contained in path into css_provider, making it clear any previously loaded information. 
- Parameters
- 
  
    | path | The path of a filename to load, in the GLib filename encoding. |  
 
- Returns
- true. The return value is deprecated and- falsewill only be returned for backwards compatibility reasons if an error is not- 0and a loading error occured. To track errors while loading CSS, connect to the GtkCssProvider::parsing-error signal.
 
 
Convertes the provider into a string representation in CSS format. 
Using load_from_data() with the return value from this function on a new provider created with new() will basicallu create a duplicate of this provider.
- Since gtkmm 3.2:
- Returns
- A new string representing the provider. 
 
 
A Glib::wrap() method for this object. 
- Parameters
- 
  
    | object | The C instance. |  | take_copy | False if the result should take ownership of the C instance. True if it should take a new copy or ref. |  
 
- Returns
- A C++ instance that wraps this C instance. 
 
 
The documentation for this class was generated from the following file: