• src/conio/cterm.adoc cter

    From Deuc¿@VERT to Git commit to main/sbbs/m on Tue Mar 17 22:37:00 2026
    https://gitlab.synchro.net/main/sbbs/-/commit/db6107bde7cc1855f89844ff
    Modified Files:
    src/conio/cterm.adoc cterm.c
    Log Message:
    Implement DECRQM (Request Mode) for private, ANSI, and CTerm modes

    CSI ? Ps $ p queries DEC private modes (DECOM, DECAWM, DECTCEM,
    video flags, DECBKM, DECLRMM, sixel scroll, mouse, bracket paste).
    CSI = Ps $ p queries CTerm extension modes (LCF, forced LCF, doorway).
    CSI Ps $ p queries ANSI modes (none implemented, always returns 0).
    All unrecognized prefixes/modes return Pm=0 (not recognized).
    Forced LCF reports Pm=3 (permanently set).

    Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>

    ---
    þ Synchronet þ Vertrauen þ Home of Synchronet þ [vert/cvs/bbs].synchro.net
  • From Deuc¿@VERT to Git commit to main/sbbs/m on Wed Mar 18 16:58:00 2026
    https://gitlab.synchro.net/main/sbbs/-/commit/d61223fea0ab02b105315d75
    Modified Files:
    src/conio/cterm.adoc cterm.c src/syncterm/term.c termtest.c
    Log Message:
    Expand test suite to 145 tests, fix retbuf/callback response path

    Tests (99 -> 145):
    Add 46 new tests covering ED modes 1/2, EL modes 1/2, SL, SR, CVT,
    TSR, CTDA, BCDSR, XTSRGA, DECCKSR, CTSMRR (Ps=1-6), DECRQSS (t,
    $|, *|), CTSMS/CTRMS, SGR (dim, blink, noblink, normal intensity,
    default fg/bg, bright bg), CT24BC, OSC 10/11 queries, OSC 8
    hyperlink readback, DECRPM for modes 31-35/67/80 + mouse modes,
    SM/RM for FETM/TTM, APC JXL query, NUL in doorway mode with
    doorway encoding verification, and response ordering regression.

    cterm.c Ä retbuf audit:
    Convert all response sites from retbuf-gated strcat() to
    cterm_respond()/cterm_respond_printf(). Fixes ANSI mode DECRQM
    (CSI Ps $ p), CTSMRR Ps=4/5, and other queries that failed when
    response_cb was set and retbuf was NULL.

    cterm.c Ä escaped ST for OSC 8 in STS:
    OSC 8 terminators inside SOS-framed STS content use ESC : \
    instead of ESC \ to avoid premature SOS closure. ESC : is an
    unassigned Fp private-use escape (ECMA-35) that parsers silently
    drop.

    term.c Ä eliminate dual response path:
    APC handler and WRITE_OUTBUF now use conn_send/response_cb
    exclusively instead of mixing retbuf writes with callback-based
    responses, which caused response ordering bugs.

    Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>

    ---
    þ Synchronet þ Vertrauen þ Home of Synchronet þ [vert/cvs/bbs].synchro.net
  • From Deuc¿@VERT to Git commit to main/sbbs/m on Wed Mar 18 16:58:00 2026
    https://gitlab.synchro.net/main/sbbs/-/commit/bcca49315f5257a349289df7
    Modified Files:
    src/conio/cterm.adoc cterm.c cterm.h src/syncterm/termtest.c
    Log Message:
    Implement vertical line tabulation, scroll verification, ANSI mode reporting

    Vertical tabs (ECMA-48):
    Add VTS (ESC J) to set line tabulation stops at fixed row numbers.
    Fix CVT (CSI Pn Y) to advance to the Pn-th next line tab stop
    (preserving column) instead of incorrectly acting as horizontal CHT.
    When no line tab stop exists, CVT scrolls up and moves to the last row.
    Extend TBC: Ps=1 clears line tab at current row, Ps=4 clears all
    line tabs, Ps=5 now correctly clears both character and line tabs.
    Line tab stops are at fixed row numbers, unaffected by scrolling,
    with no defaults set. VT (0x0B) remains a displayable CP437 glyph.

    Scroll content verification (tests):
    Add scroll_witness_setup/check_up/check_down helpers for verifying
    that screen content actually moves during scroll operations.
    Strengthen SU, SD, RI_scroll, LF_scroll, DECSTBM_scroll, and CVT
    tests to verify content shifted, not just cursor position.
    Add SU_margins, SD_margins, SL_margins, SR_margins tests verifying
    content inside margins scrolls while content outside stays put.

    ANSI mode DECRQM (CSI Ps $ p):
    Report all 20 ECMA-48 standard modes: 1-13/15/17/18 permanently
    reset (Pm=4), 14/16 changeable (Pm=1/2), 21 GRCM and 22 ZDM
    permanently set (Pm=3).

    Test count: 145 -> 149, all passing.

    Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>

    ---
    þ Synchronet þ Vertrauen þ Home of Synchronet þ [vert/cvs/bbs].synchro.net
  • From Deuc¿@VERT to Git commit to main/sbbs/m on Wed Mar 18 16:58:00 2026
    https://gitlab.synchro.net/main/sbbs/-/commit/80b5ad1b89408202579c4fc8
    Modified Files:
    src/conio/cterm.adoc cterm.c src/syncterm/termtest.c
    Log Message:
    Implement DEC rectangular area operations and column editing

    New sequences:
    DECERA (CSI Pt;Pl;Pb;Pr $ z) Ä erase rectangular area
    DECFRA (CSI Pch;Pt;Pl;Pb;Pr $ x) Ä fill rectangular area
    DECCRA (CSI ...params... $ v) Ä copy rectangular area
    DECIC (CSI Pn ' }) Ä insert column(s) within scrolling margins
    DECDC (CSI Pn ' ~) Ä delete column(s) within scrolling margins

    All operations use current SGR attributes for new/erased cells and
    clear hyperlink_id. Coordinates respect DECOM (origin mode) but are
    not affected by margins (except DECIC/DECDC which operate within
    margins only). Cursor does not move. DECFRA accepts any character
    except C0 (0x00-0x1F) and DEL (0x7F).

    cterm.adoc:
    Document all five new sequences. Fix sort order of entire CSI
    section Ä entries now correctly ordered by (final byte, intermediate
    byte, private prefix) in ASCII order, fixing 19 pre-existing
    ordering errors.

    Tests: 149 -> 154 (DECERA, DECFRA, DECCRA, DECIC, DECDC), all passing.

    Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>

    ---
    þ Synchronet þ Vertrauen þ Home of Synchronet þ [vert/cvs/bbs].synchro.net
  • From Deuc¿@VERT to Git commit to main/sbbs/m on Wed Mar 18 21:52:00 2026
    https://gitlab.synchro.net/main/sbbs/-/commit/079cf7902899f1a94746a5ff
    Modified Files:
    src/conio/cterm.adoc cterm.c cterm.h src/syncterm/CHANGES termtest.c Log Message:
    Implement DECCARA, DECRARA, DECSACE and DECRQSS speed query

    Add rectangular attribute operations: DECCARA (CSI $ r) sets SGR
    attributes, DECRARA (CSI $ t) toggles bold/blink/negative, and
    DECSACE (CSI * x) controls rectangle vs stream mode. Extract
    apply_sgr() from SGR handler for reuse by DECCARA. Add DECRQSS
    queries for DECSACE (*x) and DECSCS speed (*r). 11 new tests
    (165 total), cterm.adoc entries, fix unused variable warning.

    Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>

    ---
    þ Synchronet þ Vertrauen þ Home of Synchronet þ [vert/cvs/bbs].synchro.net
  • From Deuc¿@VERT to Git commit to main/sbbs/m on Thu Mar 19 01:34:00 2026
    https://gitlab.synchro.net/main/sbbs/-/commit/37088cdb5b85c52e394d8170
    Modified Files:
    src/conio/cterm.adoc cterm_test.c
    Log Message:
    Add ATASCII documentation and 19 unit tests (57 total)

    Document the ATASCII emulation mode in cterm.adoc: two screen modes
    (40x24 standard, 80x25 XEP80), control codes, cursor wrapping
    behavior, ESC inverse mode, tab stops, and character encoding.
    Normal mode stores raw ATASCII bytes; ESC (inverse) mode applies
    screen code translation.

    19 ATASCII tests: printable chars, return, clear screen, cursor
    movement with wrapping (up/down/left/right), destructive backspace,
    ESC inverse mode and auto-reset, delete/insert line, delete/insert
    char, bell, return with scroll, tab, tab set/clear, screen code
    mapping in normal vs ESC mode.

    Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>

    ---
    þ Synchronet þ Vertrauen þ Home of Synchronet þ [vert/cvs/bbs].synchro.net
  • From Deuc¿@VERT to Git commit to main/sbbs/m on Thu Mar 19 01:34:00 2026
    https://gitlab.synchro.net/main/sbbs/-/commit/0fa02bfc9f73da604517804a
    Modified Files:
    src/conio/cterm.adoc cterm_test.c
    Log Message:
    Add PETSCII documentation and 28 unit tests (85 total)

    Document the PETSCII emulation in cterm.adoc: three screen modes
    (C64 40x25, C128 40x25, C128 80x25), control codes, color mapping
    tables for both C64/C128-40 (VIC-II palette) and C128-80 (CGA
    palette), reverse video, cursor movement, font switching, and a
    table of known C64/C128 hardware differences not yet implemented.

    28 PETSCII tests across all three screen modes: printable chars,
    return (with reverse disable), shift+return (preserves reverse),
    clear screen, home, cursor movement (up/down/left/right with
    wrapping and clamping), delete, insert, reverse video, color
    setting (per-mode palette verification), all 16 C64 colors, bell,
    ignored controls, return with scroll, C64 lock/unlock case bytes,
    C128 disputed control bytes, and LF behavior per mode.

    Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>

    ---
    þ Synchronet þ Vertrauen þ Home of Synchronet þ [vert/cvs/bbs].synchro.net
  • From Deuc¿@VERT to Git commit to main/sbbs/m on Thu Mar 19 01:34:00 2026
    https://gitlab.synchro.net/main/sbbs/-/commit/5f805082cabbca72aa9ff0b3
    Modified Files:
    src/conio/cterm.adoc cterm_test.c
    Log Message:
    Add Prestel and BEEB unit tests (122 total), fix BEEB ESC docs

    37 new tests: 26 Prestel (C0 controls, cursor movement with wrapping,
    clear screen, home, cursor on/off, ENQ, NUL, ignored controls, serial attributes via ESC and raw C1 Ä alpha/mosaic color, flash/steady,
    conceal, hold/release, double height, background, separated/contiguous,
    row attribute reset) and 11 BEEB (printable chars, character
    translation #/_/`, BEL, APD/APU scroll behavior, DEL, APS direct
    addressing, VDU 23 cursor control, APH, CS, C1 serial attributes).

    Fix cterm.adoc: BEEB mode uses raw C1 bytes (0x80-0x9F) for serial
    attributes, not ESC (ESC is for VDU sequences only in BEEB mode).

    Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>

    ---
    þ Synchronet þ Vertrauen þ Home of Synchronet þ [vert/cvs/bbs].synchro.net
  • From Deuc¿@VERT to Git commit to main/sbbs/m on Fri Mar 20 11:13:00 2026
    https://gitlab.synchro.net/main/sbbs/-/commit/9a318870ea9352444b35be18
    Modified Files:
    src/conio/cterm.adoc cterm.c cterm_test.c
    Log Message:
    Re-process (not discard) invalid bytes in command strings

    When a byte outside the allowed command string range (ECMA-48 5.6)
    appeared inside a DCS, OSC, APC, or PM string, both the string and
    the invalid byte were silently discarded. The discard behavior was a placeholder from before string processing was implemented (c99f9885).

    Now the malformed string is discarded but the invalid byte is
    re-processed as normal input (e.g., BEL beeps, FF clears screen).

    Added 4 tests: OSC+BEL, DCS+BEL, APC+SI, SOS+SOS.
    Documented the behavior in cterm.adoc.
    Added comment documenting the SOS frame invariant in STS readback.

    Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>

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