From bb75e40bca7a6d81eb4070a7b67950119dc4b8b5 Mon Sep 17 00:00:00 2001 From: Neil Date: Wed, 25 Aug 2021 08:21:33 +1000 Subject: Allow SCI_HIDELINES to hide the first line or all lines. --- src/ContractionState.cxx | 2 +- src/Editor.cxx | 3 +-- 2 files changed, 2 insertions(+), 3 deletions(-) (limited to 'src') diff --git a/src/ContractionState.cxx b/src/ContractionState.cxx index 199b3cb78..68724ebab 100644 --- a/src/ContractionState.cxx +++ b/src/ContractionState.cxx @@ -197,7 +197,7 @@ Sci::Line ContractionState::DocFromDisplay(Sci::Line lineDisplay) const no if (OneToOne()) { return lineDisplay; } else { - if (lineDisplay <= 0) { + if (lineDisplay < 0) { return 0; } if (lineDisplay > LinesDisplayed()) { diff --git a/src/Editor.cxx b/src/Editor.cxx index 341165776..1fed61e36 100644 --- a/src/Editor.cxx +++ b/src/Editor.cxx @@ -7409,8 +7409,7 @@ sptr_t Editor::WndProc(Message iMessage, uptr_t wParam, sptr_t lParam) { break; case Message::HideLines: - if (wParam > 0) - pcs->SetVisible(LineFromUPtr(wParam), lParam, false); + pcs->SetVisible(LineFromUPtr(wParam), lParam, false); SetScrollBars(); Redraw(); break; -- cgit v1.2.3