Skip to content

Commit d2f8e40

Browse files
committed
Add a check to the current selection at the end, not just the start.
1 parent 4d9550e commit d2f8e40

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

tkintermd/tkintermd_frame.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -383,7 +383,7 @@ def check_bold_italic(self, md_syntax, md_ignore, md_special):
383383
# Ignore items in the md_ignore variable and then deal with special
384384
# syntax individually. If string starts with anything in md_ignore do
385385
# nothing and return from the function.
386-
if str(self.cur_selection).startswith(self.md_ignore):
386+
if str(self.cur_selection).startswith(self.md_ignore) or str(self.cur_selection).endswith(self.md_ignore):
387387
return
388388
# If the formatting requires special items which can't go in md_ignore
389389
# because they cause issues with markdown being applied incorrectly.

0 commit comments

Comments
 (0)