<ResourceDictionary
|
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
|
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
|
mc:Ignorable="d"
|
xmlns:ui="clr-namespace:HMI.UI"
|
xmlns:sys="clr-namespace:System;assembly=mscorlib"
|
xmlns:pw="https://opensource.panuon.com/wpf"
|
xmlns:pu="https://opensource.panuon.com/wpf-ui"
|
xmlns:uic="clr-namespace:HMI.UI.Converter"
|
xmlns:dp="clr-namespace:HMI.UI.DpUtil;assembly=HMI.UI">
|
<ResourceDictionary.MergedDictionaries>
|
<pu:StyleDictionary Includes="ListView" />
|
<ResourceDictionary Source="/HMI.UI;component/Style/Colors.xaml"/>
|
<ResourceDictionary Source="/HMI.UI;component/Resources/Font/Font.xaml"/>
|
<ResourceDictionary Source="/HMI.UI;component/Style/ScrollBarResource.xaml"/>
|
</ResourceDictionary.MergedDictionaries>
|
|
<uic:ListViewRowNumberConverter x:Key="lvRowNumber"/>
|
|
<uic:ListViewRowHeightConverter x:Key="sbC"/>
|
|
<Style x:Key="CellBorder" TargetType="Border">
|
<Setter Property="BorderBrush" Value="{DynamicResource CommonBoarder}"/>
|
<Setter Property="BorderThickness" Value="1,0,0,0"/>
|
<Setter Property="Margin" Value="-5,0"/>
|
<Setter Property="Padding" Value="5,0,0,0"/>
|
<Setter Property="Height" Value="{Binding ActualHeight,
|
Mode=OneWay,
|
RelativeSource={RelativeSource Mode=FindAncestor,AncestorType=GridViewRowPresenter,AncestorLevel=1}}"/>
|
<!--<Setter Property="Width" Value="{Binding ActualWidth,
|
Converter={StaticResource sbC},ConverterParameter=2.0,
|
RelativeSource={RelativeSource Mode=FindAncestor,AncestorType=ContentPresenter,AncestorLevel=1}}"/>-->
|
</Style>
|
|
<Style x:Key="ListTableTextBlock" TargetType="TextBlock">
|
<Setter Property="Padding" Value="0,5"/>
|
<Setter Property="Margin" Value="0"/>
|
<Setter Property="VerticalAlignment" Value="Center"/>
|
<Setter Property="TextWrapping" Value="Wrap"/>
|
</Style>
|
|
<Style x:Key="DefaultListTableItemStyle" TargetType="ListViewItem" BasedOn="{StaticResource {x:Static pu:StyleKeys.ListViewItemStyle}}">
|
<Setter Property="Background" Value="#FFF"/>
|
<Style.Triggers>
|
<Trigger Property="ItemsControl.AlternationIndex" Value="1">
|
<Setter Property="Background" Value="#eeeeee"/>
|
</Trigger>
|
</Style.Triggers>
|
</Style>
|
|
<Style x:Key="DefaultListTable" TargetType="ListView" BasedOn="{StaticResource {x:Static pu:StyleKeys.ListViewStyle}}">
|
<Style.Resources>
|
<Style TargetType="ScrollBar" BasedOn="{StaticResource ScrollStyle_Mobile}"/>
|
</Style.Resources>
|
|
<Setter Property="BorderThickness" Value="0"/>
|
<Setter Property="VirtualizingPanel.IsVirtualizing" Value="True"/>
|
<Setter Property="AlternationCount" Value="2"/>
|
<Setter Property="pu:ListViewHelper.ColumnHeaderHeight" Value="36"/>
|
<Setter Property="pu:ListViewHelper.ColumnHeaderBackground" Value="{DynamicResource VerBar}"/>
|
<Setter Property="pu:ListViewHelper.ColumnHeaderHoverBackground" Value="{DynamicResource VerBar}"/>
|
<Setter Property="pu:ListViewHelper.ColumnHeaderForeground" Value="#FFF"/>
|
<Setter Property="pu:ListViewHelper.ItemsHoverBackground" Value="{DynamicResource SecondPrimaryColor}"/>
|
<Setter Property="pu:ListViewHelper.ItemsHoverForeground" Value="{DynamicResource SecondPrimaryColorContract}"/>
|
<Setter Property="pu:ListViewHelper.ItemsSelectedBackground" Value="{DynamicResource PrimaryColor}"/>
|
<Setter Property="pu:ListViewHelper.ItemsSelectedForeground" Value="{DynamicResource PrimaryColorContract}"/>
|
<Setter Property="pu:ListViewHelper.ItemsSeparatorBrush" Value="{DynamicResource CommonBoarder}"/>
|
<Setter Property="pu:ListViewHelper.ItemsSeparatorThickness" Value="1"/>
|
<Setter Property="pu:ListViewHelper.ItemsPadding" Value="0"/>
|
<Setter Property="pu:ListViewHelper.ItemsHeight" Value="30"/>
|
<Setter Property="pu:ListViewHelper.ItemsSeparatorVisibility" Value="Visible"/>
|
<Setter Property="ItemContainerStyle" Value="{StaticResource DefaultListTableItemStyle}"/>
|
</Style>
|
|
</ResourceDictionary>
|