- Jan 14, 2025
-
-
Rob Swindell authored
uncrustify nl_split_if_one_liner setting
-
Rob Swindell authored
... using uncrustify mod_paren_on_return config
-
Rob Swindell authored
White-space changes only, exception being the rare insertion of NL before closing brace (couldn't find the option to disable that behavior). I excluded some header files (e.g. sbbs.h) since uncrustify seemed to be doing more harm than good there. I might just end up applying different set of rules to .h files.
-
- Nov 05, 2024
-
-
Rob Swindell authored
for getstr() to be able to return when user right-arrows off end of string (for use in msgeditor).
-
- Feb 16, 2024
-
-
Rob Swindell authored
Don't corrupt UTF-8 strings with SAFECOPY() (use new SAFECOPY_UTF8). Some terminals (notably, Windows Terminal) display zero width UNICODE chars as a single column-wide space. <sigh> Auto-detect the zero-width "width" (1 or 0) of the terminal during connection and UTF-8 auto-detection. getstr() works a lot better now with UTF-8 strings with wide chars (e.g. emojis), but likely much more to do.
-
- Apr 09, 2023
-
-
Rob Swindell authored
The sbbs_t::wordwrap[] buffer was 81 characters (80 printable characters, plus NUL terminator) and sbbs_t.getstr(), when used with the K_WRAP mode flag could potentially write more than 81 characters to this buffer (e.g. when using a wider than 80 column terminal and writing a message with the internal line editor which calls sbbs_t::getstr(... K_WRAP)) - would corrupt sbbs_t members after wordwrap[], which included pointers that would be freed in the sbbs_t destructor (~sbbs_t) and subsequently page/segfault as seen in issue #545. This change increases the wordwrap buffer to likely twice the same needed (maximum columns + NUL terminator) and adds wordwrap bounds checking to sbbs_t::getstr(). There were comments indicating crash sightings in the sbsb_t destructor going back to 2002, so this commit removes those comments. Thanks to Nelgin for providing the gdb dump details ('print *this') that was the clue needed to reach the root-cause determination. This fixes issue #545.
-
- Feb 19, 2023
-
-
Rob Swindell authored
At one time, Synchronet was a 16-bit DOS project, plagued by the 16-bit [u]int, so long's were used everywhere > 16-bits were known to be needed/wanted (This is before the days of the standard sized types from stdint.h), and they've persisted. But '[u]long int' is 64-bits on *nix 64-bit builds, 32-bits everywhere else (even 64-bit Windows builds if/when we ever get around to that), so this could lead to insidious bugs that would only show up on one flavor or the other. Since [u]int is 32-bits on everything we currently support, we'll use that instead of [u]long. This "part 1" because I'm sure there's going to be warnings and errors from the GCC/Clang builds as a result, which I'll get to next.
-
- Nov 18, 2021
-
-
Rob Swindell authored
The internal line editor's quoting feature add some hard-coded strings ("Done" and "All") and the (L)ist key was hard-coded. Use the text.dat string (new and pre-existing) for these now. Also, use the new sbbs_t *_key() methods for referencing the configured key bindings (via text.dat) for these common key-stroke commands. Convert the text.dat strings for keys (e.g. YNQP) to uppercase always as well.
-
- Feb 15, 2021
-
-
Rob Swindell authored
Hopefully not introducing any bugs in the process.
-
Rob Swindell authored
Hopefully not introducing any bugs in the process.
-
- Nov 06, 2020
-
-
Rob Swindell authored
I'm fed-up with MSVC assertions in ctype functions (e.g. isdigit, isprint, isspace, etc.) when called with out-of-range (e.g. negative) values. This problem only affects MSVC debug builds, but if you run them (like I do), these things are like little time bombs that can drive you crazy (knocking your board out of service). The new macros names are bit more descriptive as well.
-
- Aug 16, 2020
-
-
Rob Swindell authored
-
- May 08, 2020
-
-
rswindell authored
- User Defaults menu mousified - When all hot spots have scrolled off the screen, clear the hot spot list - Insert new hot spots in the front of the list so they will take precedence over any previously defined duplicate hot spots - Numeric hot spot commands end in a carriage-return - No auto-acceptence of numbers when there are keys in the keyboard buffer - Baja UNGETKEY function now inserts keys into the "front" of the keyboard buffer (next to be consumed) - Hot key @-code command text supports C-style escape sequences (allows encoding of ctrl chars, spaces, etc.)
-
- Apr 28, 2020
-
-
rswindell authored
getstr's insert mode (Ctrl-V) indicator and edit/line modes. Global Hot Keys (e.g. Ctrl-T) would do weird stuff like return the cursor to the end of the line or redraw the input string multiple times. So as part of this fix: - backspasce() now removed the last count characters from the save-line buffer (it is a destructive backspace afterall). - outchar('\b') (a non-destructive backspace) adds the \b to the save-line buf - restoreline() now always redraws the current insert/overwrite indicator in the upper right-most corner fo the screen - insert_indicator() now uses functions that aren't line-saved. An unrelated change included in this comment: center() now sends a CR before the cursor movement and centered-text, for times when the current column is *not* already at 0. Very useful for use with @-codes (e.g. display some pattern or "graphics" and then center some text over it).
-
- Mar 31, 2020
-
-
rswindell authored
when echo is disabled or when we're echoing X's (for password input). Ctrl-R key would redraw the raw password at a password prompt, even when the console is in Echo-X mode, pass a non-zero mode flag to redrwstr() to fix that. Also, some experimental UTF-8 input stuff that doesn't work right yet.
-
- Jul 24, 2019
-
-
rswindell authored
- Export all FIDOCTRL (other FTN kludge lines) to the QWK HEADERS.DAT file. These should already be imported if they exist, but were never added during export, so untested/new behavior. The control paragraph (kludge line) of specific interest here is the "CHRS" (charset) kludge we need for UTF-8. - Don't use the QWK "newline" character (0xE3) when the message is UTF-8. Use bare-LF's instead. This is pretty untested at this point as I will need another QWKnet board to post or receive UTF-8 encoded messages to test, getting the code into CVS is the first step. At least for now, there's no opt-in/out for this behavior. If your BBS has UTF-8 encoded messages, some QWK nodes or offline readers may have trouble with packets which include those messages. Or they may work fine (but likely display garbage CP437 chars in-place of the proper Unicode codepoint glyph). - The beginning of UTF-8 input support in getstr() - which needs more work, particularly around character and word deletion and insertion. - The internal message editor now supports UTF-8 messages and kind of somewhat supports inputting UTF-8 characters in message text. New put/print text flag: P_AUTO_UTF8 which can auto-detect UTF8 strings and do the "right thing" for the user's terminal. New associated sbbs_t method: auto_utf8() which automatically sets P_UTF8 for any stirng that begins with a UTF-8 BOM (ZWNBSP). Else, if the P_AUTO_UTF8 mode flag is set, then it checks to see if the string contains invalid US-ASCII chars but valid UTF-8 sequences and then sets P_UTF8 accordingly. Used by putmsg() and bputs(). There's a new permuation of bprintf() which accepts a mode argument (i.e. for P_UTF8) and passes it on to the new mode-capable bputs().
-
- May 09, 2019
-
-
rswindell authored
- for PETSCII, this is automatic and you don't lose blink, but you do lose colored foreground when enabling a bright background ("reverse video") - for ANSI, this mode is typically referred to as "iCE colors" and disables blinking-text support - Ctrl-AE (^AE) is the new attribute code to enable bright-background (will have no effect on ANSI terminals that are not iCE color enabled) "E" is now valid in the ctrl/attr.cfg file and string values for JS console.attributes assignments, as well - Ctrl-AI (^AI) - blink - now does nothing for ANSI/ICE color terminals (blinking is not supported in combination with bright-background) - Using a new/non-standard CGA attribute bit-flag to indicate the selection of bright-background colors (BG_BRIGHT, bit 10), separate from BLINK. This change required all/most char/uchar attribute representations to be converted to int/uint. New text.dat strings: - PetTerminalDetected (renamed from PetTermDetected) - PetTerminalQ - TerminalAutoDetect - TerminalColumns - TerminalRows - TerminalMonochrome - TerminalColor - TerminalIceColor - IceColorTerminalQ This also moved the MsgCarbonCopyList definition to the end of the file for now. PETSCII reverse-video attribute fix: When a CR is sent to the terminal, the reverse-video attibute is auto-disabled so update our "current attribute" (curatr) value to match the remote. Support new printfile/putmsg mode flag: P_WRAP to force an ungraceful line-wrap (splitting) to the specified column width. If no column width is specified (0), then this mode will force an ungraceful wrap before the last terminal column where some terminals *may* auto-wrap. JS console.printfile() and printtail() methods now support an optional "orig_columns" argument, similar to console.putmsg(). Must specify P_WORDWRAP or P_WRAP for this argument to have any effect. Much improved terminal-type selection/configuration in the user defaults menu and abort (^C) at any of the yes/no prompts is now detected/handled much better (to answers to the prompted questions are not saved to the user settings).
-
- Oct 22, 2018
-
-
rswindell authored
So Omegix recently asked in the Synchronet Discussion group whether or not a PETSCII (Commodore) terminal could be used to access his Synchronet BBS. Now, the answer is "Yes". :-) The major issues addressed: - detecting a PETSCII terminal, solved by assigning specific (configurable): TCP ports to be used for incoming PETSCII connections, by default: port 64 is for 40-column PETSCII and port 128 is for 80-column PETSCII, but if the terminal sends a Telnet Window Size reply (e.g. SyncTERM), then either size terminal should fine on either port. The port numbers are configurable in the [BBS] section of your sbbs.ini file using the new keys: PET40Port (default value: 64) and PET80Port (default value: 128). Having these keys set doesn't make make the terminal server listen on that additional port - you'll need to add more IP:port combinations to one of Interfaces values, example: TelnetInterface=71.95.196.34,71.95.196.34:64,71.95.196.34:128 And you don't have to use Telnet for the PETSCII connections - you could use RLogin or SSH instead (or in addition). - support for terminal widths < 80 columns: This was achieved through a combination of text.dat changes (numerous), new Ctrl-A and @-codes and new optional terminal-width-specific menu files (e.g. text/menu/main.40col.asc) A side effect of these changes is actually better support for terminals *wider* than 80 columns as well! - support for terminals that don't expand tabs to spaces (e.g. PETSCII): The terminal server now handles tab expansion with a run-time settable tab-size (default size: 8) - conditional access based on PETSCII (or small) terminal use (or not): + New PETSCII ARS keyword (boolean) + New COLS and ROWS ARS keywords (for terminal width and height requirements) + New TERM (string) ARS keyword New @-codes: - WORDWRAP, when placed at the top of a file, enables auto-wordwrap for lines longer than the terminal width - CENTER, the text following before an end of line will be displayed centered on the terminal (whatever the width, in columns) - CLEAR, like CLS, except it ignores (doesn't display) a CRLF that follows - COLS, current number of terminal columns (width) - ROWS, current number of terminal rows (height) - TERM, the auto-detected or reported terminal type (e.g. ANSI, TTY, etc.) - SYSONLY, toggles "echo" (display) off/back-on for non-sysops similar to the Ctrl-A( and ) codes, but more convenient to use (and PabloDraw won't strip the @-code from the file like it does with Ctrl-A codes it doesn't support) New Ctrl-A codes: - \ conditional new-line/continuation when the terminal width is < 80 cols prints the new text.dat string LongLineContinuationPrefix yesno() will now return true if passed a blank string. noyes() will now return false if passed a blank string. getstr()'s input length limiting based on terminal width is more broadly applied now (not just when using the K_LINE mode flag). New JS bbs object method: menu_exists(<base_filename>) returns Boolean New JS console object property: tabstop (Number) New JS console object methods: getbyte() and putbyte() to recv/send raw byte value with (very little) interpretation/intervention by the terminal server New JS console object method: creturn() - performs a carriage return (or equivalent) New JS (and C) printfile() mode flag: P_TRUNCATE, causes long lines to be truncated, rather than displaying causing a line-wrap. New text.dat strings: - NoAccessTerminal (for ARS check failures) - LongLineContinuationPrefix (for breaking long lines for 40col terminals) - Scanning (replaces a previously hard-coded "Scanning" string) - Done (replaces a previusly hard-coded "Done") - Scanned (when finished scannning, clears the progress bar)
-
- Oct 03, 2018
-
-
rswindell authored
from both ends of the input string automatically and disallow (ignore) more than one consecutive space character mid-string. The returned value is still the non-trimmed string length - perhaps that should be changed.
-
- Sep 05, 2018
-
-
rswindell authored
NULL. When history is NULL, treat TAB the same as before (in weird ways). The TAB-completion algo is very simple: just find the first (case insensitive) match in the history list and if there is one, use it as the current string content.
-
- Jul 29, 2018
-
-
rswindell authored
additional, optional, "history" argument - an array of strings that can be recalled/scrolled using the up/down arrow keys. Currently, I just plan to use this for netmail destination address recall, but it could be used other places easily enough.
-
- Jul 25, 2018
-
-
rswindell authored
fix the resulting warnings.
-
- Dec 08, 2016
-
-
rswindell authored
than sprinkling the mapping around the source files. Also, disable the message thread nav keys (arrow keys, home, end) when not in Thread View Mode - too confusing.
-
- Aug 22, 2015
-
-
deuce authored
-
- Apr 28, 2015
-
-
rswindell authored
was never used. This was intended to be a method for internationalization, letting the sysop change which key is used as the uiniversal "quit" key. This commit replaces most of the uses of the hard-coded 'Q' for quit wtih the 3rd charcter in the text.dat YNQP string. Some hard-coded menus still have the 'Q' key hard-coded and will need to be addressed later. The text.h YN index macro was changed to YNQP and the JS text index variable name will change as well.
-
- Oct 04, 2014
-
-
rswindell authored
Fix Ctrl-Z/Undo so it only redisplays from the correct column/offset. Note: K_NOECHO mode appears to still have some bugs if/when K_EDIT is also used (which would be a weird combination of modes).
-
- Feb 19, 2009
- Feb 16, 2008
-
-
deuce authored
If default value is not zero, it is the value returned if enter is pressed with no input. In this case, zero is allowed to be entered.
-
- Aug 23, 2006
-
-
rswindell authored
- returns true/false if the user's terminal supports all the passed flags - returns the supported flags if no flags are passed for comparison - automatically uses the auto-terminal-type flags if no user is logged-on
-
- Sep 02, 2005
-
-
deuce authored
CON_R_ECHOX and CON_L_ECHOX, then sends "\b \b" Replace all instances of [br]puts("\b \b") with call to backspace() This fixes once and for all the "spaces entered at password prompt are echoed as spaces" problem. Har. PR:42->closed
-
- Sep 01, 2005
-
-
rswindell authored
-
- May 30, 2004
-
-
deuce authored
-
- May 11, 2004
-
-
rswindell authored
-
- Oct 02, 2003
-
-
deuce authored
(I always wanted to do that commit!)
-
- Jul 25, 2003
- Jul 08, 2003