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

Subversion Repositories or1k

[/] [or1k/] [trunk/] [insight/] [tix/] [demos/] [MkDirLis.tcl] - Blame information for rev 1778

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

Line No. Rev Author Line
1 578 markom
# MkDirLis.tcl --
2
#
3
#       This file implements the "Directory List" page in the widget demo
4
#
5
#       This file has not been properly documented. It is NOT intended
6
#       to be used as an introductory demo program about Tix
7
#       programming. For such demos, please see the files in the
8
#       demos/samples directory or go to the "Samples" page in the
9
#       "widget demo"
10
#
11
#
12
# Copyright (c) 1996, Expert Interface Technologies
13
#
14
# See the file "license.terms" for information on usage and redistribution
15
# of this file, and for a DISCLAIMER OF ALL WARRANTIES.
16
#
17
 
18
proc MkDirList {nb page} {
19
    set w [$nb subwidget $page]
20
 
21
    set name [tixOptionName $w]
22
    option add *$name*TixLabelFrame*label.padX 4
23
 
24
    tixLabelFrame $w.dir  -label "tixDirList"
25
    tixLabelFrame $w.fsbox -label "tixExFileSelectBox"
26
    MkDirListWidget [$w.dir subwidget frame]
27
    MkExFileWidget  [$w.fsbox subwidget frame]
28
 
29
    tixForm $w.dir  -top 0 -left 0 -right %40 -bottom -1
30
    tixForm $w.fsbox -top 0 -left %40 -right -1 -bottom -1
31
}
32
 
33
proc MkDirListWidget {w} {
34
    set name [tixOptionName $w]
35
 
36
    message $w.msg -font -*-helvetica-bold-r-normal-*-14-*-*-*-*-*-*-*\
37
        -relief flat -width 240 -anchor n\
38
        -text {The TixDirList widget gives a graphical representation of \
39
the file system directory and makes it easy for the user to choose and \
40
access directories.}
41
 
42
    tixDirList $w.dirlist -options {
43
        hlist.padY 1
44
        hlist.width 25
45
        hlist.height 16
46
    }
47
 
48
    pack $w.msg     -side top -expand yes -fill both -padx 3 -pady 3
49
    pack $w.dirlist -side top  -padx 3 -pady 3
50
}
51
 
52
proc MkExFileWidget {w} {
53
    set name [tixOptionName $w]
54
 
55
    message $w.msg -font -*-helvetica-bold-r-normal-*-14-*-*-*-*-*-*-*\
56
        -relief flat -width 240 -anchor n\
57
        -text {The TixExFileSelectBox widget is more user friendly \
58
than the Motif style FileSelectBox.}
59
 
60
    tixExFileSelectBox $w.exfsbox -bd 2 -relief raised
61
 
62
    pack $w.msg    -side top -expand yes -fill both -padx 3 -pady 3
63
    pack $w.exfsbox -side top  -padx 3 -pady 3
64
}
65
 

powered by: WebSVN 2.1.0

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