/b-gtk/fix-viz

To get this branch, use:
bzr branch http://gegoxaren.bato24.eu/bzr/b-gtk/fix-viz

« back to all changes in this revision

Viewing changes to diff.py

  • Committer: David Planella
  • Date: 2011-03-06 08:24:07 UTC
  • mfrom: (718 trunk)
  • mto: This revision was merged to the branch mainline in revision 719.
  • Revision ID: david.planella@ubuntu.com-20110306082407-y9zwkjje5oue9egw
Added preliminary internationalization support. Merged from trunk.

Show diffs side-by-side

added added

removed removed

Lines of Context:
105
105
        :param buf: a gtksourceview2.Buffer object.
106
106
        """
107
107
        GEDIT_SCHEME_PATH = '/apps/gedit-2/preferences/editor/colors/scheme'
 
108
        GEDIT_USER_STYLES_PATH = os.path.expanduser('~/.gnome2/gedit/styles')
108
109
 
109
110
        client = gconf.client_get_default()
110
111
        style_scheme_name = client.get_string(GEDIT_SCHEME_PATH)
111
112
        if style_scheme_name is not None:
112
 
            style_scheme = gtksourceview2.StyleSchemeManager().get_scheme(style_scheme_name)
113
 
            
114
 
            buf.set_style_scheme(style_scheme)
 
113
            style_scheme_mgr = gtksourceview2.StyleSchemeManager()
 
114
            style_scheme_mgr.append_search_path(GEDIT_USER_STYLES_PATH)
 
115
            
 
116
            style_scheme = style_scheme_mgr.get_scheme(style_scheme_name)
 
117
            
 
118
            if style_scheme is not None:
 
119
                buf.set_style_scheme(style_scheme)
115
120
 
116
121
    @classmethod
117
122
    def apply_colordiff_colors(klass, buf):