• repeat char @-code?

    From mark lewis@VERT to digital man on Friday, August 16, 2019 16:18:02
    is there an @-code i can use to have some text repeated X times or maybe even to repeat to the terminal width or repeat to the terminal width minus X columns?

    maybe something like @RPT#horizline-TWIDTH@ to repeat the horizontal line character to the terminal width where horizline is the actual character to be used... or @RPT#=-L40@ to repeat the '=' from the left 40 times or @RPT#=-R40@ to do the same except from the right...

    i've used "#" intead of ":" for the length specifiers so we can use format modifiers...

    i'm just tossing this out there because i'm trying to dress up my message headers without hard coding dividing and framing lines to a certain width and looking unfinished when used on wide terminals or wrapping on narrow terminals...

    )\/(ark

    Once men turned their thinking over to machines in the hope that this would set
    them free. But that only permitted other men with machines to enslave them.
    ... You know you're in YK when: you have to break the smoke off your chimney. ---
    * Origin: (1:3634/12.73)
    Synchronet Vertrauen Home of Synchronet [vert/cvs/bbs].synchro.net
  • From Digital Man@VERT to mark lewis on Friday, August 16, 2019 15:55:00
    Re: repeat char @-code?
    By: mark lewis to digital man on Fri Aug 16 2019 09:18 am

    is there an @-code i can use to have some text repeated X times or maybe even to repeat to the terminal width or repeat to the terminal width minus X columns?

    maybe something like @RPT#horizline-TWIDTH@ to repeat the horizontal line character to the terminal width where horizline is the actual character to be used... or @RPT#=-L40@ to repeat the '=' from the left 40 times or @RPT#=-R40@ to do the same except from the right...

    i've used "#" intead of ":" for the length specifiers so we can use format modifiers...

    i'm just tossing this out there because i'm trying to dress up my message headers without hard coding dividing and framing lines to a certain width and looking unfinished when used on wide terminals or wrapping on narrow terminals...

    How about just: @fill:<char>@ which would fill the rest of the current line with the specified char?

    digital man

    Synchronet "Real Fact" #23:
    The third ever Synchronet BBS was The Beast's Domain (sysop: King Drafus). Norco, CA WX: 66.3F, 89.0% humidity, 2 mph NNW wind, 0.00 inches rain/24hrs

    ---
    Synchronet Vertrauen Home of Synchronet [vert/cvs/bbs].synchro.net
  • From mark lewis@VERT to Digital Man on Sunday, August 18, 2019 05:25:12
    On 2019 Aug 16 08:55:00, you wrote to me:

    i'm just tossing this out there because i'm trying to dress up my
    message headers without hard coding dividing and framing lines to a
    certain width and looking unfinished when used on wide terminals or
    wrapping on narrow terminals...

    How about just: @fill:<char>@ which would fill the rest of the current line with the specified char?

    that'll work for now... thanks for implementing it :)

    )\/(ark

    Once men turned their thinking over to machines in the hope that this would set
    them free. But that only permitted other men with machines to enslave them.
    ... Tabasco: hmmm, tangy... I thought it was supposed to be hot?
    ---
    * Origin: (1:3634/12.73)
    Synchronet Vertrauen Home of Synchronet [vert/cvs/bbs].synchro.net
  • From Digital Man@VERT to mark lewis on Sunday, August 18, 2019 04:49:32
    Re: repeat char @-code?
    By: mark lewis to Digital Man on Sat Aug 17 2019 10:25 pm


    On 2019 Aug 16 08:55:00, you wrote to me:

    i'm just tossing this out there because i'm trying to dress up my
    message headers without hard coding dividing and framing lines to a
    certain width and looking unfinished when used on wide terminals or
    wrapping on narrow terminals...

    How about just: @fill:<char>@ which would fill the rest of the current line with the specified char?

    that'll work for now... thanks for implementing it :)

    Sure, no problem. I didn't really see an obvious use case for those RPT examples you gave, but if/when you have one, I'll take a second look.

    digital man

    This Is Spinal Tap quote #2:
    Nigel Tufnel: Well, this piece is called "Lick My Love Pump".
    Norco, CA WX: 64.5F, 84.0% humidity, 0 mph SE wind, 0.00 inches rain/24hrs

    ---
    Synchronet Vertrauen Home of Synchronet [vert/cvs/bbs].synchro.net
  • From Rampage@VERT/SESTAR to Digital Man on Sunday, August 18, 2019 17:41:29
    Re: repeat char @-code?
    By: Digital Man to mark lewis on Sat Aug 17 2019 21:49:32

    How about just: @fill:<char>@ which would fill the rest of the current line with the specified char?

    that'll work for now... thanks for implementing it :)

    Sure, no problem. I didn't really see an obvious use case for those RPT examples you gave, but if/when you have one, I'll take a second look.

    well, the idea was for something codified for the different terminal widths... kinda like the current header.asc has the line going from left to right and then terminating with the dots...

    the thought was for something like

    @rpt#--l20@ . . . @rpt# -c20@ . . . @rpt#--r20@

    which would result in 20 "-" from the left followed by the three dots followed by 20 spaces followed by three dots ending with 20 "-" on the right but with the whole thing taking the actual terminal width into account... so maybe the "20" used in this example would be 20% instead of 20 glyphs...

    it was just an idea to be able to draw using the macros and taking the screen width into account without having to draw a bunch of different screens and then figure out how to use the proper one for the terminal width of the user... but i can see how this might also be a rabbit hole, too...


    )\/(ark

    ---
    Synchronet The SouthEast Star Mail HUB - SESTAR
  • From Digital Man@VERT to Rampage on Sunday, August 18, 2019 19:09:46
    Re: repeat char @-code?
    By: Rampage to Digital Man on Sun Aug 18 2019 10:41 am

    Re: repeat char @-code?
    By: Digital Man to mark lewis on Sat Aug 17 2019 21:49:32

    How about just: @fill:<char>@ which would fill the rest of the current line with the specified char?

    that'll work for now... thanks for implementing it :)

    Sure, no problem. I didn't really see an obvious use case for those RPT examples you gave, but if/when you have one, I'll take a second look.

    well, the idea was for something codified for the different terminal widths... kinda like the current header.asc has the line going from left to right and then terminating with the dots...

    the thought was for something like

    @rpt#--l20@ . . . @rpt# -c20@ . . . @rpt#--r20@

    which would result in 20 "-" from the left followed by the three dots followed by 20 spaces followed by three dots ending with 20 "-" on the right but with the whole thing taking the actual terminal width into account... so maybe the "20" used in this example would be 20% instead of 20 glyphs...

    it was just an idea to be able to draw using the macros and taking the screen width into account without having to draw a bunch of different screens and then figure out how to use the proper one for the terminal width of the user... but i can see how this might also be a rabbit hole, too...

    I'm not really seeing a big benefit/use there. <shrug>

    digital man

    Synchronet "Real Fact" #61:
    How to get Synchronet technical support: http://wiki.synchro.net/howto:support Norco, CA WX: 77.3F, 61.0% humidity, 4 mph NNW wind, 0.00 inches rain/24hrs

    ---
    Synchronet Vertrauen Home of Synchronet [vert/cvs/bbs].synchro.net