• I noticed that the Find dialog is now RESIZEABLE. Cool! This opens up some space on the “word”, “case” and “wrap” checkboxes…I was thinking of customizing the text on those to put some regex help text on there (to the right of the existing text) as a mind-jogger when I’m writing a regex search. I know I was able to customize the text on menus and controls in the past with Notepad++, but I can’t seem to remember how I did that–or at least what I think I remember isn’t working. Is there a tutorial or a posting on how to do that? (Search on this site is POOR).

  • @Claudia-Frank

    Hi Claudia, I forgot about this for a while. :(

    But now I’m interested again.

    I looked up how to install a clipboard viewer in the chain using C and the Windows API, and I am a little familiar with Python’s ctypes, but I don’t really see how to put it all together. The first thing I’m confused on is the hwnd I would use…but I’m sure there’s more. Can you possibly show me how to do this? TIA…

  • I needed to make a record and sign in just to state this is a portion of the most astute thing that I’ve perused in a while I truly like www.proessay.co.uk

  • this is amazing post of Write my Assignment thanks for sharing this educational post.

  • Hello, @evertdb, @scott-sumner and All,

    Here is my contribution to the general padding problem, at end of lines. As in the Scott's solution, above, it uses two consecutive regex S/R

    So, EvertDB, let’s suppose the original test example, below :

    ;; 1 ;; 12 ;; 123 ;; 1234 ;; 12345 ;; 123456 ;; 1234567 ;; 12345678 ;; 123456789 ;; 1234567890 ;; 12345678901 ;; 123456789012 ;; 1234567890123 ;; 12345678901234 ;; 123456789012345 ;; 1234567890123456 ;; 12345678901234567 ;; 123456789012345678 ;; 1234567890123456789 ;; 12345678901234567890 ;; 123456789012345678901

    As I suppose that the two leading semicolons is the line-comment syntax, in your language, perform, the first S/R, below :

    SEARCH (?-s)^;;.+

    REPLACE $0 ==============================

    Notes :

    First, due to the (?-s) syntax, the special dot character will stand, strictly, for any single standard character

    Then, in the searched part, we’re just looking for two semicolons, at beginning of lines, followed by a non-null amount of standard characters

    In replacement, we, simply, rewrite the complete searched match, followed with a space character and 30 equal signs.

    From your example, it happens that the minimum, of equal signs to add, is 21. But, you don’t have to bother about estimating that minimum. Just add a large enough amount of this character, at the end of the replacement regex

    So, we get the modified text, below :

    ;; 1 ============================== ;; 12 ============================== ;; 123 ============================== ;; 1234 ============================== ;; 12345 ============================== ;; 123456 ============================== ;; 1234567 ============================== ;; 12345678 ============================== ;; 123456789 ============================== ;; 1234567890 ============================== ;; 12345678901 ============================== ;; 123456789012 ============================== ;; 1234567890123 ============================== ;; 12345678901234 ============================== ;; 123456789012345 ============================== ;; 1234567890123456 ============================== ;; 12345678901234567 ============================== ;; 123456789012345678 ============================== ;; 1234567890123456789 ============================== ;; 12345678901234567890 ============================== ;; 123456789012345678901 ==============================

    Now, we just have to delete the extra equal signs at the end of each line. To do so, this second S/R needs the number of characters, at beginning of each line, after the two semicolons symbols, which must be preserved !

    From your example, below, you can, visually, determine that this number is 24 :

    ;; foo bar =============== 123456789012345678901234

    So, we’ll use the following regex S/R, below :

    SEARCH (?-s)^;;.{24}\K.+

    REPLACE Leave Empty

    Notes :

    For the first part (?-s), just refer the notes, above

    The part ^;;.{24} looks, from beginning of each line ( ^ ), for two semicolons, followed by the next 24 characters

    Then the part \K resets the regex engine working position and forgets the immediate previous search

    Therefore, the final regex match, is, simply, .+, which stands for any non-null amount of standard characters, after the absolute location 24, till the end of each line

    Empty replacement regex means that this ending amount of characters is just deleted

    IMPORTANT :

    For this second S/R, due to the \K regex feature, you must, exclusively use the Replace All button ( NOT the step-by-step Replace button ! )

    And, we obtain the final text, with a lined-up padding of equal characters, at the end of each line :

    ;; 1 ===================== ;; 12 ==================== ;; 123 =================== ;; 1234 ================== ;; 12345 ================= ;; 123456 ================ ;; 1234567 =============== ;; 12345678 ============== ;; 123456789 ============= ;; 1234567890 ============ ;; 12345678901 =========== ;; 123456789012 ========== ;; 1234567890123 ========= ;; 12345678901234 ======== ;; 123456789012345 ======= ;; 1234567890123456 ====== ;; 12345678901234567 ===== ;; 123456789012345678 ==== ;; 1234567890123456789 === ;; 12345678901234567890 == ;; 123456789012345678901 =

    Et voilà !

    Finally, EvertDB, to be exact, we need to get rid of any empty comment line, located right above each real comment-line. To that purpose, use the regex S/R, below :

    SEARCH (?-s)^;;\R(?=^;;.+)

    REPLACE Leave Empty

    Notes :

    For the first part (?-s), just refer the notes, above

    The part ^;;\R looks for two semicolons, at beginning of each line, immediately followed by End of Line character(s), whatever it is/they are !

    The part (?=........) is a positive look-ahead, in other words, a condition which must be true, for an overall match

    The condition, to respect, is the regex ^;;.+, which represents a non-empty comment line, in your language ( two semicolons, followed by a non-mull amount of standard characters, before the end of the line )

    Due to empty replacement, the searched regex ( the null-comment line ) is, simply, deleted

    Best Regards,

    guy038

    P.S. :

    For padding characters, at beginning of a list, you may refer to the topic, below :

    https://notepad-plus-plus.org/community/topic/13988/find-replace-issues/5

  • Hello
    do you think that its possible to move a block not to the bottom but to the top?
    i dont succeed
    i mean that in this example, how to move <img etc… and …style=“display:none;”></div> just before <noscript class"text" lang=“example”>

    1.html
    <noscript class"text" lang=“example”>
    line1
    line2
    line3
    line4
    </noscript>
    some text…
    etc…
    etc
    <img… and …style=“display:none;”></div>

    2.html
    <noscript class"text" lang=“otherexample”>
    otherline1
    otherline2
    otherline3
    otherline4
    </noscript>
    othersome text…
    etc…
    etc etc
    <img… other and …style=“display:none;”></div>

  • This is one of the most informative and educational posts. Actually, I’m searching this kind of material. Thank you so much for sharing this post. More details to follow Case-Study.

  • I got it to my relevant information from here. Thank you so much for sharing this post. Here is a link to my Website.

  • I am such a phenomenal measure of animated coming about to analyzing your blog. Your blog is particularly innovative and much relentless for any industry and what’s more for an individual. For more info, Click Here

  • Hello, @rafał-kowalski,

    My idea is to find, with a regex, a 00:00:00 time template, ONLY IF it’s followed, further on, by an other 00:00:00 time template and to store this second time template, in a group, for further use in replacement

    To that purpose, we’ll use a positive look-ahead structure ( a condition which have to be true for an overall match, but which is never part of the final regex )

    So, the regex S/R could be :

    SEARCH (?s)\d\d:\d\d:\d\d(?=.+?(\d\d:\d\d:\d\d))

    REPLACE $0 \1

    Notes :

    The first part, (?s), is a modifier, which means that the dot special character stands for any single character ( Standard or EOL ones )

    Then the second part, \d\d:\d\d:\d\d, is the final text to find ( a 00:00::00 time template )

    Now, the third part,(?=.........), is the positive look-ahead feature, which have to be true

    Finally, the fourth part, .+?(\d\d:\d\d:\d\d), is the condition to respect :

    .+? represents the shortest, non-null, range of any character, even split on several lines

    (\d\d:\d\d:\d\d) is the nearest following 00:00:00 time template, which is stored as group 1, due to the surrounded parentheses

    In replacement, we re-writes, first, the whole searched string ( $0 ), followed with a space character, and ended with the group 1 ( \1 ), which represents the second time template

    REMARK :

    It is important to point out that, when evaluating the condition .+?(\d\d:\d\d:\d\d, inside the look-ahead, the character position, used by the regex engine, is, finally, NOT moved and is still located, right after the last digit of the first time template ( the final regex to look for ), even if, somehow, it had to go ahead, till the end of the second 00:00:00 time template, in order to verify the condition )

    So starting with your original text, below :

    00:01:11 fdfdfdfdfdfdf 00:02:12 hjhgjjjjjjjjjjg 00:03:22 hgffggggggg 00:04:14 hjghhhghggg

    This S/R would produce the text, below :

    00:01:11 00:02:12 fdfdfdfdfdfdf 00:02:12 00:03:22 hjhgjjjjjjjjjjg 00:03:22 00:04:14 hgffggggggg 00:04:14 hjghhhghggg

    Et voilà !

    Best Regards,

    guy038

  • You’re probably right, but I’m not happy with the workarounds for two reasons. First, they require 3rd party plugins. I’m trying to keep the footprint of NPP as small as possible and the plugins just add more bloat. Second, when using NPP across a large number of computers, the workaround has to be performed on every machine. I can’t just tell users to go into settings and change it to whatever they prefer. Unless there’s some underlying technical issue, It seems like an easy change to make since it’s already available in the Style Configurator, it’s just grayed out.

    Rich

  • @Vince-kuzanagi

    I tried it on similar data with 2000 lines with no problem.

    Can you post your complete BEFORE and AFTER text (maybe on textuploader.com) that this problem happens with? [Make sure the problem happens with the XXX’s rather than just the real phone numbers…I’m sure you don’t want to post the real phone numbers…]

    Also try to describe exactly what you do: where is your caret before you start?, etc. Sometimes there is more to what you are doing than you say, and that can be the thing(s) that reveal a bug…

    Also, what version of Notepad++, including whether or not it is a 32 or 64 bit version.

  • What made me think about it was long registry files, where I wanted to delete differently named keys with similar values.

  • @Капитан-Маузер

    If you mean what I think you do about non-breaking space, try this Find:

    Find-what box: \xA0
    Search mode: ☑ Regular expression

    If this posting was useful, don’t post a “thanks”, just upvote ( click the ^ in the ^ 0 v area on the right )

  • @Antonio-Rojas-Carmona Tienes que usar el menu Settings, y luego Style Configurator. En la ventana siguente, verás junto a “Select Theme” una lista que dice algo así como “Default (stylers.xml)”. Allí aparecen varios temas con diferentes combinaciones de colores, solo tienes que elegir el más apropriado, por ejemplo Deep Black.

  • @zhangyuhangk

    Instead of using “Join Lines” you could do a regular expression replace-all operation:

    Find-what box: \R
    Replace-with box: make sure this box is EMPTY
    Search mode: ☑ Regular expression
    ☑ Wrap around (maybe…depending upon what you want…)
    “Join Lines” works on the active selection; if you want the replace operation to do likewise, then: ☑ In selection

    If this posting was useful, don’t post a “thanks”, just upvote ( click the ^ in the ^ 0 v area on the right )

  • This happens when files are marked as “read-only”, but in that case, you can not make changes because editing is disabled.

Internal error.

Oops! Looks like something went wrong!