From ed97cb6060c786a4ddc0567250911f7093244d55 Mon Sep 17 00:00:00 2001 From: Zufu Liu Date: Mon, 19 Jan 2026 15:23:12 +1100 Subject: Allow Euro in code page 936 for byte 0x80. --- doc/ScintillaHistory.html | 4 ++++ src/DBCS.cxx | 5 ++++- 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/doc/ScintillaHistory.html b/doc/ScintillaHistory.html index 1148abaa1..45ffeefe9 100644 --- a/doc/ScintillaHistory.html +++ b/doc/ScintillaHistory.html @@ -608,6 +608,10 @@ Feature #184.
  • + Allow Euro '€' in code page 936 for 0x80. + Feature #1575. +
  • +
  • Fix SCI_SETSELECTIONNSTART and SCI_SETSELECTIONNEND to behave more sensibly. Bug #2488.
  • diff --git a/src/DBCS.cxx b/src/DBCS.cxx index f92b7a5a9..062c30a51 100644 --- a/src/DBCS.cxx +++ b/src/DBCS.cxx @@ -90,10 +90,13 @@ bool DBCSIsTrailByte(int codePage, char ch) noexcept { bool IsDBCSValidSingleByte(int codePage, int ch) noexcept { switch (codePage) { case cp932: + // Shift_jis return ch == 0x80 || (ch >= 0xA0 && ch <= 0xDF) || (ch >= 0xFD); - + case cp936: + // GBK + return ch == 0x80; default: return false; } -- cgit v1.2.3