https://gitlab.synchro.net/main/sbbs/-/commit/4eb42d604b264e6671a90ed9
Modified Files:
ctrl/modopts.ini docs/v322_new.md exec/load/select_item.js exec/text_sec.js
Log Message:
text_sec.js: arrow-key navigation, highlight and paging via select_item.js
The text file section list and each section's file list are now built
on load/select_item.js, as the area selection lists and uselect.js are:
a list longer than the screen is paged, with an [x-y of n] indicator,
the arrow, Home/End and PgUp/PgDn keys move through it, and it is
repainted in place.
New modopts.ini [text_sec] options default_item_prefix,
nondefault_item_prefix and default_item_attr mark and highlight a
default item, which Enter then selects; more_fmt formats the indicator.
In a file list the default item is the first file, then the one after
the file last read. Without those options the lists look as they did,
no item is marked, the navigation keys only scroll a long list and
Enter does what it did before. The highlight is applied only when the
text.dat format displays the name with a plain %s. A text_sec or
text<N> menu file displayed in place of a list keeps number entry only.
The stock modopts.ini enables the marker and highlight, as it does for
[shell].
For the file list's command keys ('?' and the sysop's A, R, E and D), select_item() gains two options: "keys", additional command keys
returned to the caller (read with console.getkeys() in place of console.getnum()), and "no_default", for a list with no marked item.
Ctrl-C at a file list now always quits; it used to read the next file
when one had already been read. A clicked item number that could be the
start of a longer one is now completed with Enter.
First part of #1346; xtrn_sec.js is not changed.
Co-Authored-By: Claude Fable 5.2 <
noreply@anthropic.com>
---
■ Synchronet ■ Vertrauen ■ Home of Synchronet ■ [vert/cvs/bbs].synchro.net