28 lines
1.1 KiB
XML
28 lines
1.1 KiB
XML
<ResourceDictionary xmlns="https://github.com/avaloniaui"
|
|
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
|
x:ClassModifier="internal">
|
|
|
|
<MenuFlyout x:Key="SelectableTextBlockContextFlyout"
|
|
Placement="Bottom">
|
|
<MenuItem Header="Copy"
|
|
Cursor="Arrow"
|
|
Command="{Binding $parent[SelectableTextBlock].Copy}"
|
|
IsEnabled="{Binding $parent[SelectableTextBlock].CanCopy}"
|
|
InputGesture="{x:Static TextBox.CopyGesture}" />
|
|
</MenuFlyout>
|
|
|
|
<ControlTheme x:Key="{x:Type SelectableTextBlock}"
|
|
TargetType="SelectableTextBlock">
|
|
<Setter Property="SelectionBrush"
|
|
Value="{DynamicResource HighlightBrush}" />
|
|
|
|
<Style Selector="^[IsEnabled=True]">
|
|
<Setter Property="Cursor"
|
|
Value="IBeam" />
|
|
<Setter Property="ContextFlyout"
|
|
Value="{StaticResource SelectableTextBlockContextFlyout}" />
|
|
</Style>
|
|
</ControlTheme>
|
|
|
|
</ResourceDictionary>
|