From 77bdd46330aeab37d53d60c4d2eb5c148adaf922 Mon Sep 17 00:00:00 2001 From: dogmaphobic Date: Mon, 12 Oct 2015 14:54:46 -0400 Subject: [PATCH] Plan View Tweaks Replacing some icons, cleaning up help text, etc. --- qgroundcontrol.qrc | 9 +- resources/Sync.png | Bin 4035 -> 0 bytes ...{MapHomeTearDrop.svg => MapAddMission.svg} | 5 +- src/FlightMap/Images/MapHome.svg | 11 ++ src/FlightMap/Images/MapSync.svg | 29 ++++ src/FlightMap/qmldir | 2 +- src/MissionEditor/MissionEditor.qml | 159 ++++++------------ 7 files changed, 97 insertions(+), 118 deletions(-) delete mode 100644 resources/Sync.png rename src/FlightMap/Images/{MapHomeTearDrop.svg => MapAddMission.svg} (54%) create mode 100644 src/FlightMap/Images/MapHome.svg create mode 100644 src/FlightMap/Images/MapSync.svg diff --git a/qgroundcontrol.qrc b/qgroundcontrol.qrc index b5e879ef69..f6d196c447 100644 --- a/qgroundcontrol.qrc +++ b/qgroundcontrol.qrc @@ -63,13 +63,16 @@ src/FlightMap/Images/scale_end.png src/FlightMap/Images/airplaneOutline.svg src/FlightMap/Images/airplaneOpaque.svg - src/FlightMap/Images/MapType.svg - src/FlightMap/Images/MapCenter.svg src/FlightMap/Images/ZoomPlus.svg src/FlightMap/Images/ZoomMinus.svg - resources/Sync.png + src/FlightMap/Images/MapCenter.svg + src/FlightMap/Images/MapSync.svg + src/FlightMap/Images/MapType.svg + src/FlightMap/Images/MapHome.svg + src/FlightMap/Images/MapAddMission.svg + src/test.qml diff --git a/resources/Sync.png b/resources/Sync.png deleted file mode 100644 index ea9bcccf7df54515ad6c399c2a26fb5ac7f1ac06..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 4035 zcmeAS@N?(olHy`uVBq!ia0y~yU`hdD4mJh`hW&!Jdl(oP*pj^6T^Rm@;DWu&Co?cG za29w(7Bet#3xhBt!>ld;6ATMgZ_RiU`|X~>35JWR*JeEV`>jvm1j9qsOEaF-eveZ)!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s7EP6Br}DflZfi?n!iGl}xx8{iVau*sG&Hl{4ZChapF?Gh32RkK(a2 znoT?#o(Lw-xSUtFiN#y4Wrn5d8D7bVPYNL0l6VZ;BHun!_ulZpv14ZFp*s^AS^1OB ztPy(F#-mdqkOXQl9g*lT{OmPD+GxWa$BvodERqR3m5-cRy&P1*ChSx`c0{6Ory{dq zo50~SN+%e)WfjxX1XCK0_Tl8SE&Y8*c|(I>>J8=@;VhD3hSO}H-LFwPv0=i-ABNv& zc(O=}8S^oo*=6Z6A<^@3z=59RcLFI9*DO>Fu0P{(Y&+WP%)Gg0XOhi-eo2movx-WG z8VZh7vxr&!Xv>c?wB|6-DQ6A!2`N#+2RG8{$>4xm_e=n2gH%E92!G4W{| z4_0NM^vK}QbMa(-HDiN7vw?XEIQkhBjtQhNC>&Ebaeo4%!Vys829g9j3|T-4gyWNW z3Iim*zzKsPsRtBM4jqm&q>UILVM{cpQK9+Hq5Io%KbtsoIR5$jo#UNj#GB|}^W;HE zg=3TFw0+MxoOoCyn{p-{eP7um!0gzjFgxLA^)iJc4igmR)GQfnqCx%;;GHbPFwc;~ zP#}e)&6AJuykv_6hf&KR752vGydVRZ5+@x#P|U8#*2I%&aI*2i&*XOuj&8LgXG%0W zjL*m@oM4&ReDFCVNU73+hYDv5(i;?nQ}{UN^McH@_#rE1r+h{fq|EtnIx9#SUln`% zd7jNI97cg+&WnC#;xLlA z$0uIcCdug7=6qZ6@#bSS3{5@94&O>tK4&1TaH7D&x}xUW3}%N37t0N-8}@KN;uc7; z=#lm4FnMpSaN>n^gRIXz!HcX4Cpctx@oB&B{lFxU!onBDE*{=x_Fj8v_b$P%|NfD^ Wbf57S6@lvKAik%opUXO@geCyaT1b!p diff --git a/src/FlightMap/Images/MapHomeTearDrop.svg b/src/FlightMap/Images/MapAddMission.svg similarity index 54% rename from src/FlightMap/Images/MapHomeTearDrop.svg rename to src/FlightMap/Images/MapAddMission.svg index ee5587c25f..a74d313b8f 100644 --- a/src/FlightMap/Images/MapHomeTearDrop.svg +++ b/src/FlightMap/Images/MapAddMission.svg @@ -2,8 +2,9 @@ - + - + + diff --git a/src/FlightMap/Images/MapHome.svg b/src/FlightMap/Images/MapHome.svg new file mode 100644 index 0000000000..3344ab9c4d --- /dev/null +++ b/src/FlightMap/Images/MapHome.svg @@ -0,0 +1,11 @@ + + + + + + + + + diff --git a/src/FlightMap/Images/MapSync.svg b/src/FlightMap/Images/MapSync.svg new file mode 100644 index 0000000000..ddf5dc4c02 --- /dev/null +++ b/src/FlightMap/Images/MapSync.svg @@ -0,0 +1,29 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/src/FlightMap/qmldir b/src/FlightMap/qmldir index 692c7d79e8..18f0c2102c 100644 --- a/src/FlightMap/qmldir +++ b/src/FlightMap/qmldir @@ -19,4 +19,4 @@ QGCSpeedWidget 1.0 QGCSpeedWidget.qml # MapQuickItems VehicleMapItem 1.0 VehicleMapItem.qml -MissionItemIndicator 1.0 MissionItemIndicator.qml +MissionItemIndicator 1.0 MissionItemIndicator.qml diff --git a/src/MissionEditor/MissionEditor.qml b/src/MissionEditor/MissionEditor.qml index 28b0e3a984..b8ab367435 100644 --- a/src/MissionEditor/MissionEditor.qml +++ b/src/MissionEditor/MissionEditor.qml @@ -130,88 +130,44 @@ QGCView { } } - Rectangle { + Image { id: addMissionItemsButton anchors.rightMargin: ScreenTools.defaultFontPixelHeight anchors.right: homePositionManagerButton.left anchors.top: homePositionManagerButton.top - radius: (ScreenTools.defaultFontPixelHeight * 3) / 2 - width: radius * 2 - height: radius * 2 - border.width: 2 - border.color: "white" - color: _addMissionItems ? _qgcPal.buttonHighlight : "black" - opacity: _addMissionItems ? 0.75 : 1.0 - + width: ScreenTools.defaultFontPixelHeight * 3 + fillMode: Image.PreserveAspectFit + mipmap: true + smooth: true + source: "/qmlimages/MapAddMission.svg" + opacity: _addMissionItems ? 1.0 : 0.75 MouseArea { anchors.fill: parent - onClicked: { _addMissionItems = !_addMissionItems _showHomePositionManager = false } } - - Rectangle { - anchors.verticalCenter: parent.verticalCenter - anchors.horizontalCenter: parent.horizontalCenter - width: ScreenTools.defaultFontPixelHeight * 1.5 - height: width - radius: width / 2 - border.width: 2 - border.color: "white" - color: "transparent" - - QGCLabel { - anchors.fill: parent - horizontalAlignment: Text.AlignHCenter - verticalAlignment: Text.AlignVCenter - color: "white" - text: "1" - } - } } - Rectangle { + Image { id: homePositionManagerButton anchors.rightMargin: ScreenTools.defaultFontPixelHeight anchors.right: centerMapButton.left anchors.top: centerMapButton.top - radius: (ScreenTools.defaultFontPixelHeight * 3) / 2 - width: radius * 2 - height: radius * 2 - border.width: 2 - border.color: "white" - color: _showHomePositionManager ? _qgcPal.buttonHighlight : "black" - opacity: _showHomePositionManager ? 0.75 : 1.0 - + width: ScreenTools.defaultFontPixelHeight * 3 + fillMode: Image.PreserveAspectFit + mipmap: true + smooth: true + source: "/qmlimages/MapHome.svg" + opacity: _showHomePositionManager ? 1.0 : 0.75 MouseArea { anchors.fill: parent - onClicked: { _showHomePositionManager = !_showHomePositionManager _addMissionItems = false } } - - Rectangle { - anchors.verticalCenter: parent.verticalCenter - anchors.horizontalCenter: parent.horizontalCenter - width: ScreenTools.defaultFontPixelHeight * 1.5 - height: width - radius: width / 2 - border.width: 2 - border.color: "white" - color: "transparent" - - QGCLabel { - anchors.fill: parent - horizontalAlignment: Text.AlignHCenter - verticalAlignment: Text.AlignVCenter - color: "white" - text: "H" - } - } } DropButton { @@ -296,7 +252,7 @@ This code will need to wait for Qml 5.5 support since Map.visibleRegion is only anchors.right: mapTypeButton.left anchors.top: mapTypeButton.top dropDirection: dropDown - buttonImage: "/qmlimages/Sync.png" + buttonImage: "/qmlimages/MapSync.svg" viewportMargins: ScreenTools.defaultFontPixelWidth / 2 exclusiveGroup: _dropButtonsExclusiveGroup @@ -571,9 +527,9 @@ This code will need to wait for Qml 5.5 support since Map.visibleRegion is only QGCLabel { width: parent.width wrapMode: Text.WordWrap - text: "To add a new home position, click in the Map to set the position. " + + text: "To add a new home position, click on the Map to set the position. " + "Then give it a new name and click Add/Update. " + - "To change the current home position, click in the Map to set the new position. " + + "To change the current home position, click on the Map to set the new position. " + "Then click Add/Update without changing the name." } @@ -716,28 +672,18 @@ This code will need to wait for Qml 5.5 support since Map.visibleRegion is only anchors.top: helpTitle.bottom width: parent.width wrapMode: Text.WordWrap - text: "In the upper right corner of the map you will see the Mission Planner tools:" + text: "Mission Planner tool buttons:" } - Rectangle { - id: addMissionItemsHelpIcon - anchors.topMargin: ScreenTools.defaultFontPixelHeight - anchors.top: helpIconLabel.bottom - anchors.horizontalCenter: mapTypeHelpIcon.horizontalCenter - width: ScreenTools.defaultFontPixelHeight * 1.5 - height: width - radius: width / 2 - border.width: 2 - border.color: "white" - color: _qgcPal.window - - QGCLabel { - anchors.fill: parent - horizontalAlignment: Text.AlignHCenter - verticalAlignment: Text.AlignVCenter - color: "white" - text: "1" - } + Image { + id: addMissionItemsHelpIcon + anchors.topMargin: ScreenTools.defaultFontPixelHeight + anchors.top: helpIconLabel.bottom + width: ScreenTools.defaultFontPixelHeight * 3 + fillMode: Image.PreserveAspectFit + mipmap: true + smooth: true + source: "/qmlimages/MapAddMission.svg" } QGCLabel { @@ -747,30 +693,19 @@ This code will need to wait for Qml 5.5 support since Map.visibleRegion is only anchors.right: parent.right anchors.top: addMissionItemsHelpIcon.top wrapMode: Text.WordWrap - text: "This is the Add Mission Items tool. " + - "Click it to turn on the ability to add mission items by clicking in the map. " + - "Click it again to turn it off." + text: "Add Mission Items
" + + "When enabled, add mission items by clicking on the map." } - Rectangle { - id: homePositionManagerHelpIcon - anchors.topMargin: ScreenTools.defaultFontPixelHeight - anchors.top: addMissionItemsHelpText.bottom - anchors.horizontalCenter: mapTypeHelpIcon.horizontalCenter - width: ScreenTools.defaultFontPixelHeight * 1.5 - height: width - radius: width / 2 - border.width: 2 - border.color: "white" - color: _qgcPal.window - - QGCLabel { - anchors.fill: parent - horizontalAlignment: Text.AlignHCenter - verticalAlignment: Text.AlignVCenter - color: "white" - text: "H" - } + Image { + id: homePositionManagerHelpIcon + anchors.topMargin: ScreenTools.defaultFontPixelHeight + anchors.top: addMissionItemsHelpText.bottom + width: ScreenTools.defaultFontPixelHeight * 3 + fillMode: Image.PreserveAspectFit + mipmap: true + smooth: true + source: "/qmlimages/MapHome.svg" } QGCLabel { @@ -780,8 +715,8 @@ This code will need to wait for Qml 5.5 support since Map.visibleRegion is only anchors.right: parent.right anchors.top: homePositionManagerHelpIcon.top wrapMode: Text.WordWrap - text: "This is the Home Position Manager tool. " + - "This tool allows you to select/add/update home positions. " + + text: "Home Position Manager
" + + "When enabled, allows you to select/add/update home positions. " + "You can save multiple home position to represent multiple flying areas." } @@ -803,8 +738,8 @@ This code will need to wait for Qml 5.5 support since Map.visibleRegion is only anchors.right: parent.right anchors.top: mapCenterHelpIcon.top wrapMode: Text.WordWrap - text: "This is the Map Center tool. " + - "It will show a set of options which will center the map." + text: "Map Center
" + + "Options for centering the map." } Image { @@ -815,7 +750,7 @@ This code will need to wait for Qml 5.5 support since Map.visibleRegion is only fillMode: Image.PreserveAspectFit mipmap: true smooth: true - source: "/qmlimages/Sync.png" + source: "/qmlimages/MapSync.svg" } QGCLabel { @@ -825,8 +760,8 @@ This code will need to wait for Qml 5.5 support since Map.visibleRegion is only anchors.right: parent.right anchors.top: syncHelpIcon.top wrapMode: Text.WordWrap - text: "This is the Sync tool. " + - "It will show a set of options for saving/loading mission items." + text: "Sync
" + + "Options for saving/loading mission items." } Image { @@ -847,8 +782,8 @@ This code will need to wait for Qml 5.5 support since Map.visibleRegion is only anchors.right: parent.right anchors.top: mapTypeHelpIcon.top wrapMode: Text.WordWrap - text: "This is the Map Type tool. " + - "It will show a set of options for selecting map types." + text: "Map Type
" + + "Map type options." } } // Item - Help Panel } // Item -- GitLab