Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. QTabWidget in QScrollArea scroll wheel event issues
Forum Updated to NodeBB v4.3 + New Features

QTabWidget in QScrollArea scroll wheel event issues

Scheduled Pinned Locked Moved Unsolved General and Desktop
2 Posts 2 Posters 517 Views
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • S Offline
    S Offline
    s0H57
    wrote on last edited by
    #1

    Hi all,
    i am using a QTabWidget which is embedded inside a QScrollArea.
    The problem now is that scrolling via the MouseWheel when hovering the Tabs not only scrolls trough the tabs, but also scrolls the QScrollArea vertically. Is there any possibility to prevent this behaviour?
    When using other widgets like QSpinBox inside my QScrollArea this problem does not apprea, it seems for SpinBoxes the focus is correctly set and only the box itself scrolls.
    What i tried so far is EventFilters for the wheel event and also setting different FocusPolicies (e.g. StrongFocus) for the TabWidget and QScrollArea.

    I am using QT 5 with C++ building a Desktop Application.
    Thanks for your help.

    S 1 Reply Last reply
    0
    • S s0H57

      Hi all,
      i am using a QTabWidget which is embedded inside a QScrollArea.
      The problem now is that scrolling via the MouseWheel when hovering the Tabs not only scrolls trough the tabs, but also scrolls the QScrollArea vertically. Is there any possibility to prevent this behaviour?
      When using other widgets like QSpinBox inside my QScrollArea this problem does not apprea, it seems for SpinBoxes the focus is correctly set and only the box itself scrolls.
      What i tried so far is EventFilters for the wheel event and also setting different FocusPolicies (e.g. StrongFocus) for the TabWidget and QScrollArea.

      I am using QT 5 with C++ building a Desktop Application.
      Thanks for your help.

      S Offline
      S Offline
      SuperSelrak
      wrote on last edited by
      #2

      @s0H57 Yep I have the same issue and just posted about it ...

      https://forum.qt.io/topic/143148/qtabwidget-in-qscroll-area-concurrent-scrolling

      Maybe a bug ?

      1 Reply Last reply
      0

      • Login

      • Login or register to search.
      • First post
        Last post
      0
      • Categories
      • Recent
      • Tags
      • Popular
      • Users
      • Groups
      • Search
      • Get Qt Extensions
      • Unsolved