Ignore:
Timestamp:
Oct 18, 2013 4:00:32 PM (8 years ago)
Author:
toby
Message:

rework exports for new types

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/exports/G2export_shelx.py

    r1102 r1115  
    2626        super(self.__class__,self).__init__( # fancy way to say <parentclass>.__init__
    2727            G2frame=G2frame,
    28             formatName = 'SHELX',
     28            formatName = 'SHELX .ins',
    2929            extension='.ins',
    3030            longFormatName = 'Export phase as SHELX .ins file'
     
    3838        import re
    3939        # the export process starts here
     40        self.InitExport(event)
    4041        # load all of the tree into a set of dicts
    4142        self.loadTree()
    4243        # create a dict with refined values and their uncertainties
    4344        self.loadParmDict()
    44         if self.SetupExport(event,                         # set export parameters
    45                             AskFile=True
    46                             ): return
     45        if self.ExportSelect(  # set export parameters
     46            AskFile=True): return
    4747        for phasenam in self.phasenam:
    4848            phasedict = self.Phases[phasenam] # pointer to current phase info           
     
    5656            # title line
    5757            self.Write("TITL from "+str(self.G2frame.GSASprojectfile)+", phase "+str(phasenam))
    58             # get & write cell parameters
    59             pfx = str(phasedict['pId'])+'::'
    60             A,sigA = G2stIO.cellFill(pfx,phasedict['General']['SGData'],self.parmDict,self.sigDict)
    61             self.Write("CELL 0.5 {:.5f} {:.5f} {:.5f} {:.3f} {:.3f} {:.3f}".format(*G2lat.A2cell(A)))
     58            # get & write cell parameters
     59            cell,sig = self.GetCell(phasenam)
     60            self.Write("CELL 0.5 {:.5f} {:.5f} {:.5f} {:.3f} {:.3f} {:.3f}".format(*cell[:6]))
    6261            # Shelx lattice number
    6362            lattnum = {'P':1,'I':2,'R':2,'F':3,'A':4,'B':5,'C':6}.get(phasedict['General']['SGData']['SGLatt'],0)
Note: See TracChangeset for help on using the changeset viewer.