134 Commits
Author SHA1 Message Date
Warchamp7 d268a19b4a frontend: Avoid recreating YouTube dock 2025-07-11 17:28:59 -04:00
Warchamp7 9858e7e722 frontend: Enforce minimum height for QList items 2025-07-07 14:35:42 -04:00
Matt Gajownik 70c85f9875 Update translations from Crowdin 2025-07-01 13:34:08 -04:00
Sebastian Beckmann d3c5d2ce0b frontend: Set Frontend-API QActions role to NoRole
When no role is set, the default is QAction::TextHeuristicRole. This
means that the text of the item gets fuzzy-matched in Qt against a set
of possible strings that could indicate that the menu should be in the
application menu on macOS.
For us this meant however that on some languages, the translation of
"WebSocket Server Settings" would begin with "Config", and as such the
related QAction replaces our "Settings" action for the PreferencesRole,
and clicking "Preferences..." in the application menu would open the
websocket settings. It should probably be considered a bug in Qt that
implicit matches via TextHeuristicRole can overwrite ones that are
explicitly set (like our PreferencesRole). However we explicitly set our
roles ourselves anyways and there is no scenario where a  plugin should
overwrite them, we can just default actions added via the Frontend API
to be NoRole; and worry about the Qt bug later.
2025-06-16 15:20:41 -04:00
PatTheMav 059fd6210c frontend: Fix visibility issues of meta type stream operators
For custom types to become usable as QVariants they not only need to
be declared as meta types, but also need to have appropriate stream
operators declared.

These declarations (both of the meta type itself, which provides a
static meta type ID getter via the macro, as well as the operators)
need to be visible to the compiler in any compilation unit where they
might be used in their QVariant form, otherwise the templates will
be incomplete.

A blanket include of "qt-wrappers.hpp" in "OBSBasic.hpp" is not the
most subtle fix, but it's necessary to ensure that the meta types
are always "complete". Putting both declarations in the qt-wrappers
header (instead of splitting them up) ensures that (as the classes
themselves are declared in "obs.hpp", which is included by
"qt-wrappers.hpp", and thus qt-wrappers can provide a complete class.
2025-06-16 14:44:27 -04:00
shiina424 bd68d33b0d frontend: Fix preview zoom buttons translation string 2025-06-16 13:31:20 -04:00
shiina424 2b38b92652 frontend: Fix group icon position in System theme 2025-06-13 17:54:04 -04:00
Matt Gajownik ffef7504ac Update translations from Crowdin 2025-06-09 14:55:50 -04:00
Sebastian Beckmann 1d5bcec80f frontend: Make Mac font base value configurable
Sets the base value to 1.2 times the "displayed" value instead of
forcing 12 (which was 1.2x of the default 10pt). This should look the
same as on other operating systems.
2025-06-05 15:19:49 -04:00
Sebastian Beckmann 3cba029a38 frontend: Recognize OBS appearance setting usage in math statements
The check for whether an OBS appearance setting is used in a theme only
checks whether there is a direct alias to an injected variable, like
`--font_base_value: var(--obsFontScale)`. Math statements like
`--font_base_value: calc(1 + var(--obsFontScale))` would not get
recognized, so if a theme only uses such statements (no direct aliases),
the check would wrongfully conclude that the appearance setting is not
used, which would later lead to the setting being disabled in the UI.
The value however would be injected correctly.

This can be mitigated by checking whether the arguments of the math
operations contain the expression.
2025-06-05 15:19:49 -04:00
PatTheMav 8b7331642f frontend: Fix metatype declaration for scenes' SignalContainer
To be used as a QVariant, stream operators need to be provided
as the meta type will otherwise be considered "incomplete". These were
implemented before the frontend reorganization but not migrated as part
of it.
2025-06-04 14:15:11 -04:00
Monsteer 34eb24508b frontend: Fix tab padding for the new appearance options
Add padding variables for tabs to allow the new density option.
2025-06-04 13:49:27 -04:00
shiina424 6a01aab641 frontend/forms: Fix text cut off in multitrack video info 2025-06-04 13:26:33 -04:00
Sebastian Beckmann cabe65cb98 frontend/forms: Fix duplicate UI element name warning
horizontalLayout_5 was already used further up.
2025-06-04 13:03:35 -04:00
Warchamp7 b45f776ee3 frontend: Set minimum width for menubar padding 2025-06-04 12:30:51 -04:00
Warchamp7 86e3e4b358 frontend: Fix appearance settings enabling Apply button 2025-06-04 12:30:51 -04:00
Warchamp7 dd71444069 frontend: Update projector menu for disabled preview 2025-06-04 12:30:51 -04:00
Warchamp7 31bcad96ad frontend: Adjust volume mixer styling on Classic theme 2025-06-04 12:30:51 -04:00
Ryan Foster 9bd4514b45 frontend: Ensure cookie ID is always 16 hexadecimal characters
At a glance, the GenId function looks like it can only return a
16-character hexadecimal string with all characters being [0-9A-F].
However, it seems that it can rarely return a 16-character string that
has one or two space characters at the beginning due to the value of id,
from which the final string is derived, being too low (lower than
1152921504606846976 or 0x1000000000000000) and the printf format
specifier having a width of 16. This results in a string of less than 16
characters that is padded with blank spaces. The end result is a cookie
directory that has leading spaces in its name, which can cause various
issues, such as breaking syncing on OneDrive.

If we set the format specifier to pad with zeroes instead of spaces, the
resulting hexadecimal value is always 16 characters long without spaces.
2025-05-28 12:42:22 -04:00
Warchamp7 a3884d1375 frontend: Update Dock toolbar styling 2025-05-28 12:22:41 -04:00
tytan652 bdebea3d85 frontend: Enable browser hw accel toggle under Linux 2025-05-24 14:20:21 -04:00
Warchamp7 910271d21c frontend: Fix spacing of group expand button 2025-05-23 04:25:55 -04:00
Ryan Foster b9cd9f30b1 frontend: Make profile export menu item translatable 2025-05-22 16:55:49 -04:00
shiina424 b4e8fa78fb frontend: Fix multiview translation string 2025-05-22 16:55:49 -04:00
shiina424 16965844dc frontend: Fix button pressed color in Rachni theme 2025-05-22 15:47:05 -04:00
Warchamp7 32f1b93d72 frontend: Swap preview zoom buttons 2025-05-22 14:21:08 -04:00
shiina424 ae61432c8e frontend: Add missing translations 2025-05-22 13:21:41 -04:00
shiina424 b7bd7c00c5 frontend: Fix visibility and lock checkbox in System theme 2025-05-22 12:48:13 -04:00
Warchamp7 0b7c1f7081 frontend: Explicitly set titlebar item padding 2025-05-21 15:22:44 -04:00
Exeldro cae8d8a3da frontend: Fix canvas remove event 2025-05-21 11:45:14 -04:00
Warchamp7 b46e5bb1c0 frontend: Fix dock title button sizes 2025-05-20 14:40:38 -04:00
shiina424 91ad044e68 frontend: Add close icon 2025-05-14 13:18:37 -04:00
tytan652 b65ee89451 frontend: Use winId for Wayland surface in Qt 6.9+
As of Qt 6.9, winId return a wl_surface pointer which allows us to move
away completely from QPlatformNativeInterface.

https://github.com/qt/qtwayland/commit/32f9b4d
2025-05-13 14:40:31 -04:00
Ryan Foster 840ca8e0d9 frontend: Use public QNativeInterface in Qt 6.5+
Using QNativeInterface allows us to move away from most of
QPlatformNativeInterface usage.
2025-05-13 14:40:31 -04:00
Ed Maste e0e132e5cf frontend: Fix build on FreeBSD
libpci is now required on FreeBSD, as on Linux.

Fixes: e1d2cf705d ("frontend: Support enhanced broadcasting on Linux")
2025-05-12 17:21:09 -04:00
Dennis Sädtler e474a3723b frontend: Allow 5 multitrack reconnect attempts before re-running GCC 2025-05-07 15:46:50 -04:00
PatTheMav 16216b2e30 frontend: Fix character encoding issue during profile import
The directory name string passed into libobs functions needs to be
converted into a 8-bit-based encoding (e.g., UTF-8) to avoid mangling
of characters and encoding issues particularly on Windows systems which
use UTF-16 for file names.
2025-05-07 14:58:38 -04:00
cg2121 d7cce79d7e frontend: Use static_cast when casting from void pointers
Using static_cast is preferred here, as it is safer to use than
reinterpret_cast.
2025-05-05 20:47:10 -04:00
Dennis Sädtler 0552062390 frontend: Allow selecting additional canvases for multitrack 2025-05-05 17:17:20 -04:00
Dennis Sädtler 8117c89b9a frontend: Update multitrack API model
"revision" was defined to be a string in the schema but accepted
integers, this is enforced with the new schema version.
2025-05-05 17:17:20 -04:00
Dennis Sädtler 811072d0fd frontend: Always limit multitrack video encoders to libobs maximum 2025-05-05 17:17:20 -04:00
cg2121 345fe56b6e frontend: Make sure all QObject subclasses have Q_OBJECT macro
Went through and found all QObject subclasses that didn't have
a Q_OBJECT macro.
2025-05-05 13:10:39 -04:00
Dennis Sädtler 8441c04c73 frontend: Add frontend API canvas methods 2025-05-02 14:35:22 -04:00
Dennis Sädtler 368185019e frontend: Add support loading/saving additional canvases 2025-05-02 14:35:22 -04:00
Dennis Sädtler afd7619c98 frontend: Add OBS::Canvas class 2025-05-02 14:35:22 -04:00
cg2121 47360a92c5 frontend: Use Q_OBJECT macro for BrowserDock
This is needed as the BrowserDock is a QObject.
2025-05-01 16:01:14 -04:00
gxalpha 281f8137f5 UI,libobs,obs-outputs: Remove HAVE_OBSCONFIG_H ifdefs
With the removal of all legacy code paths, obsconfig.h always exists and
the compile definition always gets set. As such, it's no longer
necessary to check for it.

As removing the definition itself could be seen as a breaking change,
this simply moves the definition to pc.in and cmake.in files for now to
preserve the value for plugins that might expect this to be set. We may
remove the definition entirely in a later release.
2025-04-30 13:05:35 -04:00
Ruwen Hahn 9bba6e52ff frontend: Allow Network Optimizations with multitrack video
"Enable network optimizations" in the Advanced Settings is referred to
as `NewSocketLoop` in the code. This feature was incompatible with
multitrack video but now works properly. Remove it from the
incompatible settings check.
2025-04-30 12:27:03 -04:00
Alex Luccisano 6bb9019aff frontend: Allow Stream Delay with multitrack video
Remove Stream Delay from the incompatible settings list for multitrack
video as it works properly now.
2025-04-29 13:50:57 -04:00
Warchamp7 99d7d134a7 frontend: Clip source names when dock too small 2025-04-28 16:18:07 -04:00