diff options
| author | Zufu Liu <unknown> | 2019-10-13 19:14:54 +1100 |
|---|---|---|
| committer | Zufu Liu <unknown> | 2019-10-13 19:14:54 +1100 |
| commit | 9bf41a8027e2ddd750c43e44c8cb466c17e63214 (patch) | |
| tree | cc981106e9ddbb1bdb92dbfc034f98858b9426cb /lexers/LexTCL.cxx | |
| parent | 66c006764cd823ff9148bf036a78d50edbe2b9be (diff) | |
| download | scintilla-mirror-9bf41a8027e2ddd750c43e44c8cb466c17e63214.tar.gz | |
Bug [#2131]. Turn off whitespace fold flag when fold.compact=0.
Diffstat (limited to 'lexers/LexTCL.cxx')
| -rw-r--r-- | lexers/LexTCL.cxx | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/lexers/LexTCL.cxx b/lexers/LexTCL.cxx index 1ea6ecf6e..5bba2b6a1 100644 --- a/lexers/LexTCL.cxx +++ b/lexers/LexTCL.cxx @@ -46,6 +46,7 @@ static inline bool IsANumberChar(int ch) { static void ColouriseTCLDoc(Sci_PositionU startPos, Sci_Position length, int , WordList *keywordlists[], Accessor &styler) { #define isComment(s) (s==SCE_TCL_COMMENT || s==SCE_TCL_COMMENTLINE || s==SCE_TCL_COMMENT_BOX || s==SCE_TCL_BLOCK_COMMENT) bool foldComment = styler.GetPropertyInt("fold.comment") != 0; + const bool foldCompact = styler.GetPropertyInt("fold.compact", 1) != 0; bool commentLevel = false; bool subBrace = false; // substitution begin with a brace ${.....} enum tLineState {LS_DEFAULT, LS_OPEN_COMMENT, LS_OPEN_DOUBLE_QUOTE, LS_COMMENT_BOX, LS_MASK_STATE = 0xf, @@ -199,7 +200,7 @@ next: } } int flag = 0; - if (!visibleChars) + if (!visibleChars && foldCompact) flag = SC_FOLDLEVELWHITEFLAG; if (currentLevel > previousLevel) flag = SC_FOLDLEVELHEADERFLAG; |
