16
16
<Grid >
17
17
<esriUI : MapView x : Name =" MyMapView" GeoViewTapped =" MyMapView_GeoViewTapped" />
18
18
<Grid Margin =" 5,5,5,5"
19
- ColumnDefinitions =" auto, auto"
20
19
ColumnSpacing =" 5"
21
20
HorizontalOptions =" End"
22
- RowDefinitions =" auto, auto, auto, auto, auto, auto, auto "
21
+ RowDefinitions =" auto,* "
23
22
RowSpacing =" 5"
24
- VerticalOptions =" Start" >
25
- <Button x : Name =" PointButton"
23
+ VerticalOptions =" Start"
24
+ WidthRequest =" 150" >
25
+ <Button x : Name =" ToggleGeometryEditorPanelButton"
26
26
Grid.Row=" 0"
27
- Clicked =" PointButton_Click"
28
- Style =" {StaticResource IconStyle}"
29
- Text ="  "
30
- ToolTipProperties.Text=" Point" />
31
- <Button x : Name =" MultipointButton"
32
- Grid.Row=" 0"
33
- Grid.Column=" 1"
34
- Clicked =" MultipointButton_Click"
35
- FontSize =" 15"
36
- Style =" {StaticResource IconStyle}"
37
- Text ="  "
38
- ToolTipProperties.Text=" Multipoint" />
39
- <Button x : Name =" PolylineButton"
40
- Grid.Row=" 1"
41
- Clicked =" PolylineButton_Click"
42
- Style =" {StaticResource IconStyle}"
43
- Text ="  "
44
- ToolTipProperties.Text=" Polyline / no shape fill" />
45
- <Button x : Name =" PolygonButton"
46
- Grid.Row=" 1"
47
- Grid.Column=" 1"
48
- Clicked =" PolygonButton_Click"
49
- Style =" {StaticResource IconStyle}"
50
- Text ="  "
51
- ToolTipProperties.Text=" Polygon / shape fill" />
52
- <Border Grid.Row=" 2"
53
- Grid.ColumnSpan=" 2"
54
- BackgroundColor =" {AppThemeBinding Light={StaticResource White},
55
- Dark={StaticResource Dark}}" >
56
- <Picker x : Name =" ToolPicker"
57
- SelectedIndexChanged =" ToolPicker_SelectedIndexChanged"
58
- ToolTipProperties.Text=" Tools"
59
- WidthRequest =" 150" />
60
- </Border >
61
- <HorizontalStackLayout Grid.Row=" 3"
62
- Grid.ColumnSpan=" 2"
63
- Padding =" 1"
64
- Background =" {AppThemeBinding Light={StaticResource White},
65
- Dark={StaticResource Dark}}" >
66
- <CheckBox x : Name =" UniformScaleCheckBox" CheckedChanged =" CheckBox_CheckedChanged" />
67
- <Label Text =" Uniform Scale" VerticalOptions =" Center" />
68
- </HorizontalStackLayout >
69
- <Button Grid.Row=" 4"
70
- Clicked =" UndoButton_Click"
71
- IsEnabled =" {Binding GeometryEditor.CanUndo, Source={x:Reference MyMapView}}"
72
- Style =" {StaticResource IconStyle}"
73
- Text ="  "
74
- ToolTipProperties.Text=" Undo" />
75
- <Button Grid.Row=" 4"
76
- Grid.Column=" 1"
77
- Clicked =" RedoButton_Click"
78
- IsEnabled =" {Binding GeometryEditor.CanRedo, Source={x:Reference MyMapView}}"
79
- Style =" {StaticResource IconStyle}"
80
- Text ="  "
81
- ToolTipProperties.Text=" Redo" />
82
- <Button Grid.Row=" 5"
83
- Clicked =" DeleteSelectedButton_Click"
84
- IsEnabled =" {Binding GeometryEditor.SelectedElement.CanDelete, Source={x:Reference MyMapView}, FallbackValue=False}"
85
- Style =" {StaticResource IconStyle}"
86
- Text ="  "
87
- ToolTipProperties.Text=" Delete selected" />
88
- <Button x : Name =" SaveButton"
89
- Grid.Row=" 5"
90
- Grid.Column=" 1"
91
- Clicked =" SaveButton_Click"
92
- IsEnabled =" {Binding GeometryEditor.CanUndo, Source={x:Reference MyMapView}}"
93
- Style =" {StaticResource IconStyle}"
94
- Text ="  "
95
- ToolTipProperties.Text=" Save edits" />
96
- <Button Grid.Row=" 6"
97
- Clicked =" DiscardButton_Click"
98
- IsEnabled =" {Binding GeometryEditor.IsStarted, Source={x:Reference MyMapView}}"
99
- Style =" {StaticResource IconStyle}"
100
- Text ="  "
101
- ToolTipProperties.Text=" Discard edits" />
102
- <Button x : Name =" DeleteAllButton"
103
- Grid.Row=" 6"
104
- Grid.Column=" 1"
105
- Clicked =" DeleteAllButton_Click"
106
- IsEnabled =" {Binding GeometryEditor.IsStarted, Source={x:Reference MyMapView}, Converter={StaticResource InvertedBoolConverter}}"
107
- Style =" {StaticResource IconStyle}"
108
- Text ="  "
109
- ToolTipProperties.Text=" Delete all geometries" />
27
+ HorizontalOptions =" Fill"
28
+ Pressed =" ToggleGeometryEditorPanelButton_Pressed"
29
+ Text =" Show UI" />
30
+ <ScrollView x : Name =" GeometryEditorPanel"
31
+ Grid.Row=" 1"
32
+ IsVisible =" False"
33
+ MaximumHeightRequest =" 400" >
34
+ <Grid ColumnDefinitions =" auto, auto"
35
+ ColumnSpacing =" 5"
36
+ RowDefinitions =" auto, auto, auto, auto, auto, auto, auto"
37
+ RowSpacing =" 5" >
38
+ <Button x : Name =" PointButton"
39
+ Grid.Row=" 0"
40
+ Clicked =" PointButton_Click"
41
+ Style =" {StaticResource IconStyle}"
42
+ Text ="  "
43
+ ToolTipProperties.Text=" Point" />
44
+ <Button x : Name =" MultipointButton"
45
+ Grid.Row=" 0"
46
+ Grid.Column=" 1"
47
+ Clicked =" MultipointButton_Click"
48
+ FontSize =" 15"
49
+ Style =" {StaticResource IconStyle}"
50
+ Text ="  "
51
+ ToolTipProperties.Text=" Multipoint" />
52
+ <Button x : Name =" PolylineButton"
53
+ Grid.Row=" 1"
54
+ Clicked =" PolylineButton_Click"
55
+ Style =" {StaticResource IconStyle}"
56
+ Text ="  "
57
+ ToolTipProperties.Text=" Polyline / no shape fill" />
58
+ <Button x : Name =" PolygonButton"
59
+ Grid.Row=" 1"
60
+ Grid.Column=" 1"
61
+ Clicked =" PolygonButton_Click"
62
+ Style =" {StaticResource IconStyle}"
63
+ Text ="  "
64
+ ToolTipProperties.Text=" Polygon / shape fill" />
65
+ <Border Grid.Row=" 2"
66
+ Grid.ColumnSpan=" 2"
67
+ BackgroundColor =" {AppThemeBinding Light={StaticResource White},
68
+ Dark={StaticResource Dark}}" >
69
+ <Picker x : Name =" ToolPicker"
70
+ SelectedIndexChanged =" ToolPicker_SelectedIndexChanged"
71
+ ToolTipProperties.Text=" Tools"
72
+ WidthRequest =" 150" />
73
+ </Border >
74
+ <Border Grid.Row=" 3"
75
+ Grid.ColumnSpan=" 2"
76
+ Padding =" 5"
77
+ Background =" {AppThemeBinding Light={StaticResource White},
78
+ Dark={StaticResource Dark}}" >
79
+ <Border .StrokeShape>
80
+ <RoundRectangle CornerRadius =" 5" />
81
+ </Border .StrokeShape>
82
+ <HorizontalStackLayout >
83
+ <CheckBox x : Name =" UniformScaleCheckBox"
84
+ Margin =" 3,0,5,0"
85
+ CheckedChanged =" CheckBox_CheckedChanged" />
86
+ <Label Text =" Uniform Scale" VerticalOptions =" Center" />
87
+ </HorizontalStackLayout >
88
+ </Border >
89
+ <Button Grid.Row=" 4"
90
+ Clicked =" UndoButton_Click"
91
+ IsEnabled =" {Binding GeometryEditor.CanUndo, Source={x:Reference MyMapView}}"
92
+ Style =" {StaticResource IconStyle}"
93
+ Text ="  "
94
+ ToolTipProperties.Text=" Undo" />
95
+ <Button Grid.Row=" 4"
96
+ Grid.Column=" 1"
97
+ Clicked =" RedoButton_Click"
98
+ IsEnabled =" {Binding GeometryEditor.CanRedo, Source={x:Reference MyMapView}}"
99
+ Style =" {StaticResource IconStyle}"
100
+ Text ="  "
101
+ ToolTipProperties.Text=" Redo" />
102
+ <Button Grid.Row=" 5"
103
+ Clicked =" DeleteSelectedButton_Click"
104
+ IsEnabled =" {Binding GeometryEditor.SelectedElement.CanDelete, Source={x:Reference MyMapView}, FallbackValue=False}"
105
+ Style =" {StaticResource IconStyle}"
106
+ Text ="  "
107
+ ToolTipProperties.Text=" Delete selected" />
108
+ <Button x : Name =" SaveButton"
109
+ Grid.Row=" 5"
110
+ Grid.Column=" 1"
111
+ Clicked =" SaveButton_Click"
112
+ IsEnabled =" {Binding GeometryEditor.CanUndo, Source={x:Reference MyMapView}}"
113
+ Style =" {StaticResource IconStyle}"
114
+ Text ="  "
115
+ ToolTipProperties.Text=" Save edits" />
116
+ <Button Grid.Row=" 6"
117
+ Clicked =" DiscardButton_Click"
118
+ IsEnabled =" {Binding GeometryEditor.IsStarted, Source={x:Reference MyMapView}}"
119
+ Style =" {StaticResource IconStyle}"
120
+ Text ="  "
121
+ ToolTipProperties.Text=" Discard edits" />
122
+ <Button x : Name =" DeleteAllButton"
123
+ Grid.Row=" 6"
124
+ Grid.Column=" 1"
125
+ Clicked =" DeleteAllButton_Click"
126
+ IsEnabled =" {Binding GeometryEditor.IsStarted, Source={x:Reference MyMapView}, Converter={StaticResource InvertedBoolConverter}}"
127
+ Style =" {StaticResource IconStyle}"
128
+ Text ="  "
129
+ ToolTipProperties.Text=" Delete all geometries" />
130
+ </Grid >
131
+ </ScrollView >
110
132
</Grid >
133
+
111
134
</Grid >
112
135
</ContentPage >
0 commit comments