• Truncating description lines sometimes reveals pipe codes

    From Björn Wiberg@2:201/137 to g00r00 on Tuesday, January 03, 2023 09:29:30
    Hello g00r00!

    I've seen this before, but haven't really thought about the possible reasons for it until now --

    If the lightbar file listing (prompts #434 and/or #435, I think) uses a $T display code to ensure that too long description lines are cut off and don't overflow to the next line, this sometimes affects the rendering of ANSI file descriptions, where pipes and partial pipe codes might become visible as a result of the cutoff.

    Example:
    https://scbbs.nsupdate.info/files/ansi_cutoff.png

    File:
    https://scbbs.nsupdate.info/files/fire-2023-ansi-calendar.zip

    This is when using the following prompts (pipes replaced with PIPE):

    434: PIPE07PIPE$D29 PIPE$T49PIPE&4
    435: PIPE07PIPE$D29 PIPE$T49PIPE&4

    It appears to me that the cut-off might be based on the character count of the contents of the FILE_ID.DIZ, instead of the "resulting" number of output characters on screen.

    Would it be possible to have the cutoff cutting off the resulting "output" to the specified number of characters instead? But perhaps this complicates things a lot and makes this a corner case for file listings...

    Many thanks in advance!

    Best regards
    Björn

    --- Mystic BBS v1.12 A48 (Linux/64)
    * Origin: Star Collision BBS, Uppsala, Sweden (2:201/137)
  • From g00r00@1:129/215 to Björn Wiberg on Tuesday, January 03, 2023 19:10:48
    If the lightbar file listing (prompts #434 and/or #435, I think) uses a
    $T display code to ensure that too long description lines are cut off
    and don't overflow to the next line, this sometimes affects the
    rendering of ANSI file descriptions, where pipes and partial pipe codes might become visible as a result of the cutoff.

    I probably should have used |$R instead. In the update I am about to upload I have tried to enable $T to take account of pipe codes in that situation.

    Let me know how it goes after you test it. I didn't set up a good test for it as I am a little bit pressed for time tonight and I want to get through all the messages/tasks tonight. It might work but could be totally broken too so keep your current mystic binary just in case :)

    ... I'd love to help you out. Which way did you come in?

    --- Mystic BBS v1.12 A48 (Windows/64)
    * Origin: Sector 7 * Mystic WHQ (1:129/215)
  • From Björn Wiberg@2:201/137 to g00r00 on Wednesday, January 04, 2023 09:05:42
    Hello g00r00!

    On 03 Jan 2023, g00r00 said the following...
    I probably should have used |$R instead. In the update I am about to

    I'm guilty for the $T there as the original doesn't perform any truncation. :)

    I probably should have used |$R instead. In the update I am about to upload I have tried to enable $T to take account of pipe codes in that situation.

    Thanks a lot! Seems to be working fine!

    Best regards
    Björn

    --- Mystic BBS v1.12 A48 (Linux/64)
    * Origin: Star Collision BBS, Uppsala, Sweden (2:201/137)
  • From g00r00@1:129/215 to Björn Wiberg on Wednesday, January 04, 2023 05:05:18
    I probably should have used |$R instead. In the update I am about to

    I'm guilty for the $T there as the original doesn't perform any truncation. :)

    I am glad you did...

    $R/L/C all work with pipe codes, so it was my mistake that $T wasn't doing it!

    Thanks a lot! Seems to be working fine!

    Thanks for letting me know. Saves me some time having to test it now! :)

    ... The only place I want data loss is on my credit card!

    --- Mystic BBS v1.12 A48 (Windows/64)
    * Origin: Sector 7 * Mystic WHQ (1:129/215)