mirror of
https://github.com/ankitects/anki.git
synced 2025-09-19 14:32:22 -04:00
display helpful dialog if cloze bad
This commit is contained in:
parent
273bf8c9c6
commit
24b8ddce29
1 changed files with 8 additions and 4 deletions
|
@ -804,13 +804,17 @@ class FactEditor(object):
|
|||
self.saveFields()
|
||||
return
|
||||
else:
|
||||
ui.utils.showInfo(_("Next field must be blank."),
|
||||
parent=self.parent)
|
||||
ui.utils.showInfo(
|
||||
_("Next field must be blank."),
|
||||
help="ClozeDeletion",
|
||||
parent=self.parent)
|
||||
return
|
||||
# check if there's anything to change
|
||||
if not re.search("\[.+?\]", unicode(src.toPlainText())):
|
||||
QDesktopServices.openUrl(QUrl(ankiqt.appWiki +
|
||||
"ClozeDeletion"))
|
||||
ui.utils.showInfo(
|
||||
_("You didn't specify anything to occlude."),
|
||||
help="ClozeDeletion",
|
||||
parent=self.parent)
|
||||
return
|
||||
# create
|
||||
s = unicode(src.toHtml())
|
||||
|
|
Loading…
Reference in a new issue