Skip to content

Commit

Permalink
Plugin updates.
Browse files Browse the repository at this point in the history
Signed-off-by: Carlos Agüero <caguero@openrobotics.org>
  • Loading branch information
caguero committed Jul 19, 2024
1 parent 8db1277 commit 1f28e07
Show file tree
Hide file tree
Showing 17 changed files with 217 additions and 198 deletions.
4 changes: 3 additions & 1 deletion include/gz/gui/qml/GzColor.qml
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,9 @@ Item {
id: gzColorDialog
title: "Choose a color"
visible: false
showAlphaChannel: true
options: {
ShowAlphaChannel: true
}
onAccepted: {
r = gzColorDialog.color.r
g = gzColorDialog.color.g
Expand Down
1 change: 0 additions & 1 deletion include/gz/gui/qml/PlottingInterface.qml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@
import QtQuick
import QtCharts
import QtQuick.Controls
import QtQuick.Controls.Styles
import QtQuick.Controls.Material
import QtQuick.Layouts
import Qt.labs.platform
Expand Down
24 changes: 12 additions & 12 deletions src/plugins/GridConfig/GridConfig.qml
Original file line number Diff line number Diff line change
Expand Up @@ -112,10 +112,10 @@ GridLayout {
Layout.columnSpan: 2
Layout.fillWidth: true
id: verticalCellCount
maximumValue: Number.MAX_VALUE
minimumValue: 0
to: Number.MAX_VALUE
from: 0
value: 0
onEditingFinished: GridConfig.UpdateVCellCount(verticalCellCount.value)
onValueChanged: GridConfig.UpdateVCellCount(verticalCellCount.value)
}

Text {
Expand All @@ -129,10 +129,10 @@ GridLayout {
Layout.columnSpan: 2
Layout.fillWidth: true
id: horizontalCellCount
maximumValue: Number.MAX_VALUE
minimumValue: 1
to: Number.MAX_VALUE
from: 1
value: 20
onEditingFinished: GridConfig.UpdateHCellCount(horizontalCellCount.value)
onValueChanged: GridConfig.UpdateHCellCount(horizontalCellCount.value)
}

Text {
Expand All @@ -153,12 +153,12 @@ GridLayout {
Layout.columnSpan: 2
Layout.fillWidth: true
id: cellLength
maximumValue: Number.MAX_VALUE
minimumValue: 0.0000001
value: 1.00
decimals: gzHelpers.getDecimals(cellLength.width)
stepSize: 0.01
onEditingFinished: GridConfig.UpdateCellLength(cellLength.value)
to: Number.MAX_VALUE
from: 0
value: 1
//decimals: gzHelpers.getDecimals(cellLength.width)
stepSize: 1
onValueChanged: GridConfig.UpdateCellLength(cellLength.value)
}

Text {
Expand Down
2 changes: 1 addition & 1 deletion src/plugins/MinimalScene/MinimalScene.qml
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ Rectangle {
anchors.fill: parent
hoverEnabled: true
acceptedButtons: Qt.NoButton
visible: MinimalScene.loadingError.length == 0
visible: MinimalScene.loadingError.length === 0
onEntered: {
MinimalScene.OnFocusWindow()
}
Expand Down
2 changes: 2 additions & 0 deletions src/plugins/NavsatMap/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,8 @@ gz_gui_add_plugin(NavSatMap
NavSatMap.cc
QT_HEADERS
NavSatMap.hh
QML_SOURCES
NavSatMap.qml
QML_URI
NavSatMap
)
2 changes: 2 additions & 0 deletions src/plugins/Plotting/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,8 @@ gz_gui_add_plugin(TransportPlotting
TransportPlotting.cc
QT_HEADERS
TransportPlotting.hh
QML_SOURCES
TransportPlotting.qml
QML_URI
TransportPlotting
)
2 changes: 2 additions & 0 deletions src/plugins/PointCloud/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,8 @@ gz_gui_add_plugin(PointCloud
PointCloud.cc
QT_HEADERS
PointCloud.hh
QML_SOURCES
PointCloud.qml
PUBLIC_LINK_LIBS
gz-rendering${GZ_RENDERING_VER}::gz-rendering${GZ_RENDERING_VER}
TEST_SOURCES
Expand Down
7 changes: 3 additions & 4 deletions src/plugins/PointCloud/PointCloud.qml
Original file line number Diff line number Diff line change
Expand Up @@ -121,10 +121,9 @@ ColumnLayout {
GzSpinBox {
id: pointSizeSpin
value: PointCloud.pointSize
minimumValue: 1
maximumValue: 1000
decimals: 0
onEditingFinished: {
from: 1
to: 1000
onValueChanged: {
PointCloud.SetPointSize(pointSizeSpin.value)
}
}
Expand Down
2 changes: 2 additions & 0 deletions src/plugins/ShutdownButton/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,8 @@ gz_gui_add_plugin(ShutdownButton
ShutdownButton.cc
QT_HEADERS
ShutdownButton.hh
QML_SOURCES
ShutdownButton.qml
TEST_SOURCES
ShutdownButton_TEST.cc
QML_URI
Expand Down
8 changes: 6 additions & 2 deletions src/plugins/TapeMeasure/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,6 +1,10 @@
gz_gui_add_plugin(TapeMeasure
SOURCES TapeMeasure.cc
QT_HEADERS TapeMeasure.hh
SOURCES
TapeMeasure.cc
QT_HEADERS
TapeMeasure.hh
QML_SOURCES
TapeMeasure.qml
PRIVATE_LINK_LIBS
gz-rendering${GZ_RENDERING_VER}::gz-rendering${GZ_RENDERING_VER}
QML_URI
Expand Down
3 changes: 1 addition & 2 deletions src/plugins/TapeMeasure/TapeMeasure.qml
Original file line number Diff line number Diff line change
Expand Up @@ -20,15 +20,14 @@ import QtQuick.Controls
import QtQuick.Controls.Material
import QtQuick.Controls.Material.impl
import QtQuick.Layouts
import QtQuick.Controls.Styles
import "qrc:/gz/gui/qml"

ToolBar {
id: tapeMeasure
Layout.minimumWidth: 250
Layout.minimumHeight: 100

property var distance: 0.0
property real distance: 0.0

function updateDistance() {
distance = TapeMeasure.Distance();
Expand Down
2 changes: 2 additions & 0 deletions src/plugins/Teleop/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,8 @@ gz_gui_add_plugin(Teleop
Teleop.cc
QT_HEADERS
Teleop.hh
QML_SOURCES
Teleop.qml
TEST_SOURCES
Teleop_TEST.cc
QML_URI
Expand Down
32 changes: 16 additions & 16 deletions src/plugins/Teleop/Teleop.qml
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,9 @@
import QtQuick
import QtQuick.Controls
import QtQuick.Controls.Material
import QtQuick.Controls.Styles
import QtQuick.Layouts
import gz.gui
import "qrc:/gz/gui/qml"

ColumnLayout {
Layout.minimumWidth: 400
Expand Down Expand Up @@ -123,11 +123,11 @@ ColumnLayout {
id: maxForwardVelField
Layout.fillWidth: true
value: maxForwardVel
maximumValue: 10000.0
minimumValue: 0.0
decimals: 2
stepSize: 0.10
onEditingFinished:{
to: 10000
from: 0
// decimals: 2
stepSize: 1
onValueChanged:{
Teleop.SetMaxForwardVel(value)
}
}
Expand All @@ -142,11 +142,11 @@ ColumnLayout {
id: maxVerticalVelField
Layout.fillWidth: true
value: maxVerticalVel
maximumValue: 10000.0
minimumValue: 0.0
decimals: 2
stepSize: 0.10
onEditingFinished:{
to: 10000
from: 0
// decimals: 2
stepSize: 1
onValueChanged:{
Teleop.SetMaxVerticalVel(value)
}
}
Expand All @@ -161,11 +161,11 @@ ColumnLayout {
id: maxYawVelField
Layout.fillWidth: true
value: maxYawVel
maximumValue: 10000.0
minimumValue: 0.0
decimals: 2
stepSize: 0.10
onEditingFinished:{
to: 10000
from: 0
// decimals: 2
stepSize: 1
onValueChanged:{
Teleop.SetMaxYawVel(value)
}
}
Expand Down
2 changes: 2 additions & 0 deletions src/plugins/TopicEcho/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,8 @@ gz_gui_add_plugin(TopicEcho
TopicEcho.cc
QT_HEADERS
TopicEcho.hh
QML_SOURCES
TopicEcho.qml
TEST_SOURCES
TopicEcho_TEST.cc
QML_URI
Expand Down
2 changes: 2 additions & 0 deletions src/plugins/TopicViewer/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,8 @@ gz_gui_add_plugin(TopicViewer
TopicViewer.cc
QT_HEADERS
TopicViewer.hh
QML_SOURCES
TopicViewer.qml
TEST_SOURCES
TopicViewer_TEST.cc
PUBLIC_LINK_LIBS
Expand Down
Loading

0 comments on commit 1f28e07

Please sign in to comment.