aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/PositionCache.cxx
diff options
context:
space:
mode:
authorNeil <nyamatongwe@gmail.com>2021-09-28 12:53:58 +1000
committerNeil <nyamatongwe@gmail.com>2021-09-28 12:53:58 +1000
commitfe41a24534e1280f088835ea1813fa64120f4169 (patch)
treeb25f80573180e44d01b078331022251792174f86 /src/PositionCache.cxx
parent810964f8e6b80fbfdb7f96b9a084acc4cbe5a3a1 (diff)
downloadscintilla-mirror-fe41a24534e1280f088835ea1813fa64120f4169.tar.gz
Fix bad layout of monospace text on Cocoa by adding separate field
monospaceCharacterWidth for width of monospaced characters.
Diffstat (limited to 'src/PositionCache.cxx')
-rw-r--r--src/PositionCache.cxx2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/PositionCache.cxx b/src/PositionCache.cxx
index 073a62692..f24164636 100644
--- a/src/PositionCache.cxx
+++ b/src/PositionCache.cxx
@@ -906,7 +906,7 @@ void PositionCache::MeasureWidths(Surface *surface, const ViewStyle &vstyle, uns
if (vstyle.styles[styleNumber].monospaceASCII) {
if (AllGraphicASCII(sv)) {
for (size_t i = 0; i < sv.length(); i++) {
- positions[i] = vstyle.styles[styleNumber].aveCharWidth * (i+1);
+ positions[i] = vstyle.styles[styleNumber].monospaceCharacterWidth * (i+1);
}
return;
}