Branch-view - %bv[options]

In this section:

The %bv (Branch View) format is used to construct a hierarchical tree-view that is similar to %tv (Tree Control). %bv gives a control with a slightly different appearance. %bv has more options and is simpler to use because a call-back function is nolonger needed in order to change the image when expanding a node. Here is some sample code like that for %tv:

  WINAPP
  CHARACTER*30 contents(56),fmt*120
  INTEGER item,i,winio@
  DATA contents/
& 'AEBBook', 'BCAChapter 1', 'CCASection 1.1',
  ....
  item=1
  fmt='%`bv[has_buttons,has_lines,show_selection_always,'
& //'edit_labels,lines_at_root,paired_bitmaps]'
  i=winio@('%ww%sy[3d]%pv&')
  i=winio@('%ca[Branch-view]&')
  i=winio@(fmt,200,160,contents,56,item,'CLOSED,OPEN')
  END

  RESOURCES
  CLOSED BITMAP closeb.bmp
  OPEN BITMAP openb.bmp

%bv uses 16x16 bitmaps. The character array called contents is constructed in the same way as for %tv. The option paired_bitmaps indicates that the list of bitmaps 'CLOSED, OPEN' is ordered such that the bitmap for an expanded node (OPEN) follows immediately after that for the corresponding collapsed node (CLOSE). For further details see %bv (Branch View).

 

 

Basket
Empty
 
Copyright © 1999-2024 Silverfrost Limited