Skip to content

Commit

Permalink
zim/gui/pageview: TextBuffer: Set grey background for preformatted text.
Browse files Browse the repository at this point in the history
Similar to how Github renders that in Markdown. Both intra-line and
paragraph-level preformatting is handled.

Change-Id: Ie1e0eb4bfbc6b462fb11ddfc9f01846f8ed35a91
Signed-off-by: Paul Sokolovsky <pfalcon@users.sourceforge.net>
  • Loading branch information
pfalcon committed May 8, 2021
1 parent 5ccaf7b commit 7f48f96
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions zim/gui/pageview.py
Original file line number Diff line number Diff line change
Expand Up @@ -555,8 +555,8 @@ class TextBuffer(Gtk.TextBuffer):
'strong': {'weight': Pango.Weight.BOLD},
'mark': {'background': 'yellow'},
'strike': {'strikethrough': True, 'foreground': 'grey'},
'code': {'family': 'monospace'},
'pre': {'family': 'monospace', 'wrap-mode': Gtk.WrapMode.NONE},
'code': {'family': 'monospace', 'background': '#f3f3f3'},
'pre': {'family': 'monospace', 'paragraph-background': '#f3f3f3'},
'sub': {'rise': -3500, 'scale': 0.7},
'sup': {'rise': 7500, 'scale': 0.7},
'link': {'foreground': 'blue'},
Expand Down

0 comments on commit 7f48f96

Please sign in to comment.