aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/Editor.cxx
diff options
context:
space:
mode:
authornyamatongwe <unknown>2012-09-19 22:42:10 +1000
committernyamatongwe <unknown>2012-09-19 22:42:10 +1000
commit5157aaacf43d61b6fabb3f967b6308c0f9956e4e (patch)
tree6260f0a7b8541f265bbe7eb5a22d67f38e9ec31e /src/Editor.cxx
parent1de003690c05688d6857ab57b3d02e7e262c092a (diff)
downloadscintilla-mirror-5157aaacf43d61b6fabb3f967b6308c0f9956e4e.tar.gz
Allow subclasses to modify padding when last segment on line is italics.
Used by ncurses platform layer. From Mitchell Foral.
Diffstat (limited to 'src/Editor.cxx')
-rw-r--r--src/Editor.cxx3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/Editor.cxx b/src/Editor.cxx
index 2b2b1785d..bb23e9e6d 100644
--- a/src/Editor.cxx
+++ b/src/Editor.cxx
@@ -220,6 +220,7 @@ Editor::Editor() {
marginNumberPadding = 3;
ctrlCharPadding = 3; // +3 For a blank on front and rounded edge each side
+ lastSegItalicsOffset = 2;
hsStart = -1;
hsEnd = -1;
@@ -2243,7 +2244,7 @@ void Editor::LayoutLine(int line, Surface *surface, ViewStyle &vstyle, LineLayou
}
// Small hack to make lines that end with italics not cut off the edge of the last character
if ((startseg > 0) && lastSegItalics) {
- ll->positions[startseg] += 2;
+ ll->positions[startseg] += lastSegItalicsOffset;
}
ll->numCharsInLine = numCharsInLine;
ll->numCharsBeforeEOL = numCharsBeforeEOL;