Changeset 5eb69bceda70…
Parent 7a7eda7adfc2…
by
Changes to one file · Browse files at 5eb69bceda70 Showing diff from parent 7a7eda7adfc2 Diff from another changeset...
@@ -90,6 +90,7 @@ self.status_error = None
self.preview_tab_name_label = None
self.subrepos = []
+ self.colorstyle = self.repo.ui.config('tortoisehg', 'diffcolorstyle')
def auto_check(self):
# Only auto-check files once, and only if a pattern was given.
@@ -1082,8 +1083,15 @@
def diff_highlight_buffer(self, difftext):
buf = gtk.TextBuffer()
- buf.create_tag('removed', foreground=gtklib.DRED)
- buf.create_tag('added', foreground=gtklib.DGREEN)
+ if self.colorstyle == 'background':
+ buf.create_tag('removed', paragraph_background=gtklib.PRED)
+ buf.create_tag('added', paragraph_background=gtklib.PGREEN)
+ elif self.colorstyle == 'none':
+ buf.create_tag('removed')
+ buf.create_tag('added')
+ else:
+ buf.create_tag('removed', foreground=gtklib.DRED)
+ buf.create_tag('added', foreground=gtklib.DGREEN)
buf.create_tag('position', foreground='#FF8000')
buf.create_tag('header', foreground=gtklib.DBLUE)
|
Loading...