1
0
mirror of https://github.com/gryf/wmaker.git synced 2026-01-31 04:55:54 +01:00

added text widget from nwanua

This commit is contained in:
kojima
2000-06-20 23:27:37 +00:00
parent e410e1862b
commit c49ad9cac8
10 changed files with 4142 additions and 5 deletions

View File

@@ -2,6 +2,8 @@
#include "WINGsP.h"
#include <X11/Xlocale.h>
#include <proplist.h>
@@ -52,6 +54,7 @@ W_ReadConfigurations(void)
if (defaults) {
char *buttonName;
unsigned button;
char *str;
WINGsConfiguration.systemFont =
WMGetUDStringForKey(defaults, "SystemFont");
@@ -59,8 +62,26 @@ W_ReadConfigurations(void)
WINGsConfiguration.boldSystemFont =
WMGetUDStringForKey(defaults, "BoldSystemFont");
WINGsConfiguration.useMultiByte =
WMGetUDBoolForKey(defaults, "MultiByteText");
WINGsConfiguration.useMultiByte = False;
str = WMGetUDStringForKey(defaults, "MultiByteText");
if (str) {
if (strcasecmp(str, "YES") == 0) {
WINGsConfiguration.useMultiByte = True;
} else if (strcasecmp(str, "AUTO") == 0) {
char *locale;
/* if it's a multibyte language (japanese, chinese or korean)
* then set it to True */
locale = setlocale(LC_CTYPE, NULL);
if (locale != NULL
&& (strncmp(locale, "ja", 2) == 0
|| strncmp(locale, "zh", 2) == 0
|| strncmp(locale, "ko", 2) == 0)) {
WINGsConfiguration.useMultiByte = True;
}
}
}
WINGsConfiguration.doubleClickDelay =
WMGetUDIntegerForKey(defaults, "DoubleClickTime");