[vlc-devel] [PATCH 05/15] qml: use IconLabel and MenuCaption widget in TabButtonExt

Prince Gupta guptaprince8832 at gmail.com
Tue Jul 21 14:18:03 CEST 2020


---
 modules/gui/qt/widgets/qml/TabButtonExt.qml | 8 +++-----
 1 file changed, 3 insertions(+), 5 deletions(-)

diff --git a/modules/gui/qt/widgets/qml/TabButtonExt.qml b/modules/gui/qt/widgets/qml/TabButtonExt.qml
index bcc6aacd53..bf0f77d147 100644
--- a/modules/gui/qt/widgets/qml/TabButtonExt.qml
+++ b/modules/gui/qt/widgets/qml/TabButtonExt.qml
@@ -21,6 +21,7 @@ import QtQuick.Controls 2.4
 import QtQuick.Templates 2.4 as T
 import QtQuick.Layouts 1.3
 
+import "qrc:///widgets/" as Widgets
 import "qrc:///style/"
 
 T.TabButton {
@@ -35,7 +36,6 @@ T.TabButton {
     implicitHeight: contentItem.implicitHeight
 
     property string iconTxt: ""
-    property string bgColor: "transparent"
     property bool selected: false
 
     font.pixelSize: VLCStyle.fontSize_normal
@@ -65,7 +65,7 @@ T.TabButton {
                 implicitHeight: VLCStyle.fontHeight_normal
                 visible: control.iconTxt !== ""
 
-                Text {
+                Widgets.IconLabel {
                     id: icon
 
                     anchors.fill: parent
@@ -76,14 +76,12 @@ T.TabButton {
                     color: VLCStyle.colors.buttonText
 
                     font.pixelSize: VLCIcons.pixelSize(VLCStyle.icon_topbar)
-                    font.family: VLCIcons.fontFamily
                 }
             }
 
 
-            Label {
+            Widgets.MenuCaption {
                 text: control.text
-                font: control.font
                 color: VLCStyle.colors.text
             }
         }
-- 
2.25.1



More information about the vlc-devel mailing list