>>> When a modifier is down, Fl::event_text() no longer emits anything.
>>> In fact it appears key ups no longer put anything in event_text() at
>>> all.  The following program should reproduce it.  I believe that
>>> previously keyup the letter (capital if shift is held), but now it
>>> doesn't.
>>
>> Should be fixed with r.8773. Can you confirm, please?
>
> Looks good to me.  Thanks!

Sorry, I spoke too soon!  If you hold down shift+control (or any other
modifier), no text is emitted.

However, maybe this is actually correct.  Control+letter doesn't
actually emit that letter, so why should control+shift+letter?  My
code to determine the letter is:

    m.key = Fl::event_text()[0];
    if (!isprint(m.key)) {
        // shift or backspace or some such
        m.key = Fl::event_key();
    }
    if (isletter(m.key) && FL_SHIFT in Fl::modifier_state())
        m.key = toupper(m.key);

This seems to get what I want.  In fact, I arguably shouldn't be using
event_text()[0] at all, but I recall event_key() had some weird issues
with my remapped keyboard.

_______________________________________________
fltk-dev mailing list
fltk-dev@easysw.com
http://lists.easysw.com/mailman/listinfo/fltk-dev

Reply via email to