Tab order in Dock Window



  • If the Tab key is pressed in the Dock Window then the focus changed to the next widget in the specified tab order.
    But when the Tab key is pressed on the last child in the Dock Window then the focus changed in unpredictable way to another application Dock Window or central widget. Even more, the Shift-Tab keys do not return focus to the last widget.

    Can anybody advice me how to move focus from the last widget in the Dock Window to the first one on Tab key press. I know about setTabOrder() function, but it does not help in this case.



  • Focus chains are on a window basis.

    There's no such thing as a dock window in Qt. There's a dock widget though that sometimes acts as a window (when detached).

    You can try not setting a parent (but I don't know the results of that).
    Or setting the Qt::Window flag.



  • Thank you for reply.

    [quote author="tbscope" date="1290405320"]There's no such thing as a dock window in Qt. There's a dock widget though that sometimes acts as a window (when detached).[/quote]

    You are right, I mean QDockWidget (in Qt3 it was called QDockWindow).

    [quote author="tbscope" date="1290405320"]You can try not setting a parent (but I don't know the results of that).[/quote]

    It will be re-parented when added to QMainWindow dock area.

    [quote author="tbscope" date="1290405320"]Or setting the Qt::Window flag.[/quote]

    The problem exists if the widget is docked.


Log in to reply
 

Looks like your connection to Qt Forum was lost, please wait while we try to reconnect.