Talk:Terminal control/Unicode output: Difference between revisions

m
My internet connect keeps dropping in storm. I hope this works
m (My internet connect keeps dropping in storm. I hope this works)
Line 8:
== Er, "Terminal supports"? ==
 
I can run <code>xterm +u8</code> with UTF-8 locale, and both current awk and shell solutions output garbage. What does it mean, "terminal supports unicode"? The ZX spectrum basic solution doesn't even make sense: can you display more than 256 different characters on screen at once? If not, what good is this "unicode support"? --[[User:Ledrug|Ledrug]] 03:12, 12 September 2011 (UTC)
 
Terminal supports unicode means that the terminal supports Unicode output. Not all terminals can do this.
 
:The ZX spectrum basic solution doesn't even make sense: can you display more than 256 different characters on screen at once? If not, what good is this "unicode support"? --[[User:Ledrug|Ledrug]] 03:12, 12 September 2011 (UTC)
 
:Yes, the ZX Spectrum can display more than 256 different characters at once. You need to define some switching code though, and you are limited to about 40k usable memory,but that is more than enough to fill the screen. You can even reference the symbol numbers using the listed Unicode symbols, but you would need to code this. The ZX Spectrum was a versatile little machine. FWIW, I used an alternative character set called M5C (one of my own inventions), which I also implemented on IBM compatible computers. This used a 5 bit character set with page switching, and supported many different characters. I will eventually expand and publish updated specifications (because my notes were only partially complete. There are still unused pages that could be implemented. I only implemented what was needed at the time, and the unused pages left room for expansion.)
 
Yeah, the printf may not work on some systems. I am working on some Unicode compatible helper programs which will be guaranteed to produce the appropriate Unicode output from shell scripts, etc. This in on my todo list.
 
There are some other problems with the Unix shell solution. It uses a non-portable construct "set --" instead of "unset". I will try to find why this construct was used instead of "unset" (which is more portable). Maybe we need two versions here. I am investigating this. [[User:Markhobley|Markhobley]] 15:48, 12 September 2011 (UTC)