Commit Graph

5 Commits

Author SHA1 Message Date
Marek Roszko f0987821b5 Move locale_io to kicommon 2023-09-11 21:51:58 -04:00
luz paz 79fa911e0e Fix various typos
Found via `codespell -q 3 -S *.po,./thirdparty,./Documentation/changelogs -L aactual,acount,aline,alocation,alog,anormal,anumber,aother,apoints,aparent,aray,ba,busses,dout,einstance,leaded,modul,ontext,ot,overide,serie,te,,tesselate,tesselator,tht`
2022-07-21 16:31:41 +00:00
Jeff Young b065ff33dc Looks like clang (or OSX?) needs an extra include.... 2021-09-23 20:14:03 +01:00
jean-pierre charras 0cf81b6d4e LOCALE_IO rework to fix issues on linux when using env vars with non ASCII7 chars.
We need to use a "C" locate to read/write files, and therefore switch the locale.
Removing use of setlocale( LC_NUMERIC, "C" ) and use only
wxLocale( "C", "C", "C", false ) was too fast: on linux it breaks the env vars.
on MSW
    using setlocale( LC_NUMERIC, "C" ) generates an alert message in debug mode,
    and this message ("Decimal separator mismatch") must be disabled.
    But calling wxLocale( "C", "C", "C", false ) works fine
On unix:
    calling wxLocale( "C", "C", "C", false ) breaks env vars containing non ASCII7 chars.
    these env vars return a empty string from wxGetEnv() in many cases, and if such a
    var must be read after calling wxLocale( "C", "C", "C", false ), it looks like empty

So use wxLocale on Windows and setlocale on unix
2021-09-23 14:31:25 +02:00
Marek Roszko 1d559108c8 Move LOCALE_IO out of common.h 2020-10-23 21:49:42 -04:00