Hello, Josef. The situation you describe lead me into using everywhere iso-8859-1/15. This incoding is closest to DOS codepage, a 1-Byte charset, and causing no troubles when interacting with microcontrollers (also usually only using 8-Bit charsets). For me "UTF8 everywhere" would be an odyssee. I would have to implement UTF8 into microcontrollers with a few k of ROM (a no-go), or everywhere implement a translation. It is lots easier to have everywhere 8859-1 in use. About YaST: I see that Yast can perfectly work with config files edited with 'joe' on 8859-1 system. So I see no need to change something in this part? The problem YaST has, is controlling the screen/terminal in text mode! It is fully ok if you internally always use UTF8, but it appears there is a problem with correctly controlling the terminal. Therefore it works fine on screens/terminals using UTF8, but it has some glitches when controlling a terminal on 8859-1 (as an example). So YaST *must* read the locale settings and then do some kind of translation before writing to the screen. This is the only way to get this working. Noone can use YaST without logging in. And with logging in, a locale setting is already assigned. No? Btw: I do the same (internally using a standard encoding) in my programs. The only difference is that my standard is iso-8859-15 while your standard is utf8. Doesn't really matter, we (both) have to convert while reading/writing. But it seems that some of this conversions have been not implemented in Yast, and this causes the described distortions. Am Freitag, 18. Jan 2019, 12:06:32 schrieb Josef Reidinger:
V Fri, 18 Jan 2019 08:17:43 +0100
Rainer Hantsch
napsáno: Hello.
Well, YaST supports only UTF-8. Reason is that guessing enconding just from text is unreliable, so we pick one format that works well for various locale. Originally we use locale to set enconding, but it leads to many issues with config files that user download, with locale set to C, but config files in UTF and others similar issues.
So unless there is reliable and fast way how to detect encoding of text, we do not plan to modify it unless there is a good reason for it and that won't break cases mentioned above.
Josef
-- To unsubscribe, e-mail: opensuse-factory+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse-factory+owner@opensuse.org