Community
    • Login

    multi-part keywords folding doesn't work in other languages

    Scheduled Pinned Locked Moved Help wanted · · · – – – · · ·
    4 Posts 2 Posters 338 Views
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • Pillow DarkP
      Pillow Dark
      last edited by

      As you can see in this example open and close keywords cannot be found if they are written in other language and in quotation marks
      8626a46e-733b-42ce-8044-89d35943cb28-image.png 74b490d4-427d-4d60-8544-d6a3bd58a0b4-image.png
      Without quotation marks works just fine
      ca539cfe-ccfb-41ef-b827-76901f69dba6-image.png e4ec4e7b-f852-443f-8320-100f873b7ed3-image.png
      And in english too
      ca28b1eb-b7da-4691-9575-e3fc03fa2d75-image.png fe0335d8-b0b0-4bcc-8cf1-3f34251cc1ce-image.png
      Maybe it’s encoding problem but i’m not shure

      1 Reply Last reply Reply Quote 1
      • Pillow DarkP
        Pillow Dark
        last edited by

        I’m curious if this was intended or not.
        P.S. sorry for bad English.

        PeterJonesP 1 Reply Last reply Reply Quote 0
        • PeterJonesP
          PeterJones @Pillow Dark
          last edited by PeterJones

          @Pillow-Dark ,

          Unfortunately, the bulk of the User Defined Language (UDL) system was built without encoding in mind, so many of the entries – including the code-folding – don’t properly handle non-ASCII characters.

          There are, unfortunately, many open issues regarding UDL. And at least a half-dozen that I could find that were about UDL’s inadequacies with respect to non-ASCII characters:

          • https://github.com/notepad-plus-plus/notepad-plus-plus/issues/8562
          • https://github.com/notepad-plus-plus/notepad-plus-plus/issues/8399
          • https://github.com/notepad-plus-plus/notepad-plus-plus/issues/6197
          • https://github.com/notepad-plus-plus/notepad-plus-plus/issues/6014
          • https://github.com/notepad-plus-plus/notepad-plus-plus/issues/4742
          • https://github.com/notepad-plus-plus/notepad-plus-plus/issues/4688

          Maybe if more people would upvote those, and provide more examples that it’s still not working, the developers would prioritize UDL fixes.

          If you are willing to install a plugin like PythonScript, it’s likely possible to script a solution – I believe that it’s possible to affect code folding from a scripting plugin, similar to the way that @Ekopalypse used regex to enhance any lexer (UDL or builtin), but I’ve never played around with that, and don’t have as much time for PythonScript hacking as I used to. If you give it a go, but get stuck, show us what you have, and we can likely provide advice; or, if it catches someone’s interest, there may be someone here with the time to give it a go and get you to a good head start.

          Sorry I don’t have better news, or a fully-functional workaround, for you.

          1 Reply Last reply Reply Quote 0
          • Pillow DarkP
            Pillow Dark
            last edited by

            @PeterJones thanks for the explanation. Maybe I’ll try to fix this myself, but I dont feel confident.

            1 Reply Last reply Reply Quote 1
            • First post
              Last post
            The Community of users of the Notepad++ text editor.
            Powered by NodeBB | Contributors