From bbe507ec0504fda0f67a084079692649aedc2e51 Mon Sep 17 00:00:00 2001 From: David Rowe Date: Fri, 11 Mar 2016 09:53:10 +1300 Subject: [PATCH 1/8] Add file headers and update Qt versions in VR menu QML files --- .../resources/qml/menus/MenuMouseHandler.qml | 10 ++++++++++ interface/resources/qml/menus/VrMenuItem.qml | 16 +++++++++++++--- interface/resources/qml/menus/VrMenuView.qml | 17 +++++++++++++---- 3 files changed, 36 insertions(+), 7 deletions(-) diff --git a/interface/resources/qml/menus/MenuMouseHandler.qml b/interface/resources/qml/menus/MenuMouseHandler.qml index 6f507dd445..d99b7f7828 100644 --- a/interface/resources/qml/menus/MenuMouseHandler.qml +++ b/interface/resources/qml/menus/MenuMouseHandler.qml @@ -1,3 +1,13 @@ +// +// MessageDialog.qml +// +// Created by Bradley Austin Davis on 18 Jan 2016 +// Copyright 2016 High Fidelity, Inc. +// +// Distributed under the Apache License, Version 2.0. +// See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html +// + import QtQuick 2.5 import QtQuick.Controls 1.4 diff --git a/interface/resources/qml/menus/VrMenuItem.qml b/interface/resources/qml/menus/VrMenuItem.qml index c23a54a2c7..955ab86167 100644 --- a/interface/resources/qml/menus/VrMenuItem.qml +++ b/interface/resources/qml/menus/VrMenuItem.qml @@ -1,6 +1,16 @@ -import QtQuick 2.4 -import QtQuick.Controls 1.3 -import QtQuick.Controls.Styles 1.3 +// +// VrMenuItem.qml +// +// Created by Bradley Austin Davis on 29 Apr 2015 +// Copyright 2015 High Fidelity, Inc. +// +// Distributed under the Apache License, Version 2.0. +// See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html +// + +import QtQuick 2.5 +import QtQuick.Controls 1.4 +import QtQuick.Controls.Styles 1.4 import "../controls" import "../styles" diff --git a/interface/resources/qml/menus/VrMenuView.qml b/interface/resources/qml/menus/VrMenuView.qml index bbb9bd706e..8b0673229c 100644 --- a/interface/resources/qml/menus/VrMenuView.qml +++ b/interface/resources/qml/menus/VrMenuView.qml @@ -1,10 +1,19 @@ -import QtQuick 2.4 -import QtQuick.Controls 1.3 -import QtQuick.Controls.Styles 1.3 +// +// VrMenuView.qml +// +// Created by Bradley Austin Davis on 18 Jan 2016 +// Copyright 2016 High Fidelity, Inc. +// +// Distributed under the Apache License, Version 2.0. +// See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html +// + +import QtQuick 2.5 +import QtQuick.Controls 1.4 +import QtQuick.Controls.Styles 1.4 import "../styles" - FocusScope { id: root implicitHeight: border.height From 2b45971f8cfea55ffd894a5479b3a52904a6e755 Mon Sep 17 00:00:00 2001 From: David Rowe Date: Fri, 11 Mar 2016 11:42:49 +1300 Subject: [PATCH 2/8] Style HMD menu backgrounds --- .../resources/qml/menus/MenuMouseHandler.qml | 4 ++-- interface/resources/qml/menus/VrMenuView.qml | 23 +++++++++++-------- .../qml/styles-uit/HifiConstants.qml | 2 ++ 3 files changed, 17 insertions(+), 12 deletions(-) diff --git a/interface/resources/qml/menus/MenuMouseHandler.qml b/interface/resources/qml/menus/MenuMouseHandler.qml index d99b7f7828..9ba158cb28 100644 --- a/interface/resources/qml/menus/MenuMouseHandler.qml +++ b/interface/resources/qml/menus/MenuMouseHandler.qml @@ -104,8 +104,8 @@ Item { function buildMenu(items, targetPosition) { var model = toModel(items); - // Menu's must be childed to desktop for Z-ordering - var newMenu = menuViewMaker.createObject(desktop, { model: model, z: topMenu ? topMenu.z + 1 : desktop.zLevels.menu }); + // Menus must be childed to desktop for Z-ordering + var newMenu = menuViewMaker.createObject(desktop, { model: model, z: topMenu ? topMenu.z + 1 : desktop.zLevels.menu, isSubMenu: topMenu !== null }); if (targetPosition) { newMenu.x = targetPosition.x newMenu.y = targetPosition.y - newMenu.height / 3 * 1 diff --git a/interface/resources/qml/menus/VrMenuView.qml b/interface/resources/qml/menus/VrMenuView.qml index 8b0673229c..8778bc4bd1 100644 --- a/interface/resources/qml/menus/VrMenuView.qml +++ b/interface/resources/qml/menus/VrMenuView.qml @@ -12,33 +12,35 @@ import QtQuick 2.5 import QtQuick.Controls 1.4 import QtQuick.Controls.Styles 1.4 -import "../styles" +import "../styles-uit" FocusScope { id: root - implicitHeight: border.height - implicitWidth: border.width + implicitHeight: background.height + implicitWidth: background.width property alias currentItem: listView.currentItem property alias model: listView.model + property bool isSubMenu: false signal selected(var item) + HifiConstants { id: hifi } - Border { - id: border + Rectangle { + id: background anchors.fill: listView - anchors.margins: -8 - border.color: hifi.colors.hifiBlue - color: hifi.colors.window - // color: "#7f7f7f7f" + radius: hifi.dimensions.borderRadius + border.width: hifi.dimensions.borderWidth + border.color: hifi.colors.lightGrayText80 + color: isSubMenu ? hifi.colors.faintGray : hifi.colors.faintGray80 } ListView { id: listView x: 8; y: 8 - HifiConstants { id: hifi } width: 128 height: count * 32 + topMargin: hifi.dimensions.menuPadding onEnabledChanged: recalcSize(); onVisibleChanged: recalcSize(); onCountChanged: recalcSize(); @@ -84,6 +86,7 @@ FocusScope { newHeight += currentItem.implicitHeight } } + newHeight += 2 * hifi.dimensions.menuPadding; // White space at top and bottom. if (maxWidth > width) { width = maxWidth; } diff --git a/interface/resources/qml/styles-uit/HifiConstants.qml b/interface/resources/qml/styles-uit/HifiConstants.qml index eb4c84b5b8..4f06b676e6 100644 --- a/interface/resources/qml/styles-uit/HifiConstants.qml +++ b/interface/resources/qml/styles-uit/HifiConstants.qml @@ -70,6 +70,7 @@ Item { readonly property color baseGrayHighlight40: "#66575757" readonly property color baseGrayHighlight15: "#26575757" readonly property color lightGrayText80: "#ccafafaf" + readonly property color faintGray80: "#cce3e3e3" readonly property color faintGray50: "#80e3e3e3" // Other colors @@ -135,6 +136,7 @@ Item { readonly property real modalDialogTitleHeight: 40 readonly property real controlLineHeight: 29 // Height of spinbox control on 1920 x 1080 monitor readonly property real controlInterlineHeight: 22 // 75% of controlLineHeight + readonly property real menuPadding: 12 } Item { From fb0f97264c29f5f9af8b96cb92e9abab1865430d Mon Sep 17 00:00:00 2001 From: David Rowe Date: Fri, 11 Mar 2016 15:24:35 +1300 Subject: [PATCH 3/8] Style HMD menu items --- interface/resources/qml/menus/VrMenuItem.qml | 55 ++++++++++++------- interface/resources/qml/menus/VrMenuView.qml | 14 +++-- .../qml/styles-uit/HifiConstants.qml | 5 +- 3 files changed, 48 insertions(+), 26 deletions(-) diff --git a/interface/resources/qml/menus/VrMenuItem.qml b/interface/resources/qml/menus/VrMenuItem.qml index 955ab86167..f2c077a59e 100644 --- a/interface/resources/qml/menus/VrMenuItem.qml +++ b/interface/resources/qml/menus/VrMenuItem.qml @@ -12,8 +12,8 @@ import QtQuick 2.5 import QtQuick.Controls 1.4 import QtQuick.Controls.Styles 1.4 -import "../controls" -import "../styles" +import "../controls-uit" +import "../styles-uit" Item { id: root @@ -21,24 +21,28 @@ Item { property alias text: label.text property var source - implicitHeight: source.visible ? label.implicitHeight * 1.5 : 0 - implicitWidth: label.width + label.height * 2.5 + implicitHeight: source.visible ? 2 * label.implicitHeight : 0 + implicitWidth: 2 * hifi.dimensions.menuPadding.x + check.width + label.width + tail.width visible: source.visible width: parent.width FontAwesome { clip: true id: check - verticalAlignment: Text.AlignVCenter - horizontalAlignment: Text.AlignHCenter - anchors.verticalCenter: parent.verticalCenter + verticalAlignment: Text.AlignVCenter + anchors { + verticalCenter: parent.verticalCenter + left: parent.left + leftMargin: hifi.dimensions.menuPadding.x + } + width: 1.5 * hifi.dimensions.menuPadding.x color: label.color text: checkText() size: label.height visible: source.visible font.pixelSize: size function checkText() { - if (!source || source.type != 1 || !source.checkable) { + if (!source || source.type !== 1 || !source.checkable) { return "" } // FIXME this works for native QML menus but I don't think it will @@ -50,25 +54,36 @@ Item { } } - Text { + RalewaySemiBold { id: label + size: hifi.fontSizes.rootMenu + font.capitalization: Font.AllUppercase anchors.left: check.right - anchors.leftMargin: 4 anchors.verticalCenter: parent.verticalCenter verticalAlignment: Text.AlignVCenter - color: source.enabled ? hifi.colors.text : hifi.colors.disabledText + color: source.enabled ? hifi.colors.baseGrayShadow : hifi.colors.baseGrayShadow50 enabled: source.visible && (source.type !== 0 ? source.enabled : false) visible: source.visible } - FontAwesome { - id: tag - x: root.parent.width - width - size: label.height - width: implicitWidth - visible: source.visible && (source.type == 2) - text: "\uF0DA" - anchors.verticalCenter: parent.verticalCenter - color: label.color + Item { + // Space for shortcut key or disclosure icon. + id: tail + width: 4 * hifi.dimensions.menuPadding.x + anchors { + verticalCenter: parent.verticalCenter + right: parent.right + rightMargin: hifi.dimensions.menuPadding.x + } + + HiFiGlyphs { + text: hifi.glyphs.disclosureExpand + color: source.enabled ? hifi.colors.baseGrayShadow : hifi.colors.baseGrayShadow25 + size: 2 * hifi.fontSizes.rootMenuDisclosure + anchors.verticalCenter: parent.verticalCenter + anchors.right: parent.right + horizontalAlignment: Text.AlignRight + visible: source.visible && (source.type === 2) + } } } diff --git a/interface/resources/qml/menus/VrMenuView.qml b/interface/resources/qml/menus/VrMenuView.qml index 8778bc4bd1..d8cc0e6667 100644 --- a/interface/resources/qml/menus/VrMenuView.qml +++ b/interface/resources/qml/menus/VrMenuView.qml @@ -40,16 +40,20 @@ FocusScope { x: 8; y: 8 width: 128 height: count * 32 - topMargin: hifi.dimensions.menuPadding + topMargin: hifi.dimensions.menuPadding.y onEnabledChanged: recalcSize(); onVisibleChanged: recalcSize(); onCountChanged: recalcSize(); focus: true highlight: Rectangle { - width: listView.currentItem ? listView.currentItem.width : 0 - height: listView.currentItem ? listView.currentItem.height : 0 - color: "lightsteelblue"; radius: 3 + anchors { + left: parent ? parent.left : undefined + right: parent ? parent.right : undefined + leftMargin: hifi.dimensions.borderWidth + rightMargin: hifi.dimensions.borderWidth + } + color: hifi.colors.white } delegate: VrMenuItem { @@ -86,7 +90,7 @@ FocusScope { newHeight += currentItem.implicitHeight } } - newHeight += 2 * hifi.dimensions.menuPadding; // White space at top and bottom. + newHeight += 2 * hifi.dimensions.menuPadding.y; // White space at top and bottom. if (maxWidth > width) { width = maxWidth; } diff --git a/interface/resources/qml/styles-uit/HifiConstants.qml b/interface/resources/qml/styles-uit/HifiConstants.qml index 4f06b676e6..3b6eb2d9fc 100644 --- a/interface/resources/qml/styles-uit/HifiConstants.qml +++ b/interface/resources/qml/styles-uit/HifiConstants.qml @@ -67,6 +67,8 @@ Item { readonly property color darkGray30: "#4d121212" readonly property color darkGray0: "#00121212" readonly property color baseGrayShadow60: "#99252525" + readonly property color baseGrayShadow50: "#80252525" + readonly property color baseGrayShadow25: "#40252525" readonly property color baseGrayHighlight40: "#66575757" readonly property color baseGrayHighlight15: "#26575757" readonly property color lightGrayText80: "#ccafafaf" @@ -136,7 +138,7 @@ Item { readonly property real modalDialogTitleHeight: 40 readonly property real controlLineHeight: 29 // Height of spinbox control on 1920 x 1080 monitor readonly property real controlInterlineHeight: 22 // 75% of controlLineHeight - readonly property real menuPadding: 12 + readonly property vector2d menuPadding: Qt.vector2d(12, 12) } Item { @@ -154,6 +156,7 @@ Item { readonly property real logs: dimensions.largeScreen ? 16 : 12 readonly property real code: dimensions.largeScreen ? 16 : 12 readonly property real rootMenu: dimensions.largeScreen ? 15 : 11 + readonly property real rootMenuDisclosure: dimensions.largeScreen ? 20 : 16 readonly property real menuItem: dimensions.largeScreen ? 15 : 11 readonly property real shortcutText: dimensions.largeScreen ? 13 : 9 readonly property real carat: dimensions.largeScreen ? 38 : 30 From e175c1975464fe3a22fbf46b5509ca7ecc42f0d2 Mon Sep 17 00:00:00 2001 From: David Rowe Date: Fri, 11 Mar 2016 15:51:27 +1300 Subject: [PATCH 4/8] Style checkbox for menu items --- interface/resources/qml/menus/VrMenuItem.qml | 28 ++++++++----------- .../qml/styles-uit/HifiConstants.qml | 2 +- 2 files changed, 12 insertions(+), 18 deletions(-) diff --git a/interface/resources/qml/menus/VrMenuItem.qml b/interface/resources/qml/menus/VrMenuItem.qml index f2c077a59e..636728c890 100644 --- a/interface/resources/qml/menus/VrMenuItem.qml +++ b/interface/resources/qml/menus/VrMenuItem.qml @@ -26,31 +26,25 @@ Item { visible: source.visible width: parent.width - FontAwesome { - clip: true + CheckBox { id: check - verticalAlignment: Text.AlignVCenter + // FIXME: Shouild use radio buttons if source.exclusiveGroup. anchors { - verticalCenter: parent.verticalCenter left: parent.left leftMargin: hifi.dimensions.menuPadding.x + top: label.top + topMargin: 0 } - width: 1.5 * hifi.dimensions.menuPadding.x - color: label.color - text: checkText() - size: label.height - visible: source.visible - font.pixelSize: size - function checkText() { + width: 20 + visible: source.visible && source.type === 1 && source.checkable + checked: setChecked() + function setChecked() { if (!source || source.type !== 1 || !source.checkable) { - return "" + return false; } // FIXME this works for native QML menus but I don't think it will // for proxied QML menus - if (source.exclusiveGroup) { - return source.checked ? "\uF05D" : "\uF10C" - } - return source.checked ? "\uF046" : "\uF096" + return source.checked; } } @@ -69,7 +63,7 @@ Item { Item { // Space for shortcut key or disclosure icon. id: tail - width: 4 * hifi.dimensions.menuPadding.x + width: 48 anchors { verticalCenter: parent.verticalCenter right: parent.right diff --git a/interface/resources/qml/styles-uit/HifiConstants.qml b/interface/resources/qml/styles-uit/HifiConstants.qml index 3b6eb2d9fc..718c1e32cb 100644 --- a/interface/resources/qml/styles-uit/HifiConstants.qml +++ b/interface/resources/qml/styles-uit/HifiConstants.qml @@ -138,7 +138,7 @@ Item { readonly property real modalDialogTitleHeight: 40 readonly property real controlLineHeight: 29 // Height of spinbox control on 1920 x 1080 monitor readonly property real controlInterlineHeight: 22 // 75% of controlLineHeight - readonly property vector2d menuPadding: Qt.vector2d(12, 12) + readonly property vector2d menuPadding: Qt.vector2d(14, 12) } Item { From ecf67282d5b43ae43473e9b6736625867c5badfe Mon Sep 17 00:00:00 2001 From: David Rowe Date: Sat, 12 Mar 2016 12:29:52 +1300 Subject: [PATCH 5/8] Add separators to HMD menus --- interface/resources/qml/menus/VrMenuItem.qml | 22 ++++++++++++++++++- .../qml/styles-uit/HifiConstants.qml | 1 + libraries/ui/src/VrMenu.cpp | 14 ++++++++++++ libraries/ui/src/VrMenu.h | 1 + libraries/ui/src/ui/Menu.cpp | 6 ++++- 5 files changed, 42 insertions(+), 2 deletions(-) diff --git a/interface/resources/qml/menus/VrMenuItem.qml b/interface/resources/qml/menus/VrMenuItem.qml index 636728c890..5854a75ef5 100644 --- a/interface/resources/qml/menus/VrMenuItem.qml +++ b/interface/resources/qml/menus/VrMenuItem.qml @@ -28,7 +28,7 @@ Item { CheckBox { id: check - // FIXME: Shouild use radio buttons if source.exclusiveGroup. + // FIXME: Should use radio buttons if source.exclusiveGroup. anchors { left: parent.left leftMargin: hifi.dimensions.menuPadding.x @@ -60,6 +60,26 @@ Item { visible: source.visible } + Item { + id: separator + anchors { + fill: parent + leftMargin: hifi.dimensions.menuPadding.x + check.width + rightMargin: hifi.dimensions.menuPadding.x + tail.width + } + visible: source.type === MenuItemType.Separator + + Rectangle { + anchors { + left: parent.left + right: parent.right + verticalCenter: parent.verticalCenter + } + height: 1 + color: hifi.colors.lightGray50 + } + } + Item { // Space for shortcut key or disclosure icon. id: tail diff --git a/interface/resources/qml/styles-uit/HifiConstants.qml b/interface/resources/qml/styles-uit/HifiConstants.qml index 718c1e32cb..2a1053c2b6 100644 --- a/interface/resources/qml/styles-uit/HifiConstants.qml +++ b/interface/resources/qml/styles-uit/HifiConstants.qml @@ -71,6 +71,7 @@ Item { readonly property color baseGrayShadow25: "#40252525" readonly property color baseGrayHighlight40: "#66575757" readonly property color baseGrayHighlight15: "#26575757" + readonly property color lightGray50: "#806a6a6a" readonly property color lightGrayText80: "#ccafafaf" readonly property color faintGray80: "#cce3e3e3" readonly property color faintGray50: "#80e3e3e3" diff --git a/libraries/ui/src/VrMenu.cpp b/libraries/ui/src/VrMenu.cpp index 76acf5d18a..41768a5349 100644 --- a/libraries/ui/src/VrMenu.cpp +++ b/libraries/ui/src/VrMenu.cpp @@ -190,6 +190,20 @@ void VrMenu::addAction(QMenu* menu, QAction* action) { bindActionToQmlAction(result, action); } +void VrMenu::addSeparator(QMenu* menu) { + Q_ASSERT(MenuUserData::forObject(menu)); + MenuUserData* userData = MenuUserData::forObject(menu); + if (!userData) { + return; + } + QObject* menuQml = findMenuObject(userData->uuid.toString()); + Q_ASSERT(menuQml); + + bool invokeResult = QMetaObject::invokeMethod(menuQml, "addSeparator", Qt::DirectConnection); + Q_ASSERT(invokeResult); + Q_UNUSED(invokeResult); // FIXME - apparently we haven't upgraded the Qt on our unix Jenkins environments to 5.5.x +} + void VrMenu::insertAction(QAction* before, QAction* action) { QObject* beforeQml{ nullptr }; { diff --git a/libraries/ui/src/VrMenu.h b/libraries/ui/src/VrMenu.h index b092b63566..d03887821f 100644 --- a/libraries/ui/src/VrMenu.h +++ b/libraries/ui/src/VrMenu.h @@ -28,6 +28,7 @@ public: VrMenu(QObject* parent = nullptr); void addMenu(QMenu* menu); void addAction(QMenu* parent, QAction* action); + void addSeparator(QMenu* parent); void insertAction(QAction* before, QAction* action); void removeAction(QAction* action); diff --git a/libraries/ui/src/ui/Menu.cpp b/libraries/ui/src/ui/Menu.cpp index 1b70213876..a5d801869d 100644 --- a/libraries/ui/src/ui/Menu.cpp +++ b/libraries/ui/src/ui/Menu.cpp @@ -511,7 +511,11 @@ void MenuWrapper::setEnabled(bool enabled) { } QAction* MenuWrapper::addSeparator() { - return _realMenu->addSeparator(); + QAction* action = _realMenu->addSeparator(); + VrMenu::executeOrQueue([=](VrMenu* vrMenu) { + vrMenu->addSeparator(_realMenu); + }); + return action; } void MenuWrapper::addAction(QAction* action) { From 9da64e540dd7485b8fdcdd64e2f5a27e040030e2 Mon Sep 17 00:00:00 2001 From: David Rowe Date: Sat, 12 Mar 2016 12:53:16 +1300 Subject: [PATCH 6/8] Add shortcut keys to HMD menu --- interface/resources/qml/menus/VrMenuItem.qml | 14 ++++++++++++-- libraries/ui/src/VrMenu.cpp | 1 + 2 files changed, 13 insertions(+), 2 deletions(-) diff --git a/interface/resources/qml/menus/VrMenuItem.qml b/interface/resources/qml/menus/VrMenuItem.qml index 5854a75ef5..0b18811ccf 100644 --- a/interface/resources/qml/menus/VrMenuItem.qml +++ b/interface/resources/qml/menus/VrMenuItem.qml @@ -81,15 +81,25 @@ Item { } Item { - // Space for shortcut key or disclosure icon. id: tail - width: 48 + width: 48 + (shortcut.visible ? shortcut.width : 0) anchors { verticalCenter: parent.verticalCenter right: parent.right rightMargin: hifi.dimensions.menuPadding.x } + RalewayLight { + id: shortcut + text: source.shortcut ? source.shortcut : "" + size: hifi.fontSizes.shortcutText + color: hifi.colors.baseGrayShadow + anchors.verticalCenter: parent.verticalCenter + anchors.right: parent.right + anchors.rightMargin: 15 + visible: source.visible && text != "" + } + HiFiGlyphs { text: hifi.glyphs.disclosureExpand color: source.enabled ? hifi.colors.baseGrayShadow : hifi.colors.baseGrayShadow25 diff --git a/libraries/ui/src/VrMenu.cpp b/libraries/ui/src/VrMenu.cpp index 41768a5349..5acf81c319 100644 --- a/libraries/ui/src/VrMenu.cpp +++ b/libraries/ui/src/VrMenu.cpp @@ -104,6 +104,7 @@ void updateQmlItemFromAction(QObject* target, QAction* source) { target->setProperty("checkable", source->isCheckable()); target->setProperty("enabled", source->isEnabled()); target->setProperty("text", source->text()); + target->setProperty("shortcut", source->shortcut().toString()); target->setProperty("checked", source->isChecked()); target->setProperty("visible", source->isVisible()); } From 3bf1afb80ba22e2f36f72f18568e3c0d46182100 Mon Sep 17 00:00:00 2001 From: David Rowe Date: Sat, 12 Mar 2016 12:56:38 +1300 Subject: [PATCH 7/8] HMD submenus not allcaps --- interface/resources/qml/menus/VrMenuItem.qml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/interface/resources/qml/menus/VrMenuItem.qml b/interface/resources/qml/menus/VrMenuItem.qml index 0b18811ccf..38d2b57c03 100644 --- a/interface/resources/qml/menus/VrMenuItem.qml +++ b/interface/resources/qml/menus/VrMenuItem.qml @@ -51,7 +51,7 @@ Item { RalewaySemiBold { id: label size: hifi.fontSizes.rootMenu - font.capitalization: Font.AllUppercase + font.capitalization: isSubMenu ? Font.MixedCase : Font.AllUppercase anchors.left: check.right anchors.verticalCenter: parent.verticalCenter verticalAlignment: Text.AlignVCenter From 3deb30d699488f1ed7860f3d435d9bfdc7131b0a Mon Sep 17 00:00:00 2001 From: David Rowe Date: Sat, 12 Mar 2016 13:06:29 +1300 Subject: [PATCH 8/8] Remove no longer need font type --- .../resources/qml/styles-uit/FontAwesome.qml | 26 ------------------- 1 file changed, 26 deletions(-) delete mode 100644 interface/resources/qml/styles-uit/FontAwesome.qml diff --git a/interface/resources/qml/styles-uit/FontAwesome.qml b/interface/resources/qml/styles-uit/FontAwesome.qml deleted file mode 100644 index 5c03ef09b2..0000000000 --- a/interface/resources/qml/styles-uit/FontAwesome.qml +++ /dev/null @@ -1,26 +0,0 @@ -// -// FontAwesome.qml -// -// Created by Bradley Austin Davis on 24 Apr 2015 -// Copyright 2015 High Fidelity, Inc. -// -// Distributed under the Apache License, Version 2.0. -// See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html -// - -import QtQuick 2.5 -import QtQuick.Controls 1.4 -import QtQuick.Controls.Styles 1.4 - -Text { - id: root - FontLoader { id: iconFont; source: "../../fonts/fontawesome-webfont.ttf"; } - property int size: 32 - width: size - height: size - font.pixelSize: size - verticalAlignment: Text.AlignVCenter - horizontalAlignment: Text.AlignLeft - font.family: iconFont.name -} -