Beispiel #1
0
 def _getGrammarSettings(self):
     """Get file paths, style names, and other options from user vars."""
     logger.debug(util.funcName('begin'))
     self.outSettings = lingex_structs.InterlinOutputSettings(self.userVars)
     self.outSettings.loadUserVars()
     self.inSettings = fileitemlist.InterlinInputSettings(self.userVars)
     self.inSettings.loadUserVars()
     self.inSettings.loadOutputSettings(self.outSettings)
     logger.debug("Using %d file(s).", len(self.inSettings.fileList))
     logger.debug(util.funcName('end'))
 def setUp(self):
     self.unoObjs = testutil.unoObjsForCurrentDoc()
     self.exnumRanges = []
     USERVAR_PREFIX = "LTg_"  # for Grammar
     self.userVars = UserVars(USERVAR_PREFIX, self.unoObjs.document, logger)
     self.styles = styles.GrammarStyles(self.unoObjs, self.userVars)
     self.styles.createStyles()
     self.baseConfig = lingex_structs.InterlinOutputSettings(None)
     self.baseConfig.makeOuterTable = True
     self.baseConfig.methodFrames = True
     self.baseConfig.methodTables = False
     self.baseConfig.showOrthoTextLine = True
     self.baseConfig.showText = True
     self.baseConfig.showOrthoMorphLine = True
     self.baseConfig.showMorphemeBreaks = True
     self.baseConfig.showPartOfSpeech = True
     self.baseConfig.insertNumbering = True
     self.baseConfig.separateMorphColumns = True
     self.baseConfig.POS_aboveGloss = False
     self.baseConfig.freeTransInQuotes = True
     self.baseConfig.startingOuterRowHeight = 2
     self.baseConfig.tableBottomMargin = 0.5
     self.baseConfig.numberingColumnWidth = 5
Beispiel #3
0
 def setUp(self):
     self.unoObjs = testutil.unoObjsForCurrentDoc()
     self.exnumRanges = []
     self.userVars = UserVars(Prefix.INTERLINEAR, self.unoObjs.document,
                              logger)
     self.styles = styles.InterlinStyles(self.unoObjs, self.userVars)
     self.config = lingex_structs.InterlinOutputSettings(None)
     self.config.makeOuterTable = True
     self.config.insertNumbering = False
     self.config.methodFrames = True
     self.config.startingOuterRowHeight = 2
     self.config.numberingColumnWidth = 5
     self.config.showOrthoTextLine = False
     self.config.showText = True
     self.config.showOrthoMorphLine = False
     self.config.showMorphemeBreaks = True
     self.config.showPartOfSpeech = True
     self.config.insertNumbering = True
     self.config.separateMorphColumns = True
     self.config.POS_aboveGloss = False
     self.config.tableBottomMargin = 0
     self.styles.parastyles.createInDoc("numP")
     self.styles.styleNames = {}
     self.styles.styleNames['numP'] = 'User Index 1'