From 253bc4cd3a19e93f7090c74af92a871765afe002 Mon Sep 17 00:00:00 2001 From: Neil Date: Sun, 2 Feb 2014 18:09:44 +1100 Subject: Added wrap mode SC_WRAP_WHITESPACE which only wraps on whitespace, not on style changes. From Robert Gieseke. --- src/Editor.cxx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/Editor.cxx') diff --git a/src/Editor.cxx b/src/Editor.cxx index 6694cbbb3..0f0eed80b 100644 --- a/src/Editor.cxx +++ b/src/Editor.cxx @@ -2400,7 +2400,7 @@ void Editor::LayoutLine(int line, Surface *surface, ViewStyle &vstyle, LineLayou - posLineStart; p = pdoc->MovePositionOutsideChar(p + 1 + posLineStart, 1) - posLineStart; continue; - } else if (ll->styles[p] != ll->styles[p - 1]) { + } else if ((vstyle.wrapState == eWrapWord) && (ll->styles[p] != ll->styles[p - 1])) { lastGoodBreak = p; } else if (IsSpaceOrTab(ll->chars[p - 1]) && !IsSpaceOrTab(ll->chars[p])) { lastGoodBreak = p; -- cgit v1.2.3