[meld] sourceview: Make inline-highlighted text show whitespace (bgo#589366)
- From: Kai Willadsen <kaiw src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [meld] sourceview: Make inline-highlighted text show whitespace (bgo#589366)
- Date: Sun, 19 Nov 2017 01:09:33 +0000 (UTC)
commit f46b302fa4a8c03036029e4d0361c7d10147b824
Author: Kai Willadsen <kai willadsen gmail com>
Date: Sun Nov 19 11:04:32 2017 +1000
sourceview: Make inline-highlighted text show whitespace (bgo#589366)
The rationale here is that if your differences include whitespace, it's
probably best that you be able to see the whitespace characters. The
downside is that under normal GtkSourceView themes, the whitespace
indicators are quite low-contrast, so between that and the coloured
background in these chunks, the indicators are very difficult to see.
This is being included on a provisional basis until I decide whether
it's actually okay or whether we need to fix some stuff before it goes
in.
meld/sourceview.py | 4 +++-
1 files changed, 3 insertions(+), 1 deletions(-)
---
diff --git a/meld/sourceview.py b/meld/sourceview.py
index 1cf6cd1..1f69c5b 100644
--- a/meld/sourceview.py
+++ b/meld/sourceview.py
@@ -145,7 +145,9 @@ class MeldSourceView(GtkSource.View):
self._show_line_numbers = None
buf = MeldBuffer()
- buf.create_tag("inline")
+ inline_tag = GtkSource.Tag.new("inline")
+ inline_tag.props.draw_spaces = True
+ buf.get_tag_table().add(inline_tag)
buf.create_tag("dimmed")
self.set_buffer(buf)
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]