You can use the procedures this chapter to set a system-wide default locale or to add a new locale from the Solaris DVD and CD media. You also change the font path set by the Xsession script included in the Traditional Chinese Solaris operating system. This chapter includes the following sections.
This section describes methods to set the default locale.
Become superuser.
In the /etc/default/init file, add or update the LANG variable with the appropriate locale.
LANG=locale |
You can set the LANG variable with one of the following locales: C, zh_TW, zh_TW.BIG5, zh_TW.UTF-8, zh_HK.BIG5HK, zh_HK.UTF-8
Instruct all users to exit CDE.
Kill the dtconfig process.
# /usr/dt/bin/dtconfig -kill |
Reboot the system.
# reboot |
You can use aliases to change locales in a terminal window without typing long commands or editing your .dtlogin file and running source every time.
Put aliases such as the following in your .profile file.
alias twn_EUC "export LANG=zh_TW; /bin/stty cs8 -istrip defeucw" alias twn_BIG5 "export LANG=zh_TW.BIG5; /bin/stty cs8 -istrip \defeucw" alias asc "export LANG=C; /bin/stty cs7 istrip defeucw" alias twn_UTF-8 "export LANG=zh_TW.UTF-8; /bin/stty cs8 -istrip defeucw" |
Put aliases like the following in your .cshrc file.
alias twn_EUC "setenv LANG zh_TW; /bin/stty cs8 -istrip defeucw" alias twn_BIG5 "setenv LANG zh_TW.BIG5; /bin/stty cs8 -istrip \defeucw" alias asc "setenv LANG C; /bin/stty cs7 istrip defeucw" alias twn_UTF-8 "setenv LANG=zh_TW.UTF-8; /bin/stty cs8 -istrip defeucw" |