# PANEL.GUI -- Test GUI for the frame and layout widgets.
# This gui can be run as "cl> hello gui=panel.gui".

reset-server
appInitialize panel Panel {
    *objects:\
	toplevel	Frame		frame\
	frame		Layout		panel\
	panel		Frame		label1F\
	label1F		Label		label1\
	panel		Frame		label2F\
	label2F		Label		label2\
	panel		Command		button1\
	panel		Command		button2\
	panel		RadioGroup	color

    *background:				gray
    *foreground:				black

    *frame.highlightThickness:			0
    *frame.frameWidth:				2
    *frame.frameType:				chiseled
    *frame.innerOffset:				5
    *frame.outerOffset:				5

    *panel.debug:				False
    *panel.borderWidth:				0

    *panel.layout: horizontal { \
	0 < +inf > \
	vertical { \
	    5 < +inf -5 > \
	    horizontal { \
		-1 \
		label1F < +inf * +inf > \
		-1 \
	    } \
	    5 < +inf -5 > \
	    horizontal { \
		-1 \
		label2F < +inf * +inf > \
		-1 \
	    } \
	    5 < +inf -5 > \
	    horizontal {\
		-1 < +inf > \
		button1 < +inf * +inf > \
		5 < +inf -5 > \
		button2 < +inf * +inf > \
		-1 < +inf > \
	    }\
	    5 < +inf -5 > \
	} \
	0 < +inf > \
	color < +inf * +inf > \
	0 < +inf > \
    }

    *Command.highlightThickness:		0
    *Label.borderWidth:				0
    *Label.background:				gray60
    *label1*shadowWidth:			0
    *label1F.frameType:				sunken
    *label1F.frameWidth:			2
    *label2*shadowWidth:			0
    *label2F.frameType:				sunken
    *label2F.frameWidth:			2

    *color.location:				0 0 100 0
    *color.shrinkToFit:				True
    *color.outerOffset:				5
    *color.innerOffset:				5
    *color.frameWidth:				2
    *color*offIcon:				diamond0s
    *color*onIcon:				diamond1s
    *color.red.highlightColor:			red
    *color.green.highlightColor:		green
    *color.blue.highlightColor:			blue
    *color.yellow.highlightColor:		yellow
    *color.label:				Color:
    *color.labels:				|red|green|blue|yellow
    *color.selectionStyle:			multi
    *color.selection:				0

    *allowShellResize:				true
    *beNiceToColormap:				False
}

# Start up the GUI.
createObjects
activate

proc quit args { send client gkey q; deactivate unmap }
send button1 addCallback quit
