diff options
Diffstat (limited to 'src/PositionCache.cxx')
| -rw-r--r-- | src/PositionCache.cxx | 3 | 
1 files changed, 2 insertions, 1 deletions
| diff --git a/src/PositionCache.cxx b/src/PositionCache.cxx index bf5560678..31a8601f5 100644 --- a/src/PositionCache.cxx +++ b/src/PositionCache.cxx @@ -508,7 +508,8 @@ TextSegment BreakFinder::Next() {  				charWidth = UTF8DrawBytes(reinterpret_cast<unsigned char *>(&ll->chars[nextBreak]),  					static_cast<int>(lineRange.end - nextBreak));  			else if (encodingFamily == efDBCS) -				charWidth = pdoc->IsDBCSLeadByteNoExcept(ll->chars[nextBreak]) ? 2 : 1; +				charWidth = pdoc->DBCSDrawBytes( +					std::string_view(&ll->chars[nextBreak], lineRange.end - nextBreak));  			const Representation *repr = preprs->RepresentationFromCharacter(&ll->chars[nextBreak], charWidth);  			if (((nextBreak > 0) && (ll->styles[nextBreak] != ll->styles[nextBreak - 1])) ||  					repr || | 
