diff --git a/src/PlanView/CameraSection.qml b/src/PlanView/CameraSection.qml index 0a01e62e09489081785e110d83f2f4ca54c582c2..fc588b18a0830297018c662ae854a12ef722ded0 100644 --- a/src/PlanView/CameraSection.qml +++ b/src/PlanView/CameraSection.qml @@ -24,6 +24,8 @@ Column { SectionHeader { id: cameraSectionHeader + anchors.left: parent.left + anchors.right: parent.right text: qsTr("Camera") checked: false } diff --git a/src/PlanView/CorridorScanEditor.qml b/src/PlanView/CorridorScanEditor.qml index 86058e936df4b4d78d7eee3403c6a6184598fba1..3ccfe084bc2d9d708ecd20d1a51b0ddb1c593a83 100644 --- a/src/PlanView/CorridorScanEditor.qml +++ b/src/PlanView/CorridorScanEditor.qml @@ -124,8 +124,10 @@ Rectangle { } SectionHeader { - id: corridorHeader - text: qsTr("Corridor") + id: corridorHeader + anchors.left: parent.left + anchors.right: parent.right + text: qsTr("Corridor") } GridLayout { @@ -182,9 +184,11 @@ Rectangle { } SectionHeader { - id: terrainHeader - text: qsTr("Terrain") - checked: missionItem.followTerrain + id: terrainHeader + anchors.left: parent.left + anchors.right: parent.right + text: qsTr("Terrain") + checked: missionItem.followTerrain } ColumnLayout { @@ -228,8 +232,10 @@ Rectangle { } SectionHeader { - id: statsHeader - text: qsTr("Statistics") + id: statsHeader + anchors.left: parent.left + anchors.right: parent.right + text: qsTr("Statistics") } TransectStyleComplexItemStats { } diff --git a/src/PlanView/FWLandingPatternEditor.qml b/src/PlanView/FWLandingPatternEditor.qml index 44a1493d7a6d41fb9e40e6f1a358727cfa8c0dc4..f69c81e080dcba75c8b6a7d55f6e13f9544f114d 100644 --- a/src/PlanView/FWLandingPatternEditor.qml +++ b/src/PlanView/FWLandingPatternEditor.qml @@ -52,8 +52,10 @@ Rectangle { visible: !editorColumnNeedLandingPoint.visible SectionHeader { - id: loiterPointSection - text: qsTr("Loiter point") + id: loiterPointSection + anchors.left: parent.left + anchors.right: parent.right + text: qsTr("Loiter point") } Column { @@ -101,8 +103,10 @@ Rectangle { } SectionHeader { - id: landingPointSection - text: qsTr("Landing point") + id: landingPointSection + anchors.left: parent.left + anchors.right: parent.right + text: qsTr("Landing point") } Column { @@ -181,9 +185,11 @@ Rectangle { } SectionHeader { - id: cameraSection - text: qsTr("Camera") - visible: _showCameraSection + id: cameraSection + anchors.left: parent.left + anchors.right: parent.right + text: qsTr("Camera") + visible: _showCameraSection } Column { diff --git a/src/PlanView/GeoFenceEditor.qml b/src/PlanView/GeoFenceEditor.qml index 40bfa0e62d1f1b0b9fa996e5ebcc6867579f47fe..667b6d37d84d99a21bdf9698550d9d96e7c8c751 100644 --- a/src/PlanView/GeoFenceEditor.qml +++ b/src/PlanView/GeoFenceEditor.qml @@ -110,8 +110,10 @@ QGCFlickable { } SectionHeader { - id: insertSection - text: qsTr("Insert GeoFence") + id: insertSection + anchors.left: parent.left + anchors.right: parent.right + text: qsTr("Insert GeoFence") } QGCButton { @@ -139,8 +141,10 @@ QGCFlickable { } SectionHeader { - id: polygonSection - text: qsTr("Polygon Fences") + id: polygonSection + anchors.left: parent.left + anchors.right: parent.right + text: qsTr("Polygon Fences") } QGCLabel { @@ -212,8 +216,10 @@ QGCFlickable { } // GridLayout SectionHeader { - id: circleSection - text: qsTr("Circular Fences") + id: circleSection + anchors.left: parent.left + anchors.right: parent.right + text: qsTr("Circular Fences") } QGCLabel { @@ -302,8 +308,10 @@ QGCFlickable { } // GridLayout SectionHeader { - id: breachReturnSection - text: qsTr("Breach Return Point") + id: breachReturnSection + anchors.left: parent.left + anchors.right: parent.right + text: qsTr("Breach Return Point") } QGCButton { diff --git a/src/PlanView/MissionSettingsEditor.qml b/src/PlanView/MissionSettingsEditor.qml index 3efe77fc971de78d972708421a9a15df36394812..4c6f5095aaa5299f69d65bc40b51fb666873a731 100644 --- a/src/PlanView/MissionSettingsEditor.qml +++ b/src/PlanView/MissionSettingsEditor.qml @@ -108,9 +108,11 @@ Rectangle { } SectionHeader { - id: missionEndHeader - text: qsTr("Mission End") - checked: true + id: missionEndHeader + anchors.left: parent.left + anchors.right: parent.right + text: qsTr("Mission End") + checked: true } Column { @@ -128,10 +130,12 @@ Rectangle { SectionHeader { - id: vehicleInfoSectionHeader - text: qsTr("Vehicle Info") - visible: _offlineEditing && !_waypointsOnlyMode - checked: false + id: vehicleInfoSectionHeader + anchors.left: parent.left + anchors.right: parent.right + text: qsTr("Vehicle Info") + visible: _offlineEditing && !_waypointsOnlyMode + checked: false } GridLayout { @@ -192,10 +196,12 @@ Rectangle { } // GridLayout SectionHeader { - id: plannedHomePositionSection - text: qsTr("Planned Home Position") - visible: !_vehicleHasHomePosition - checked: false + id: plannedHomePositionSection + anchors.left: parent.left + anchors.right: parent.right + text: qsTr("Planned Home Position") + visible: !_vehicleHasHomePosition + checked: false } Column { diff --git a/src/PlanView/StructureScanEditor.qml b/src/PlanView/StructureScanEditor.qml index 31e307ef69f47cae28e5518651a3445c97f75d6d..c8a8611477410cf7129e0ab4f8aea33bd9820599 100644 --- a/src/PlanView/StructureScanEditor.qml +++ b/src/PlanView/StructureScanEditor.qml @@ -130,8 +130,10 @@ Rectangle { } SectionHeader { - id: scanHeader - text: qsTr("Scan") + id: scanHeader + anchors.left: parent.left + anchors.right: parent.right + text: qsTr("Scan") } Column { @@ -200,8 +202,10 @@ Rectangle { } // Column - Scan SectionHeader { - id: statsHeader - text: qsTr("Statistics") + id: statsHeader + anchors.left: parent.left + anchors.right: parent.right + text: qsTr("Statistics") } Grid { diff --git a/src/PlanView/SurveyItemEditor.qml b/src/PlanView/SurveyItemEditor.qml index 291dd8680b1446a8cb8525da21f5a12bbe542e6f..c2fcf07e697ce1f7fbacfc7bc0dd62fe46397a32 100644 --- a/src/PlanView/SurveyItemEditor.qml +++ b/src/PlanView/SurveyItemEditor.qml @@ -124,8 +124,10 @@ Rectangle { } SectionHeader { - id: transectsHeader - text: qsTr("Transects") + id: transectsHeader + anchors.left: parent.left + anchors.right: parent.right + text: qsTr("Transects") } GridLayout { @@ -233,9 +235,11 @@ Rectangle { } SectionHeader { - id: terrainHeader - text: qsTr("Terrain") - checked: missionItem.followTerrain + id: terrainHeader + anchors.left: parent.left + anchors.right: parent.right + text: qsTr("Terrain") + checked: missionItem.followTerrain } ColumnLayout { @@ -280,8 +284,10 @@ Rectangle { } SectionHeader { - id: statsHeader - text: qsTr("Statistics") + id: statsHeader + anchors.left: parent.left + anchors.right: parent.right + text: qsTr("Statistics") } TransectStyleComplexItemStats { @@ -357,8 +363,6 @@ Rectangle { SectionHeader { id: presectsTransectsHeader - anchors.left: undefined - anchors.right: undefined Layout.fillWidth: true text: qsTr("Transects") } @@ -400,11 +404,9 @@ Rectangle { } SectionHeader { - id: presetsStatsHeader - anchors.left: undefined - anchors.right: undefined + id: presetsStatsHeader Layout.fillWidth: true - text: qsTr("Statistics") + text: qsTr("Statistics") } TransectStyleComplexItemStats { diff --git a/src/QmlControls/ParameterEditor.qml b/src/QmlControls/ParameterEditor.qml index 811f26192abdd1c8778a1d1e738aba69fe6472bf..4095eb1570b16ab7ddcdfb4b8c369518f1fc8920 100644 --- a/src/QmlControls/ParameterEditor.qml +++ b/src/QmlControls/ParameterEditor.qml @@ -174,6 +174,8 @@ Item { SectionHeader { id: categoryHeader + anchors.left: parent.left + anchors.right: parent.right text: category checked: controller.currentCategory === text exclusiveGroup: sectionGroup diff --git a/src/QmlControls/PreFlightCheckGroup.qml b/src/QmlControls/PreFlightCheckGroup.qml index f3d2b3feeffece0f96f44bbc397a0dfc13ee3a1f..19280ba8d26d38b7159a36e57ea82939d059b293 100644 --- a/src/QmlControls/PreFlightCheckGroup.qml +++ b/src/QmlControls/PreFlightCheckGroup.qml @@ -43,8 +43,10 @@ Column { } SectionHeader { - id: header - text: name + (passed ? qsTr(" (passed)") : "") + id: header + anchors.left: parent.left + anchors.right: parent.right + text: name + (passed ? qsTr(" (passed)") : "") } Column { diff --git a/src/QmlControls/SectionHeader.qml b/src/QmlControls/SectionHeader.qml index 06c9a2ca533ccb57c9f5a810bd242c016ab98931..dc763f2e3da17c4fe55391980e5bd5fca492156e 100644 --- a/src/QmlControls/SectionHeader.qml +++ b/src/QmlControls/SectionHeader.qml @@ -7,10 +7,8 @@ import QGroundControl.ScreenTools 1.0 import QGroundControl.Palette 1.0 FocusScope { - id: _root - anchors.left: parent.left - anchors.right: parent.right - height: column.height + id: _root + height: column.height property alias text: label.text property bool checked: true