From e4ebdb228521a6eeef33377188ec47e000fbff08 Mon Sep 17 00:00:00 2001 From: Sven Strickroth Date: Thu, 22 Feb 2018 13:55:06 +0100 Subject: [PATCH] Correctly set the max line length if there is only one line and recalculate the horizontal scrollbar when wrapping changes Based on TortoiseSVN rev. 28112. Signed-off-by: Sven Strickroth --- src/TortoiseMerge/BaseView.cpp | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/TortoiseMerge/BaseView.cpp b/src/TortoiseMerge/BaseView.cpp index 6ae2b8a7b..3428f9c4e 100644 --- a/src/TortoiseMerge/BaseView.cpp +++ b/src/TortoiseMerge/BaseView.cpp @@ -594,7 +594,10 @@ int CBaseView::GetMaxLineLength() m_nMaxLineLength = 0; int nLineCount = GetLineCount(); if (nLineCount == 1) - return GetLineLengthWithTabsConverted(0); + { + m_nMaxLineLength = GetLineLengthWithTabsConverted(0); + return m_nMaxLineLength; + } for (int i=0; i