Every project has different requirements for arranging elements on the screen. In some scenarios, it might be difficult to use the existing panels to implement the layout. Custom panels provide a means to build a custom layout pattern in a WPF application.
- [Instructor] This is the chapter where I look at…how to create custom panels.…But before I show you how to make those panels…and to use them within a WPF window,…let's talk about why you would do this.…It comes down to when you find yourself…using a certain layout pattern on the screen…more than once,…and you want to automate that process.…So here's an example:…We have the need to take our elements,…like we have here,…and put them on the screen starting from left,…and moving them to the right…and then when we fill up the size area,…we want to move down to the next row…and move from right to left.…
Then we go from left to right,…and right to left.…Also while we're moving through this layout,…I also want to increase the size…of each of the elements,…so they get bigger for each item.…Think of this as a stair-step layout,…where they get bigger,…looks like stairs climbing up stairs.…The way I did this is I created…a StackPanel, an outer StackPanel,…and then I put four child StackPanels in here.…So each of these rows is a child StackPanel.…
- Exploring the layout panels
- Working with the grid
- Adding rows and columns
- Creating scrolling content
- Controlling element visibility
- Aligning content
- Making custom layout panels
Skill Level Intermediate
Learning Visual Studio Team Serviceswith Jose Miguel Rady Allende1h 17m Intermediate
1. Layout Panels
2. Other Layout Concepts
3. Custom Layout Panel
Next steps1m 34s
- Mark as unwatched
- Mark all as unwatched
Are you sure you want to mark all the videos in this course as unwatched?
This will not affect your course history, your reports, or your certificates of completion for this course.Cancel
Take notes with your new membership!
Type in the entry box, then click Enter to save your note.
1:30Press on any video thumbnail to jump immediately to the timecode shown.
Notes are saved with you account but can also be exported as plain text, MS Word, PDF, Google Doc, or Evernote.