1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556 |
- <UserControl x:Class="PDF_Office.CustomControl.ColorDropBox"
- xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
- xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
- xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
- xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
- xmlns:local="clr-namespace:PDF_Office.CustomControl"
- mc:Ignorable="d"
- d:DesignHeight="450" d:DesignWidth="800" MinWidth="52" Background="#01000000">
- <Grid>
- <Grid.ColumnDefinitions>
- <ColumnDefinition Width="*"></ColumnDefinition>
- <ColumnDefinition Width="auto" MinWidth="{DynamicResource {x:Static SystemParameters.VerticalScrollBarWidthKey}}" ></ColumnDefinition>
- </Grid.ColumnDefinitions>
- <!--正常颜色显示模块-->
- <Border Width="16" Height="16" HorizontalAlignment="Left" BorderThickness="1" BorderBrush="#33000000" Margin="12,0,0,0"
- Visibility="{Binding ElementName=NormalColorRectControl,Path=Visibility}">
- <Rectangle Name="NormalColorRectControl" Visibility="Collapsed"/>
- </Border>
- <!--透明颜色显示模块-->
- <Border Width="16" Height="16" HorizontalAlignment="Left" BorderThickness="1" Margin="12,0,0,0"
- BorderBrush="#33000000" Visibility="{Binding ElementName=TransparentRectControl,Path=Visibility}">
- <Rectangle Name="TransparentRectControl" Visibility="Collapsed">
- <Rectangle.Fill>
- <DrawingBrush>
- <DrawingBrush.Drawing>
- <DrawingGroup>
- <GeometryDrawing Brush="White">
- <GeometryDrawing.Pen>
- <Pen Thickness="1" Brush="#E2E3E6"></Pen>
- </GeometryDrawing.Pen>
- <GeometryDrawing.Geometry>
- <RectangleGeometry Rect="0,0,16,16"></RectangleGeometry>
- </GeometryDrawing.Geometry>
- </GeometryDrawing>
- <GeometryDrawing>
- <GeometryDrawing.Pen>
- <Pen Thickness="2" Brush="#FF3B30"></Pen>
- </GeometryDrawing.Pen>
- <GeometryDrawing.Geometry>
- <LineGeometry StartPoint="16,0" EndPoint="0,16"></LineGeometry>
- </GeometryDrawing.Geometry>
- </GeometryDrawing>
- </DrawingGroup>
- </DrawingBrush.Drawing>
- </DrawingBrush>
- </Rectangle.Fill>
- </Rectangle>
- </Border>
- <!--下拉模块-->
- <Border Grid.Column="1" BorderThickness="0" Background="Transparent" HorizontalAlignment="Right" Padding="4,0,4,0">
- <Polygon Points="13.8535156 5.85546875 13.1445312 5.14648438 8 10.2910156 2.85546875 5.14648438 2.14648438 5.85546875 8 11.7089844"
- Fill="#000000" Width="16" Height="16"/>
- </Border>
- </Grid>
- </UserControl>
|