Skip to content

Commit

Permalink
automatic language selection fixed
Browse files Browse the repository at this point in the history
  • Loading branch information
zsiki committed Nov 28, 2017
1 parent 3c8d86a commit 88f75f8
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 7 deletions.
6 changes: 3 additions & 3 deletions geo_easy.msk
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# GUI language
global geoLang
set geoLang {hun}
# GUI language uncomment next two lines to set GUI language other than OS lang
#global geoLang
#set geoLang {eng}
# code page
global geoCp
# set geoCp {cp-1250}
Expand Down
8 changes: 4 additions & 4 deletions geo_easy.tcl
Original file line number Diff line number Diff line change
Expand Up @@ -54,8 +54,8 @@ proc GeoEasy {top} {
global fn
global version

set version 300 ;# title string too !!!!
set geoEasyMsg(mainTitle) "GeoEasy 3.0.0" ;# version variable too !!!!
set version 301 ;# title string too !!!!
set geoEasyMsg(mainTitle) "GeoEasy 3.0.1" ;# version variable too !!!!
# check conditions for geo and coo data
# each record must have point number
set geoMustHave {2 5 62}
Expand Down Expand Up @@ -142,14 +142,14 @@ proc GeoEasy {top} {
if {$tcl_platform(platform) != "unix"} {
set ww ""
catch {set ww [registry get HKEY_LOCAL_MACHINE\\SYSTEM\\CONTROLSET001\\control\\nls\\language InstallLanguage]}
switch -exact $ww {
switch -exact [string toupper $ww] {
"040E" { set w "hu"}
"0409" { set w "en"}
"0407" { set w "de"}
default { set w "en"}
}
} else {
catch {set w [string tolower $env(LANG)]}
catch {set w [string range [string tolower $env(LANG)] 0 2]}
}
if {! [info exists geoLang] || \
[lsearch -exact {hun eng ger} $geoLang] == -1} {
Expand Down

0 comments on commit 88f75f8

Please sign in to comment.