• 1 Votes
    25 Posts
    7k Views
    CoisesC

    @PeterJones said in npp v8.6 reverses the order of lines on column copy/paste:

    Unlike @Coises , I don’t consider it a “feature” (ie, a bug masquerading as a feature), I think it’s a reasonable compromise between all the different opinions on what the “right” behavior should be when mixing between column and multi-select mode.

    I agree — perhaps the scare quotes were a bit excessive. For certain, it’s intended behavior; it was never a bug that was presented as a feature to avoid dealing with it.

    I think that for users like me, who use rectangular selections frequently and multiple selections rarely, the improvements to multiple selection in the early 8.x releases felt like a degradation in user experience. Some of that has been mitigated by the Multi-Editing options (though, for example, turning off the ability to create multiple selections when you do want them is an unfortunate trade-off for not breaking normal drag-copy conventions… but if I recall correctly, that binary choice is baked into Scintilla, so it would be fragile at best for Notepad++ to attempt something different).

    I imagine it appears exactly reversed to people who use multiple selections often and rarely want rectangular selections: they probably wish the distinction could be eliminated so they didn’t have to keep track of different behaviors when a rectangular selection hasn’t been changed to a multiple selection.

  • 0 Votes
    3 Posts
    64 Views
    PeterJonesP

    @David-Fox said in How do I pass a parameter to a locally store webpage from the context (right click) menu?:

    I’m trying to get a locally stored html file to run from the context menu.

    Commands that are in the run menu also need to be runnable from the cmd.exe window (except with the full value pasted in – and, in the case of URLs, also must prefix the command with START).

    If you try to execute your command with the START prefix, in cmd.exe, you will see it does the same thing:

    START file:///E:/dwgs/Json/OSM_Tag_History/index.html?node/6135938647

    that is, it drops the query parameters. It’s a “feature” of Windows (and the shell execute or similar syntax), and not something that’s Notepad++'s fault.

    Pasting this into the browser’s URL bar the data is received & loaded

    You might then try sending the file:///E:/dwgs/Json/OSM_tag_history/index.html?$(CURRENT_WORD) as a command-line parameter to your browser’s executable (using correct syntax), insead of relying on Windows cmd interpreter. Maybe something like

    mybrowser.exe file:///E:/dwgs/Json/OSM_tag_history/index.html?$(CURRENT_WORD)
  • 0 Votes
    3 Posts
    93 Views
    Mark D Worthen PsyDM

    @PeterJones Thank you for explaining everything so well. I really appreciate it. All the best - Mark

  • 0 Votes
    2 Posts
    49 Views
    Alan KilbornA

    @Michel-Merlin

    You can customize the right-click context menu for your own use; consult the user manual (found via the ? menu in Notepad++) for details on how.

  • Fighting Malicious Ads on Download Pages

    Pinned Security
    39
    3 Votes
    39 Posts
    17k Views
    G

    @PeterJones no problem

  • 1 Votes
    4 Posts
    121 Views
    Terry RT

    @Prelle said in Window loses focus a few seconds into typing after update to v8.8.3 - Windows 11:

    i don’t know that any specific window gets focus

    I did a quick check (and test). If the status bar in Windows doesn’t indicate which window is active by colouring the icon for it differently, then use the Alt + tab key once and hold the alt key down. The window which appears should show open windows. The one highlighted is now the new one, and possibly the one to the left is what was the active window before hitting the alt + tab key.

    I’ve never had the “always on top” option in use, so I don’t know what the ramifications are for it in operation.

    Terry

  • XBrackets 2.0 is coming!

    Notepad++ & Plugin Development
    6
    4 Votes
    6 Posts
    345 Views
    Vitalii DovganV

    The further experiments show that not everything is so good with SCN_UPDATEUI and SCI_SETSTYLING. Sometimes the caret stops blinking or just disappears. Sometimes one of the brackets is not repainted.
    I think I’ll try to play with something like PostMessage(NPPM_MSGTOPLUGIN, XBRM_HIGHLIGHTBR) in order to send SCI_SETSTYLING outside of the SCN_UPDATEUI handler.
    If that will not work, then I’ll try SCI_INDICSETSTYLE and SCI_INDICATORFILLRANGE as suggested by AI.
    Anyway, if you have a better idea, please let me know!

  • Strong Flickering

    Help wanted · · · – – – · · ·
    5
    0 Votes
    5 Posts
    115 Views
    BUILMOND interactiveB

    Alright Thanks to all of you for the Instructions,

    the Rendering Mode wasnt the Case, I Updated the Nvidia Driver and then Restarted the Laptop and Found out that My Windows did updated too through the Restart, So Weather it was the Windows update or the Nvidia Graphics Driver update,

    THE ISSUE IS FIXED :)))

    Thank You All ♥

  • 0 Votes
    2 Posts
    84 Views
    mathlete2M

    @pbarney some plugins have separate settings that are stored in their own INI files - you can find these files in %appdata%\Notepad++\plugins\config. I don’t know if the cloud feature extends to these files, but if so, it’s possible that you have to add these files to your cloud manually. If they are already there, try comparing the files on your cloud to the ones on your local machine to see what might have changed.

  • 0 Votes
    2 Posts
    47 Views
    CoisesC

    @The-Hitman:

    Exactly what you’re asking — to highlight all the text following the equals signs and then sort on that — is, to the best of my knowledge, not possible. Since the equals signs don’t line up, you’d be creating a multiple selection rather than a rectangular selection, and the sort functions don’t work on multiple selections. So even if you got your selection, you wouldn’t be able to sort it.

    However, there are ways to accomplish what you want. One thing isn’t quite clear to me: in your example, both the numbers in brackets after the capital Ms at the beginning of each line and text to the right of the equals signs are in ascending order — but presumably, if you need to sort, the text parts don’t start out in ascending order. Do you want to sort the text part of the lines only, so that the numbers stay in order and the text gets associated with different numbers? Or are the numbers supposed to move with their associated text, so that the text will be in order but the numbers will no longer be in order?

    Either way, it can be done without too much difficulty. The key step is to temporarily right-justify all the numbers, so the equals signs line up:

    M[ 97]=DM-Elysium:1 M[ 98]=DM-Enemyatthegates:2 M[ 99]=DM-EternalWinter:2 M[100]=DM-FactoryTown:3 M[101]=DM-Fastfood:1 M[102]=DM-FAT-Musashi][:2

    You can do that by creating a zero-width column selection in front of the numbers from 10 to 99 and typing a space, and similarly adding two spaces before the single digit numbers; or you can use regular expression replacement to add the blanks. (With either method, you could also add zeros instead of blanks if you like those better.)

    You might not know how to do either of those things. If you don’t, please first try reading the sections in the online manual titled Selection modes & Column Editor and Regular Expressions. (Sorry to be indirect about answering your question, but these are basic skills for using Notepad++ effectively. It is worth learning how these things work so you’ll know how to solve other problems in the future.)

    Once you have the equals signs lined up, you can create a zero-width column selection just after the equal signs and use one of the sort commands to sort the result. (If you wanted the numbers to stay in order rather than move with the associated text, just use Edit | Column Editor… to renumber after sorting.) Then use regular expression replacement to remove the unwanted blanks.

    There is an alternative method, using the Columns++ plugin which is available in the Plugins Admin. Custom sorts in Columns++ allow you to specify a regular expression which matches the sort key in each line; so, instead of manipulating the lines to line up the sort fields, you’d use an expression like =.* to identify the sort key. Unless you already have that plugin installed, this would probably be more complicated for your case than the method described above, but it is an approach that could be useful in similar but more complex cases (or for those who already use that plugin).

  • 0 Votes
    3 Posts
    45 Views
    Alex HlebnikA

    @Coises Joo! Thank you! It’s work!
    Case is closed

  • 0 Votes
    8 Posts
    36k Views
    Mark OlsonM

    @Antheds-Kennel
    (?:foo|bar|baz|quz) matches any of foo, bar, baz, or quz.
    (foo|bar|baz|quz) does the same, but then the matched word can be back-referenced.

    You can combine that with some of the regex recipes earlier in this thread, as well as the official Notepad++ regex documentation, to figure out how to solve your problem.

  • 0 Votes
    8 Posts
    367 Views
    Lycan ThropeL

    @PeterJones ,
    I have this love/hate thing when using auto correct systems (Android for example) versus autocompletion and it types a completely different word than I intended because fat fingers hit the wrong key on the mini screen keypad. :-(

  • 0 Votes
    5 Posts
    131 Views
    Lycan ThropeL

    @PeterJones ,
    This is the hardest part of doing the UDL’s I think. Even after we’ve done the original dBASE UDL you helped with, I’m finding that doing the earlier versions now, and fine-tuning the keywords, operators and the nesting precedents was the most confusing and finer control over the language. Doing the earlier versions I’ve figured out how to keep an apostrophe, from screwing up my code highlighting, while still keeping it as a delimiter by simply NOT allowing it to be included in the other delimiters nesting options. In turn, dBASE also has a JSON object, and with a little fine tuning, I was able to make the delimiters in dBASE also work to outline a JSON structure, so far. If there are other options in a JSON structure I’ll have to learn that as I go, but for now, the simple W3C version showing it, it works right, as well as the dBASE delimiters without messing things up.

    Obviously a quick UDL is possible with just the categories to put things in, but I’m finding that the real power of the UDL system is in the finer use of the mechanisms like the nesting, differentiation of forward search/backward search, prefix mode, etc works much better when combined to get a desired result. It’s actually much more powerful than I originally figured. I wish I’d had a good explanation/example like you’ve done, back then…although, with so much to include to make a UDL almost a complete language system, it would have probably been too much to absorb at the time and would not have availed me much improvement at the time. It’s something that requires a lot of trial and error and understanding of the mechanisms and time playing with it, I think, to get things just right, if it’s at all possible to do. :-)

  • 1 Votes
    36 Posts
    13k Views
    K

    I’ve experienced something similar - Notepad++ will begin to occasionally corrupt files when I try to save them to a network drive. I can tell when it’s going to happen because it will not respond “not responding” for about 5-10 seconds, then display that error message. And it corrupts the file!!! When I’m heavily coding, this happens constantly. I have to make back-up copies constantly since it WILL corrupt the files! Extremely frustrating. This has only started being a problem within the past 2 ? updates.

  • 0 Votes
    4 Posts
    197 Views
    A

    @BrenMar

    Are you using Comodo AV by any chance?

    If so, add Notepad++ to the HIPS section as an ‘allowed application’.

    I normally get a pop-up asking to do that, but for versions 8.8.3 and later this wasn’t happening.

    Hope this helps.

  • 0 Votes
    11 Posts
    103 Views
    PeterJonesP

    @Atomiser said in File Open is bugged in versions later than 8.8.2:

    was ‘HIPS’ in Comodo.

    Glad you found it

  • .Net versions

    Notepad++ & Plugin Development
    5
    0 Votes
    5 Posts
    240 Views
    General CoderG

    @rdipardo Thanks! i didnt know that modern C# plugin support existed
    I’m probably going to give that a try, for now i’m just going with 4.8

  • 0 Votes
    3 Posts
    100 Views
    Dimitris TheocharidisD

    @Alan-Kilborn nice one, yes, it can be done just to read, and to have the line number of the original file. I guess, it is the only way, but not a very convenient one, because links are lost, and it becomes absolutly manual… Thank you for answering!!!

  • 0 Votes
    3 Posts
    320 Views
    V

    @PeterJones said in Hide horizontal line at folds?:

    editor.setElementColour(ELEMENT.FOLD_LINE, (0,0,255,255))
    where the color is (RED,GREEN,BLUE,ALPHA)

    And hiding it completely can be done by either setting the ALPHA to 0

    Yes, surprisingly this works.
    While:

    or editor.setFoldFlags(0) in PythonScript

    no, not by itself: it would leave behind a green line as if text were hidden with View/Hide Lines . As the other thread showed, that command would need to be followed by additional commands to set the Alpha of those “hidden lines’line” to 0. The full equivalent in Python would be:

    editor.setFoldFlags(0) old_col=editor.getElementColour(ELEMENT.HIDDEN_LINE ) new_col=old_col[:3]+(0,) # 0 for alpha, to hide; 255 to show editor.setElementColour(ELEMENT.HIDDEN_LINE, new_col)

    I find it puzzling that the latter solution requires further changing the "hidden lines’ line " colour, while:
    editor.setElementColour(ELEMENT.FOLD_LINE, (x,x,x,0))
    is enough by itself.
    At first I thought it’s a PythonScript behind the scenes trick, but it works in NppExec too, for example with:
    SCI_SENDMSG SCI_SETELEMENTCOLOUR SC_ELEMENT_FOLD_LINE 0x00000000
    (the relevant Alpha part is the first 2 0s , making color transparent/invisible).