• docs/v322_new.md src/sbbs3/atcodes.cpp getkey.cpp js_bbs.cpp putmsg.cp

    From Rob Swindell (on Windows 11)@1:103/705 to Git commit to main/sbbs/master on Sat Jul 25 22:24:37 2026
    https://gitlab.synchro.net/main/sbbs/-/commit/b17b1d3e3e45bbbc4df47ae6
    Modified Files:
    docs/v322_new.md src/sbbs3/atcodes.cpp getkey.cpp js_bbs.cpp putmsg.cpp sbbs.h terminal.h
    Log Message:
    Unicode @-codes: return the expansion instead of printing it

    @U+XXXX@, @CHECKMARK@, @ELLIPSIS@, @COPY@, @SOUNDCOPY@, @REGISTERED@, @TRADEMARK@, @DEGREE_C@, @DEGREE_F@ and @WIDE:text@ wrote their glyph
    straight to the terminal from inside atcode() and returned an empty
    string. Format modifiers were therefore applied to "": @CHECKMARK-R10@
    emitted the glyph and then right-aligned nothing in a 10-column field.
    Callers that expand an @-code into a buffer for a non-printing reason -- bbs.atcode(), bbs.expand_atcodes(), format_text(), mnemonics(),
    putnode(), notify() and putmsg()'s @CENTER@ -- got an empty expansion
    plus stray output on the current node's terminal.

    These codes now encode into the caller's buffer and set P_UTF8, so show_atcode()'s existing display-width compensation makes alignment and truncation work. formatted_atcode() and expand_atcodes() take an
    optional pmode out-param so the buffer-expansion callers can learn the
    result is UTF-8; @CENTER@ and mnemonics() use it, the latter needing the
    P_UTF8 branch bputs() already has, since it emits byte-by-byte through outchar(). Terminal::center() measures with bstrlen(str, mode & P_UTF8):
    the other code sets bstrlen() recognizes are translated by putmsg(), not bputs(), and a centered line bypasses putmsg()'s character loop.

    The |W (doubled) modifier prints a UTF-8 expansion as-is rather than
    feeding it to wide(), which would double each byte rather than the glyph. Output buffers grew to fit @WIDE:, which triples byte length.

    Introduced in 9374bfe37e (pill-4-pencil), a9eea57362 (begun-3-ended) and 43c793a14b (hold-20-maps).

    Fixes #1198

    Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
    --- SBBSecho 3.37-Linux
    * Origin: Vertrauen - [vert/cvs/bbs].synchro.net (1:103/705)