Changeset 106 for trunk/src/widgets


Ignore:
Timestamp:
Jul 29, 2006, 3:56:44 PM (19 years ago)
Author:
dmik
Message:

Widgets: QTextEdit: Fixed: AltGr+key can produce valid characters in some kbd layouts (i.e. the German one) which we must not ignore.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/widgets/qtextedit.cpp

    r8 r106  
    13761376            if ( e->text().length() &&
    13771377                ( !( e->state() & ControlButton ) &&
    1378 #ifndef Q_OS_MACX
     1378#if !defined(Q_OS_MACX) && !defined(Q_OS_OS2)
     1379                  // AltGr+key can produce valid characters in some kbd layouts
     1380                  // (i.e. the German one) which we must not ignore
    13791381                  !( e->state() & AltButton ) &&
    13801382#endif
    13811383                  !( e->state() & MetaButton ) ||
     1384                  // Note (dmik): the below line is possibly a typo because it's
     1385                  // equivalent to just (e->state() & ControlButton) which obviously
     1386                  // contradicts !( e->state() & ControlButton ) above. Anyway,
     1387                  // as a result, Ctrl+key are successfully handled by QTextEdit on
     1388                  // all platforms (because of the || operator), unless assigned
     1389                  // as hot keys (shortcuts).
    13821390                 ( ( (e->state()&ControlButton) | AltButton ) == (ControlButton|AltButton) ) ) &&
    13831391                 ( !e->ascii() || e->ascii() >= 32 || e->text() == "\t" ) ) {
Note: See TracChangeset for help on using the changeset viewer.