Changeset 645


Ignore:
Timestamp:
Dec 4, 2009 5:09:38 PM (14 years ago)
Author:
toby
Message:

# on 2002/09/05 18:22:20, toby did:
trap error in localconfig and .gsas_config
add CIFselect

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/expgui

    • Property rcs:date changed from 2002/07/18 20:50:45 to 2002/09/05 18:22:20
    • Property rcs:lines changed from +7 -0 to +21 -7
    • Property rcs:rev changed from 1.57 to 1.58
    r631 r645  
    140140#---------------------------------------------------------------------------
    141141# override options with locally defined values
    142 if [file exists [file join $expgui(scriptdir) localconfig]] {
    143     source [file join $expgui(scriptdir) localconfig]
    144 }
    145 if [file exists [file join ~ .gsas_config]] {
    146     source [file join ~ .gsas_config]
     142if {[catch {
     143    if [file exists [file join $expgui(scriptdir) localconfig]] {
     144        source [file join $expgui(scriptdir) localconfig]
     145    }
     146    if [file exists [file join ~ .gsas_config]] {
     147        source [file join ~ .gsas_config]
     148    }
     149} errmsg]} {
     150    MyMessageBox -parent . -title "Customize warning" \
     151            -message "Error reading localconfig or .gsas_config: $errmsg" \
     152            -icon warning -type Ignore -default ignore \
     153            -helplink "expguierr.html Customizewarning"
    147154}
    148155SetTkDefaultOptions $expgui(font)
     
    39253932    $expgui(fm).$m.menu.cifexp add command -label FillTemplate \
    39263933            -command "exec $wishshell [file join $expgui(scriptdir) fillcif.tcl] \[file root \[file tail \$expgui(expfile)]]"
     3934    $expgui(fm).$m.menu.cifexp add command -label CIFselect \
     3935            -command {
     3936        if {[info procs CIFselect] == ""} {
     3937            source [file join $expgui(scriptdir) cifselect.tcl]
     3938        }
     3939        CIFselect $expgui(expfile)
     3940    }
    39273941    # add the commands in expgui_menulist
    39283942    foreach menu [array names expgui_menulist ] {
Note: See TracChangeset for help on using the changeset viewer.