Layer properties - Tweaked step sizes for draggable float

UI - Tweak selection rectangle design
This commit is contained in:
Robert committed 2022-06-15 21:57:10 +02:00
1 parent c0e2d8e579
commit e1a66f8a7e
14 files changed
+85 -57

No files matched your search

@@ -24,7 +24,16 @@
</TreeDataTemplate>
</ItemsControl.ItemTemplate>
</ItemsControl>
<shared:SelectionRectangle Name="SelectionRectangle" InputElement="{CompiledBinding $parent}" SelectionFinished="SelectionRectangle_OnSelectionFinished" />
<shared:SelectionRectangle Name="SelectionRectangle"
InputElement="{CompiledBinding $parent}"
BorderBrush="{DynamicResource SystemAccentColor}"
BorderRadius="8"
BorderThickness="1"
SelectionFinished="SelectionRectangle_OnSelectionFinished">
<shared:SelectionRectangle.Background>
<SolidColorBrush Color="{DynamicResource SystemAccentColorLight1}" Opacity="0.2" />
</shared:SelectionRectangle.Background>
</shared:SelectionRectangle>
</Grid>
@@ -9,7 +9,7 @@
<shared:SelectionRectangle InputElement="{Binding $parent[ZoomBorder]}"
BorderBrush="{DynamicResource SystemAccentColor}"
BorderRadius="8"
BorderThickness="2"
BorderThickness="1"
SelectionFinished="SelectionRectangle_OnSelectionFinished"
ZoomRatio="{Binding $parent[ZoomBorder].ZoomX}">
<shared:SelectionRectangle.Background>
@@ -11,7 +11,7 @@
<shared:SelectionRectangle InputElement="{Binding $parent[paz:ZoomBorder]}"
BorderBrush="{DynamicResource SystemAccentColor}"
BorderRadius="8"
BorderThickness="2"
BorderThickness="1"
SelectionFinished="SelectionRectangle_OnSelectionFinished"
ZoomRatio="{Binding $parent[ZoomBorder].ZoomX}">
<shared:SelectionRectangle.Background>
@@ -30,8 +30,7 @@
HorizontalAlignment="Stretch"
Background="{StaticResource LargeCheckerboardBrush}"
ZoomChanged="ZoomBorder_OnZoomChanged">
<Grid Name="ContainerGrid"
Background="Transparent">
<Grid Name="ContainerGrid" Background="Transparent">
<Grid.Transitions>
<Transitions>
<TransformOperationsTransition Property="RenderTransform" Duration="0:0:0.2" Easing="CubicEaseOut" />
@@ -103,7 +103,9 @@
InputElement="{Binding #ZoomBorder}"
SelectionUpdated="SelectionRectangle_OnSelectionUpdated"
BorderBrush="{DynamicResource SystemAccentColor}"
BorderRadius="8">
BorderRadius="8"
BorderThickness="1"
ZoomRatio="{Binding $parent[ZoomBorder].ZoomX}">
<shared:SelectionRectangle.Background>
<SolidColorBrush Color="{DynamicResource SystemAccentColorLight1}" Opacity="0.2" />
</shared:SelectionRectangle.Background>
@@ -47,7 +47,6 @@ public class SurfaceEditorView : ReactiveUserControl<SurfaceEditorViewModel>
private void ZoomBorder_OnZoomChanged(object sender, ZoomChangedEventArgs e)
{
UpdateZoomBorderBackground();
_selectionRectangle.BorderThickness = 1 / _zoomBorder.ZoomX;
_surfaceBounds.BorderThickness = new Thickness(2 / _zoomBorder.ZoomX);
}