Commit Graph

30 Commits

Author SHA1 Message Date
Christian Grasser 881e8c285e Update to scintilla 5.5.0 & Lexilla 5.3.2
Sintilla Release 5.5.0 (https://www.scintilla.org/scintilla550.zip)

    Released 23 April 2024.
    Add elements for inactive additional selections SC_ELEMENT_SELECTION_INACTIVE_ADDITIONAL_TEXT and SC_ELEMENT_SELECTION_INACTIVE_ADDITIONAL_BACK. When not set these default to SC_ELEMENT_SELECTION_INACTIVE_TEXT and SC_ELEMENT_SELECTION_INACTIVE_BACK. Bug #2417.
    On Cocoa, avoid use of NSUserDefaults which will soon require justification when used in applications on the App Store.
    Fix Win32 IME crash in windowed mode. Bug #2433.
    Scale reverse arrow cursor for margins to match other cursors when user changes pointer size. Bug #2321.

Lexilla Release 5.3.2 (https://www.scintilla.org/lexilla532.zip)

    Released 23 April 2024.
    COBOL: Stop string literal continuing over line end. Issue #229.
    COBOL: Stop doc comment assigning different styles to \r and \n at line end. Issue #229.
    COBOL: Recognize keywords that start with 'V'. Issue #230.
    COBOL: Recognize comments after tag or that start with '/'. Issue #231.
    HTML: Implement substyles for tags, attributes, and identifiers SCE_H_TAG, SCE_H_ATTRIBUTE, SCE_HJ_WORD, SCE_HJA_WORD, SCE_HB_WORD, SCE_HP_WORD, SCE_HPHP_WORD.
    HTML: Implement context-sensitive attributes. "tag.attribute" matches "attribute" only inside "tag".
    HTML: Match standard handling of comments. Issue #232.
    Lua: Implement substyles for identifiers SCE_LUA_IDENTIFIER.
    Ruby: Allow non-ASCII here-doc delimiters. Issue #234.
    Ruby: Allow modifier if, unless, while and until after heredoc delimiter. Issue #236.
    Rust: Recognize raw identifiers. Issue #239, Pull request #240.

Close #15042
2024-04-30 04:19:49 +02:00
Christian Grasser 0f3ae2e3d5 Updated to Scintilla 5.4.2 & Lexilla 5.3.1
https://www.scintilla.org/scintilla542.zip
Release 5.4.2

    Released 5 March 2024.
    Significantly reduce memory used for undo actions, often to a half or quarter of previous versions. Feature #1458.
    Add APIs for saving and restoring undo history.
    For GTK, when laying out text, detect runs with both left-to-right and right-to-left ranges and divide into an ASCII prefix and more complex suffix. Lay out the ASCII prefix in the standard manner but, for the suffix, measure the whole width and spread that over the suffix bytes. This produces more usable results where the caret moves over the ASCII prefix correctly and over the suffix reasonably but not accurately.
    For ScintillaEdit on Qt, fix reference from ScintillaDocument to Document to match change in 5.4.1 using IDocumentEditable for SCI_GETDOCPOINTER and SCI_SETDOCPOINTER.
    For Direct2D on Win32, use the multi-threaded option to avoid crashes when Scintilla instances created on different threads. There may be more problems with this scenario so it should be avoided. Bug #2420.
    For Win32, ensure keyboard-initiated context menu appears in multi-screen situations.

https://www.scintilla.org/lexilla531.zip
Release 5.3.1

    Released 5 March 2024.
    Assembler: After comments, treat \r\n line ends the same as \n. This makes testing easier.
    Bash: Fix folding when line changed to/from comment and previous line is comment. Issue #224.
    Batch: Fix handling ':' next to keywords. Issue #222.
    JavaScript: in cpp lexer, add lexer.cpp.backquoted.strings=2 mode to treat ` back-quoted strings as template literals which allow embedded ${expressions}. Issue #94.
    Python: fix lexing of rb'' and rf'' strings. Issue #223, Pull request #227.
    Ruby: fix lexing of methods on numeric literals like '3.times' so the '.' and method name do not appear in numeric style. Issue #225.
2024-03-11 03:58:17 +01:00
Christian Grasser dcc7e600c7 Updated to Scintilla 5.4.1 & Lexilla 5.3.0
Scintilla 5.4.1
https://www.scintilla.org/scintilla541.zip
Released 27 December 2023.

1.  Add IDocumentEditable interface to allow efficient interaction with document objects which may not be visible in a Scintilla instance. This feature is provisonal and may change before being declared stable. For better type-safety, the ScintillaCall C++ API uses IDocumentEditable* where void* was used before which may require changes to client code that uses document pointer APIs DocPointer, SetDocPointer, CreateDocument, AddRefDocument, and ReleaseDocument.
2.  Ctrl-click on a selection deselects it in multiple selection mode.
3.  Add SCI_SELECTIONFROMPOINT for modifying multiple selections.
4.  Add SCI_SETMOVEEXTENDSSELECTION and SCI_CHANGESELECTIONMODE to simplify selection mode manipulation.
5.  Improve performance of global replace by reducing cache invalidation overhead. [Feature #1502](https://sourceforge.net/p/scintilla/feature-requests/1502/).
6.  Fix regular expression search for "\<" matching beginning of search when not beginning of word and for "\>" not matching line end. [Bug #2157](https://sourceforge.net/p/scintilla/bugs/2157/).
7.  Fix regular expression search failure when search for "\<" followed by search for "\>". [Bug #2413](https://sourceforge.net/p/scintilla/bugs/2413/).
8.  Fix regular expression assertion (^, $, \b. \B) failures when using SCFIND_CXX11REGEX. [Bug #2405](https://sourceforge.net/p/scintilla/bugs/2405/).
9.  Fix regular expression bug in reverse direction where shortened match returned. [Bug #2405](https://sourceforge.net/p/scintilla/bugs/2405/).
10. Avoid character fragments in regular expression search results. [Bug #2405](https://sourceforge.net/p/scintilla/bugs/2405/).
11. With a document that does not have the SC_DOCUMENTOPTION_TEXT_LARGE option set, allocating more than 2G (calling SCI_ALLOCATE or similar) will now fail with SC_STATUS_FAILURE.
12. Protect SCI_REPLACETARGET, SCI_REPLACETARGETMINIMAL, and SCI_REPLACETARGETRE from application changing target in notification handlers. [Bug #2289](https://sourceforge.net/p/scintilla/bugs/2289/).

Lexilla 5.3.0
https://www.scintilla.org/lexilla530.zip
Released 27 December 2023.

1. Fix calling AddStaticLexerModule by defining as C++ instead of C which matches header. [Bug #2421](https://sourceforge.net/p/scintilla/bugs/2421/).
2. Bash: Fix shift operator << incorrectly recognized as here-doc. [Issue #215](https://github.com/ScintillaOrg/lexilla/issues/215).
3. Bash: Fix termination of '${' with first unquoted '}' instead of nesting. [Issue #216](https://github.com/ScintillaOrg/lexilla/issues/216).
4. HTML: JavaScript double-quoted strings may escape line end with '\'. [Issue #214](https://github.com/ScintillaOrg/lexilla/issues/214).
5. Lua: recognize --- doc comments. Defined by [LDoc](https://github.com/lunarmodules/ldoc). Does not recognize --[[-- doc comments which seem less common.

Close #14375
2023-12-26 23:17:53 +01:00
Christian Grasser 69998ab7de Update Scintilla to v5.3.8 & Lexilla to v5.2.8
Scintilla Release 5.3.8 https://www.scintilla.org/scintilla538.zip

    Released 5 November 2023.
    Fix excessive memory use when deleting contiguous ranges backwards. Notepad++ Issue #13442.
    Fix incorrect substitution when searching for a regular expression backwards. Bug #2405.
    Make SCI_MOVESELECTEDLINESUP and SCI_MOVESELECTEDLINESDOWN work for rectangular selections. Bug #2078.
    For Cocoa, minimum supported macOS release increased to 10.13.
    For Cocoa, fix invisible text on macOS 14 Sonoma. Bug #2402.
    For Cocoa, do nothing for suspendDrawing on macOS 10.14+ as the underlying calls have been deprecated.

and lexilla

Release 5.2.8 https://www.scintilla.org/lexilla528.zip

    Released 5 November 2023.
    Python: Update f-string handling to match PEP 701 and Python 3.12. Controlled with property lexer.python.strings.f.pep.701. Issue #150, Pull request #209.
    R: Fix escape sequence highlighting with change of for loop to while loop. Issue #206, Pull request #207.
    Minimum supported macOS release increased to 10.13.

Related to Notepad++ issue #13442, #14188 & #14288
Tested with: https://github.com/notepad-plus-plus/notepad-plus-plus/issues/14188#issuecomment-1740088956
Result: https://github.com/notepad-plus-plus/notepad-plus-plus/issues/14188#issuecomment-1799039503

Fix #13442, fix #14188, fix #14288, close #14320
2023-11-07 17:00:13 +01:00
Christian Grasser cc1a3c826b Update: Scintilla 5.3.6 and Lexilla 5.2.6
update to Scinitlla Release 5.3.6 (https://www.scintilla.org/scintilla536.zip)

    Released 26 July 2023.
    Redraw calltip after showing as didn't update when size of new text exactly same as previous. Feature #1486.
    On Win32 fix reverse arrow cursor when scaled. Bug #2382.
    On Win32 hide cursor when typing if that system preference has been chosen. Bug #2333.
    On Win32 and Qt, stop aligning IME candidate window to target. It is now always aligned to start of composition string. This undoes part of feature #1300. Feature #1488, Bug #2391, Feature #1300.
    On Qt, for IMEs, update micro focus when selection changes. This may move the location of IME popups to align with the caret.
    On Qt, implement replacement for IMEs which may help with actions like reconversion. This is similar to delete-surrounding on GTK.

and Lexilla Release 5.2.6 (https://www.scintilla.org/lexilla526.zip)

    Released 26 July 2023.
    Include empty word list names in value returned by DescribeWordListSets and SCI_DESCRIBEKEYWORDSETS. Issue #175, Pull request #176.
    Bash: style here-doc end delimiters as SCE_SH_HERE_DELIM instead of SCE_SH_HERE_Q. Issue #177.
    Bash: allow '$' as last character in string. Issue #180, Pull request #181.
    Bash: fix state after expansion. Highlight all numeric and file test operators. Don't highlight dash in long option as operator. Issue #182, Pull request #183.
    Bash: strict checking of special parameters ($*, $@, $$, ...) with property lexer.bash.special.parameter to specify valid parameters. Issue #184, Pull request #186.
    Bash: recognize keyword before redirection operators (< and >). Issue #188, Pull request #189.
    Errorlist: recognize Bash diagnostic messages.
    HTML: allow ASP block to terminate inside line comment. Issue #185.
    HTML: fix folding with JSP/ASP.NET <%-- comment. Issue #191.
    HTML: fix incremental styling of multi-line ASP.NET directive. Issue #191.
    Matlab: improve arguments blocks. Add support for multiple arguments blocks. Prevent "arguments" from being keyword in function declaration line. Fix semicolon handling. Pull request #179.
    Visual Prolog: add support for embedded syntax with SCE_VISUALPROLOG_EMBEDDED and SCE_VISUALPROLOG_PLACEHOLDER.
    Styling of string literals changed with no differentiation between literals with quotes and those that are prefixed with "@". Quote characters are in a separate style (SCE_VISUALPROLOG_STRING_QUOTE) to contents (SCE_VISUALPROLOG_STRING).
    SCE_VISUALPROLOG_CHARACTER, SCE_VISUALPROLOG_CHARACTER_TOO_MANY, SCE_VISUALPROLOG_CHARACTER_ESCAPE_ERROR, SCE_VISUALPROLOG_STRING_EOL_OPEN, and SCE_VISUALPROLOG_STRING_VERBATIM_SPECIAL were removed (replaced with SCE_VISUALPROLOG_UNUSED[1-5]). Pull request #178.

Fix #13901, fix #13911, fix #13943, close #13940
2023-08-01 19:44:35 +02:00
Christian Grasser b39ca37c3a Update: Scintilla 5.3.5 Lexilla 5.2.5
update to Scinitlla Release 5.3.5 (https://www.scintilla.org/scintilla535.zip)

    Released 31 May 2023.
    On Win32, implement IME context sensitivity with IMR_DOCUMENTFEED. Feature #1310.
    On Win32 remove dependence on MSIMG32.DLL by replacing AlphaBlend by GdiAlphaBlend. Bug #1923.
    On Qt, stop movement of IME candidate box.
    On Qt, report correct caret position within paragraph for IME retrieve surrounding text.
    On Qt for Cocoa, fix crash in entry of multi-character strings with IME.

and Lexilla Release 5.2.5 (https://www.scintilla.org/lexilla525.zip)

    Released 31 May 2023.
    Add CharacterSetArray constructor without setBase initial argument for common case where this is setNone and the initialSet argument completely defines the characters. This shortens and clarifies use of CharacterSetArray.
    Bash: implement highlighting inside quoted elements and here-docs. Controlled with properties lexer.bash.styling.inside.string, lexer.bash.styling.inside.backticks, lexer.bash.styling.inside.parameter, and lexer.bash.styling.inside.heredoc. Issue #154, Issue #153, Feature #1033.
    Bash: add property lexer.bash.command.substitution to choose how to style command substitutions. 0 → SCE_SH_BACKTICKS; 1 → surrounding "$(" and ")" as operators and contents styled as bash code; 2 → use distinct styles (base style + 64) for contents. Choice (2) is a provisional feature and details may change before it is finalized. Issue #153.
    Bash: fix nesting of parameters (SCE_SH_PARAM) like ${var/$sub/"${rep}}"}. Issue #154.
    Bash: fix single character special parameters like $? by limiting style. Issue #154.
    Bash: treat "$$" as special parameter and end scalars before "$". Issue #154.
    Bash: treat "<<" in arithmetic contexts as left bitwise shift operator instead of here-doc. Issue #137.
    Batch: style SCE_BAT_AFTER_LABEL used for rest of line after label which is not executed. Issue #148.
    F#: Lex interpolated verbatim strings as verbatim. Issue #156.
    VB: allow multiline strings when lexer.vb.strings.multiline set. Issue #151.

Close #13729
2023-06-02 14:15:54 +02:00
Christian Grasser fc61868cf2 Update to Scintilla 5.3.2 and Lexilla 5.2.1
update to https://www.scintilla.org/scintilla532.zip with:

    Released 6 December 2022.
    Add SCI_REPLACETARGETMINIMAL to change text without causing unchanged prefix and suffix to be marked as modified in change history.
    Draw background colour for EOL annotations with standard and boxed visuals.
    Add SCI_GETSTYLEDTEXTFULL to support 64-bit document positions on Win32 replacing SCI_GETSTYLEDTEXT which is not safe for huge documents. Feature #1455.
    Send SCN_AUTOCCOMPLETED for SCI_AUTOCSHOW triggering insertion because of SCI_AUTOCSETCHOOSESINGLE mode. Feature #1459.
    Change 'paragraph up' commands SCI_PARAUP and SCI_PARAUPEXTEND to go to the start position of the paragraph containing the caret. Only if the caret is already at the start of the paragraph will it go to the start of the previous paragraph. Bug #2363.
    Change release compilation optimization option to favour speed over space. -O2 for MSVC and -O3 for gcc and clang.
    On Win32, avoid blurry display with DirectWrite in GDI scaling mode. Bug #2344.
    On Win32, use the top-level window to find the monitor for DirectWrite rendering parameters. Temporarily switch DPI awareness to find correct monitor in GDI scaling mode. Bug #2344.
    On Qt, implement SCI_SETRECTANGULARSELECTIONMODIFIER for all platforms.
    On Qt, allow string form XPM images for SCI_REGISTERIMAGE.

and https://www.scintilla.org/lexilla521.zip with

    Released 6 December 2022.
    Update to Unicode 14. Feature #1461.
    Change default compilation optimization option to favour speed over space. -O2 for MSVC and -O3 for gcc and clang.
    Batch: Fix comments starting inside strings. Issue #115.
    F#: Lex signed numeric literals more accurately. Issue #110, Issue #111.
    F#: Add specifiers for 64-bit integer and floating point literals. Issue #112.
    Markdown: Stop styling numbers at line start in PRECHAR style. Issue #117.
    PowerShell: Recognise numeric literals more accurately. Issue #118.

Close #12624
2022-12-15 13:11:17 +01:00
Christian Grasser b502266e8d Update to scintilla 5.3.1 and lexilla 5.2.0
Close #12327
2022-10-31 00:45:13 +01:00
Christian Grasser 1646ea6139 Update to scintilla 5.3.0 and lexilla 5.1.9
Close #12045
2022-09-12 19:02:55 +02:00
Christian Grasser 6a33bf6c4c Update to Scintilla 5.2.4 and Lexilla 5.1.8
Close #12022
2022-08-27 03:49:39 +02:00
Christian Grasser ed4bb1a93e Update lexilla to 5.1.7 & Scintilla to 5.2.3
Use new interfaces SCI_FORMATRANGEFULL, SCI_GETTEXTRANGEFULL, SCI_FINDTEXTFULL from scintilla 5.2.3

Close #11734
2022-06-28 16:19:19 +02:00
Christian Grasser 100d45f7cf Update Scintilla from 5.2.1 to 5.2.2 and Lexilla from 5.1.5 to 5.1.6
Close #11537
2022-04-28 23:27:54 +02:00
Christian Grasser a61b03ea88 Update Scintilla from v4.4.6 to v5.2.1 and add Lexilla v5.1.5
Update with https://www.scintilla.org/scintilla521.zip
            https://www.scintilla.org/lexilla515.zip

- fix setting to bring Scintilla::PositionCR from ScintillaStructures.h inline with Sci_Position.h Sci_PositionCR
- add workaround to enable lexer for searchResult
commented out SCI_SETILEXER call on searchResult to get one result which is correctly handled by the lexer,
added comment about the current problem with property @MarkingsStruct which seems to disappear after call to SCI_SETILEXER or CreateLexer
- corrected usage of ObjC lexer
- removed unnecessary filter stuff
- use own sections for scintilla and lexilla build targets and allow parallel builds
- as libscilex is no longer existing, changed to libscintilla
- adapt makefiles and cmake
- use VS2019
- started simple changes for createlexer adaptations, nullpointercheck missing on return of lexer name from deprecated LexerNameFromID -> undefined behaviour
- movement from id -> lexer name, mostly done via LexerNameFromID + switching off corresponding compiler warning
- changed to SCI_SETILEXER from SCI_SETLEXER, SCI_SETLEXERLANGUAGE needs to be corrected, see Scintilla5Migration.html
- just commented out: SCI_LOADLEXERLIBRARY

Fix #10504, close #11419
2022-03-27 17:12:53 +02:00
Udo Hoffmann 926e6e97d8 Catch regex search exceptions and show exception message
Fix #9565, close #9566
2021-03-24 01:24:24 +01:00
Don HO d7819cf601
Upgrade Scintilla from v4.2.0 to v4.4.6
Close #8900, close #9550
2021-02-21 19:14:40 +01:00
Udo Hoffmann d55350b4b5
Fix mouse cursor flicker while hovering
The reason, why the flicker occurs, is the following: There are two Windows messages sent by Windows to Scintilla, when the mouse is moved: WM_MOUSEMOVE and WM_SETCURSOR.

WM_MOUSEMOVE informs Scintilla, that the mouse has been moved inside its window.
WM_SETCURSOR informs Scintilla, that the mouse cursor has been moved. Anywhere, not necessarily in its window.
Scintilla calls the Windows function SetCursor (, which sets the mouse cursor shape, not the position), while processing both messages. Unfortunately, Scintilla uses different ways to calculate the desired cursor shape. So, whenever the mouse cursor is moved, two SetCursor calls are applied, sometimes with two different cursor shapes.

On WM_MOUSEMOVE, Scintilla calls ButtonMoveWithModifiers, which sets the correct cursor shape.
On WM_SETCURSOR, Scintilla calls SetCursor directly, sometimes with the wrong cursor shape.

This PR shows how to eliminate this effect in the modified Scintilla version used by Notepad++. This may be the fastest way to get results without introducing new effects.

The current original Scintilla version (Version 4.4.4, downloaded 2020-07-30, 5d134721c303ceecbdcb28ec82b28f0cbbdb4a55) has the same effect and can be fixed in the same way, although the WM_SETCURSOR code has been changed a little. Before updating to a new Scintilla version, we should try to get it fixed in the original Scintilla.

Fix #8588, fix #8647, close #8641
2020-08-01 15:41:04 +02:00
Don HO 92bad0a60a
Upgrade Scintilla from 4.1.4 to 4.2.0
Fix #5822
2019-07-22 13:08:41 +02:00
Don HO cc2d246ae2
Fix Cyrillic, Turkish and other languages input issue in ANSI mode.
For more information, check:
https://github.com/notepad-plus-plus/notepad-plus-plus/issues/5671

Fix #5671
2019-06-11 08:38:35 +02:00
Don HO 37c4b894cc
Upgrade Scintilla from v3.56 to v4.14 2019-05-04 21:14:48 +03:00
Don Ho 4ac665d0ce [UPGRADE] Upgrade Scintilla from v3.34 to v3.56. 2015-06-07 23:19:26 +02:00
Don Ho cb7806e94c [UPDATE] Update Scintilla to 3.3.4
[BUG_FIXED] (Author: Dave Brotherstone) Fix scintilla crash bug while closing a document.

git-svn-id: svn://svn.tuxfamily.org/svnroot/notepadplus/repository/trunk@1104 f5eea248-9336-0410-98b8-ebc06183d4e3
2013-08-28 00:44:27 +00:00
Don Ho 10dc4e06d7 [UPDATE] Update Scintilla to 2.27.
git-svn-id: svn://svn.tuxfamily.org/svnroot/notepadplus/repository/trunk@791 f5eea248-9336-0410-98b8-ebc06183d4e3
2011-07-17 22:30:49 +00:00
Don Ho 0152ded3ff [UPDATE] Scintilla update from 2.21 to 2.25
git-svn-id: svn://svn.tuxfamily.org/svnroot/notepadplus/repository/trunk@742 f5eea248-9336-0410-98b8-ebc06183d4e3
2011-03-22 00:16:49 +00:00
Don Ho 059f9977ef [UPDATE] Update Scintilla to v2.21.
git-svn-id: svn://svn.tuxfamily.org/svnroot/notepadplus/repository/trunk@662 f5eea248-9336-0410-98b8-ebc06183d4e3
2010-09-05 22:56:27 +00:00
Don Ho d4d42f8a1a [UPDATE] Update Scintilla from 2.12 to 2.20
git-svn-id: svn://svn.tuxfamily.org/svnroot/notepadplus/repository/trunk@653 f5eea248-9336-0410-98b8-ebc06183d4e3
2010-08-21 23:59:56 +00:00
Don Ho a2dd828443 [UPDATE] Update Scintilla from 2.0.1 to 2.1.2
git-svn-id: svn://svn.tuxfamily.org/svnroot/notepadplus/repository/trunk@640 f5eea248-9336-0410-98b8-ebc06183d4e3
2010-07-12 22:19:51 +00:00
Don Ho c84437b0d1 [UPDATE] Update Scintilla from v1.78 to v2.01.
git-svn-id: svn://svn.tuxfamily.org/svnroot/notepadplus/repository/trunk@525 f5eea248-9336-0410-98b8-ebc06183d4e3
2009-08-23 02:24:48 +00:00
Don Ho 8ee30eaef2 [NEW] Upgrade Scintilla from 1.77 to 1.78.
Signed-off-by: Don HO <don.h@free.fr>

git-svn-id: svn://svn.tuxfamily.org/svnroot/notepadplus/repository/trunk@499 f5eea248-9336-0410-98b8-ebc06183d4e3
2009-06-24 19:09:31 +00:00
Don Ho 9b645c68d3 [UPDATE] Update Scintilla from v1.75 to v1.77.
git-svn-id: svn://svn.tuxfamily.org/svnroot/notepadplus/repository/trunk@464 f5eea248-9336-0410-98b8-ebc06183d4e3
2009-04-25 23:38:15 +00:00
Don Ho 9d4a4a9edb Moved scintilla in trunk remotely
git-svn-id: svn://svn.tuxfamily.org/svnroot/notepadplus/repository/trunk@461 f5eea248-9336-0410-98b8-ebc06183d4e3
2009-04-24 23:35:41 +00:00