Community
    • Login
    1. Home
    2. Popular
    Log in to post
    • All Time
    • Day
    • Week
    • Month
    • All Topics
    • New Topics
    • Watched Topics
    • Unreplied Topics
    • All categories
    • Murray Sobol 1M

      Idea of a new installation routine

      Watching Ignoring Scheduled Pinned Locked Moved General Discussion
      6
      0 Votes
      6 Posts
      108 Views
      PeterJonesP

      @Murray-Sobol-1 said in Idea of a new installation routine:

      @PeterJones said in Idea of a new installation routine:

      No one should ever download a 32bit installer for modern OS. For any app. (Modern OS don’t come in 32-bit versions anymore, so I don’t understand why apps still bother distributing the 32-bit versions)

      I agree with the above statement, however when I ask for an update by clicking Downloads I see this section:
      Download 32-bit x86
      Installer | GPG Signature
      Portable (zip) | GPG Signature
      Portable (7z) | GPG Signature
      Mini-portable (7z) | GPG Signature

      Why is this even being distributed anymore??

      Because my statement was just my opinion, and not everyone agrees with it. Because there are some people who mistakenly think they need a 32-bit even though they have a 64-bit OS. And there are some people who have some unmaintained plugin that only comes in 32-bit (*). And because the developer has never decided to cut off those poor, unfortunate souls.

      (*: aside: anytime I come across someone like that, I do a bit of research to help them find an alternative, or find someone who has done an unofficial recompile of the plugin for 64-bit. there are very few public plugins that have no 64-bit version and no alternative)

      But that’s why we lobbied to put the 32-bit below the 64-bit, so the 64-bit gets the prominence it deserves – and why I rejoiced when it happened. Someone downloading N++ for the first time will see the 64-bit first, and will likely download that. Someone updating N++ should use the menu or auto-update, and never have to go back to the website.

    • Troglo37T

      Is There a Way to Prevent Pasted Text from Spreading Out with Rows of Spaces?

      Watching Ignoring Scheduled Pinned Locked Moved Help wanted · · · – – – · · ·
      16
      0 Votes
      16 Posts
      939 Views
      mpheathM

      @Troglo37 said in Is There a Way to Prevent Pasted Text from Spreading Out with Rows of Spaces?:

      Is there a way to make it automatic?

      If register a callback to respond to the notification SC_MOD_INSERTCHECK then it can be automated to change the text before insertion. This example code can be added to the user startup.py file. Make sure the PythonScript configuration is set to ATSTARTUP.

      import re def event_paste_single_line(args): SC_MOD_INSERTCHECK = 0x100000 if args['modificationType'] & SC_MOD_INSERTCHECK: text = args['text'] if ' episode\r\n ' in text: result = notepad.messageBox('Paste text as single line?', 'InsertCheck', MESSAGEBOXFLAGS.ICONQUESTION | MESSAGEBOXFLAGS.YESNO) if result == MESSAGEBOXFLAGS.RESULTNO: return text = re.sub(r'\s+', ' ', text) editor.changeInsertion(text) editor.callbackSync(event_paste_single_line, [SCINTILLANOTIFICATION.MODIFIED])

      I added a messagebox to allow a choice rather then being fully automatic with the text change.

    • Carlos SánchezC

      [New plugin] Smart Math

      Watching Ignoring Scheduled Pinned Locked Moved Notepad++ & Plugin Development
      2
      0 Votes
      2 Posts
      15 Views
      PeterJonesP

      @Carlos-Sánchez said in [New plugin] Smart Math:

      I’m a bit lazy and haven’t got a clue

      I can’t solve the first part, but for the clue:

      it’s just a PR to the nppPluginList project. Since you’re working in GitHub already, I assume you know how to do the PR fork the nppPluginList repo, create your own branch in that branch, edit pl.x64.json to link to the 64-bit version, and pl.x86.json to link to the 32-bit version the id required in the JSON is just the SHA256 hash, which GitHub provides for you:
      fd4a838f-9724-477d-b755-24836141dc88-image.png once you have edited both files in your branch, submit the PR from that branch
    • donhoD

      You've a lot of reasons to hate Notepad++

      Watching Ignoring Scheduled Pinned Locked Moved Boycott Notepad++
      91
      5 Votes
      91 Posts
      154k Views
      MJKlodt747M

      @donho Hey!! Don’t ever tell me whuddafugg to-do… I’ll hate WHOEVER I feel like 🤌🏻, WHATEVER I feel like 🤌🏻, WHEN–THA-FUGGG-EVER I FEEL LIKE! 🤌🏻🤌🏻🤌🏻

      Good day sir…🫵🏻 I SAY GOOD DAY!! 🧜🏻‍♂️

    • Guido ThelenG

      C# Plugin for ARM64

      Watching Ignoring Scheduled Pinned Locked Moved Notepad++ & Plugin Development
      2
      1 Votes
      2 Posts
      77 Views
      rdipardoR

      @Guido-Thelen said in C# Plugin for ARM64:

      DNNE (Dot-Net Native Exports) is a modern NuGet package that generates a native C wrapper DLL around your .NET 8 assembly. It uses [UnmanagedCallersOnly] attributes to define exports and supports ARM64 natively.

      I assume you mean this?

      I tried it, and quickly ran into the limitation that custom types require user-defined C-language equivalents, which are passed to the code generator as strings of C code(!)

      So, for example, to export the setInfo function from a plugin, you would provide a definition of the C++ template’s NppData structure that compiles to the C99 standard. (The generator can emit C or Rust, but not C++, in the interest of portability, I guess.) Then you annotate the method with your type definition code, and apply the C type specifier to the corresponding C# type:

      [UnmanagedCallersOnly] [DNNE.C99DeclCode("#include <windows.h>\r\nstruct NppData { HWND _nppHandle, _scintillaMainHandle, _scintillaSecondHandle; };")] public static void setInfo([DNNE.C99Type("struct NppData")]NppData theData) { // use theData ... }

      This would be quite fragile against API changes, unless you can produce the code strings automatically from the Notepad++ headers.

      It’s much easier to install a template package and target ARM64 with Native AOT. You can even start a project in Visual Studio:

      vs.npp.dotnet.templates.start.screen.png