summaryrefslogtreecommitdiff
path: root/src/Fl_Input_.cxx
diff options
context:
space:
mode:
authorMatthias Melcher <fltk@matthiasm.com>2006-04-17 17:56:05 +0000
committerMatthias Melcher <fltk@matthiasm.com>2006-04-17 17:56:05 +0000
commite682ec63392c413db5a7bfa00fd092dbf07bc4d3 (patch)
tree3e3eeea891e4563fd50d6d4f3868b3f2dcce85f3 /src/Fl_Input_.cxx
parent1184d7eee6ae394a93d352fe60b6630eb444fea5 (diff)
Allowing characters between 0x80 and 0x9f to be enetered into Fl_Input_ derived widgets. Although these were not defined in the western ISO code page, they seem to be implemented in most X11 drivers now as MSWindows Latin-1. For example, the Euro symbol is at 0x80. It should now be possible to enter the Euro sign and other chars in this range correctly. Please verify.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.1@4971 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
Diffstat (limited to 'src/Fl_Input_.cxx')
-rw-r--r--src/Fl_Input_.cxx16
1 files changed, 9 insertions, 7 deletions
diff --git a/src/Fl_Input_.cxx b/src/Fl_Input_.cxx
index 9d9150e01..a61be37e1 100644
--- a/src/Fl_Input_.cxx
+++ b/src/Fl_Input_.cxx
@@ -90,12 +90,13 @@ const char* Fl_Input_::expand(const char* p, char* buf) const {
*o++ = ' ';
#else
// in ISO 8859-1, undefined characters are rendered as octal
- } else if (c >= 128 && c < 0xA0) {
+ // this is commented out since most X11 seems to use MSWindows Latin-1
+ //} else if (c >= 128 && c < 0xA0) {
// these codes are not defined in ISO code, so we output the octal code instead
- *o++ = '\\';
- *o++ = ((c>>6)&0x03) + '0';
- *o++ = ((c>>3)&0x07) + '0';
- *o++ = (c&0x07) + '0';
+ // *o++ = '\\';
+ // *o++ = ((c>>6)&0x03) + '0';
+ // *o++ = ((c>>3)&0x07) + '0';
+ // *o++ = (c&0x07) + '0';
} else if (c == 0xA0) { // nbsp
*o++ = ' ';
#endif
@@ -124,9 +125,10 @@ double Fl_Input_::expandpos(
#ifdef __APPLE__
// in MacRoman, all characters are defined
#else
- } else if (c >= 128 && c < 0xA0) {
+ // in Windows Latin-1 all characters are defined
+ //} else if (c >= 128 && c < 0xA0) {
// these codes are not defined in ISO code, so we output the octal code instead
- n += 4;
+ // n += 4;
#endif
} else {
n++;