I'm using mred-designer, and am confused as to how I am supposed to get children under the appropriate tabs. All the areas I have added appear under tabs-panel, but under the first tab only. The generated code looks like this:
(set! tab-panel-123843
(new
(class tab-panel%
(super-new)
(define child-panels '())
(define/public
(add-child-panel p label)
(set! child-panels (append child-panels (list p)))
(send this append label)
(when (> (length child-panels) 1) (send this delete-child p)))
(define/public
(active-child n)
(send this change-children
(lambda (children) (list (list-ref child-panels n))))))
(parent horizontal-pane-123316)
(choices (list "Market Values" "Market Selections"))
(callback (λ (tp e) (send tp active-child (send tp get-selection))))
(style '())
(enabled #t)
(vert-margin 0)
(horiz-margin 0)
(border 0)
(spacing 0)
(alignment (list 'center 'center))
(min-width 0)
(min-height 0)
(stretchable-width #f)
(stretchable-height #t)))
All areas added with mred appear under the first tab, I can't work out how to get contents under the second tab. I have specified two 'choices', and there appears to be two tabs, but only one with children (trying to set active-child to 1 gives me an error).
Using add-child-panel creates a new tab (with contents), but I can't see how to add/change children under existing tabs? The interface won't let me create an empty tab-panel (i.e. no choices) in order to do add-child-panel from scratch.
I'm obviously missing something, so if someone could please point me in the right direction...
Thanks.