[vlc-commits] qml: add SubtitleLabel widget
Fatih Uzunoglu
git at videolan.org
Fri Jul 3 14:59:02 CEST 2020
vlc | branch: master | Fatih Uzunoglu <fuzun54 at outlook.com> | Thu Jun 25 00:53:52 2020 +0300| [b30fc3ebb3fcce7f936eaf9ef7782838eacefa41] | committer: Pierre Lamot
qml: add SubtitleLabel widget
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=b30fc3ebb3fcce7f936eaf9ef7782838eacefa41
---
modules/gui/qt/Makefile.am | 1 +
modules/gui/qt/vlc.qrc | 1 +
modules/gui/qt/widgets/qml/SubtitleLabel.qml | 26 ++++++++++++++++++++++++++
3 files changed, 28 insertions(+)
diff --git a/modules/gui/qt/Makefile.am b/modules/gui/qt/Makefile.am
index e3c78a3008..af2cc0ae57 100644
--- a/modules/gui/qt/Makefile.am
+++ b/modules/gui/qt/Makefile.am
@@ -670,6 +670,7 @@ libqt_plugin_la_QML = \
gui/qt/widgets/qml/ListItem.qml \
gui/qt/widgets/qml/ListLabel.qml \
gui/qt/widgets/qml/MediaCover.qml \
+ gui/qt/widgets/qml/SubtitleLabel.qml \
gui/qt/widgets/qml/MenuExt.qml \
gui/qt/widgets/qml/MenuItemExt.qml \
gui/qt/widgets/qml/NavigableCol.qml \
diff --git a/modules/gui/qt/vlc.qrc b/modules/gui/qt/vlc.qrc
index 6c12e06b2b..ce26f6774b 100644
--- a/modules/gui/qt/vlc.qrc
+++ b/modules/gui/qt/vlc.qrc
@@ -214,6 +214,7 @@
<file alias="CaptionLabel.qml">widgets/qml/CaptionLabel.qml</file>
<file alias="IconLabel.qml">widgets/qml/IconLabel.qml</file>
<file alias="ListLabel.qml">widgets/qml/ListLabel.qml</file>
+ <file alias="SubtitleLabel.qml">widgets/qml/SubtitleLabel.qml</file>
<file alias="PlayCover.qml">widgets/qml/PlayCover.qml</file>
<file alias="MediaCover.qml">widgets/qml/MediaCover.qml</file>
</qresource>
diff --git a/modules/gui/qt/widgets/qml/SubtitleLabel.qml b/modules/gui/qt/widgets/qml/SubtitleLabel.qml
new file mode 100644
index 0000000000..b9cdd5092e
--- /dev/null
+++ b/modules/gui/qt/widgets/qml/SubtitleLabel.qml
@@ -0,0 +1,26 @@
+/*****************************************************************************
+ * Copyright (C) 2020 VLC authors and VideoLAN
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * ( at your option ) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston MA 02110-1301, USA.
+ *****************************************************************************/
+import QtQuick 2.11
+import QtQuick.Controls 2.4
+import "qrc:///style/"
+
+Label {
+ elide: Text.ElideRight
+ font.pixelSize: VLCStyle.fontSize_xxlarge
+ color: VLCStyle.colors.text
+}
More information about the vlc-commits
mailing list