wrong LC_NUMBERIC cause CSS unsupported value

warning: unsupported value
position: absolute; width: 12.9em; transform: translateX(16.27em);
^
and you know, some countries uses decimal point as comma - not point.
so scanf function cannot read "12.9em" if we set NUMERIC at that country.
Such as French.
 
// query LC_NUMERIC 
char* locale = setlocale(LC_NUMERIC, NULL); 
// set LC_NUMERIC 
char* locale = "en_US.utf8"; 
setlocale(LC_NUMERIC, locale); 
 
if LC_NUMERIC was set to "frCA.UTF-8",
12.9em can't be read as a Decimal.
The correct should be like "en_US.utf8"
Refer:
https://en.wikipedia.org/wiki/Decimal_mark
http://man7.org/linux/man-pages/man3/setlocale.3.html

Comments

Popular posts from this blog

react-native run-android : do not build/update modified code(App.js)

react-native run-android : sun.security.provider.cert path.SunCertPathBuilderException : unable to find valid certification path to req uested target

How to fix error : no module named sendgrid when try to use sendgrid python lib in PHP.