Merge pull request #2118 from RaiKoHoff/RC2_DEV

Changed: Focused-View scrolling
This commit is contained in:
Rainer Kottenhoff 2020-03-17 09:57:55 +01:00 committed by GitHub
commit f04ca68faf
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
7 changed files with 15 additions and 16 deletions

View File

@ -1 +1 @@
3
1

View File

@ -1 +1 @@
316
317

View File

@ -3,7 +3,7 @@
<assemblyIdentity
name="Notepad3"
processorArchitecture="*"
version="5.20.316.3"
version="5.20.317.1"
type="win32"
/>
<description>Notepad3 RC3</description>

View File

@ -4819,8 +4819,7 @@ void EditEnsureSelectionVisible()
SciCall_EnsureVisible(iAnchorLine);
if (iAnchorLine != iCurrentLine) { SciCall_EnsureVisible(iCurrentLine); }
//SciCall_ScrollCaret();
Sci_ScrollToLine(iCurrentLine);
Sci_ScrollToLine(iCurrentLine, true);
}
@ -4847,7 +4846,7 @@ void EditJumpTo(HWND hwnd, DocLn iNewLine, DocPos iNewCol)
const DocPos iNewPos = SciCall_FindColumn(iNewLine, iNewCol);
SciCall_GotoPos(iNewPos);
Sci_ScrollToLine(iNewLine);
Sci_ScrollToLine(iNewLine, true);
// remember x-pos for moving caret vertically
SciCall_ChooseCaretX();
@ -6978,11 +6977,11 @@ void EditToggleView(HWND hwnd)
EditHideNotMarkedLineRange(hwnd, FocusedView.HideNonMatchedLines);
if (FocusedView.HideNonMatchedLines) {
Sci_ScrollToLine(0);
Sci_ScrollToLine(0, false);
SciCall_SetReadOnly(true);
}
else {
Sci_ScrollToLine(Sci_GetCurrentLineNumber());
Sci_ScrollToLine(Sci_GetCurrentLineNumber(), true);
SciCall_SetReadOnly(false);
}

View File

@ -2957,7 +2957,7 @@ LRESULT MsgChangeNotify(HWND hwnd, WPARAM wParam, LPARAM lParam)
if (FileWatching.MonitoringLog)
{
SciCall_SetReadOnly(FileWatching.MonitoringLog);
Sci_ScrollToLine(Sci_GetLastDocLineNumber());
Sci_ScrollToLine(Sci_GetLastDocLineNumber(), false);
}
else {
SciCall_GotoPos(iCurPos);
@ -5311,7 +5311,7 @@ LRESULT MsgCommand(HWND hwnd, UINT umsg, WPARAM wParam, LPARAM lParam)
FileWatching.AutoReloadTimeout = 250UL;
UndoRedoRecordingStop();
SciCall_SetEndAtLastLine(false);
Sci_ScrollToLine(Sci_GetLastDocLineNumber());
Sci_ScrollToLine(Sci_GetLastDocLineNumber(), false);
}
else {
s_flagChangeNotify = FileWatching.flagChangeNotify;
@ -5321,7 +5321,7 @@ LRESULT MsgCommand(HWND hwnd, UINT umsg, WPARAM wParam, LPARAM lParam)
FileWatching.AutoReloadTimeout = Settings2.AutoReloadTimeout;
UndoRedoRecordingStart();
SciCall_SetEndAtLastLine(!Settings.ScrollPastEOF);
Sci_ScrollToLine(Sci_GetCurrentLineNumber());
Sci_ScrollToLine(Sci_GetCurrentLineNumber(), true);
}
InstallFileWatching(Globals.CurrentFile); // force
@ -9733,7 +9733,7 @@ bool FileRevert(LPCWSTR szFileName, bool bIgnoreCmdLnEnc)
if (FileWatching.FileWatchingMode == FWM_AUTORELOAD) {
if (docView.bIsTail || FileWatching.MonitoringLog) {
bPreserveView = false;
Sci_ScrollToLine(Sci_GetLastDocLineNumber());
Sci_ScrollToLine(Sci_GetLastDocLineNumber(), false);
}
}

View File

@ -599,7 +599,7 @@ inline DocPos Sci_GetRangeMaxLineLength(DocLn iBeginLine, DocLn iEndLine) {
}
// respect VSlop settings
#define Sci_ScrollToLine(L) SciCall_ScrollRange(SciCall_GetLineEndPosition(L), SciCall_PositionFromLine(L));
#define Sci_ScrollToLine(L,C) { SciCall_ScrollRange(SciCall_PositionFromLine(L), SciCall_GetLineEndPosition(L)); if (C) { SciCall_ScrollCaret(); } }
#define Sci_ReplaceTarget(M,L,T) (((M) == SCI_REPLACETARGET) ? SciCall_ReplaceTarget((L),(T)) : SciCall_ReplaceTargetRe((L),(T)))

View File

@ -8,12 +8,12 @@
#define SAPPNAME "Notepad3"
#define VERSION_MAJOR 5
#define VERSION_MINOR 20
#define VERSION_REV 316
#define VERSION_BUILD 3
#define VERSION_REV 317
#define VERSION_BUILD 1
#define SCINTILLA_VER 432
#define ONIGURUMA_REGEX_VER 6.9.4
#define UCHARDET_VER 2018.09.27
#define TINYEXPR_VER 2018.05.11
#define UTHASH_VER 2.1.0
#define VERSION_PATCH RC3
#define VERSION_COMMIT_ID dkt1-amr
#define VERSION_COMMIT_ID t7820-rk