Fix compose bug on OSX.

git-svn-id: file:///fltk/svn/fltk/branches/branch-1.1@2985 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
This commit is contained in:
Michael R Sweet 2003-05-20 15:29:42 +00:00
parent 1cbbf7f53f
commit b31a225083
2 changed files with 11 additions and 2 deletions

View File

@ -1,5 +1,7 @@
CHANGES IN FLTK 1.1.4
- OSX users couldn't enter some special chars when using
some foreign key layouts (STR #32)
- Hiding subwindows on OSX would hide the parent window
(STR #22)
- Added thin plastic box types.

View File

@ -1,5 +1,5 @@
//
// "$Id: Fl_compose.cxx,v 1.1.2.7.2.3 2003/01/30 21:43:04 easysw Exp $"
// "$Id: Fl_compose.cxx,v 1.1.2.7.2.4 2003/05/20 15:29:42 easysw Exp $"
//
// Character compose processing for the Fast Light Tool Kit (FLTK).
//
@ -76,7 +76,14 @@ int Fl::compose(int& del) {
// Alt+letters are reserved for shortcuts. But alt+foreign letters
// has to be allowed, because some key layouts require alt to be held
// down in order to type them...
if (e_state & (FL_ALT|FL_META) && !(ascii & 128)) return 0;
//
// OSX users sometimes need to hold down ALT for keys, so we only check
// for META on OSX...
#ifdef __APPLE__
if ((e_state & FL_META) && !(ascii & 128)) return 0;
#else
if ((e_state & (FL_ALT|FL_META)) && !(ascii & 128)) return 0;
#endif // __APPLE__
if (compose_state == 1) { // after the compose key