• Preferences not saving

    2
    0 Votes
    2 Posts
    154 Views
    EkopalypseE

    I don’t really understand your problem, can you elaborate on it?

  • Breaking one text file to multiple files.

    2
    0 Votes
    2 Posts
    252 Views
    dailD

    What have you tried so far?

  • Regex Help to replace text except when it matches a string

    5
    0 Votes
    5 Posts
    455 Views
    guy038G

    Hello, @alfred-streich, @alan-kilborn and All,

    As, seemingly, all lines, which must be joined to their previous line, do not contain any colon symbol ( : ), an alternate syntax, to the Alan’s one, could be :

    SEARCH (?-i)</para>\h*\R+\h*<para>(?![^\r\n]+:)

    REPLACE \x20

    Notes :

    First, the in-line modifier (?-i) forces a non-insensitive search process

    The part \h*\R+\h* matches any range of horizontal blank char(s) ( Space and Tab ), even null, followed with a non null range of line-breaks ( \r\n, \n or \r ), itself followed with an other possible range of blank char(s)

    The part (?![^\r\n]+:) is a negative look-ahead structure, which defines a necessary condition for the overall regex to match, although not part of the final match, and looks for a line with does not contain any colon character, after the literal string <para> till its line-break

    Note that the [^\r\n]+ defines a non-null of characters, different of EOL chars. So, any char after <para> till the colon symbol : !

    In replacement, the syntax \x20 is the hexadecimal representation of a space character and you may, as well, write a single space char in the Replace with: zone

    Best regards,

    guy038

  • Disable Find Autocomplete

    6
    0 Votes
    6 Posts
    640 Views
    Alan KilbornA

    @Hyde233

    reversing the negative

    I think you’re right, and that it would be that way if it was a settable preference from Notepad++ 1.0.

    Notepad++ users are used to it filling the field in; “don’t” seems to flow logically from that, maybe.

    In the end it doesn’t matter: It will never be changed now.

  • ColdFusion Lexer and NPP after (7.5.9)

    11
    0 Votes
    11 Posts
    7k Views
    PeterJonesP

    @Michael-Benoit , the user @Joe-DeRose hasn’t been here since that single post.

    In the intervening 8 months, that old collection has been moved to https://github.com/notepad-plus-plus/userDefinedLanguages, and the specific file he mentioned is
    https://raw.githubusercontent.com/notepad-plus-plus/userDefinedLanguages/master/UDLs/ColdfusionCF9_bySpenster.xml

  • Start notepad++ with administrator rights

    1
    0 Votes
    1 Posts
    160 Views
    No one has replied
  • Set Notepad++ as default app in Windows 10

    14
    0 Votes
    14 Posts
    92k Views
    MordicusM

    @Jason-M-Fruge
    Got this issue recently, could not add a new notepad++ document from contextual menu.
    I followed your solution, but “.txt” was already in supported extensions panel.
    What I’ve done: restarted Notepad++ with admin rights, removed and re-added “.txt”.
    It worked!

  • Simple html tag question

    3
    0 Votes
    3 Posts
    678 Views
    Terry RT

    @Donna-Middleton

    I’ve taken the liberty of providing an example of how it might work, of course having your examples will help immensely.

    In the first block below we see how the lines might look before the html tags are applied. Note I have presumed you already have the <ul> & </ul> code already in place as you ONLY mentioned the <li> and </li> tags. The second block shows the result with my regex applied.

    First you would highlight JUST the lines containing the list items. Very important not to select any additional lines. After this you would use the “Replace” function (Search, Replace). Now as this is a regex we need to select “regular expression” as the search mode. The expression we use is:
    in the Find What window:(?-s)(.+)
    in the Replace window: <li>\1</li> note 2 spaces before as our original text is left justified and we want to indent it 2 positions.
    Before we click on “Replace All” confirm the selection is still in place and then tick the box named “In Selection”. If this box not selectable it means the selection has been lost. Click on “Replace all” button. Confirm your items are now correctly tagged.

    <ul style="list-style-type:circle;"> Coffee Tea Milk </ul>

    and after using the regex we have

    <ul style="list-style-type:circle;"> <li>Coffee</li> <li>Tea</li> <li>Milk</li> </ul>

    Hope this helps, but as I say it is best if you can provide some examples. If the data is sensitive, please do replace with dummy data but the original formatting of your real data needs to remain (tabs, spaces etc) as this can help or hinder the final solution.

    Terry

  • problems with apostrophies

    3
    0 Votes
    3 Posts
    734 Views
    James LongJ

    Alan, you are my hero. Thank you!!

  • 0 Votes
    11 Posts
    2k Views
    John SleeJ

    @Alan-Kilborn Thank you so much, Alan. It’s years since I did any proper programming, though that was a previous occupation. Guess I’m going to have to teach myself to use Python!

  • UDL Breaks

    6
    0 Votes
    6 Posts
    1k Views
    Dan DeweyD

    It happened again so attached are images of:
    the state after the syntax highlighting breaks
    after_issue.jpg
    the state after refreshing the UDL via the language dropdown
    after_refresh.jpg
    the state the code was before the highlighting broke
    before_issue.jpg

    When I make the same modifications again it doesn’t break so it’s not consistent. This was also the very first change I made after opening the file so that might be relevant.

    As a note, that highlighting is as if there is a left quote without matching right quote. However, there isn’t any left quote in the prior code, much less without a matching right quote.

    I had longer snippets from the beginning of the code initially however I work with sensitive information and although it was probably okay I’d rather not risk it.

  • Search fails

    12
    0 Votes
    12 Posts
    3k Views
    hatsa tsaaH

    Thanks guy038 for the tip!

  • 0 Votes
    7 Posts
    385 Views
    R

    Thanks Alan and Ekopalypse. I’ll add something in there…

  • Level Folds with brackets in comments after double slashes

    1
    0 Votes
    1 Posts
    143 Views
    No one has replied
  • find duplicate and copy to other text

    4
    0 Votes
    4 Posts
    1k Views
    EkopalypseE

    Ok, if ordering is not relevant then you could do the following

    edit->line operations->sort line lexicographically ascending
    make sure that last line has an eol
    open find dialog and goto mark tab
    check bookmark line box
    put the following into find box:(.+\R)\1
    press mark all
    use one of the commands from search->bookmarks menu.

  • Number expression as close folding point

    6
    1 Votes
    6 Posts
    437 Views
    André AlbuquerqueA

    Thank you all for the support. The @guy038 work-around is helping for now.

  • How does npp persist and restore files that were opened between startup?

    4
    0 Votes
    4 Posts
    309 Views
    Alan KilbornA

    @ElusiveTau

    But it isn’t always on the “appdata” path. I could be located in the same folder as notepad++.exe is! In fact, that’s my preferred place for it.

  • Seeking Clarification on Entering Alt Keypad Characters

    3
    0 Votes
    3 Posts
    2k Views
    guy038G

    Hello, @haleba-hotmail, @peterjones and All,

    First, in your post, you’re speaking about 2 characters, one char part of the Basic Multilingual Plane ( BMP ) and the other character outside the BMP These are :

    The KATAKANA letter TU ( = TSU ) ( \x{30C4} ), from the Unicode block Katakana, in range 30A0–30FF

    The SHRUG 🤷 portrait symbol ( \x{1F937} ) from the Unicode block Supplemental Symbols and Pictographs, in range 1F900–1F9FF

    The main characteristics of these two chars are :

    Character ツ Character name KATAKANA LETTER TU Hex code point 30C4 Decimal code point 12484 Hex UTF-8 bytes E3 83 84 Octal UTF-8 bytes 343 203 204 UTF-8 bytes as Latin-1 characters bytes ã <83> <84>

    and

    Character 🤷 Character name SHRUG Hex code point 1F937 Decimal code point 129335 Hex UTF-8 bytes F0 9F A4 B7 Octal UTF-8 bytes 360 237 244 267 UTF-8 bytes as Latin-1 characters bytes ð <9F> ¤ · Hex UTF-16 Surrogates D83E DD37

    I got information on these characters, from an useful on-line UTF-8 tool, described in the last section of the post below :

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

    I must say that I did not pay attention, until now, to the Converter plugin, of @don-ho !!

    Seemingly, if you select one or some consecutive character(s) and use the option Plugins > Converter > ASCII -> HEX, it correctly writes the hexadecimal byte(s), needed to encode this/these character(s) in UTF8, or in ANSI for the 255-characters allowed block !

    IMPORTANT : Even if your current encoding is UCS-2 BE BOM or UCS-2 LE BOM, it still shows the hexadecimal bytes, used in an UTF-8 or an UTF-8 BOM file, to encode this/these characters :-( In any case, it’s best to avoid these two encodings because they cannot handle characters which are over the BMP, like your SHRUG symbol !

    For instance, in an UTF-8 file, the selection of the string 🤷Aツé and then the option Plugins > Converter > ASCII -> HEX gives the result F09FA4B741E38384C3A9, because :

    The 🤷 character is coded with the 4-bytes UTF-8 sequence F09FA4B7

    The A character is coded with the 1-byte UTF-8 sequence 41

    The character is coded with the 3-bytes UTF-8 sequence E38384

    The é character is coded with the 2-bytes UTF-8 sequence C3A9

    And, in an ANSI file, the selection of the string , with the option Plugins > Converter > ASCII -> HEX gives the result 41E9 because :

    The A character is coded with the 1-byte ANSI sequence 41

    The é character is coded with the 1-byte ANSI sequence E9

    In the same way, if you select one or some consecutive hexadecimal bytes and use the option Plugins > Converter > HEX -> ASCII, it correctly writes the corresponding glyphs of this/these character(s), produced by the current font, in an UTF-8 or ANSI file. For instance, selecting the sequence F09FA4B741E38384C3A9, does give back our 4chars string 🤷Aツé

    Now, regarding the different Windows input methods, I strongly advice you to read this post, first, where I recapitulate all the different Windows input methods :

    https://community.notepad-plus-plus.org/topic/18903/regex-misidentifying-foreign-characters/6

    And, in its last section, looks the reference to a nice monospaced font, which correctly writes almost the majority of all the Unicode characters, even those which are outside the BMP

    As said in that post, after modifying the registry ( be careful ! ), you may directly insert, for instance, the KATAKANA letter TU, following these steps :

    Hold down the Alt key and, successively :

    Hit the + key, on the numeric keypad

    Hit the 3 key, on the numeric keypad

    Hit the 0 key, on the numeric keypad

    Hit the C key, on the main keyboard

    Hit the 4 key , on the numeric keypad

    Release the Alt key

    => Immediately, the character should be inserted at cursor location ;-))

    However, note that the Shrug symbol cannot be inserted, even using this powerful input method, because its code-point 1F937 is greater than \x{FFFF} ! You’ll have to use, in that case, an on-line tool to get these characters, from their Unicode code-point, in the range \x{10000} - \x{10FFFF}, as, for instance, the UTF-8 tool described above !

    Best Regards,

    guy038

    P.S. : I started writing this post, before the @peterjones reply. Also, some parts may be redundant ;-))

  • Functionlist for HLSL

    1
    0 Votes
    1 Posts
    302 Views
    No one has replied
  • Text file is showing null null

    1
    0 Votes
    1 Posts
    245 Views
    No one has replied