1

这是我的xaml代码...

悬停颜色仍然是开箱即用的金黄色......我做错了什么吗?我想更改它,以便我可以指定鼠标悬停的颜色。

 <telerik:RadDropDownButton Height="16" HorizontalAlignment="Left" IsOpen="False" Margin="999,16,0,0" Name="RDDLocations" VerticalAlignment="Top" Width="15" Content=" " Background="#FF25B7DB" Foreground="White" BorderThickness="0">
        <telerik:RadDropDownButton.DropDownContent>
            <telerik:RadListBox x:Name="UIOptionsList" ItemsSource="{Binding LocationItems}" Background="#FF25B7DB">
                <telerik:RadListBox.ItemTemplate>
                    <DataTemplate>
                        <telerik:RadButton>
                            <telerik:RadButton.Style>
                                <Style TargetType="telerik:RadButton">
                                    <Setter Property="BorderBrush" Value="Transparent"/>
                                    <Setter Property="Height" Value="32"/>
                                    <Setter Property="Width" Value="200"/>
                                    <Setter Property="Foreground" Value="White"/>
                                    <Setter Property="FontFamily" Value="Franklin Gothic Book"/>
                                    <Setter Property="FontSize" Value="16"/>
                                    <Setter Property="Content" Value="{Binding Text}"/>
                                    <Setter Property="ToolTip" Value="{Binding ToolTip}"/>
                                    <Setter Property="BorderThickness" Value="0"/>
                                    <Setter Property="Background" Value="Transparent"/>
                                    <Style.Triggers>
                                        <Trigger Property="IsMouseOver" Value="True">
                                            <Setter Property="Background" Value="#FF25B7DB"/>
                                            <Setter Property="Foreground" Value="Orange"/>
                                        </Trigger>
                                    </Style.Triggers>
                                </Style>
                            </telerik:RadButton.Style>
                        </telerik:RadButton>
                    </DataTemplate>
                </telerik:RadListBox.ItemTemplate>
            </telerik:RadListBox>
        </telerik:RadDropDownButton.DropDownContent>
    </telerik:RadDropDownButton>
4

1 回答 1

0

我的解决方案是使用常规按钮而不是 Telerik radbutton。

于 2013-11-06T17:15:10.040 回答