TADS3 German Language Special Character Support (ä, ö, ü, █)

Hi all!

I’m working on a TADS/adv3 text adventure (using frobtads) in German, and I’d like to include the language-specific characters ä, ö, and ü in my text. Although I’ve set the charset to UTF-8, the characters are not displayed correctly in the terminal. I’m using the G-TADS library extension, but that one uses ae, oe, and ue instead of ä, ö, and ü. Does this mean that these characters aren’t supported, or could there be another reason for this?

On another note, I was also trying to use the █ character in my text, but it gets replaced with question marks. Is there anything I can do to make this work?

I’d really appreciate any suggestions you have! Thanks in advance for your help!

Vic

2 Likes

Hm… I don’t know if there is an answer for displaying these characters in FrobTads specifically, but on my computer the special characters do not appear in FrobTads but they do with QTads.

1 Like

Have you tried using the -k option to set FrobTADS char set to UTF-8? The default is us-ascii.

Edit: Whoops. Didn’t read the post.

Edit 2: Well, assumed that what was meant was just setting the char set for the source, but then I realised that was a rubbish asssumption.

1 Like

The charset needs to be set in the source file(s) containing the “special” characters, via:

#charset "utf-8"

Sounds like you already did that, but I’m just making sure/typing it out for when this shows up in someone’s search results in the future.

The second bit is telling frob to use UTF-8 as well:

> frob -k "utf-8" game.t3

That works on linux; the name of the charset might be slightly different on other platforms.

5 Likes

Oh wow, thanks everyone for your quick answers! The -k "utf-8" tag indeed solved the issue!

However, now that I’m running it with UTF-8 encoding, another issue has popped up: In my code, I use <q>...</q> for quotation marks, but now these are displayed improperly as �~~. Any suggestions on how to fix this?

2 Likes

Interesting, I tried the -k option but I couldn’t get FrobTads to display special characters on Mac…

1 Like

Hmm that’s interesting … I’m also running it on a Mac, and it worked for me. Have you also set the charset in the source file like @jbg mentioned? Or perhaps it could be the character encoding settings of your terminal? (not sure though if this matters)

1 Like

Actually no, I’m using us-ascii, but I use the \u codes now and then embedded in strings. But it’s not a big deal for me, the special characters are very limited and the game is meant to be run in QTads anyway…

I presume this is something to do with G-TADS, since from looking at the source, it uses latin1 and not UTF-8.