Add optional padding to single and double quotes

This commit is contained in:
Veronica K. B. Olsen
2021-03-13 23:25:20 +01:00
parent de57d0b027
commit e07a7ac496
2 changed files with 40 additions and 4 deletions
+15
View File
@@ -164,6 +164,9 @@ class Config:
self.fmtApostrophe = nwUnicode.U_RSQUO
self.fmtSingleQuotes = [nwUnicode.U_LSQUO, nwUnicode.U_RSQUO]
self.fmtDoubleQuotes = [nwUnicode.U_LDQUO, nwUnicode.U_RDQUO]
self.fmtPadSingle = False
self.fmtPadDouble = False
self.fmtPadThin = True
## Spell Checking
self.spellTool = None
@@ -578,6 +581,15 @@ class Config:
self.fmtDoubleQuotes = self._parseLine(
cnfParse, cnfSec, "fmtdoublequote", self.CNF_S_LST, self.fmtDoubleQuotes
)
self.fmtPadSingle = self._parseLine(
cnfParse, cnfSec, "fmtpadsingle", self.CNF_BOOL, self.fmtPadSingle
)
self.fmtPadDouble = self._parseLine(
cnfParse, cnfSec, "fmtpaddouble", self.CNF_BOOL, self.fmtPadDouble
)
self.fmtPadThin = self._parseLine(
cnfParse, cnfSec, "fmtpadthin", self.CNF_BOOL, self.fmtPadThin
)
self.spellTool = self._parseLine(
cnfParse, cnfSec, "spelltool", self.CNF_STR, self.spellTool
)
@@ -746,6 +758,9 @@ class Config:
cnfParse.set(cnfSec, "autoscrollpos", str(self.autoScrollPos))
cnfParse.set(cnfSec, "fmtsinglequote", self._packList(self.fmtSingleQuotes))
cnfParse.set(cnfSec, "fmtdoublequote", self._packList(self.fmtDoubleQuotes))
cnfParse.set(cnfSec, "fmtpadsingle", str(self.fmtPadSingle))
cnfParse.set(cnfSec, "fmtpaddouble", str(self.fmtPadDouble))
cnfParse.set(cnfSec, "fmtpadthin", str(self.fmtPadThin))
cnfParse.set(cnfSec, "spelltool", str(self.spellTool))
cnfParse.set(cnfSec, "spellcheck", str(self.spellLanguage))
cnfParse.set(cnfSec, "showtabsnspaces", str(self.showTabsNSpaces))