Navigation

    Community

    • Login
    • Search
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Search

    Wrap at column 72 as i am typing

    General Discussion
    4
    10
    147
    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.
    • Anthony Blinco
      Anthony Blinco last edited by Anthony Blinco

      So i would like notepad++ to simply move the cursor to say column 8 once i have gone past column 72.
      So as i type a character that would move the cursor beyond column 72 it moves that character to column 8
      and continues typing from there.

      Is that at all possible?

      Thanks for your help.

      Alan Kilborn 1 Reply Last reply Reply Quote 0
      • Alan Kilborn
        Alan Kilborn @Anthony Blinco last edited by

        @Anthony-Blinco

        Is that at all possible?

        Not totally/strictly.

        Notepad++ has a “wrap” feature, but it is based upon window size.
        So…if you sized your window such that column 72 data shows at the very right edge, you’d get what you want.
        However, that effect is only visual, i.e., it doesn’t change your data.

        If you want your data to really be limited to 72 columns, you could use the Split Lines command, but you’d have to have your window sized as above, or use the Vertical Edge feature.

        We can provide more details, but will wait until you tell us which direction you would like to go in.

        1 Reply Last reply Reply Quote 1
        • Anthony Blinco
          Anthony Blinco last edited by

          Thank you Alan.
          If you want your data to really be limited to 72 columns
          This is the case. I need it to create a new line and continue editing at about column 13

          To elaborate on my situation, i am implementing an editing system for very old COBOL.
          Originally in cobol the layout is thus;
          Columns Description
          1-6______ line numbers
          7________ comment/continuation/debug
          8-12____ Area-A
          13-72___ Area-B
          73-80___ Modification code

          So i should only be able to edit columns 7 through 72
          Columns 73-80 should idealy be modified by the editor to record user/date modified

          I guess i’m asking if there is a way i can get into the nitty gritty of notepad++ and modify the behaviour of the editing.
          I’m happy to code something if that’s possible

          Alan Kilborn PeterJones 2 Replies Last reply Reply Quote 0
          • Alan Kilborn
            Alan Kilborn @Anthony Blinco last edited by

            @Anthony-Blinco said in Wrap at column 72 as i am typing:

            only be able to edit columns 7 through 72

            I actually did some COBOL back in the 1980’s, so I know something of this. :-)
            But I’d rather forget. :-)

            Actually, I don’t know of a plugin that would allow this behavior, but it would not terribly surprise me if there were one.

            is a way i can get into the nitty gritty of notepad++ and modify the behaviour

            Well, of course you can, if you are brave enough to try.
            Notepad++ is open-source software, so everything is available.
            However, editing functions are the purview of Scintilla, not Notepad++ itself, so you’d probably need to get into the Scintilla code.
            That code is available as well.
            Good luck.

            1 Reply Last reply Reply Quote 1
            • PeterJones
              PeterJones @Anthony Blinco last edited by

              @Anthony-Blinco ,

              As a solution rather specific to COBOL, hat sounds like an ideal task for a plugin. If one doesn’t exist (check Plugins Admin; I am on a phone, so cannot easily check, but don’t think I’ve seen one), then I think writing a plugin would be better than editing the main app codebase. Since you seem willing to code, I think plugin is the way you should go.

              1 Reply Last reply Reply Quote 0
              • Anthony Blinco
                Anthony Blinco last edited by

                Is there any documentation/examples for developing plugins?

                PeterJones Michael Vincent 2 Replies Last reply Reply Quote 0
                • PeterJones
                  PeterJones @Anthony Blinco last edited by

                  @Anthony-Blinco ,

                  The Notepad++ Plugin Communication doc describes the message and notification interface with the Notepad++ app itself, which plugins use to control and get info from the GUI/environment, and the Scintilla docs describe the messages and notifications that are used when controlling the editor components of Notepad++. And the author of Notepad++ has a collection of plugin source code, with repos for the plugin template and plugin demo, plus the code that is used for the MIME tools and Npp Converter plugins that are distributed with Notepad++.

                  1 Reply Last reply Reply Quote 3
                  • Alan Kilborn
                    Alan Kilborn last edited by

                    Maybe also worth mentioning is the cookie cutter plugin template thingy: https://community.notepad-plus-plus.org/topic/17787/a-new-c-plugin-template
                    Maybe in one of the resources Peter linked; I didn’t check.

                    1 Reply Last reply Reply Quote 3
                    • Michael Vincent
                      Michael Vincent @Anthony Blinco last edited by

                      @Anthony-Blinco said in Wrap at column 72 as i am typing:

                      Is there any documentation/examples for developing plugins?

                      I should mention I know very little C/C++, I can basically write “hello world” without any assistance; beyond that I’m a copy/paste programmer. With the resources that @PeterJones and @Alan-Kilborn listed above I was able to write a few simple Notepad++ plugins and take some really functional Notepad++ plugins (most of which seemed abandoned by authors) and modify them to fix bugs, add functionality and make 64-bit compatible.

                      I say this because there is no step-by-step resource I’ve found. I had to do a lot of reading / Google-ing / experimenting etc., but the above was more than enough to get me - a non-expert C/C++ coder - going.

                      Cheers.

                      1 Reply Last reply Reply Quote 3
                      • Anthony Blinco
                        Anthony Blinco last edited by

                        That is super helpful. Thanks you guys so much!!

                        1 Reply Last reply Reply Quote 0
                        • First post
                          Last post
                        Copyright © 2014 NodeBB Forums | Contributors