Custom Items in Lists in C# forms?
I'm a bit new to the C#-form app developing and I want know, what's the best way around at making a开发者_如何学Go control that holds a list of horizontal items. In which each of these items are horizontally ruled to it's parent control, contain a thumbnail to the left and a large text block to the right of image and a smaller text block underneath that. So basically this isn't a predefined control I can find in the toolbox. Any ideas?
You could lay this out with Panels in form controls, or with WrapPanel and StackPanel in WPF.
In WindowsForms, I would create a user control that held the correct layout for a single item, then make a list of them at run time.
In WPF I would use a List control, but set the layout template to use WrapPanels and StackPanels.
WPf is the better solution long term if you don't have to coexist with winforms
精彩评论