OpenCores
URL https://opencores.org/ocsvn/or1k/or1k/trunk

Subversion Repositories or1k

[/] [or1k/] [trunk/] [insight/] [tix/] [demos/] [samples/] [Sample.tcl] - Blame information for rev 1774

Go to most recent revision | Details | Compare with Previous | View Log

Line No. Rev Author Line
1 578 markom
# Tix Demostration Program
2
#
3
# This sample program is structured in such a way so that it can be
4
# executed from the Tix demo program "widget": it must have a
5
# procedure called "RunSample". It should also have the "if" statment
6
# at the end of this file so that it can be run as a standalone
7
# program using tixwish.
8
 
9
# REPLACE WITH DESCRIPTION OF THIS DEMO.
10
#
11
 
12
proc RunSample {w} {
13
    set top [frame $w.f -bd 1 -relief raised]
14
    set box [tixButtonBox $w.b -bd 1 -relief raised]
15
 
16
    pack $box -side bottom -fill both
17
    pack $top -side top -fill both -expand yes
18
 
19
 
20
    # Create the buttons
21
    #
22
    $box add ok     -text Ok     -command "destroy $w" -width 6
23
    $box add cancel -text Cancel -command "destroy $w" -width 6
24
}
25
 
26
if {![info exists tix_demo_running]} {
27
    wm withdraw .
28
    set w .demo
29
    toplevel $w
30
    RunSample $w
31
    bind $w <Destroy> exit
32
}

powered by: WebSVN 2.1.0

© copyright 1999-2025 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.