aboutsummaryrefslogtreecommitdiffhomepage
AgeCommit message (Collapse)AuthorFilesLines
2025-02-11Update Direct2D and DirectWrite functions and types to Direct2D 1.1.Neil4-14/+51
2025-02-10Use ID2D1HwndRenderTarget::Resize when handling WM_SIZE to avoid larger stateNeil1-1/+14
invalidation which may be more costly to restore.
2025-02-09Add RenderTargets to hold one render target at a time, either Hwnd or DC.Neil3-39/+74
Drawing code just needs one or the other but other calls need a particular type with casting hiding potential problems. This will be more important in the future when a third type of render target ID2D1DeviceContext will be added. Use unique_ptr more for render targets to ensure they are freed correctly.
2025-02-09Wrap GetClientRect so it can be used more easily to produce const result.Neil1-18/+21
Move GetSizeUFromRect earlier for possible new code.
2025-02-09Update Direct2D headers to Direct2D 1.1.Neil3-6/+6
Doesn't change functionality yet but ensures more recent APIs will be available.
2025-02-09Standardize DLL freeing.Neil1-15/+21
2025-02-07Add vertical scroll position into undo selection history unconditionally.Neil3-14/+21
2025-02-07Use operator== inside <= and >= to shorten code.Neil1-14/+8
Drop else after return in asymmetric cases to clarify the returned value.
2025-02-06Feature [feature-requests:#1540]. Avoid memory leaks caused by addition ofNeil1-1/+4
uninitialized_value_construct_n by using loop in InsertEmpty.
2025-02-06Bug [#2460]. Workaround incorrect scaling of "reverse arrow" cursor under ↵Jiří Techet2-0/+10
Windows and HiDPI screens The GDK_RIGHT_PTR cursor is provided only by GTK - there's no native Windows cursor of this shape so GTK renders the cursor by itself from the cursor theme bitmap. The code doing this is apparently buggy and does not take into account HiDPI screens so on a screen with 300% scaling, the cursor is 3x smaller. Workaround this by using GDK_HAND2 which maps to a native Windows cursor that doesn't suffer from this problem. See https://sourceforge.net/p/scintilla/bugs/2460/
2025-02-05Feature [feature-requests:#1543] Add "Releases" anchor to navigate to Releases.Neil1-1/+2
2025-02-05Use new SelectionSegment constructor and SelectionRange::AsSegment to simplifyNeil3-12/+8
code.
2025-02-05Simplify SelectionRange::Intersect and add SelectionRange constructor fromNeil3-14/+50
positions without virtual space. Add unit tests.
2025-02-04Also delete the local reference to model state when history disabled.Neil1-0/+1
2025-02-04Ensure undo selection history for view is deleted when view destroyed orNeil4-2/+17
history disabled.
2025-02-04Use Lexilla.ruleset from sibling lexilla directory instead of path on myNeil1-1/+2
personal machine.
2025-02-04Fix segmentation of long lexemes to avoid breaking before modifiers like accentsNeil4-7/+157
that must be drawn with their base letters. This is only a subset of implementing grapheme cluster boundaries but it improves behaviour with some Asian scripts like Thai and Javanese. Javanese is mostly written with (ASCII) Roman characters so issues will be rare but Thai uses Thai script. Also slightly improves placement of combining accents in European texts. https://github.com/notepad-plus-plus/notepad-plus-plus/issues/14822 https://github.com/notepad-plus-plus/notepad-plus-plus/issues/16115
2025-02-04Add overload of UnicodeFromUTF8 that takes a string_view.Neil4-1/+19
2025-02-01Serialize selection type and ranges with SCI_GETSELECTIONSERIALIZED andNeil12-1/+110
SCI_SETSELECTIONSERIALIZED.
2025-02-01Use string form for selection undo history as it saves significant space.Neil4-47/+21
On average takes around 20% of SelectionSimple.
2025-02-01Implement serialization of Selection to and from strings.Neil4-0/+265
Requires std::from_chars to be available.
2025-02-01Reconnect to document's undo selection history after switching documents whenNeil1-0/+1
performing undo or redo.
2025-01-31Update comment about modules tested.Neil1-17/+11
2025-01-31Add default basic constructor and operator!= to SelectionPosition to ease use.Neil6-26/+179
Use default member initializer, constexpr for constructors and equality operators and <, [[nodiscard]] for comparison operators. Add simple unit tests for Selection. Not trying to be exhaustive here, just start the process of adding tests.
2025-01-30In Clear, clear fields in declaration order and ensure all fields handled.Neil1-3/+5
2025-01-26Bug [#1539]. Fix some incorrect tags.Zufu Liu1-2/+2
2025-01-25Bug [#1224]. Use enum for undo selection history and make API names moreNeil11-29/+62
consistent as 'undo selection' instead of 'selection undo' as more closely associated with undo than selection.
2025-01-22Bug [#1224]. Remember selection in undo history. SCI_SETSELECTIONUNDOHISTORY.Neil21-8/+337
2025-01-22There will be more use of std::vector<SelectionRange> so name it.Neil1-3/+4
2025-01-08Feature [feature-requests:#1540]. Optimize InsertEmpty to memset equivalent.Zufu Liu1-8/+6
Simplify second argument by std::fill -> std::fill_n, std::copy -> std::copy_n.
2025-01-07Feature [feature-requests:#1539]. Avoid calling UpdateBidiData for each subline.Zufu Liu1-15/+13
Remove vector of draw phases.
2025-01-05Feature [feature-requests:#1539]. Fix documentation structure.Zufu Liu1-1/+1
2025-01-04Use const, unnamed namespace, and named constant.Neil1-34/+40
No change in behaviour.
2025-01-04Fix bug where double-click stopped working after running for weeks.Neil2-4/+27
2024-12-18Added tag rel-5-5-4 for changeset 56bc6f0e611aNeil1-0/+1
2024-12-15Updates for version 5.5.4.rel-5-5-4Neil9-20/+20
2024-12-15Feature [feature-requests:#1537]. Use const where possible.Neil1-1/+1
2024-12-15Feature [feature-requests:#1537]. Use noexcept where possible.Zufu Liu2-4/+4
2024-12-15Feature [feature-requests:#1537]. Extract common code into function.Zufu Liu1-8/+10
2024-12-13Feature [feature-requests:#1538]. Reduce range checks in PartitionFromPositionZufu Liu1-1/+1
to improve performance.
2024-12-13Feature [feature-requests:#1537]. Remove explicit initialization which isZufu Liu1-3/+1
identical to default initialization. Remove constructor argument which is same as default.
2024-12-06Feature [feature-requests:#1537]. Avoid truncation potential with PerformSort.Zufu Liu2-14/+11
Use string_view to improve safety.
2024-12-06Feature [feature-requests:#1537]. Refactor Sorter in AutoComplete.Zufu Liu1-13/+21
Move into unnamed namespace. Don't hold onto AutoComplete*. Simplify indexing by 2. Use const.
2024-12-03Feature [feature-requests:#1537]. Simpify calculation of start of search forZufu Liu1-1/+1
brace matching.
2024-12-03Feature [feature-requests:#1537]. Avoid holding onto Document without need.Zufu Liu1-2/+1
2024-12-03Feature [feature-requests:#1537]. Declare IME retrieval methods const.Zufu Liu1-2/+2
2024-11-24Bug [#2457]. Fix moving line down to empty final line and moving empty finalpawelzwronek2-3/+11
line up. Handle edge cases when moving selected lines. Allow moving the selection when the end line of the document is empty or when moving up the last empty line.
2024-12-02Improve performance of simple case where FillRange just inserts two entries andNeil1-1/+18
does not need to split, merge, or delete runs. This avoids multiple binary searches and is a significant improvement for situations such as marking large numbers of search matches in a huge document.
2024-12-02Remove explicit initialization which is identical to default initialization.Neil1-5/+2
Remove constructor argument which is same as default. Shorten code and avoid else.
2024-12-02Optimize calculating lines of range to redraw when whole range is on one line.Neil1-4/+8
SciLineFromPosition is a binary search over the line indices but LineStart is just indexing so is less expensive. This code may limit performance when updating many positions.