Log In  

I can't see a way to disable the new "\#n" background-fill mode once it's been enabled. I've tried "0" for color 0, "G" for color 16, and "W" for color 32, but they just set the BG to black, and all other "0-Z" just repeat the palette. I've tried supplying a "-" for the color instead, I've tried repeating the "\#" code or just "#", I've tried various other symbols and the puny letters, and anything not in "0..Z" just sets it to black.

Is this a missing feature or is there supposed to be a way to do it? The manual says nothing of turning it off. Right now I have to start another print() to get back to no-BG mode and that seems... unintended?

I feel like it ought to be "\#-", based on the convention with the "\^" commands. Alternatively, "G" (or anything through "V") would technically make sense if you just consider bit #4 of the color to be a "transparency" bit.

Edit: Just to be clear, I mean within the same print string. You can print again and the flag will be cleared, but for the sake of tokens, I'd like to do it within the same string.

P#89182 2021-03-18 19:33 ( Edited 2021-03-20 04:19)

1

It's \^-#.

cls(1)cursor(52,61)
?'\#3foo\^-#bar'
P#89436 2021-03-24 09:57
2

@cakepie
Ahhh, I can't believe I didn't see that! 🤦

It's even documented, but maybe I didn't realize it was talking about the same thing since the enable was in the other kind of control code.

Duhhhhh.

Thank you!


@zep
Maybe write the manual a bit more like this?

:: Control Codes

        0 "\0"   terminate printing
        1 "\*"   repeat next character P0 times. ?"\*3a" --> aaa
        2 "\#"   draw solid background with colour P0 (disable with "\^-#")
        ...

I dunno if I'm the only one oblivious enough to miss the second half of the info in the other section somehow. I can be pretty thick these days. But I suspect I'm not gonna be alone.

P#89520 2021-03-25 15:24 ( Edited 2021-03-25 15:33)

[Please log in to post a comment]

Follow Lexaloffle:          
Generated 2024-03-29 09:57:58 | 0.018s | Q:15