Skip to content

frontend: Move Preview into dock widget#12190

Draft
Warchamp7 wants to merge 1 commit intoobsproject:masterfrom
Warchamp7:preview-dock
Draft

frontend: Move Preview into dock widget#12190
Warchamp7 wants to merge 1 commit intoobsproject:masterfrom
Warchamp7:preview-dock

Conversation

@Warchamp7
Copy link
Member

Description

Moves the widgets for the preview into an OBSDock within the main window. Instead of the preview being the centralwidget, a new dummy one is added to the top of the window, and all docks have their allowedAreas set to BottomDockWidgetArea only.

Depends on #12188

Note

Still need to update Browser Docks to have their allowedAreas set correctly, as well as probably override the addDock method to force set it.

The Preview dock cannot be moved, undocked or hidden and has an empty widget for it's title bar. Functionally it is effectively identical to before.

image

Motivation and Context

This makes certain dock layouts much more intuitive to set up, moves us a small step closer to more encapsulation of main window functionality. This is also a requirement for additional UI changes in the future that I am experimenting with involving either a top toolbar or a dedicated sidebar as a revamped home for Outputs, contextual controls, and eventually canvases.

How Has This Been Tested?

Interacted with the preview and ensured functionality matched main.

Types of changes

  • Tweak (non-breaking change to improve existing functionality)

Checklist:

  • My code has been run through clang-format.
  • I have read the contributing document.
  • My code is not on the master branch.
  • The code has been tested.
  • All commit messages are properly formatted and commits squashed where appropriate.
  • I have included updates to all appropriate documentation.

@exeldro
Copy link
Contributor

exeldro commented May 23, 2025

By putting everything in a single dock area "Full-Height docks" option will not be functional anymore.

OBSBasic::AddDockWidget might need to force to bottom area too for docks from plugins

@Warchamp7
Copy link
Member Author

By putting everything in a single dock area "Full-Height docks" option will not be functional anymore.

Correct, the option won't be needed anymore, since the preview not being the central widget will no longer restrict docks from being laid out in the way that full height docks addressed.

OBSBasic::AddDockWidget might need to force to bottom area too for docks from plugins

Yep, this is also planned.

@WizardCM WizardCM added Enhancement Improvement to existing functionality UI/UX Anything to do with changes or additions to UI/UX elements. labels May 28, 2025
@Warchamp7 Warchamp7 added this to the OBS Studio 32.0 milestone Jun 16, 2025
@Warchamp7 Warchamp7 force-pushed the preview-dock branch 4 times, most recently from 19eb366 to 3b0f955 Compare December 25, 2025 14:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Enhancement Improvement to existing functionality UI/UX Anything to do with changes or additions to UI/UX elements.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants