Enum StyleResourceKey
defines static style keys for WPF controls in Sartorius corporate design
Namespace: Sartorius.SAF.Presentation.Controls.Resources
Assembly: Sartorius.SAF.Presentation.Controls.dll
Syntax
public enum StyleResourceKey
Examples
Style for System.Windows.Controls.TextBox with multiple lines
<Grid Margin="0,0,0,3">
<TextBox Style="{SAF:Style TextBoxMultiLine}">TextBox with multiLine style: a long long text to be viewed in more than one line</TextBox>
</Grid>
<Grid Margin="0,0,0,3">
<TextBox Style="{SAF:Style TextBoxMultiLine}" SAF:Input.IsReadOnly="True">TextBox with multiLine style in readonly mode: a long long text to be viewed in more than one line</TextBox>
</Grid>
Style for System.Windows.Controls.TextBox with a single line
<Grid Height="28">
<TextBox Style="{SAF:Style TextBoxSingleLine}">TextBox with singleLine style: a long long text to be viewed in a singe line</TextBox>
</Grid>
<Grid Height="28">
<TextBox Style="{SAF:Style TextBoxSingleLine}" SAF:Input.IsReadOnly="True">TextBox with singleLine style in readonly mode: a long long text to be viewed in a singe line</TextBox>
</Grid>
Style for WatermarkTextBox
<Grid Height="28">
<SAF:WatermarkTextBox Style="{SAF:Style WatermarkTextBoxSingleLine}"
Watermark="watermark" Unit="unit">
WatermarkTextBoxSingleLine (!define as default WatermarkTextBox style / remove WatermarkTextBox property "Readonly"!)
</SAF:WatermarkTextBox>
</Grid>
<Grid Height="28">
<SAF:WatermarkTextBox Style="{SAF:Style WatermarkTextBoxSingleLine}"
SAF:Input.IsReadOnly="True">
ReadOnly WatermarkTextBoxSingleLine
</SAF:WatermarkTextBox>
</Grid>
Style for System.Windows.Controls.PasswordBox
<Grid Height="28">
<PasswordBox Style="{SAF:Style PasswordBox}" />
</Grid>
Usage of style for System.Windows.Controls.TextBlock embedded in the header of a HeaderedContentControl
<HeaderedContentControl Style="{SAF:Style HeaderedContentControl}" Margin="0,0,3,3">
<HeaderedContentControl.Header>
<TextBlock Style="{SAF:Style TextBlockContentBoxHeader}">HeaderedContentControl Title</TextBlock>
</HeaderedContentControl.Header>
<HeaderedContentControl.Content>HeaderedContentControl Content</HeaderedContentControl.Content>
</HeaderedContentControl>
Style for System.Windows.Controls.TextBlock used for labels on the left side of a ContentBox
<Grid Height="28">
<TextBlock Style="{SAF:Style TextBlockContentBoxLabel}">TextBlockLabel: lightweighted variant for labels instead of caption control</TextBlock>
</Grid>
Usage of style for System.Windows.Controls.TextBlock for labels in comparison to Caption control that can be used for labels as well
<SAF:Caption Grid.Row="4" Grid.Column="0" Text="Label by Caption"
Style="{SAF:Style CaptionContentBox}" />
<TextBlock Grid.Row="5" Grid.Column="0" Style="{SAF:Style TextBlockContentBoxLabel}">Label by TextBlock (TextBlockLabel)(lightweighted alternative to caption control)</TextBlock>
Usage of style for System.Windows.Controls.TextBlock for values in content boxes in comparison to WatermarkTextBox control that can be used for readonly values as well
<Grid Height="28">
<TextBlock Style="{SAF:Style TextBlockContentBoxValue}">Textblock single line value (leightweighted alternative for WatermarkTextBoxSingleLine)</TextBlock>
</Grid>
Usage of style for System.Windows.Controls.TextBox for values in content boxes in comparison to WatermarkTextBox control that can be used for readonly values as well
<Grid Height="28">
<TextBox Style="{SAF:Style TextBoxSingleLine}" SAF:Input.IsReadOnly="True">Textblox single line value (leightweighted alternative for WatermarkTextBoxSingleLine)</TextBox>
</Grid>
Style for Caption used for labels on the left side of a ContentBox
<SAF:Caption Grid.Row="1" Grid.Column="0" Text="PasswordBox" Indicator="Required"
Style="{SAF:Style CaptionContentBox}" />
Style for System.Windows.Controls.CheckBox used on the right side of a ContentBox
<StackPanel Grid.Row="6" Grid.Column="2">
<Grid Height="28">
<CheckBox Style="{SAF:Style CheckBox}" />
</Grid>
<Grid Height="28">
<CheckBox Style="{SAF:Style CheckBox}" SAF:Input.IsReadOnly="True" IsChecked="True" />
</Grid>
<Grid Height="28">
<CheckBox Style="{SAF:Style CheckBox}" SAF:Input.IsReadOnly="True" IsChecked="False" />
</Grid>
</StackPanel>
Style for System.Windows.Controls.Button used in the Toolbar embedded in the typical Toolbar background color
<DockPanel Background="{SAF:Brush Background08}" Height="39" Dock="Left" LastChildFill="False">
<Button Style="{SAF:Style ButtonToolbar}" Width="40">B?</Button>
<Button Style="{SAF:Style ButtonToolbar}" Width="40" IsEnabled="False">B!</Button>
<ToggleButton Style="{SAF:Style ToggleButtonToolbar}" Width="40">T?</ToggleButton>
<ToggleButton Style="{SAF:Style ToggleButtonToolbar}" Width="40" IsEnabled="False">T!</ToggleButton>
</DockPanel>
Style for System.Windows.Controls.Button embedded in the header of a HeaderedContentControl
<HeaderedContentControl.Header>
<Grid>
<TextBlock Style="{SAF:Style TextBlockContentBoxHeader}" HorizontalAlignment="Left">Title with Button</TextBlock>
<Button Style="{SAF:Style ButtonContentBoxHeader}" Width="30" HorizontalAlignment="Right">?</Button>
</Grid>
</HeaderedContentControl.Header>
Style for System.Windows.Controls.Button that should be used as Hyperlink
<Button Style="{SAF:Style ButtonHyperlink}">Link</Button>
Style for System.Windows.Controls.Button that should be used for single KeyActions
<Button Style="{SAF:Style ButtonPrimary}">SingleKeyAction</Button>
Style for System.Windows.Controls.Button that should be used for a set of SecondaryActions and KeyActions
<Grid Margin="10">
<Border HorizontalAlignment="Right" VerticalAlignment="Top"
BorderBrush="{SAF:Brush Border09}" BorderThickness="1,1,0,0">
<StackPanel Orientation="Horizontal">
<Button Content="Key Action" Style="{SAF:Style ButtonPrimary}" />
<Button Content="Can Action 1" Style="{SAF:Style ButtonSecondary}" />
<Button Content="Can Action 2" Style="{SAF:Style ButtonSecondary}" />
</StackPanel>
</Border>
</Grid>
Style for System.Windows.Controls.Button that should be used for single KeyAction in dark background
Style for System.Windows.Controls.Button that should be used for a set of SecondaryActions and KeyActions in dark background
<Border HorizontalAlignment="Right" VerticalAlignment="Top"
BorderBrush="{SAF:Brush Border09}" BorderThickness="1,1,0,0">
<StackPanel Orientation="Horizontal">
<Button Content="Key Action" Style="{SAF:Style ButtonPrimary}" />
<Button Content="Can Action" Style="{SAF:Style ButtonTertiary}" />
</StackPanel>
</Border>
Style for System.Windows.Controls.Primitives.ToggleButton embedded in the header of a HeaderedContentControl
<HeaderedContentControl.Header>
<Grid>
<TextBlock Style="{SAF:Style TextBlockContentBoxHeader}" HorizontalAlignment="Left">Title with ToggleButton</TextBlock>
<ToggleButton Style="{SAF:Style ToggleButtonContentBoxHeader}" HorizontalAlignment="Right"
Width="40">
?
</ToggleButton>
</Grid>
</HeaderedContentControl.Header>
Style for System.Windows.Controls.Primitives.ToggleButton used in the Toolbar embedded in Toolbar background color
<DockPanel Background="{SAF:Brush Background08}" Height="39" Dock="Left" LastChildFill="False">
<Button Style="{SAF:Style ButtonToolbar}" Width="40">B?</Button>
<Button Style="{SAF:Style ButtonToolbar}" Width="40" IsEnabled="False">B!</Button>
<ToggleButton Style="{SAF:Style ToggleButtonToolbar}" Width="40">T?</ToggleButton>
<ToggleButton Style="{SAF:Style ToggleButtonToolbar}" Width="40" IsEnabled="False">T!</ToggleButton>
</DockPanel>
Style for System.Windows.Controls.ComboBox
<ComboBox Grid.Row="1" Grid.Column="1" Style="{SAF:Style ComboBox}" Grid.ColumnSpan="2" Margin="20,2,0,2">
<ComboBoxItem>Item 1</ComboBoxItem>
<ComboBoxItem Style="{SAF:Style ComboBoxItem}">Item 2</ComboBoxItem>
<ComboBoxItem Style="{SAF:Style ComboBoxItem_SelectionIndication}">Item 3</ComboBoxItem>
</ComboBox>
Style for System.Windows.Controls.ComboBoxItem without selection indication
<ComboBox Grid.Row="2" Grid.Column="1" Style="{SAF:Style ComboBox}"
ItemContainerStyle="{SAF:Style ComboBoxItem}" Grid.ColumnSpan="2" Margin="20,2,0,2">
<ComboBoxItem>Item 1</ComboBoxItem>
<ComboBoxItem>Item 2</ComboBoxItem>
</ComboBox>
Style for System.Windows.Controls.ComboBoxItem with a selection indication
<ComboBox Grid.Row="3" Grid.Column="1" Style="{SAF:Style ComboBox}"
ItemContainerStyle="{SAF:Style ComboBoxItem_SelectionIndication}" Grid.ColumnSpan="2" Margin="20,2,0,2">
<ComboBoxItem>Item 1</ComboBoxItem>
<ComboBoxItem>Item 2</ComboBoxItem>
</ComboBox>
Style for System.Windows.Documents.Hyperlink
<TextBlock>
<Hyperlink Style="{SAF:Style Hyperlink}">
Click here
</Hyperlink>
</TextBlock>
Style for System.Windows.Controls.ScrollViewer next to the content
<ScrollViewer Style="{SAF:Style ScrollViewer}">
<Grid Height="100" Background="#878787" />
</ScrollViewer>
Style for System.Windows.Controls.Primitives.ScrollBar
<ScrollBar Style="{SAF:Style ScrollBar}" Orientation="Horizontal" />
Style for System.Windows.Controls.TabControl
<TabControl Style="{SAF:Style TabControl}" Height="150">
<TabItem Header="First">First Tab</TabItem>
<TabItem Header="Second" IsEnabled="False">Second Tab</TabItem>
<!-- #region TabItem-->
<TabItem Header="Third" Style="{SAF:Style TabItem}">Third Tab</TabItem>
Style for System.Windows.Controls.TabItem
Style for horizontal System.Windows.Controls.ProgressBar
<ProgressBar x:Name="progressBar" Style="{SAF:Style ProgressBar}" Width="100"
Height="10">
<ProgressBar.Triggers>
<EventTrigger RoutedEvent="ProgressBar.Loaded">
<BeginStoryboard>
<Storyboard>
<DoubleAnimation Storyboard.TargetName="progressBar"
Storyboard.TargetProperty="Value"
From="0" To="100" Duration="0:0:5"
RepeatBehavior="Forever" />
</Storyboard>
</BeginStoryboard>
</EventTrigger>
</ProgressBar.Triggers>
</ProgressBar>
Style for System.Windows.Controls.ProgressBar as circle
<ProgressBar x:Name="progressBar1" Style="{SAF:Style ProgressBarCircle}"
Margin="0,10,0,0">
<ProgressBar.Triggers>
<EventTrigger RoutedEvent="ProgressBar.Loaded">
<BeginStoryboard>
<Storyboard>
<DoubleAnimation Storyboard.TargetName="progressBar1"
Storyboard.TargetProperty="Value"
From="0" To="100" Duration="0:0:5"
RepeatBehavior="Forever" />
</Storyboard>
</BeginStoryboard>
</EventTrigger>
</ProgressBar.Triggers>
</ProgressBar>
Style for System.Windows.Controls.ListBox with SelectionMode=System.Windows.Controls.SelectionMode.Single
<ListBox Grid.Row="4" Grid.Column="1" Style="{SAF:Style ListBox}" Grid.ColumnSpan="2" Margin="20,0,0,0">
<ListBoxItem>Item 1</ListBoxItem>
<ListBoxItem>Item 2</ListBoxItem>
<ListBoxItem IsEnabled="False">Item 3</ListBoxItem>
<ListBoxItem IsSelected="True">Item 4</ListBoxItem>
</ListBox>
Style for System.Windows.Controls.ListBox with SelectionMode=System.Windows.Controls.SelectionMode.Extended same as SelectionMode=System.Windows.Controls.SelectionMode.Multiple
<ListBox Grid.Row="4" Grid.Column="1" Style="{SAF:Style ListBox}" SelectionMode="Extended" Grid.ColumnSpan="2" Margin="20,0,0,0">
<ListBoxItem>Item 1</ListBoxItem>
<ListBoxItem IsSelected="True">Item 2</ListBoxItem>
<ListBoxItem IsEnabled="False">Item 3</ListBoxItem>
<ListBoxItem IsSelected="True" IsEnabled="False">Item 4</ListBoxItem>
</ListBox>
Example for System.Windows.Controls.ListBox with System.Windows.Controls.SelectionMode.Single using circles as selection indication
<ListBox Grid.Row="7" Grid.Column="1" Style="{SAF:Style ListBox}"
ItemContainerStyle="{SAF:Style ListBoxItem}" Background="{SAF:Brush Background03}"
SelectionMode="Single" Grid.ColumnSpan="2" Margin="20,0,0,0">
<ListBoxItem>Item 1</ListBoxItem>
<ListBoxItem>Item 2</ListBoxItem>
<ListBoxItem IsEnabled="False">Item 3</ListBoxItem>
</ListBox>
Example for System.Windows.Controls.ListBox with System.Windows.Controls.SelectionMode.Extended same as System.Windows.Controls.SelectionMode.Multiple using checkmarks as selection indication
<ListBox Grid.Row="6" Grid.Column="1" Style="{SAF:Style ListBox}"
Background="{SAF:Brush Background01}" SelectionMode="Extended"
ItemContainerStyle="{SAF:Style ListBoxItem}" Grid.ColumnSpan="2" Margin="20,0,0,0">
<ListBoxItem>Item 1</ListBoxItem>
<ListBoxItem>Item 2</ListBoxItem>
<ListBoxItem IsEnabled="False">Item 3</ListBoxItem>
</ListBox>
Example for System.Windows.Controls.ListBox that should be placed in a single line - usage in ContentBoxes
<ListBox Grid.Row="9" Grid.Column="1" Style="{SAF:Style ListBoxSingleLine}" Grid.ColumnSpan="2" Margin="20,2,0,2">
<ListBoxItem>Yes</ListBoxItem>
<ListBoxItem>No</ListBoxItem>
<ListBoxItem IsEnabled="False">Dis</ListBoxItem>
</ListBox>
Style for System.Windows.Controls.TreeView
<TreeView Style="{SAF:Style TreeView}">
<TreeViewItem Header="First" />
<!-- #region TreeViewItem-->
<TreeViewItem Header="Second" Style="{SAF:Style TreeViewItem}" IsEnabled="False" />
Style for System.Windows.Controls.TreeViewItem
Style for System.Windows.Controls.HeaderedContentControl
<HeaderedContentControl Style="{SAF:Style HeaderedContentControl}" Margin="0,0,3,3">
<HeaderedContentControl.Header>
<TextBlock Style="{SAF:Style TextBlockContentBoxHeader}">HeaderedContentControl Title</TextBlock>
</HeaderedContentControl.Header>
<HeaderedContentControl.Content>HeaderedContentControl Content</HeaderedContentControl.Content>
</HeaderedContentControl>
Fields
Name | Description |
---|---|
ButtonContentBoxHeader | Button style used for buttons located at the right of the light-gray header in a HeaderedContentControl (light-gray background) (VS_S1.01) |
ButtonHyperlink | Button style used for links in dialogs |
ButtonPrimary | Button style used for single key action indicating this is what the user wants to do (yellow / VG_G1.01) |
ButtonSecondary | Button style used for single action indicating this is what the user can do (gray / VG_G1.02) |
ButtonTertiary | Button style used for possible action indicating this is what the user can do (dark gray / VG_G1.03) without any border shadows |
ButtonToolbar | Button style to be used for buttons in headers of datagrid / chart views ... / also used in ActionLines/toolbar lines (VS_S1.02) |
CaptionContentBox | default style for Caption recommended style for label fields in ContentBoxes (left side of the ContentBox) TODO: set this style as Caption control default style: if so: remove this style?! TODO: check whether the default style is used anywhere |
CheckBox | default CheckBox style - a checkmark, used in ContentBoxes for values of type bool (VS_S1.24) |
ComboBox | default ComboBox style (VS_G1.09) and ComboBoxItem of style (VS_S1.01) used in ContentBox elements |
ComboBoxItem | ComboBoxItem style used for ComboBoxItems without selection indication. VS_S1.01 without FocusVisualStyle |
ComboBoxItem_SelectionIndication | ComboBoxItem style used for ComboBoxItems with selection indication (circle). VS_S1.01 without FocusVisualStyle |
ContentBox | style used for HeaderedContentControl |
HeaderedContentControl | style used for HeaderedContentControl |
Hyperlink | default Hyperlink style |
ListBox | default ListBox style used for overlays and popups (gray background) (visual state of items VS_S1.24) |
ListBoxItem | ListBoxItem style used for ListBoxItems with selection indication If System.Windows.Controls.SelectionMode is System.Windows.Controls.SelectionMode.Single shows circle for single selection, else indicates selection with check marks visual style VS_S1.24 - same as VS_S1.01 except for FocusVisualState (VS_S1.24) |
ListBoxSingleLine | ListBox style used in dialogs and ContentBoxes to show single selection in a single row, use this style if the displayed content of the list items are short key words or icons and the number does not exceeds the place that is provided for the list (VS_S1.16) |
PasswordBox | default style for PasswordBox |
ProgressBar | default ProgressBar style, progress is indicated by a bar |
ProgressBarCircle | special ProgressBar style indicated by a circle |
ScrollBar | default ScrollBar style |
ScrollViewer | default ScrollViewer style where the scrollbars lie over the content |
SplitButtonPrimary | This style indicates primary user interaction (e.g. save) within dialogs or at the bottom rights corner of a view. |
SplitButtonSecondary | This style indicates secondary user interaction (e.g. cancel) within dialogs or at the bottom rights corner of a view. |
TabControl | default TabControl style (VS_S1.17) |
TabItem | default TabItem style (VS_S1.17) |
TextBlock | default TextBlock style defining the default font |
TextBlockContentBoxHeader | TextBlock style for text in the header of a HeaderedContentControl with style HeaderedContentControl |
TextBlockContentBoxLabel | TextBlock style to be used for labels, lightweighted alternative to Caption control. The latter supports 'Required' indication. |
TextBlockContentBoxValue | TextBlock style to be used for non editable text on the right side of a ContentBox, leightweighted alternative to WatermarkTextBox in ReadOnly mode. |
TextBoxMultiLine | TextBox style for multi line input |
TextBoxSingleLine | TextBox style for single line input, use this light-weighted version if watermark is not required, else use WatermarkTextBoxSingleLine |
ToggleButtonContentBoxHeader | ToggleButton style used for buttons located at the right of the light-gray header in a HeaderedContentControl (light-gray background) (VS_S1.01) |
ToggleButtonOnOff | ToggleButton style to be used for toggle buttons on off |
ToggleButtonToolbar | ToggleButton style to be used for toggle buttons in headers of datagrid / chart views ... / also used in ActionLines/toolbar lines (VS_S1.02) |
TreeView | default TreeView style with predefined TreeViewItems of visual state VS_S2.03 |
TreeViewItem | default TreeViewItem style (VS_S2.03) |
WatermarkTextBoxSingleLine | default style for WatermarkTextBox for single line input with the option to set a watermark and a unit, recommended style for input and readonly fields in ContentBoxes (right side of the ContentBox) TODO: this should be the default style for the WatermarkTextBox, if so remove this style ? TODO: check if default style is used public only -> if so: switch |