diff options
| -rw-r--r-- | doc/ScintillaHistory.html | 7 | ||||
| -rw-r--r-- | win32/ScintillaWin.cxx | 4 | 
2 files changed, 9 insertions, 2 deletions
diff --git a/doc/ScintillaHistory.html b/doc/ScintillaHistory.html index e78ef1070..196a7710d 100644 --- a/doc/ScintillaHistory.html +++ b/doc/ScintillaHistory.html @@ -564,6 +564,7 @@        </tr><tr>  	<td>Michael Neuroth</td>  	<td>Arne Scheffler</td> +	<td>Derek</td>      </tr>      </table>      <h2>Releases</h2> @@ -580,6 +581,12 @@  	<li>  	On GTK, fix potential crash when closing Scintilla instances due to releasing global settings object.  	</li> +	<li> +	On Win32, when window is wider than scroll width, +	use correct values when checking whether to change horizontal scroll bar so +	only update and notify dwell end when needed. +	<a href="https://sourceforge.net/p/scintilla/bugs/2288/">Bug #2288</a>. +	</li>      </ul>      <h3>         <a href="https://www.scintilla.org/scintilla513.zip">Release 5.1.3</a> diff --git a/win32/ScintillaWin.cxx b/win32/ScintillaWin.cxx index a45c7a076..4fd86ec7c 100644 --- a/win32/ScintillaWin.cxx +++ b/win32/ScintillaWin.cxx @@ -2340,10 +2340,10 @@ bool ScintillaWin::ModifyScrollBars(Sci::Line nMax, Sci::Line nPage) {  	}  	const PRectangle rcText = GetTextRectangle(); -	int horizEndPreferred = scrollWidth; +	int pageWidth = static_cast<int>(rcText.Width()); +	int horizEndPreferred = std::max(scrollWidth, pageWidth-1);  	if (horizEndPreferred < 0)  		horizEndPreferred = 0; -	int pageWidth = static_cast<int>(rcText.Width());  	if (!horizontalScrollBarVisible || Wrapping())  		pageWidth = horizEndPreferred + 1;  	sci.fMask = SIF_PAGE | SIF_RANGE;  | 
