c# - WPF 中的 float 项目

标签 c# wpf wpf-controls floating

我如何创建一个控件容器,其中每个项目(控件)的行为都像一个 float DIV(在 HTML 中),像这样 video (考虑到每个文件夹都是一个控件)?

最佳答案

看看 WrapPanel 类。 MSDN

它具有您正在寻找的功能。

Positions child elements in sequential position from left to right, breaking content to the next line at the edge of the containing box. Subsequent ordering happens sequentially from top to bottom or from right to left, depending on the value of the Orientation property.

关于c# - WPF 中的 float 项目,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/13022728/

相关文章:

c# - 检索(验证)字符串的一部分

c# - 如何更改 ViewCell 中的高度

c# - BitmapImage:访问关闭的 StreamSource

wpf - XAML 'NOT' 运算符?

c# - WPF 工具包图表 - Series.Clear() 后的 NullReferenceException

wpf - 如何更改子控件xaml的背景颜色

c# - 从代码运行 SpecFlow 场景

c# - 从 LinkedList<T> 快速删除项目

wpf - WPF 中的无边框窗口

c# - System.Windows.Baml2006.TypeConverterMarkupExtension' 抛出异常 .' Line number ' 6' and line position ' 10