[mythtv] How do I create a selectable tree widget?

Morten devel at mythtv.datascooter.com
Mon Aug 9 12:03:58 EDT 2004

Hi all!

Guess I didn't solve my question last week about how to create a selectable
tree using the standard MythUI widgets...

Here's what I want to do:

I want to create a user interface with a tree. The tree hierarchy must be
shown in one single rectangular drawing area on the screen (i.e. like the
file tree in a standard Windows File Explorer). Before each node, I want to
put a plus-sign or minus-sign to indicate whether the node is expanded or
not. (If the node isn't expandable, no sign should be shown.)

With poor man's ASCII drawing, it's something like this I want to draw in
the UI:

[-] Root node
    [+] First sub-node
    [+] Second sub-node
    [-] Third sub-node
        [+] A sub-sub-node
    [+] Fourth sub-node

I've been experimenting around with UIListTreeType, UIListType, and
UIManagedTreeListType. Depending on the widget type, it must be fed with a
GenericTree or a UIListGenericTree.... (Correct, or???)

Anyway: Since there is absolutely ZIP documentation or inline code-comments
about these widgets, I think it's a legit question to ask.... -- Just please
give me the 5 lines of code to initialize and show a fixed tree with a few
expandable nodes....

Plz help me... This is driving me absolutely nuts!


~Morten :-)

More information about the mythtv-dev mailing list