在WPF,XAML中,我有一种样式已应用于ComboBox的项目,我想获取当前项目的Content属性,但这似乎不起作用:
<dxe:ComboBoxEdit.Items>
<Style TargetType="{x:Type dxe:ComboBoxEditItem}">
<Style.Setters>
<Setter Property="Content" Value="{Binding Converter={StaticResource CrsNameCvtor}, ConverterParameter={Binding Content,RelativeSource={RelativeSource Self}}}"/>
</Style.Setters>
</Style>
</dxe:ComboBoxEdit.Items>
答案 0 :(得分:1)
应将样式分配给ComboBox的fmap read getLine
属性,并且根本不需要设置绑定的ConverterParameter:
main :: IO [Int]
main = do
let size = 3
replicateM size readLn