Categories

  • Announcements regarding our community
    315 Topics
    5k Posts
    donhoD

    @xomx said in Notepad++ release 8.9.3:

    v8.9.3 (Scintilla) EOL regression: #17920

    Thank you for the heads up.
    It’s indeed a regression, but not a critical one.
    Let’s wait one more week, if no critical regression or issue is reported, the auto-updater will be triggered for the release v8.9.3.

  • Frequently Asked Questions and Guides (about Notepad++ and this Forum)

    38 Topics
    63 Posts
    PeterJonesP
    Themes in v8.8.9

    With the release of v8.8.9, there is a new feature which automatically updates the active Theme if it is missing Style Configurator settings for any GUI elements, or missing any Languages or any Style entries in existing Languages. This is a long-needed feature, so that as Notepad++ adds new styles for the Style Configurator, you’ll be able to set them, even if your theme hasn’t been updated since before those styles were added. (Before now, if you switched to a theme years ago and set any custom color or user keyword or custom file extensions for a built-in language, it would never update the theme, no matter how many times you update Notepad++ in the meanwhile. This v8.8.9 feature is able to correct that issue, and you will be able to use the Style Configurator to set the colors of any new styles going forward, as soon as you upgrade to a Notepad++ executable that supports the new style.)

    Unfortunately, the v8.8.9 implementation included some annoying growing pains: the procedure always uses the same colors that those styles have in the stylers.model.xml file (ie, the default “light mode” colors), even if you are using a dark theme, which can make for glaring color issues: on Languages that get new styles added, the text that should be that new style can end up as black-on-white text, even if the rest of the text has a dark background; and if the theme was old enough, some GUI elements (like the Bookmark margin and Change History margin, between the line numbers and the text being edited) may clash with the surrounding GUI elements.

    In the future v8.9 this issue will be fixed, so people who had an older theme and use v8.9 will see new styles show up using the default foreground and background colors of that theme, so they won’t clash: it might not highlight the new keywords, for example, but at least it won’t look worse than it used to.

    But unfortunately, once you run it in v8.8.9, your theme will no longer have those entries “missing”, and the glaring white background will be saved. The instructions below will help you with that:

    Instructions

    These instructions are only needed if you ran Notepad++ v8.8.9. If you upgraded from something earlier to v8.9-or-later, you do not need these instructions.

    Download the updated theme file(s) from the Source (see Download Source below) Depending on circumstances, decide whether you need to update the installation-directory theme, the user-config-directory theme, or both If you have a portable version of Notepad++, without using the Cloud directory or -settingsDir, then you need to just follow the instructions to Update Theme(s) in User Config Directory If you are not using a portable version of Notepad++, then it is recommended to follow Update Theme(s) in Installation Directory first, and then decide based on the next item whether to continue or not If you have any theme file(s) in the user-configuration directory (whether it’s %AppData%\Notepad++\themes\ or the Cloud directory’s .\themes subdirectory or the -settingsDir’s .\themes subdirectory, then you should follow the Update Theme(s) in User Config Directory for those.

    Please note: when correctly following step 2, you may need to follow multiple sets of instructions. Please read and understand each point under step 2 to make the right changes.

    Download Source

    The installer themes in the source code have been updated to have all the styles needed (to be able to fix the problems from v8.8.9). You can go here to grab the theme file(s) you want: https://github.com/notepad-plus-plus/notepad-plus-plus/tree/master/PowerEditor/installer/themes.

    Update Theme(s) in Installation Directory

    Except when you have a portable version of Notepad++, you will generally need to follow this set of instructions for the themes that come in the installation directory. In a normal installation of Notepad++, the installation will be in c:\program files\Notepad++ directory or equivalent, and the installation-directory themes will thus be in c:\program files\Notepad++\themes. (See the Instructions section above for the decision process to know for sure whether to use this section.)

    Exit Notepad++ Go to the URL mentioned in the Download Source section (above), and download the raw version of your Theme file(s) Use Explorer to go to c:\program files\Notepad++\themes\ directory Copy the downloaded Theme(s) into that directory, overwriting what’s there When you run Notepad++ next time, it will use the updated theme, and the glaring color issues should be gone.

    If you have customized your theme with user-keywords or user-extensions, then this won’t be sufficient, because Notepad++ gives priority to the copy from the user-settings directory. (See the Instructions section above for the decision process to know for sure whether this section is sufficient for your needs.)

    Update Theme(s) in User Config Directory

    If you have your Theme file in the user-settings directory (AppData hierarchy or Cloud directory or -settingsDir directory) for any reason – whether you customized it by changing the font or color or added user-defined keywords or user-defined extensions using the Style Configurator, or whether you intentionally copied or downloaded a Theme into the user-settings directory, or whether it’s there and you don’t know how or why it got there: under any of those circumstances, then just replacing the theme in the installation directory won’t be sufficient. (See the Instructions section above for the decision process to know for sure whether to use this section.)

    Exit Notepad++ If you haven’t already, go to the URL mentioned in the Download Source section (above), and download the raw version of your Theme file(s) Use Explorer to go to %AppData%\Notepad++\ (🛈) or to wherever your Cloud Directory or -settingsDir option point to There should be a themes subdiretory in that directory, if you have customized your Theme. Rename your old custom theme to <themeName>_OLD.xml (like khaki.xml becomes khaki_OLD.xml) Copy the downloaded version of the Theme into that directory (for example, khaki.xml) Start Notepad++. It will use the updated version of the theme, but your customizations will be temporarily missing. Open %AppData%\Notepad++\themes\<themeName>.xml and %AppData%\Notepad++\themes\<themeName>_OLD.xml In the _OLD copy, search for ext="(?!") in Regular Expression mode. The value between the quotes will be the user-extensions for that language. Copy any that you find in the OLD file to the language’s equivalent entry in <themeName>.xml In the _OLD copy, search for (?<!>)</WordsStyle> in Regular Expression mode. Any values between the > and the </WordsStyle> should be copied to the equivalent location in the <themeName>.xml file. If <themeName>.xml just has <WordsStyle name="..." ... /> without having a </WordsStyle> closer, you can replace the /> with a > and the list of keywords, then the closing </WordsStyle> Save <themeName>.xml Exit Notepad++ When you run Notepad++ again, it should now include your customizations again. Native Feature compared to ConfigUpdater plugin

    The ConfigUpdater plugin was introduced as a testbed for some of the ideas that made it into the v8.8.9 native implementation. As such, if you are in v8.8.9 or newer, you no longer need the ConfigUpdater plugin. But if you are before v8.8.9, and waiting for the v8.9 fix to the Notepad++ feature before upgrading, then using ConfigUpdater while in v8.8.8-or-older will help you get to a point where if you did change your mind and upgrade to v8.8.9, it wouldn’t make the glaring UI clash and black-on-white text in dark themes.

    JavaScript in v8.9 Themes

    In v8.8.8 and earlier, Notepad++ would magically use the embedded javascript (JS-in-HTML) styler settings if the javascript.js (*.js) language didn’t have defined styles in a given theme, making it appear to JavaScript users that their theme had the standalone JavaScript colors defined. The v8.9 fix, which filled in default FG/BG colors for all javascript.js styles for themes that were missing javascript.js made it appear to the JavaScript users that v8.9 broke their theme, when it really meant that their already-broken theme was just being “fixed” in a different way. Updated themes are being submitted to the Notepad++ codebase, so that javascript.js will use similar colors to embedded javascript, so they won’t get the surprise color change if they upgrade from v8.8.8-or-older to v8.9.1-or-newer.

    If you already updaded to v8.9, and JavaScript *.js files look like they have stopped syntax highlighting then you will need to follow instructions similar to the Update Theme(s) in Installation Directory and/or Update Theme(s) in User Config Directory

    The PR has been merged, so you can just use https://github.com/notepad-plus-plus/notepad-plus-plus/tree/master/PowerEditor/installer/themes as the source for the updated themes (the same link as mentioned above) You can just copy the entire <LexerType name="javascript.js" desc="JavaScript" ext="">...</LexerType> section from the downloaded theme(s) and paste it overtop that same section in your Config Directory and/or Installation Directory theme file(s), then save and restart to get it to take effect.
  • Notepad++ discussions that don’t fit in other Categories

    4k Topics
    22k Posts
    PeterJonesP

    @robstoddard ,

    Personally, I just have a file named Peter's Scratchpad.txt that’s always open, where I paste things like that (and, admittedly, things that started like that but have just stayed around in that file for a lot longer than originally intended). And if I save the “temporary data” in the file, who cares? I just delete the stuff out of the file that I don’t need anymore when I don’t need them anymore. That way, I can just Save All or use the Auto-Save plugin as much as I want, without having to ask for a specific feature to “not save this one thing”.

  • 10k Topics
    54k Posts
    Amelia MendouzaA

    @Claudia-Frank

    Some seven years later: exactly my query too. Many thanks. 😊😊

  • Technical discussion of building or contributing to Notepad++ or Plugin codebases

    1k Topics
    9k Posts
    CoisesC

    @guy038 said in Search++: A work in progress:

    This still one point that’s a bit unclear to me : what is the fundamental difference between all these options, when compared in pairs :

    The principle (see the last bullet point under help for search scopes) is that commands which don’t specify a scope search in marked text if there is any; otherwise, in the current selection if it is not empty; otherwise, in the whole document. That’s subject to the Settings: if you unchecked both Automatically search within selections and Automatically search within marked text, then all the pairs of commands you listed would be identical; and there are the limits on when selections are considered “large enough” to trigger search within selection. (A selection that is the immediate result of a stepwise search never causes the same search to search within that selection no matter how large it is.)

    There are two special cases, and a third questionable feature, also involved:

    There are no Before or After commands with in Selection scope. (My logic is that something can’t be both in the selection and before or after it.) So search commands that include Before or After can only be in Marked Text or in Whole Document.

    Mark commands that don’t specify a scope don’t automatically scope to in Marked Text even if Automatically search within marked text is enabled. What happens is that unless you’ve checked Always unmark all text before Mark command, default Mark commands add to existing marks. I know this is a different behavior from selections, but I think because selections are so volatile, and marks are not, it is natural to use them in different ways. Should this exception be an option in Settings? I’m inclined to add it as a default-checked sub-option of Automatically search within marked text.

    Search commands that specify in Selection or in Marked Text search the whole document if there is no (non-empty) selection or marked text. I’m questioning the sense of that now. I’m thinking that if the user specifies “in selection” or ”in marked text,” and there is none, the search should fail with a message like “No marked text to search” rather than silently discarding the specified scope.

    Thoughts about that logic, especially point 3 (which I am inclined to change in the next release) are welcome and encouraged.

    I have tried to keep as much “symmetry” as I could, to make it all more comprehensible. I think it is possible that I have created some nonsense in practice.

    Points 1 and 3 together mean that Before and After commands without a scope are either the same as Before/After in Marked Text if Automatically search within marked text is checked, or the same as Before/After in Whole Document if it isn’t. However, as I wrote, I’m questioning point 3; without that, when the relevant setting is checked, there would be a difference (the commands that don’t specify a scope would switch between in Marked Text and in Whole Document depending on whether there was any marked text in the document, whereas neither command that specified one scope would switch to the other).

    So… looking at the full list you gave, group by group, assuming default settings… this is what is supposed to happen (full testing of every possible case has not been done):

    Find vs Find in Whole Document Find Backward vs Find Backward in Whole Document

    The two on the left will find the next match in marked text following or preceding the current position or selection if any text is marked; otherwise they will find the first or last match in the selected text if “enough” text is selected; otherwise they will find the next match following or preceding the current position or selection in the whole document. Those on the right will always find the next match following or preceding the current position or selection in the whole document regardless of whether any text is marked or selected.

    Count vs Count in Whole Document

    Count will count only matches in marked text if any text is marked; otherwise it will count only matches in selected text if “enough” text is selected; otherwise it will count all matches in the whole document. Count in Whole Document will always count all matches in the whole document regardless of whether any text is marked or selected.

    Count Before vs Count Before in Whole Document Count After vs Count After in Whole Document

    The two on the left will count only matches in marked text that are before or after the current position or selection if any text is marked; otherwise they will count matches before or after the current position or selection in the whole document. Those on the right will always count matches before or after the current position or selection in the whole document regardless of whether any text is marked.

    Find All Before vs Find All Before in Whole Document Find All After vs Find All After in Whole Document

    The two on the left will list only matches in marked text that are before or after the current position or selection if any text is marked; otherwise they will list all matches before or after the current position or selection in the whole document. Those on the right will always list all matches before or after the current position or selection in the whole document regardless of whether any text is marked.

    Select Before vs Select Before in Whole Document Select After vs Select After in Whole Document

    The two on the left will select only matches in marked text that are before or after the current position or selection if any text is marked; otherwise they will select all matches before or after the current position or selection in the whole document. Those on the right will always select all matches before or after the current position or selection in the whole document regardless of whether any text is marked.

    Mark Before vs Mark Before in Whole Document Mark After vs Mark After in Whole Document

    I’ll double-check my logic later, but I think these are identical, since (1 above) Before/After can’t be in selection, and (2 above) Mark doesn’t automatically scope to marked text. It’s unclear to me which ones to remove, since either choice breaks the symmetry and could be confusing to users, but having two commands that do the same thing is also confusing.

    Show Before vs Show Before in Whole Document Show After vs Show After in Whole Document

    I grant that this would be a strange use of Show. In the circumstance where there are hidden lines both before and after the current position or selection, and there is some marked text in document, the ones on the left would search only marked text before or after the current position or selection for lines to unhide, while the ones on the right would search all text.

    Replace and Find vs Replace And Find in Whole Document Replace and Find Backward vs Replace and Find Backward in Whole Document Find or Replace vs Find or Replace in Whole Document Find Backward or Replace vs Find Backward or Replace in Whole Document Replace All vs Replace All in Whole Document Replace All Before vs Replace All Before in Whole Document Replace All After vs Replace All After in Whole Document

    These are like their Find and Find All counterparts. The ones on the left work like “in Marked Text” if any text is marked; otherwise, like “in Selection” if “enough” text is selected; otherwise like “in Whole Document” (like the ones on the right).

  • Security shouldn't be the privilege of rich people
    70 Topics
    346 Posts
    H

    @Coises

    Thank you, Coises, for your helpful reply. I truly appreciate your support and guidance.

    Regards,
    Harmandeep Singh Kandhari

  • All the issues (publications/questions) about binary translation
    76 Topics
    480 Posts
    U

    @xomx
    Thank you very much for the work you have done, which will lead to improvements in Notepad++ in the future.
    I am very grateful to you.

  • Say fuck to Notepad++ here, and only here
    93 Topics
    552 Posts
    guy038G

    Hello, @datatraveller1 and All,

    Many thanks for joining the Compare2Lists’s author and many thanks to Fatih Ramazan Çıkan which was able to get a quick new 1.7 version which fixes this annoying bug !

    I also tried this software on that real example that I proposed in this post, some days ago :

    https://community.notepad-plus-plus.org/post/105031

    You can download this file from my Google Drive account :

    https://drive.google.com/file/d/1aYOpKon4KYw_NXSdj4Tm4Ti_FrygC2ky/view?usp=sharing

    Before using it with the Compare Two Lists software :

    Delete the last column, which counts the number of records, with a column mode selection

    Delete all trailing blank characters with the Edit > Blank operations > Trim Trailing Space option

    Place all contents in the clipboard ( Ctrl + C )

    Now, open the Compare Two Lists software

    Paste all the resulting contents with the Paste button, associated with the List #1 panel

    Check that the Settings > Cas sensitive option, if necessary

    Click on the Remove Duplicates button, associated with the List #1 panel

    => You should see that it remains 50,822 records

    And this is exactly the results produced when you use the cases #3 or #4 of my post ;-))

    Best Regards,

    guy038

  • No support request and bug report here, only unconditional praise and worship

    2 Topics
    7 Posts
    Maddox ArmstrongM

    @FreeMeow I goon to Notepad++ :P

  • Share personal tips and cool uses for Notepad++, and similar

    59 Topics
    221 Posts
    William4565W

    Its been 5 years I’m using notepad ++ and for me it was and it is very useful tool.

  • Computer/Programming Jokes are welcome here