string cssPath = "test.css";

         CssProvider provider = new CssProvider();
         provider.loadFromPath(cssPath);

unfortunately i don't know anything about yr specific problem.

but i just wanted to mention (in case you are not aware of it) that the CSS can be embedded into the D source. this is what i did to fix GTKs terrible design mistake for the background of Notebook:

```
enum myCSS = q{
    GtkNotebook {
        background-color: #e9e9e9;
    }
    GtkNotebook tab {
        background-color: #d6d6d6;
    }
};
...
int main(string[] args){
...
    import gtk.CssProvider;
    auto styleProvider = new CssProvider;
    styleProvider.loadFromData(myCSS);
    import gdk.Screen;
    import gtk.StyleContext;
StyleContext.addProviderForScreen( Screen.getDefault(), styleProvider, 800);
```

Reply via email to