• src/sbbs3/str_util.c str_util.h

    From Rob Swindell to Git commit to main/sbbs/master on Thursday, February 04, 2021 21:16:27
    https://gitlab.synchro.net/main/sbbs/-/commit/88586297679d65cc95e4a7b7
    Modified Files:
    src/sbbs3/str_util.c str_util.h
    Log Message:
    Create a version of truncstr() that returns the truncated string

    No immediate use/need, but I *almost* did. :-)
  • From Rob Swindell to Git commit to main/sbbs/master on Saturday, April 24, 2021 00:28:03
    https://gitlab.synchro.net/main/sbbs/-/commit/aa7f5b383a9f607c96431f8f
    Modified Files:
    src/sbbs3/str_util.c str_util.h
    Log Message:
    Created convert_ansi() which is kind of a minimal version of ANS2ASC

    It Ctrl-A encodes a possibly ANSI-encoded string, supporting on color/attribute sequences and stripping all others.
  • From Rob Swindell to Git commit to main/sbbs/master on Sunday, August 08, 2021 23:03:19
    https://gitlab.synchro.net/main/sbbs/-/commit/5b359484e144b2ff8bdc2dba
    Modified Files:
    src/sbbs3/str_util.c str_util.h
    Log Message:
    Allow '*' pattern character to be used mid-string (not just beg or end)

    Previously, the '*' matching pattern character could only be used as the beginning or ending character of a pattern string; for any other use, it was treated just as any other exact-match character.

    Now, you can have exact-match characters on both the left and right sides of the '*', so pattern matching like the following is possible:

    <*@gmail.com>
    digital*man

    Multiple '*'s are still not treated special (only the first/left-most '*" is), so, for example, "*blah*" will not likely produce the desired matching effect (use "blah~" instead for this case).
  • From Rob Swindell to Git commit to main/sbbs/master on Wednesday, February 23, 2022 00:19:23
    https://gitlab.synchro.net/main/sbbs/-/commit/a710f6ffb3edb43946b3008d
    Modified Files:
    src/sbbs3/str_util.c str_util.h
    Log Message:
    Add strip_cp437_graphics() and have strip_ctrl() remove DEL chars too

    strip_cp437_graphics() is like strip_exascii(), except it'll leave the foreign language characters and math symbols intact (removing just the common "block" and "line-drawing" characters).

    DEL (0x7F) is a control character too, so have strip_ctrl() remove it.
  • From Rob Swindell to Git commit to main/sbbs/master on Sunday, March 13, 2022 23:33:54
    https://gitlab.synchro.net/main/sbbs/-/commit/6966a81b8d08c75b86277e30
    Modified Files:
    src/sbbs3/str_util.c str_util.h
    Log Message:
    Create i64toac() to generate comma-separated ASCII string of 64-bit int
  • From Rob Swindell (on Windows 11) to Git commit to main/sbbs/master on Tuesday, April 30, 2024 00:26:49
    https://gitlab.synchro.net/main/sbbs/-/commit/aa592e35b8008ccdb9bfb88e
    Modified Files:
    src/sbbs3/str_util.c str_util.h
    Log Message:
    Create replace_chars(), a wrapper for REPLACE_CHARS()

    The iteration variable (p) is created on the stack.
  • From Rob Swindell (on Debian Linux) to Git commit to main/sbbs/master on Tuesday, October 22, 2024 22:13:17
    https://gitlab.synchro.net/main/sbbs/-/commit/d72b0cd2a76ee5c095553e4c
    Modified Files:
    src/sbbs3/str_util.c str_util.h
    Log Message:
    Add contains_invalid_attr() - checks string for invalid attr Ctrl-A codes

    Other Ctrl-A codes (e.g. ^A\) might be valid, but they're not attribute
    control codes, so their existence would cause this function to return true.
  • From Rob Swindell (on Windows 11) to Git commit to main/sbbs/master on Tuesday, November 12, 2024 20:08:02
    https://gitlab.synchro.net/main/sbbs/-/commit/b25e89d267b5371077703216
    Modified Files:
    src/sbbs3/str_util.c str_util.h
    Log Message:
    Add make_newsgroup_name()