From 5f324ed2013e66562c35100eb05f77083529cf2b Mon Sep 17 00:00:00 2001 From: Mitch Curtis Date: Fri, 12 Aug 2016 14:22:07 +0200 Subject: texteditor: use "brush" icon for text color and "A" for font "F" looks a bit silly. Even though most word processing applications seem to use the "A" icon with a bar underneath it for the text color, we want to use it to represent the button that opens the font dialog, since we don't use comboboxes for that. Change-Id: I3cc60ffbe388644cdcbd9e8ec0dcffbc041aa124 Reviewed-by: J-P Nurmi --- .../quickcontrols2/texteditor/fonts/fontello.ttf | Bin 9188 -> 9496 bytes .../quickcontrols2/texteditor/qml/texteditor.qml | 30 ++++++++++----------- 2 files changed, 15 insertions(+), 15 deletions(-) (limited to 'examples') diff --git a/examples/quickcontrols2/texteditor/fonts/fontello.ttf b/examples/quickcontrols2/texteditor/fonts/fontello.ttf index 9871d4c5..d2914494 100644 Binary files a/examples/quickcontrols2/texteditor/fonts/fontello.ttf and b/examples/quickcontrols2/texteditor/fonts/fontello.ttf differ diff --git a/examples/quickcontrols2/texteditor/qml/texteditor.qml b/examples/quickcontrols2/texteditor/qml/texteditor.qml index ab56ae2b..72b5da1a 100644 --- a/examples/quickcontrols2/texteditor/qml/texteditor.qml +++ b/examples/quickcontrols2/texteditor/qml/texteditor.qml @@ -270,9 +270,22 @@ ApplicationWindow { checked: document.underline onClicked: document.underline = !document.underline } + ToolButton { + id: fontFamilyToolButton + text: qsTr("\uE808") + font.family: "fontello" + font.bold: document.bold + font.italic: document.italic + font.underline: document.underline + onClicked: { + fontDialog.currentFont.family = document.fontFamily; + fontDialog.currentFont.pointSize = document.fontSize; + fontDialog.open(); + } + } ToolButton { id: textColorButton - text: "\uE808" + text: "\uF1FC" font.family: "fontello" focusPolicy: Qt.TabFocus onClicked: colorDialog.open() @@ -284,7 +297,7 @@ ApplicationWindow { parent: textColorButton.contentItem anchors.horizontalCenter: parent.horizontalCenter anchors.baseline: parent.baseline - anchors.baselineOffset: 4 + anchors.baselineOffset: 6 TextMetrics { id: aFontMetrics @@ -293,19 +306,6 @@ ApplicationWindow { } } } - ToolButton { - id: fontFamilyToolButton - text: qsTr("F") - font.family: document.fontFamily - font.bold: document.bold - font.italic: document.italic - font.underline: document.underline - onClicked: { - fontDialog.currentFont.family = document.fontFamily; - fontDialog.currentFont.pointSize = document.fontSize; - fontDialog.open(); - } - } ToolSeparator { contentItem.visible: formatRow.y === alignRow.y } -- cgit v1.2.3