Ver código fonte

wxGUI: show whitespace in the python editor (pyedit and gmodeler)

git-svn-id: https://svn.osgeo.org/grass/grass/trunk@67974 15284696-431f-4ddb-bdfa-cd5b030d7da7
Vaclav Petras 9 anos atrás
pai
commit
876b13d0d5
1 arquivos alterados com 6 adições e 1 exclusões
  1. 6 1
      gui/wxpython/gui_core/pystc.py

+ 6 - 1
gui/wxpython/gui_core/pystc.py

@@ -84,7 +84,12 @@ class PyStc(stc.StyledTextCtrl):
         self.Bind(stc.EVT_STC_UPDATEUI, self.OnUpdateUI)
         self.Bind(stc.EVT_STC_MARGINCLICK, self.OnMarginClick)
         self.Bind(wx.EVT_KEY_DOWN, self.OnKeyPressed)
-        
+
+        # show whitespace
+        self.SetViewWhiteSpace(1)
+        # make the symbols very light gray to be less distracting
+        self.SetWhitespaceForeground(True, wx.Colour(200, 200, 200))
+
         # Make some styles, the lexer defines what each style is used
         # for, we just have to define what each style looks like.
         # This set is adapted from Scintilla sample property files.