Skip to content

Store Invisible Characters and other misc fixes - #584

Draft
davidrg wants to merge 6 commits into
masterfrom
more-decrqcra-fixes
Draft

davidrg wants to merge 6 commits into
masterfrom
more-decrqcra-fixes

Conversation

@davidrg

@davidrg davidrg commented Nov 14, 2026 •

Copy link
Copy Markdown
Owner

This change stores invisible characters rather than converting them to space as has been done since C-Kermit 5A(190) of 4 October 1994 so that DECRQCRA can report the correct value for characters with that attribute set.

This change requires further changes elsewhere to deal with invisible characters now being stored:

  • GDI Renderer doesn't render invisible characters
  • Console Renderer doesn't render invisible characters
  • Copy-to-clipboard, Copy-to-host, Copy-to-printer exclude invisible characters
  • Invisible characters terminate URLs as the SPACE character (and any other character ineligible for inclusion in URLs) does
  • MC-2 (transmit screen) excludes invisible characters (confirmed on the VT520)
  • Other printing/media copy functions (needs checking) - prtline, prtpage, prtscreen
  • Find in scrollback doesn't find invisible characters
  • Function \Fscrnstr should return spaces for invisible characters

Since C-Kermit 5A(190) of 4 October 1994, wrtch(unsigned short) wrote a space character to the terminal buffer whenever a character with the invisible attribute was written.

DECRQCRA demonstrates that a real VT420/500 doesn't work this way - instead it deals with it at render time. This commit adjusts K95 to do the same.

Other things that read from the terminal buffer (mark-mode, etc) are still to be dealt with.
Copy-to-clipboard, Copy-to-Host, and Copy-to-Printer will now copy invisible text as the space character.

And mark mode itself will treat invisible characters the same as it treats space, producing the same selection behaviour as in past releases of K95.
Visual C++ doesn't like comparing int with void*. Fair enough.
Invisible characters were previously stored as a space which is ineligible for inclusion in a URL.

To retain the same behaviour as before, anything checking IsURLChar also now checks that the char isn't invisible.

And for some reason quite a lot of stuff was calling IsURLChar, almost always directly before calling IsCellPartOfURL so that check has been moved *into* IsCellPartOfURL to tidy things up a little.

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant