WPF 的列表选择器?
我正在 WPF 中开发触摸屏信息亭应用程序。我正在利用 Microsoft Surface 控件使应用程序对触摸屏更加友好,但我还没有找到 ComboBox 的良好替代品 - 这似乎是从列表中选择单个值的唯一选项之一,同时使用很少屏幕房地产。
Silverlight 中的 Windows Phone 7 工具包有一个 ListPicker,这或多或少正是我正在寻找的,但据我了解,由于它位于 Silverlight 中,所以我无法在我的 WPF 应用程序中使用它。
在我尝试从头开始构建一个控件之前,有人知道 WPF 的 ListPicker 类型控件吗?
除此之外,对于 WPF 中的触摸屏应用程序,任何人都可以选择标准 ComboBox 的替代方案吗?
编辑:澄清一下,我知道 WPF 有一个组合框,但这不是触摸屏使用的理想控件。如果您查看大多数电话或信息亭应用程序,就会尽可能避免 ComboBox 控件。这就是我提出 ListPicker 的原因(请参见此处 http://blogs.msdn.com/b/delay/archive/2010/11/03/listpicker-i-hardly-even-know-er-a-detailed-overview-of-the- windows-phone-toolkit-s-listpicker-control.aspx),因为对于这种情况,它是一个更适合触摸的控件。
I'm developing a touch screen kiosk application in WPF. I'm leveraging the Microsoft Surface controls to make the application more touchscreen friendly, but I have yet to find a good replacement for the ComboBox - which seems to be one of the only options to pick a single value from a list, while using little screen real estate.
The Windows Phone 7 toolkit, in Silverlight, has a ListPicker, which is more or less exactly what I'm looking for, but as I understand it, since it's in Silverlight, I can't use it in my WPF app.
Before I try to build one from scratch, does anyone know of a ListPicker type control for WPF?
Barring that, anyone have any preferred alternatives to the standard ComboBox for a touchscreen application in WPF?
EDIT: To clarify, I know that WPF has a ComboBox, but this is not an ideal control for touch screen use. If you look at most phone or kiosk applications, ComboBox controls are avoided where possible. This is why I brought up the ListPicker (see here http://blogs.msdn.com/b/delay/archive/2010/11/03/listpicker-i-hardly-even-know-er-a-detailed-overview-of-the-windows-phone-toolkit-s-listpicker-control.aspx), because it is a more touch-friendly control for this situation.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
您尝试过对 ListBox 进行样式设计吗?
我认为您需要做的就是删除 ScrollViewer (这可以通过使用自定义 ControlTemplate 来完成)。
这里有一个快速教程。
在这里您可以找到默认模板您需要修改它。不要被它的大小吓到——修改应该很简单。
Did you try styling ListBox?
I think all you need to do is to remove the ScrollViewer (that can be done by using a custom ControlTemplate).
Here is a quick tutorial how to do that.
Here you can find the default template which you need to modify. Don't get scared by its size - the modifications should be quite simple.