Expanding List

Crank Storyboard Designer samples and code snippets.

Moderator: jamiev

Expanding List

Postby thomas » Thu Oct 20, 2016 12:38 pm

Another area where we see requests is to understand the best way to create a collapsible menu list. Depending on your visual requirements, there are a number of different approaches that can be taken:

* If you have a uniform set of visual content, you could use a table with cells configured as headers or items. This approach is relatively simple but will not accommodate any animated transitions, for example if you want to animate the collapse up or down.

* You could use several tables whose content is fixed to a size, each for one of the collapsible sections. This would allow you to animate the open/closing of the item, but still assumes that you are going to have completely uniform content within the table.

* You could create a series of controls that serve as templates and dynamically create control items based on a type and then manage the open/close state of the items by resynchronizing the layout of the existing controls. If this is coupled with a scrolling layer, it provides a very flexible and powerful mechanism for collapsible menu lists. Additionally you have full control of the behaviour when items in the list are selected and/or changed.

An example of such a collapsible list is provided here for you to customize.

Screen Shot 2016-10-20 at 1.36.43 PM.png
Screen Shot 2016-10-20 at 1.36.43 PM.png (126.54 KiB) Viewed 3305 times

(269.71 KiB) Downloaded 267 times
Posts: 135
Joined: Mon Nov 02, 2009 4:32 pm
Location: Ottawa

Return to Samples

Who is online

Users browsing this forum: No registered users and 1 guest