Changeset 7 for trunk/tcl


Ignore:
Timestamp:
Mar 25, 2005, 8:22:06 AM (19 years ago)
Author:
mmc
Message:

Created an initial EnergyLevels? viewer and MoleculeViewer?. The
MoleculeViewer? is integrated into the driver, but the EnergyLevels?
is not. The material library file contains some new properties
for the appearance of atoms, and the MoleculeViewer? uses this.
Both energyLevels.tcl and moleculeViewer.tcl still have some
driver code at the bottom of the files, so you can run them as
a single file, by themselves, for testing. This code should be
removed when we get further along.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/tcl/scripts/library.tcl

    r6 r7  
    5757    }
    5858
    59     # otherwise, try to open the file and create its LibraryObj
    60     set fid [::open $fname r]
    61     set info [read $fid]
    62     close $fid
     59    if {[regexp {^<\?[Xx][Mm][Ll]} $fname]} {
     60        set info $fname
     61    } else {
     62        # otherwise, try to open the file and create its LibraryObj
     63        set fid [::open $fname r]
     64        set info [read $fid]
     65        close $fid
     66    }
    6367
    6468    set obj [Rappture::LibraryObj ::#auto $info]
Note: See TracChangeset for help on using the changeset viewer.