Community
    • Login

    Semi-space in NP++

    Scheduled Pinned Locked Moved General Discussion
    18 Posts 10 Posters 1.8k 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.
    • Alan KilbornA
      Alan Kilborn @Terry R
      last edited by

      @Terry-R said in Semi-space in NP++:

      I initially was going to ask the OP how he got the characters he did by using Shift+Space(bar) as I just get a normal space (x20).

      That’s a good point. I’d be willing to bet that OP didn’t get that with a Shift+Space press; he just thinks he did.

      CoisesC 1 Reply Last reply Reply Quote 1
      • Alan KilbornA
        Alan Kilborn @mkupper
        last edited by

        @mkupper said in Semi-space in NP++:

        I don’t think this forum supports table formatted data

        It does! (At least, simple tabling)

        mkupperM 1 Reply Last reply Reply Quote 0
        • mkupperM
          mkupper @Terry R
          last edited by

          @Terry-R I’m guessing the person has a keyboard shortcut as I too get a normal \x20 space when I use shift-space.

          @JamesWebb Notepad++ normally does nothing special when people use Shift-Spacebar. Let’s see how your copy of Notepad++ is configured.

          • In Notepad++ go to Settings / Shortcut mapper
          • Enter spacebar (type out the letters s-p-a-c-e-b-a-r) in the filter box at the bottom.
          • Now flip through the tabs at the top from Main menu, Macros, Run command, etc.

          On my copy of Notepad++ only three shortcuts use spacebar as part of their definition. For example, Main menu tab has Ctrl+Shift+Spacebar assigned to Function Parameters Hint.

          Do you have a shortcut for Shift-Spacebar listed in any of the tabs? If so, we can investigate that further while also figuring out what a “semi-space” is and then adding a new shortcut that will generate a semi-space using whatever keystroke you want using the same method that your copy of Notepad++ uses to support Shift-Spacebar.

          If you did not find any Notepad++ shortcuts besides the normal ones that ship with Notepad++ then it’s likely you have a Windows add-on or setting of some sort that handles shift-spacebar. I would confirm that by putting a shift-space in a test file using plain Notepad (not Notepad++) and then seeing what’s in the test file.

          1 Reply Last reply Reply Quote 1
          • mkupperM
            mkupper @Alan Kilborn
            last edited by

            @Alan-Kilborn said in Semi-space in NP++:

            @mkupper said in Semi-space in NP++:

            I don’t think this forum supports table formatted data

            It does! (At least, simple tabling)

            I had looked at https://spec.commonmark.org/0.30/ and tried

            <table>
            <tr><th>header1</th><th>header2</th></tr>
            <tr><td>row 1 col 1</td><td>row 1 col 2</td></tr>
            <tr><td>row 2 col 1</td><td>row 2 col 2</td></tr>
            </table>

            It seems well formed but I’m only seeing the raw HTML in the preview pane.

            Alan KilbornA 1 Reply Last reply Reply Quote 0
            • CoisesC
              Coises @Alan Kilborn
              last edited by

              @Alan-Kilborn said in Semi-space in NP++:

              I’d be willing to bet that OP didn’t get that with a Shift+Space press; he just thinks he did.

              There are keyboard layouts (reference) which generate a Zero Width Non-Joiner from Shift+space.

              1 Reply Last reply Reply Quote 2
              • Alan KilbornA
                Alan Kilborn @mkupper
                last edited by Alan Kilborn

                @mkupper :

                At least, simple tabling

                | Tables        | Are           | Cool  |
                | ------------- |:-------------:| -----:|
                | col 3 is      | right-aligned | $1600 |
                | col 2 is      | centered      |   $12 |
                | zebra stripes | are neat      |    $1 |
                

                produces:

                Tables Are Cool
                col 3 is right-aligned $1600
                col 2 is centered $12
                zebra stripes are neat $1
                Mark OlsonM 1 Reply Last reply Reply Quote 3
                • Mark OlsonM
                  Mark Olson @Alan Kilborn
                  last edited by

                  @Alan-Kilborn
                  This is such a nice, compact example of how to make Markdown tables that I think it might make sense for @PeterJones to add it to the Formatting Forum Posts FAQ.

                  Of course, I understand that that FAQ isn’t really meant to be a comprehensive guide to Markdown, and therefore it might make sense to omit it for the sake of conciseness.

                  PeterJonesP 1 Reply Last reply Reply Quote 1
                  • gerdb42G
                    gerdb42
                    last edited by

                    I think what the OP got is this: 39541291-a076-49ac-a09b-d390a62ff906-grafik.png, a Zero Width Non-Joiner (&#x200C). And this matches what @Coises has mentioned here.

                    @JamesWebb: These black-boxed items show characters that are invisible otherwise if you have “Show All Characters” (1df5f222-5662-438d-84ce-79f6787edd37-grafik.png ) checked in the toolbar. Do not confuse this with the literal text “ZWNJ”.

                    1 Reply Last reply Reply Quote 1
                    • JamesWebbJ
                      JamesWebb
                      last edited by JamesWebb

                      I want to clarify that when I mentioned the need for spacing in Persian language, I was not referring to em/en space. In Persian, which is a right-to-left (RTL) language, we use semi-space to indicate that two words are closer to each other than a normal space (Spacebar) would suggest, yet they do not touch each other. This is not an issue when using MS Notepad or Office Word.

                      I have a screenshot and a screen recording of the issue that occurs when I press Shift+Space. Unfortunately, I cannot share the link due to my zero reputation.

                      The SS link (just replace “[dot]” with “.” ):
                      ibb[dot]co/X4H3qPG

                      rdipardoR 1 Reply Last reply Reply Quote 0
                      • rdipardoR
                        rdipardo @JamesWebb
                        last edited by rdipardo

                        According to this issue on the Windows user forum, as well as this issue with another open source editor, the expected behaviour of the Persian IME keyboard is to insert a ZWNJ character when Shift+Space or Shift+B are pressed. The title of the Windows issue refers to “‘half-space’ or ZWNJ”, so they are actually the same thing.

                        Notepad++ is correctly receiving a ZWNJ as input from the keyboard. It was decided in version 8.5.3 to display boxed annotations of non-printing Unicode characters by default — which admittedly favours writers of source code, who need to be aware of every character in the file. MS Word doesn’t do this by default since it’s more attuned to presenting documents as they will look on paper.

                        If you don’t want to see the annotations, go to the View menu, then the Show Symbol submenu, and make sure that Show Non-Printing Characters does not have a check mark, as suggested already.

                        JamesWebbJ 1 Reply Last reply Reply Quote 2
                        • JamesWebbJ
                          JamesWebb @rdipardo
                          last edited by

                          @ rdipardo

                          It was decided in version 8.5.3 to display boxed annotations of non-printing Unicode characters by default

                          Yes! I didn’t have it before, it appears in recent (NP++) updates.
                          Thanks. It worked.

                          1 Reply Last reply Reply Quote 0
                          • PeterJonesP
                            PeterJones @Mark Olson
                            last edited by PeterJones

                            @Mark-Olson said in Semi-space in NP++:

                            I think it might make sense for @PeterJones to add it to the Formatting Forum Posts FAQ.

                            Sorry, I guess since I used that table-technique throughout the FAQ, and even posted screenshots of source code which produces such a table, and posted links to other Markdown resources, it hadn’t struck me that I’d never mentioned there was, in fact, a table syntax. But I suppose I could add an explicit mention.

                            —
                            Update: Done. I have added “Tables” to the FAQ.

                            1 Reply Last reply Reply Quote 4
                            • guy038G
                              guy038
                              last edited by guy038

                              Hello, @jameswebb, @alan-kilborn, @mkupper, @terry-r, @Coises, @mark-olson, @gerdb42, @rdipardo and All,

                              May be, I did not understand all that topic very clearly but, to my mind, it seems easy to bound the ZWNJ character to the Shift + Spacebar shortcut !

                              You just have to create a new macro :


                              So :

                              • Start Notepad++ and click on the ¶ button of the ToolBar

                              • Open your active shortcuts.xml file within N++

                              • Right before the </macros> line, insert this new macro :

                                      <Macro name="ZWNJ (Semi Space)" Ctrl="no" Alt="no" Shift="yes" Key="32">
                                          <Action type="1" message="2170" wParam="0" lParam="0" sParam="‌" />
                                      </Macro>
                              

                              Note : Although not visible, there is a ZWNJ character between the two double-quotes de sParam !

                              • Save the modifications of the shortcut.xml file ( Ctrl + S )

                              • Close the shortcut.xml file ( Ctrl + W )

                              • Exit N++ ( Alt + F4 )

                              • Restart N++

                              Here you are ! Now, each time you use the Shift + Spacebar shortcut, it will insert a zero Width Non Joiner character, at caret location, even if the Caps Lock key is set ;-))

                              Best Regards,

                              guy038

                              JamesWebbJ 1 Reply Last reply Reply Quote 1
                              • JamesWebbJ
                                JamesWebb @guy038
                                last edited by

                                @ guy038

                                You just have to create a new macro

                                Thank you for providing the macro. The solution was already present, but I wasn’t aware of it.
                                View menu>Show Symbol submenu> turn off Show Non-Printing Characters

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