Created
July 10, 2018 23:39
-
-
Save pkulchenko/128002abbecbd04c2bda86712c475c62 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/src/editor/markup.lua b/src/editor/markup.lua | |
index ddb3e208..d137899f 100644 | |
--- a/src/editor/markup.lua | |
+++ b/src/editor/markup.lua | |
@@ -194,6 +194,10 @@ function MarkupStyle(editor, lines, linee) | |
local lsep = w:find(q(MD_MARK_LINZ)..q(MD_MARK_LINA)) | |
if lsep then emark = #w-lsep+#MD_MARK_LINT end | |
end | |
+ local sp = bit.band(editor:GetStyleAt(p-1), ide.STYLEMASK) -- previous position style | |
+ if mark == MD_MARK_HEAD and not iscomment[sp] then | |
+ p = p + 1 | |
+ end | |
editor:StartStyling(p, ide.STYLEMASK) | |
editor:SetStyling(smark, markup[MD_MARK_MARK].st) | |
editor:SetStyling(t-f+1-smark-emark, markup[mark].st or markup[MD_MARK_MARK].st) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment