浏览代码

UI: Fix checkbox misalignment on macOS in properties view

Nikola Jovic 2 年之前
父节点
当前提交
21a906d7d9
共有 1 个文件被更改,包括 7 次插入1 次删除
  1. 7 1
      UI/properties-view.cpp

+ 7 - 1
UI/properties-view.cpp

@@ -1626,8 +1626,14 @@ void OBSPropertiesView::AddProperty(obs_property_t *property,
 			QHBoxLayout *boxLayout = new QHBoxLayout(newWidget);
 			boxLayout->setContentsMargins(0, 0, 0, 0);
 			boxLayout->setAlignment(Qt::AlignLeft);
+#ifdef __APPLE__
+			/* TODO: This fixes the issue of tooltip not aligning
+			 * correcty on macOS, the root cause needs further
+			 * investigation. */
+			boxLayout->setSpacing(10);
+#else
 			boxLayout->setSpacing(0);
-
+#endif
 			QCheckBox *check = qobject_cast<QCheckBox *>(widget);
 			check->setText(desc);
 			check->setToolTip(