阅读背景:

为ListBox中的选定项设置背景颜色

来源:互联网 

I cannot set the background color for the selected item on a list box. I don't want the alternating colors in this example. I put them in as a test and they work. Trigger IsSelected is firing as the fontweight goes to bold and the foreground goes to red. Setting highlight color brush to SteelBlue does not achieve the desired effect as it goes away when the ListBox loses focus. Red and bold does hold when the ListBox loses focus and is what I want. I want the background color to take and hold for the selected item. Right now the background for the selected items is white and holds when the ListBox loses focus. Thanks for your help and I will test any proposed fix.I cannot set the background color for the selec




你的当前访问异常,请进行认证后继续阅读剩余内容。

分享到: