Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Folder widget

Status
Not open for further replies.

fhutt

Programmer
Jul 7, 2006
79
AU
Hello
Does anyone know of a folder widget similar to the ones shown by Windows Explorer in Windows?
I would like to create an application that required such a widget.
Thanks
fhutt
 
That depends on what you mean by "similar". Have a look at the tree widget under BWidgets.

_________________
Bob Rashkin
 
Thank you bong.
It is just the widget I need.
I now need to look for documentation that I can follow for this widget. To reverse engineer the demo is pretty hard.
Thanks again
fhutt
 
just an excerpt from the help file:
NAME
Tree - Tree widget
CREATION
Tree pathName ?option value...?
STANDARD OPTIONS
-background or -bg -borderwidth or -bd
-cursor -highlightbackground
-highlightcolor -highlightthickness
-relief -selectbackground
-selectforeground -takefocus
-xscrollcommand -yscrollcommand

WIDGET-SPECIFIC OPTIONS
-closecmd -crossfill
-crossclosebitmap -crosscloseimage
-crossopenbitmap -crossopenimage
-deltax -deltay
-dragenabled -dragendcmd
-dragevent -draginitcmd
-dragtype -dropcmd
-dropenabled -dropovercmd
-dropovermode -droptypes
-height -linesfill
-linestipple -opencmd
-padx -redraw
-selectcommand -selectfill
-showlines -width

WIDGET COMMAND
pathName bindImage event script
pathName bindText event script
pathName cget option
pathName closetree node
pathName configure ?option? ?value option value ...?
pathName delete ?arg...?
pathName edit node text ?verifycmd? ?clickres? ?select?
pathName exists node
pathName index node
pathName insert index parent node ?option value...?
pathName itemcget node option
pathName itemconfigure node ?option? ?value option value ...?
pathName move parent node index
pathName nodes node ?first? ?last?
pathName opentree node
pathName parent node
pathName reorder node neworder
pathName see node
pathName selection cmd ?arg...?
pathName toggle node
pathName visible node
pathName xview ?arg...?
pathName yview ?arg...?


--------------------------------------------------------------------------------

DESCRIPTION

Tree widget uses canvas to display a hierarchical list of items (called nodes). Each node is composed of a label with its own font and foreground attributes, and an optional image or window. Each node can have a list of subnodes, which can be collapsed or expanded. Each node is drawn in a single line, whose height is defined by the deltay option, so they must have at most this height. A node is uniquely identified by a string given at creation (by the insert command). The node named root is the root of the tree and is not drawn. The tree structure is directly maintained by the widget.


_________________
Bob Rashkin
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top