• 2 Votes
    25 Posts
    4k Views
    Terry RT

    @Alan-Kilborn said in Use of "Wrap Around" changing start position of search if "Replace All" button pressed:

    Is THIS your ver 0.3 proposal? :-)

    Hell NO! Without the smiley face I was thinking you’re serious. Hopefully you don’t think of me capable of doing THAT! That’s way too many options on 1 window. Interfaces need to be kept simple and unconfusing.
    My version 0.3 is this:

    768fc25b-fc69-417e-a095-91af57ec71ad-image.png

    where I looked at combining both “Replace All…” buttons like a jigsaw. So it would be purely a visual change. All 3 of these concepts were just intended to reduce confusion as we have talked about. Not that I’m confused anymore, I know exactly what “Replace All” and “Wrap around” selected do now.

    However with a seemingly lackluster response to my ideas I don’t know that I’ll bother presenting it on github. I presume to catch the eyes of the developers that’s the next step. I haven’t even got a github account.

    Terry

  • Automatically apply style token when highlighting text?

    8
    1 Votes
    8 Posts
    2k Views
    Alan KilbornA

    Another method is to copy only the lines pertaining to the macro out of your shortcuts.xml and have your users put those same lines in theirs. I neglected to mention this, because, for unsophisticated users, this is probably the MOST complicated and error-prone approach.

  • Multi lines cursor manipulations

    5
    0 Votes
    5 Posts
    2k Views
    Alan KilbornA

    @Mik-Tilk said in Multi lines cursor manipulations:

    Why they exist separated?

    Because you might want to do this for some reason:

    cbaeaccf-c12e-4872-89aa-39064aa3d466-image.png

    In other words, make 4 selections (in the example) that are NOT in related columns.

  • SCC API Plugin?

    4
    0 Votes
    4 Posts
    285 Views
    Michael VincentM

    @Dan-Cooperstock said in SCC API Plugin?:

    none of which we use

    Which one do you use?

  • Find the maximum line length in a file

    6
    4 Votes
    6 Posts
    4k Views
    Alan KilbornA

    @Nick-Brown said in Find the maximum line length in a file:

    nice additions in the helper functions forEachLine

    When I first started using PS, I noticed some weirdness with forEachLine that of course I can’t remember these many years later, but since then I’ve steered clear of it. Perhaps I was doing something wrong with it, or maybe there truly was something wrong with it that has since been fixed.

  • Scam website that pretend be able to download Notepad++

    2
    0 Votes
    2 Posts
    633 Views
    PeterJonesP

    @Rin5743 ,

    Thank you for letting us know. To make sure that @donho is informed, you might want to post the same thing as an issue at https://github.com/notepad-plus-plus/notepad-plus-plus/issues

    As always, we recommend only downloading Notepad++ from the official source – either notepad-plus-plus.org/downloads or the github repo at github.com/notepad-plus-plus/notepad-plus-plus .

  • Unwanted Font Size Change

    2
    0 Votes
    2 Posts
    259 Views
    guy038G

    Hello, @freon-sandoz and All,

    If you want to disable the mouse zoom OR the keyboard zoom OR both features, in Notepad++, just use the ZoomDisabler plugin :

    https://github.com/StanDog/npp-zoomdisabler

    Best Regards

    guy038

  • How do I make an "user-defined language"?

    3
    0 Votes
    3 Posts
    2k Views
    Quality Books100Q

    Ok, thanks.
    This helped me.

  • 1 Votes
    4 Posts
    766 Views
    Alan KilbornA

    So I ended up scripting a little mock up demo of this, which I won’t post unless there’s interest, but really there’s only a couple of new things that need to happen after a search match to make this work:

    find the number of lines shown on screen

    set the first visible line to a correct value (based upon the starting line of a find match, and the number of lines shown on screen, and of course the desired effect specified by the OP)

    hmm, maybe it gets a tad more complicated if text between the match and the top of screen has folded/hidden lines…

    However, looking at how N++ moves the display/selection when a match is found, there seems to be a lot going on with the logic, so I’m not sure how well any changes would fit in.

  • How to delete all, except predefined values

    5
    0 Votes
    5 Posts
    241 Views
    Bas CurtizB

    @guy038 said in How to delete all, except predefined values:

    \u\1(?2\2:\x20)\x20M\L\3

    @Ekopalypse @guy038
    Thank you guys for thinking along with me!

    @guy038 Does EXACTLY what I want - thanks again.

  • Huge lines

    8
    0 Votes
    8 Posts
    622 Views
    Antti AlhoA

    I had this exact same thing happening.

    Not a day old Windows 10 installation.
    I noticed that my disk management started to behave rather strangely and after which I noticed HUGE line margins on np++

    f1593f0a-5956-46b6-af64-6c88464e99ef-image.png

    I do have a small 200kb video of how my disk management is behaving. But I cant embed it here. Says not enough privileges. It seems that disk management is using same windowing system so maybe these things are related?

  • How to remove part of a phrase multiple times

    5
    0 Votes
    5 Posts
    247 Views
    PeterJonesP

    @Anandkumar-Prajapati ,

    I am curious what you were trying to accomplish with your post. It was nearly identical content to Guy’s post. The places where you varied from Guy’s were either inconsequential, or nearly so for the original data shown.

    If you have a unique point you were trying to make with your slight differences, I don’t know what that point was – so if it really is trying to make a point, please explain yourself more. It might be educational for the original poster or future readers to know why you made the choices you did – but only if you explain why.

    Otherwise, I want to point out that rephrasing advice that has already been given looks a lot like trying to take credit for someone else’s work – which is highly frowned upon (to say the least). I try to give the benefit of the doubt in such circumstances, so I am not saying that it was intentional; but it is a good idea to read the whole thread before posting, and to try to avoid giving the same advice without adding anything new, in an effort to avoid such appearances.

  • Replace help

    18
    0 Votes
    18 Posts
    624 Views
    EkopalypseE

    @Ekopalypse said in Replace help:

    Really, I’m getting old and confused :-D

    once again …

  • Put 2 single quotation marks around a number

    2
    0 Votes
    2 Posts
    2k Views
    PeterJonesP

    @Doug-Tatom

    The naive interpretation of what you stated:

    FIND = \d+
    find one or more digit characters in a row REPLACE = '$0'
    replace it with a single quote, the contents of the match, and a single quote SEARCH MODE = regular expression

    Unfortunately, with how little you told us, I was not able to protect that expression against edge cases. If you give us better examples (see the italics below), you will get better answers

    ----

    Do you want regex search/replace help? Then please be patient and polite, show some effort, and be willing to learn; answer questions and requests for clarification that are made of you. All example text should be marked as literal text using the </> toolbar button or manual Markdown syntax. To make regex in red (and so they keep their special characters like *), use backticks, like `^.*?blah.*?\z`. Screenshots can be pasted from the clipboard to your post using Ctrl+V to show graphical items, but any text should be included as literal text in your post so we can easily copy/paste your data. Show the data you have and the text you want to get from that data; include examples of things that should match and be transformed, and things that don’t match and should be left alone; show edge cases and make sure you examples are as varied as your real data. Show the regex you already tried, and why you thought it should work; tell us what’s wrong with what you do get. Read the official NPP Searching / Regex docs and the forum’s Regular Expression FAQ. If you follow these guidelines, you’re much more likely to get helpful replies that solve your problem in the shortest number of tries.

  • Replace help

    8
    0 Votes
    8 Posts
    251 Views
    Y MY

    Okay thanks, it works !

  • Help with Replace

    2
    0 Votes
    2 Posts
    142 Views
    EkopalypseE

    @Otto-Scho

    In the search dialogue, check the regular expression checkbox and use the following search term FOG.+?\b to replace it with an empty string.

  • BUG: NPP Crashes when menu bar hidden and right click

    4
    0 Votes
    4 Posts
    537 Views
    Juan de DiosJ

    @Syhnd Thank you! Deleting the MenuIcons plugin fixed npp crashing for me.

  • 0 Votes
    3 Posts
    2k Views
    astrosofistaA

    @PeterJones said in How do you insert <br> or other HTML Tags into the document you're eiting?:

    Or easier than writing a script, and without the PythonScript, you could record macros which cut the currently-selected text, type the opening tag, paste the text, and type the closing tag (which, in effect, surrounds the currently-selected text with that chosen tag pair). And, like the script option above, the macros could be assigned to the keyboard shortcuts desired.

    @Tom-Sims Expanding the fine @PeterJones’ advice, here is an example of a macro that inserts <br>selection<br>, which you can easily adapt to your needs.

  • Original String Order

    8
    0 Votes
    8 Posts
    438 Views
    Terry RT

    @Nicola-Vento said in Original String Order:

    Alternatively, is there a way to know the string ordering of the original file so that I can put it in the edited file?

    There is one thing you could do, although that means adding text to the file whilst editing it. You could add the original line number to each line, then move that to the end of each line. Then when ordering it alphabetically the number would not interfere with the new ordering. Once editing is complete you could move that number back to the start of the line, re-order based on the number and then remove the number.

    This is achieved through the “Column Editor” function. You would have the cursor in the very first position of the file, use the Column editor to add a number, starting at 1, adding 1, no repeat and have the “leading zeros” ticked. Then use a regex (regular expression) to move that number to the end of each line. Continue with your editing.

    Lastly move the number back to the start of each line using another regex, order by number and then a final regex to remove the number.

    Terry

  • Deactivate "Are you sure......" dialogue

    10
    0 Votes
    10 Posts
    572 Views
    Laurie ML

    Thanks for clarifying my query and most of all for the solution which I was danged if i could find!