pythonpygobjectgtksourceview

How can I load a style in GtkSourceView in python?


How can I load a new style in a GtkSourceView ?

In Gedit I can see it lists the styles found in /usr/share/gtksourceview-3.0/styles, how can I get my own GtkSourceView to load one of these styles ?


Solution

  • Use the set_style_scheme() method. Style schemes can be obtained from the default GtkSource.StyleSchemeManager object.