• using [fmt] within Vim to simulate Nroff output

    From HenHanna@21:1/5 to All on Sun Mar 3 20:17:14 2024
    Or if you happen to use Emacs, you can invoke `M-x set-justification`,
    then type "full", then use M-q to apply full justification on the region. No ancient scribes required (well, aside from the Emacs authors). Be warned that it looks kind of goofy on a screen in a monospace font instead of in a book in a nice variable-width typeface.


    Well... it depends on what you
    mean by "goofy" -- does it not?

    And i haven't used Emacs in over
    3 decades... Is it stil used? and if
    so, in what context?

    Someone (a friend) once remarked
    (with intentional wit) that
    Emacs seems _superbly optimized_ for
    (drum-roll, please) writing Emacs-
    macros! (or should it be written
    as "Emacs's Macros" more properly?)

    i looked for online Nroff simulators
    or emulators and was able to find
    none! w w w w w w w w w w w w w w w

    Then, i suddenly had the bright idea
    of using [fmt] within Vim to
    simulate Nroff output, and got:


    'fmt' is not recognized as an internal or external command, operable program or batch file.


    ???

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Janis Papanagnou@21:1/5 to HenHanna on Mon Mar 4 08:36:17 2024
    On 03.03.2024 21:17, HenHanna wrote:

    i looked for online Nroff simulators
    or emulators and was able to find none! w w w w w w w w w w w w w w w

    Then, i suddenly had the bright idea
    of using [fmt] within Vim to simulate Nroff output, and got:

    'fmt' is not recognized as an internal or external command, operable
    program or batch file.

    ???

    'fmt' is a standard Unix command that you can use (like other external commands) as a filter; e.g. to format the file from the cursor to the
    end of the file: !Gfmt

    There's of course also a builtin available in Vim. I usually use it in
    visual mode, marking lines with: 'V' <some movements> 'gq'
    The V starts line marking and gq does the formatting. The option 'tw'
    or 'textwidth' is used to defined the desired formatting width, say
    as in :set tw=32

    (I cannot see, though, how 'fmt' would emulate 'nroff' in any way.
    Or do you want only a block justify?)

    Janis

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From HenHanna@21:1/5 to Janis Papanagnou on Tue Mar 5 07:09:35 2024
    Janis Papanagnou wrote:

    On 03.03.2024 21:17, HenHanna wrote:

    i looked for online Nroff simulators
    or emulators and was able to find none! w w w w w w w w w w w w w w w

    Then, i suddenly had the bright idea
    of using [fmt] within Vim to simulate Nroff output, and got:

    'fmt' is not recognized as an internal or external command, operable
    program or batch file.

    ???

    'fmt' is a standard Unix command that you can use (like other external commands) as a filter; e.g. to format the file from the cursor to the
    end of the file: !Gfmt

    There's of course also a builtin available in Vim. I usually use it in
    visual mode, marking lines with: 'V' <some movements> 'gq'
    The V starts line marking and gq does the formatting. The option 'tw'
    or 'textwidth' is used to defined the desired formatting width, say
    as in :set tw=32

    (I cannot see, though, how 'fmt' would emulate 'nroff' in any way.
    Or do you want only a block justify?)

    Janis



    Thank you... i wasn't familiar with gq as in gqG or gggqG

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)