mirror of
https://github.com/sourcegit-scm/sourcegit.git
synced 2024-12-24 20:57:19 -08:00
style<Histories>: change icons for buttons in histories panel
This commit is contained in:
parent
1d401d0955
commit
5bc7f9021b
4 changed files with 23 additions and 21 deletions
|
@ -46,8 +46,8 @@
|
||||||
<Geometry x:Key="Icon.Filter">M599.22969 424.769286 599.22969 657.383158 424.769286 831.844585 424.769286 424.769286 192.155415 192.155415 831.844585 192.155415Z</Geometry>
|
<Geometry x:Key="Icon.Filter">M599.22969 424.769286 599.22969 657.383158 424.769286 831.844585 424.769286 424.769286 192.155415 192.155415 831.844585 192.155415Z</Geometry>
|
||||||
<Geometry x:Key="Icon.Binary">M71.111111 1024V0h661.333333L952.888889 219.420444V1024H71.111111z m808.305778-731.420444l-220.444445-219.448889H144.583111V950.897778h734.833778V292.579556zM438.528 512h-220.444444V219.420444h220.444444V512z m-73.500444-219.420444H291.555556v146.289777h73.472v-146.289777z m0 512h73.500444v73.130666h-220.444444v-73.130666H291.555556v-146.289778H218.083556V585.102222h146.944v219.448889z m293.944888-365.710223h73.472V512H512v-73.130667h73.472v-146.289777H512V219.420444h146.972444v219.448889z m73.472 438.840889H512V585.130667h220.444444v292.579555z m-73.472-219.420444h-73.500444v146.289778h73.500444v-146.289778z</Geometry>
|
<Geometry x:Key="Icon.Binary">M71.111111 1024V0h661.333333L952.888889 219.420444V1024H71.111111z m808.305778-731.420444l-220.444445-219.448889H144.583111V950.897778h734.833778V292.579556zM438.528 512h-220.444444V219.420444h220.444444V512z m-73.500444-219.420444H291.555556v146.289777h73.472v-146.289777z m0 512h73.500444v73.130666h-220.444444v-73.130666H291.555556v-146.289778H218.083556V585.102222h146.944v219.448889z m293.944888-365.710223h73.472V512H512v-73.130667h73.472v-146.289777H512V219.420444h146.972444v219.448889z m73.472 438.840889H512V585.130667h220.444444v292.579555z m-73.472-219.420444h-73.500444v146.289778h73.500444v-146.289778z</Geometry>
|
||||||
|
|
||||||
<Geometry x:Key="Icon.Vertical">M1024 1024H0V0h1024v1024z m-64-64V320H320V256h640V64H64v896h192V64h64v896z</Geometry>
|
<Geometry x:Key="Icon.Vertical">M64 146.304c0-45.482667 36.821333-82.304 82.304-82.304H877.653333c45.482667 0 82.304 36.821333 82.304 82.304V877.653333a82.304 82.304 0 0 1-82.304 82.304H146.346667A82.304 82.304 0 0 1 64 877.696V146.346667zM146.304 106.666667a39.637333 39.637333 0 0 0-39.637333 39.637333V877.653333c0 21.888 17.749333 39.637333 39.637333 39.637334H490.666667v-810.666667H146.304z m387.029333 0v810.666666h344.362667a39.637333 39.637333 0 0 0 39.637333-39.637333V146.346667a39.637333 39.637333 0 0 0-39.637333-39.637334H533.333333z</Geometry>
|
||||||
<Geometry x:Key="Icon.Horizontal">M81.92 81.92v860.16h860.16V81.92H81.92z m802.304 57.856V322.56H139.776V139.776h744.448z m-744.448 240.64H322.56v503.808H139.776V380.416z m240.128 503.808V380.416h504.32v503.808H379.904z</Geometry>
|
<Geometry x:Key="Icon.Horizontal">M64 146.304c0-45.482667 36.821333-82.304 82.304-82.304h731.434667c45.44 0 82.261333 36.821333 82.261333 82.304v731.434667a82.304 82.304 0 0 1-82.261333 82.261333H146.304A82.304 82.304 0 0 1 64 877.738667V146.304zM146.304 106.666667a39.637333 39.637333 0 0 0-39.637333 39.637333V490.666667h810.666666V146.304a39.637333 39.637333 0 0 0-39.594666-39.637333H146.304z m771.029333 426.666666h-810.666666v344.405334c0 21.888 17.749333 39.594667 39.637333 39.594666h731.434667a39.637333 39.637333 0 0 0 39.594666-39.594666V533.333333z</Geometry>
|
||||||
|
|
||||||
<Geometry x:Key="Icon.Fetch">M1024 896v128H0V704h128v192h768V704h128v192zM576 554.688L810.688 320 896 405.312l-384 384-384-384L213.312 320 448 554.688V0h128v554.688z</Geometry>
|
<Geometry x:Key="Icon.Fetch">M1024 896v128H0V704h128v192h768V704h128v192zM576 554.688L810.688 320 896 405.312l-384 384-384-384L213.312 320 448 554.688V0h128v554.688z</Geometry>
|
||||||
<Geometry x:Key="Icon.Pull">M432 0h160c26.6 0 48 21.4 48 48v336h175.4c35.6 0 53.4 43 28.2 68.2L539.4 756.6c-15 15-39.6 15-54.6 0L180.2 452.2c-25.2-25.2-7.4-68.2 28.2-68.2H384V48c0-26.6 21.4-48 48-48z m592 752v224c0 26.6-21.4 48-48 48H48c-26.6 0-48-21.4-48-48V752c0-26.6 21.4-48 48-48h293.4l98 98c40.2 40.2 105 40.2 145.2 0l98-98H976c26.6 0 48 21.4 48 48z m-248 176c0-22-18-40-40-40s-40 18-40 40 18 40 40 40 40-18 40-40z m128 0c0-22-18-40-40-40s-40 18-40 40 18 40 40 40 40-18 40-40z</Geometry>
|
<Geometry x:Key="Icon.Pull">M432 0h160c26.6 0 48 21.4 48 48v336h175.4c35.6 0 53.4 43 28.2 68.2L539.4 756.6c-15 15-39.6 15-54.6 0L180.2 452.2c-25.2-25.2-7.4-68.2 28.2-68.2H384V48c0-26.6 21.4-48 48-48z m592 752v224c0 26.6-21.4 48-48 48H48c-26.6 0-48-21.4-48-48V752c0-26.6 21.4-48 48-48h293.4l98 98c40.2 40.2 105 40.2 145.2 0l98-98H976c26.6 0 48 21.4 48 48z m-248 176c0-22-18-40-40-40s-40 18-40 40 18 40 40 40 40-18 40-40z m128 0c0-22-18-40-40-40s-40 18-40 40 18 40 40 40 40-18 40-40z</Geometry>
|
||||||
|
|
|
@ -89,19 +89,14 @@
|
||||||
<Grid Background="Transparent">
|
<Grid Background="Transparent">
|
||||||
<Path
|
<Path
|
||||||
x:Name="Icon"
|
x:Name="Icon"
|
||||||
Width="18"
|
|
||||||
Height="18"
|
|
||||||
Style="{DynamicResource Style.Icon}"
|
Style="{DynamicResource Style.Icon}"
|
||||||
Fill="{DynamicResource Brush.Border1}"
|
Fill="{DynamicResource Brush.FG2}"
|
||||||
Data="{DynamicResource Icon.Horizontal}"/>
|
Data="{DynamicResource Icon.Vertical}"/>
|
||||||
</Grid>
|
</Grid>
|
||||||
|
|
||||||
<ControlTemplate.Triggers>
|
<ControlTemplate.Triggers>
|
||||||
<Trigger Property="IsChecked" Value="True">
|
<Trigger Property="IsChecked" Value="True">
|
||||||
<Setter TargetName="Icon" Property="Data" Value="{DynamicResource Icon.Vertical}"/>
|
<Setter TargetName="Icon" Property="Data" Value="{DynamicResource Icon.Horizontal}"/>
|
||||||
</Trigger>
|
|
||||||
<Trigger Property="IsMouseOver" Value="True">
|
|
||||||
<Setter TargetName="Icon" Property="Fill" Value="{DynamicResource Brush.FG1}"/>
|
|
||||||
</Trigger>
|
</Trigger>
|
||||||
</ControlTemplate.Triggers>
|
</ControlTemplate.Triggers>
|
||||||
</ControlTemplate>
|
</ControlTemplate>
|
||||||
|
|
|
@ -204,22 +204,22 @@
|
||||||
Checked="ChangeOrientation" Unchecked="ChangeOrientation"/>
|
Checked="ChangeOrientation" Unchecked="ChangeOrientation"/>
|
||||||
|
|
||||||
<!-- Tips to Histories Panel -->
|
<!-- Tips to Histories Panel -->
|
||||||
<Path
|
<Button Margin="4,0" ToolTip="{StaticResource Text.Histories.Guide}" Background="Transparent" Click="OpenGuide">
|
||||||
Width="20" Height="20"
|
<Path Data="{StaticResource Icon.Info}" Fill="{StaticResource Brush.FG2}"/>
|
||||||
Margin="8,0"
|
</Button>
|
||||||
|
|
||||||
Data="{StaticResource Icon.Info}"
|
<!-- Usage tooltip -->
|
||||||
Fill="{StaticResource Brush.FG1}">
|
<Popup x:Name="popupGuide" IsOpen="False" StaysOpen="False" Placement="Bottom">
|
||||||
<Path.ToolTip>
|
<Border Background="{StaticResource Brush.Popup}" BorderThickness="1" BorderBrush="{StaticResource Brush.Border2}">
|
||||||
<StackPanel Orientation="Vertical" TextElement.FontFamily="Consolas">
|
<StackPanel Orientation="Vertical" TextElement.FontFamily="Consolas" Margin="8">
|
||||||
<Label Content="{StaticResource Text.Histories.Guide}" FontWeight="Bold" FontSize="14" Margin="0,0,0,8"/>
|
<Label Content="{StaticResource Text.Histories.Guide}" FontWeight="Bold" FontSize="14" Margin="0,0,0,8"/>
|
||||||
<Label Content="{StaticResource Text.Histories.Guide_1}"/>
|
<Label Content="{StaticResource Text.Histories.Guide_1}"/>
|
||||||
<Label Content="{StaticResource Text.Histories.Guide_2}"/>
|
<Label Content="{StaticResource Text.Histories.Guide_2}"/>
|
||||||
<Label Content="{StaticResource Text.Histories.Guide_3}"/>
|
<Label Content="{StaticResource Text.Histories.Guide_3}"/>
|
||||||
<Label Content="{StaticResource Text.Histories.Guide_4}"/>
|
<Label Content="{StaticResource Text.Histories.Guide_4}"/>
|
||||||
</StackPanel>
|
</StackPanel>
|
||||||
</Path.ToolTip>
|
</Border>
|
||||||
</Path>
|
</Popup>
|
||||||
</StackPanel>
|
</StackPanel>
|
||||||
</Grid>
|
</Grid>
|
||||||
</Grid>
|
</Grid>
|
||||||
|
|
|
@ -584,5 +584,12 @@ namespace SourceGit.UI {
|
||||||
layout.InvalidateVisual();
|
layout.InvalidateVisual();
|
||||||
}
|
}
|
||||||
#endregion
|
#endregion
|
||||||
|
|
||||||
|
#region GUIDE
|
||||||
|
private void OpenGuide(object sender, RoutedEventArgs e) {
|
||||||
|
popupGuide.IsOpen = !popupGuide.IsOpen;
|
||||||
|
e.Handled = true;
|
||||||
|
}
|
||||||
|
#endregion
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue