This may be a backwards inquiry, but how do I remove the highlight from a MenuItem?
I'm using RadMenu to create a dropdown for a global search field. The parent level displays a vector-path icon, clicking it drops down the menu with a RadWatermarkTextBox and RadButton on one line and a Checkbox/TextBlock on the next. Works great (attached-Search1.png)! The only thing is the undesirable highlight on the mouseover (attached-Search2.png). Is there a XAML attribute I can apply?
Below is the current XAML code I'm using:
<telerik:RadMenu HorizontalAlignment="Left"
Background="{StaticResource MainBrush}"
Orientation="Horizontal"
Padding="0"
Height="33"
Margin="0 0 0 0"
VerticalAlignment="Top"
ClickToOpen="True"
IconColumnWidth="0">
<telerik:RadMenuItem StaysOpenOnClick="True"
Foreground="{StaticResource MarkerBrush}">
<telerik:RadMenuItem.Icon>
<CustomShape:CustomShape Style="{StaticResource GlobalSearch}"
Margin="0 0 0 0" />
</telerik:RadMenuItem.Icon>
<Grid>
<Grid.RowDefinitions>
<RowDefinition Height="Auto" />
<RowDefinition Height="Auto" />
</Grid.RowDefinitions>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="Auto" />
<ColumnDefinition Width="Auto" />
</Grid.ColumnDefinitions>
<StackPanel Orientation="Horizontal">
<telerik:RadWatermarkTextBox Grid.Row="0"
Grid.Column="0"
Height="24"
Margin="-2 2 0 2"
VerticalAlignment="Center"
SelectionOnFocus="SelectAll"
WatermarkContent="{Binding Labels[GlobalSearch]}"
Text="{Binding GlobalSearchString, Mode=TwoWay, UpdateSourceTrigger=PropertyChanged}"
Events:EventToCommandBehavior.Command="{Binding GlobalSearchTextKeyDown}"
Events:EventToCommandBehavior.Event="KeyDown"
Width="130" />
<telerik:RadButton Grid.Row="0"
Grid.Column="1"
VerticalAlignment="Center"
Margin="4 0 -2 0"
Height="24"
Command="{Binding GlobalSearchCommand}"
IsEnabled="{Binding SearchButtonEnabled, Mode=TwoWay}"
Style="{StaticResource SearchButton}" />
</StackPanel>
<CheckBox Grid.Row="1"
Grid.Column="0"
Grid.ColumnSpan="2"
Margin="-3,4,0,0"
VerticalAlignment="Center"
IsChecked="{Binding WholeWordsOnly, Mode=TwoWay}">
<TextBlock TextWrapping="Wrap"
Text="{Binding Labels[WholeWordsOnly]}"
FontSize="9.333"
VerticalAlignment="Center"
HorizontalAlignment="Center"
Margin="0,2,0,0" />
</CheckBox>
</Grid>
</telerik:RadMenuItem>
</telerik:RadMenu>
Thank you much,
John
I'm using RadMenu to create a dropdown for a global search field. The parent level displays a vector-path icon, clicking it drops down the menu with a RadWatermarkTextBox and RadButton on one line and a Checkbox/TextBlock on the next. Works great (attached-Search1.png)! The only thing is the undesirable highlight on the mouseover (attached-Search2.png). Is there a XAML attribute I can apply?
Below is the current XAML code I'm using:
<telerik:RadMenu HorizontalAlignment="Left"
Background="{StaticResource MainBrush}"
Orientation="Horizontal"
Padding="0"
Height="33"
Margin="0 0 0 0"
VerticalAlignment="Top"
ClickToOpen="True"
IconColumnWidth="0">
<telerik:RadMenuItem StaysOpenOnClick="True"
Foreground="{StaticResource MarkerBrush}">
<telerik:RadMenuItem.Icon>
<CustomShape:CustomShape Style="{StaticResource GlobalSearch}"
Margin="0 0 0 0" />
</telerik:RadMenuItem.Icon>
<Grid>
<Grid.RowDefinitions>
<RowDefinition Height="Auto" />
<RowDefinition Height="Auto" />
</Grid.RowDefinitions>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="Auto" />
<ColumnDefinition Width="Auto" />
</Grid.ColumnDefinitions>
<StackPanel Orientation="Horizontal">
<telerik:RadWatermarkTextBox Grid.Row="0"
Grid.Column="0"
Height="24"
Margin="-2 2 0 2"
VerticalAlignment="Center"
SelectionOnFocus="SelectAll"
WatermarkContent="{Binding Labels[GlobalSearch]}"
Text="{Binding GlobalSearchString, Mode=TwoWay, UpdateSourceTrigger=PropertyChanged}"
Events:EventToCommandBehavior.Command="{Binding GlobalSearchTextKeyDown}"
Events:EventToCommandBehavior.Event="KeyDown"
Width="130" />
<telerik:RadButton Grid.Row="0"
Grid.Column="1"
VerticalAlignment="Center"
Margin="4 0 -2 0"
Height="24"
Command="{Binding GlobalSearchCommand}"
IsEnabled="{Binding SearchButtonEnabled, Mode=TwoWay}"
Style="{StaticResource SearchButton}" />
</StackPanel>
<CheckBox Grid.Row="1"
Grid.Column="0"
Grid.ColumnSpan="2"
Margin="-3,4,0,0"
VerticalAlignment="Center"
IsChecked="{Binding WholeWordsOnly, Mode=TwoWay}">
<TextBlock TextWrapping="Wrap"
Text="{Binding Labels[WholeWordsOnly]}"
FontSize="9.333"
VerticalAlignment="Center"
HorizontalAlignment="Center"
Margin="0,2,0,0" />
</CheckBox>
</Grid>
</telerik:RadMenuItem>
</telerik:RadMenu>
Thank you much,
John