blob: b6d27cefe893cffb2d02d1c39ae30904efbbec76 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
|
# Copyright (C) 1999 - Martin Strauss - under terms of GPL
################################################################
# Options
################################################################
proc SaveOptions {} {
global wsearch_gb KlammerFlag syntax_flag log_flag Package inifile myown Tcltexed_Version language tft_size
set f [open $inifile w]
#Get text to save
lappend liste $Tcltexed_Version $wsearch_gb $KlammerFlag $syntax_flag $log_flag "[array get Package]" "[array get myown]" $language $tft_size
#Save it
puts $f $liste
#and close file
close $f
}
################################################################
proc LoadOptions {} {
global wsearch_gb KlammerFlag syntax_flag log_flag Package PLISTE bhtpath I_flag inifile myown Tcltexed_Version language tft_size
foreach {i n} $PLISTE {
set Package($i) 0
}
set Package(latex) 1
if [file exists $inifile] then {
set f [open $inifile r]
#Get text to save
set liste [gets $f]
if {[lindex $liste 0] == $Tcltexed_Version} {
set wsearch_gb [lindex $liste 1]
set KlammerFlag [lindex $liste 2]
set syntax_flag [lindex $liste 3]
set log_flag [lindex $liste 4]
array set Package [lindex $liste 5]
array set myown [lindex $liste 6]
set language [lindex $liste 7]
set tft_size [lindex $liste 8]
}
close $f
}
foreach {i n} $PLISTE {
if $Package($i) then {
set I_file $bhtpath/$i.bht
set I_flag 1
source $bhtpath/$i.bht
}
}
}
|