Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Gui: Move more button to the end WB TabBar #13721

Merged
merged 7 commits into from
May 13, 2024

Commits on May 12, 2024

  1. Gui: Add our ToolBarArea enumeration

    This refactors implementation of toolbars in menu / status bar a bit. It
    introduces enum with all possible areas like it is in Qt that can be
    later used to decide what to do based on toolbar placement.
    kadet1090 committed May 12, 2024
    3 Configuration menu
    Copy the full SHA
    4d1b375 View commit details
    Browse the repository at this point in the history
  2. Gui: Move more button to the end WB TabBar

    This changes back placement of the "more" button of the WB TabBar to be
    at the end, where it should be naturally placed. In order to ensure that
    it is always visible the control was reworked to show this button always
    after the tab bar widget which now is dynamically sized. This is
    behavior that is well known from browsers.
    
    This commit also ensures that active workbench is always visible in the
    TabBar by adding additional temporary tab when necessary. This tab will
    automatically dissapear when not needed.
    
    Fixes: FreeCAD#13720
    Fixes: FreeCAD#13630
    kadet1090 committed May 12, 2024
    Configuration menu
    Copy the full SHA
    3405939 View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    7e22dad View commit details
    Browse the repository at this point in the history
  4. Gui: Adjust sizing of Workbench TabBar when changing orientation

    This should fix issues when toolbar containing Workbench TabBar suddenly
    (or not) changes orientation. It also fixes size policies so toolbar
    resizes properly and does not cause window to grow.
    
    Fixes: FreeCAD#13286
    kadet1090 committed May 12, 2024
    Configuration menu
    Copy the full SHA
    37d6ba2 View commit details
    Browse the repository at this point in the history
  5. Gui: Use RTL layout when Wb Tab Bar is placed in right corner

    Right corner is placed to the right edge of screen, so its natural
    growth occours on the left side. Basically it is Right to Left order and
    so in that case the "end" is actually on left and so TabBar should grow
    in that direction.
    
    Unfortunately it is not possible to simply use RTL Qt feature to handle
    that case as it would result in reverse order of workbenches (people will still
    read it in LTR order) and icons on the right which is not wanted. That's
    custom support is introduced.
    kadet1090 committed May 12, 2024
    Configuration menu
    Copy the full SHA
    82f6b68 View commit details
    Browse the repository at this point in the history
  6. Gui: Fix wrong orientation of workbench tab bar after start

    This replaces old mechanism that was based on storing tab bar
    orientation in user settings with one that delays initialization by half
    of a second to ensure that toolbar is placed where in right place.
    kadet1090 committed May 12, 2024
    Configuration menu
    Copy the full SHA
    b1a11a6 View commit details
    Browse the repository at this point in the history
  7. Gui: Reuse QActions for workbench activation

    This fixes segfault that can occour due to keeping reference to QAction
    that is supposed to change workbench.
    kadet1090 committed May 12, 2024
    Configuration menu
    Copy the full SHA
    2e6af15 View commit details
    Browse the repository at this point in the history