Fixed a few bugs

This commit is contained in:
Veronica K. B. Olsen
2019-10-19 15:05:28 +02:00
parent 16401f4c1f
commit 691717ce96
3 changed files with 8 additions and 9 deletions
+2 -2
View File
@@ -27,7 +27,7 @@ class ToMarkdown(Tokenizer):
def doConvert(self):
htmlTags = {
mdTags = {
self.FMT_B_B : "**",
self.FMT_B_E : "**",
self.FMT_I_B : "_",
@@ -63,7 +63,7 @@ class ToMarkdown(Tokenizer):
elif tType == self.T_TEXT:
tTemp = tText
for xPos, xLen, xFmt in reversed(tFormat):
tTemp = tTemp[:xPos]+tTemp[xPos+xLen:]
tTemp = tTemp[:xPos]+mdTags[xFmt]+tTemp[xPos+xLen:]
tText = tTemp
tLen = len(tText)