mirror of
https://github.com/ankitects/anki.git
synced 2025-09-18 22:12:21 -04:00
Merge pull request #782 from johan456789/patch-1
fix outdated help site
This commit is contained in:
commit
a4a461c17b
15 changed files with 18 additions and 18 deletions
|
@ -63,6 +63,7 @@ Jakub Kaczmarzyk <jakub.kaczmarzyk@gmail.com>
|
||||||
Akshara Balachandra <akshara.bala.18@gmail.com>
|
Akshara Balachandra <akshara.bala.18@gmail.com>
|
||||||
lukkea <github.com/lukkea/>
|
lukkea <github.com/lukkea/>
|
||||||
David Allison <davidallisongithub@gmail.com>
|
David Allison <davidallisongithub@gmail.com>
|
||||||
|
Tsung-Han Yu <johan456789@gmail.com>
|
||||||
|
|
||||||
********************
|
********************
|
||||||
|
|
||||||
|
|
|
@ -66,7 +66,7 @@ MODEL_CLOZE = 1
|
||||||
|
|
||||||
STARTING_FACTOR = 2500
|
STARTING_FACTOR = 2500
|
||||||
|
|
||||||
HELP_SITE = "https://apps.ankiweb.net/docs/manual.html"
|
HELP_SITE = "https://docs.ankiweb.net/#/"
|
||||||
|
|
||||||
# Leech actions
|
# Leech actions
|
||||||
LEECH_SUSPEND = 0
|
LEECH_SUSPEND = 0
|
||||||
|
|
|
@ -35,7 +35,6 @@ except AttributeError:
|
||||||
|
|
||||||
appVersion = _version
|
appVersion = _version
|
||||||
appWebsite = "https://apps.ankiweb.net/"
|
appWebsite = "https://apps.ankiweb.net/"
|
||||||
appChanges = "https://apps.ankiweb.net/docs/changes.html"
|
|
||||||
appDonate = "https://apps.ankiweb.net/support/"
|
appDonate = "https://apps.ankiweb.net/support/"
|
||||||
appShared = "https://ankiweb.net/shared/"
|
appShared = "https://ankiweb.net/shared/"
|
||||||
appUpdate = "https://ankiweb.net/update/desktop"
|
appUpdate = "https://ankiweb.net/update/desktop"
|
||||||
|
|
|
@ -61,7 +61,7 @@ class AddCards(QDialog):
|
||||||
self.deckChooser = aqt.deckchooser.DeckChooser(self.mw, self.form.deckArea)
|
self.deckChooser = aqt.deckchooser.DeckChooser(self.mw, self.form.deckArea)
|
||||||
|
|
||||||
def helpRequested(self):
|
def helpRequested(self):
|
||||||
openHelp("addingnotes")
|
openHelp("editing?id=adding-cards-and-notes")
|
||||||
|
|
||||||
def setupButtons(self) -> None:
|
def setupButtons(self) -> None:
|
||||||
bb = self.form.buttonBox
|
bb = self.form.buttonBox
|
||||||
|
|
|
@ -1499,7 +1499,7 @@ where id in %s"""
|
||||||
return sf
|
return sf
|
||||||
|
|
||||||
def onHelp(self):
|
def onHelp(self):
|
||||||
openHelp("browser")
|
openHelp("browsing")
|
||||||
|
|
||||||
# Misc menu options
|
# Misc menu options
|
||||||
######################################################################
|
######################################################################
|
||||||
|
@ -1939,7 +1939,7 @@ where id in %s"""
|
||||||
self.mw.taskman.run_in_background(do_search, on_done)
|
self.mw.taskman.run_in_background(do_search, on_done)
|
||||||
|
|
||||||
def onFindReplaceHelp(self):
|
def onFindReplaceHelp(self):
|
||||||
openHelp("findreplace")
|
openHelp("browsing?id=find-and-replace")
|
||||||
|
|
||||||
# Edit: finding dupes
|
# Edit: finding dupes
|
||||||
######################################################################
|
######################################################################
|
||||||
|
@ -2282,7 +2282,7 @@ Are you sure you want to continue?"""
|
||||||
QDialog.accept(self)
|
QDialog.accept(self)
|
||||||
|
|
||||||
def onHelp(self):
|
def onHelp(self):
|
||||||
openHelp("browsermisc")
|
openHelp("browsing?id=other-menu-items")
|
||||||
|
|
||||||
|
|
||||||
# Card Info Dialog
|
# Card Info Dialog
|
||||||
|
|
|
@ -828,4 +828,4 @@ Enter deck to place new %s cards in, or leave blank:"""
|
||||||
self.mw = None
|
self.mw = None
|
||||||
|
|
||||||
def onHelp(self):
|
def onHelp(self):
|
||||||
openHelp("templates")
|
openHelp("templates/intro")
|
||||||
|
|
|
@ -38,7 +38,7 @@ class DeckConf(QDialog):
|
||||||
self.setupCombos()
|
self.setupCombos()
|
||||||
self.setupConfs()
|
self.setupConfs()
|
||||||
self.setWindowModality(Qt.WindowModal)
|
self.setWindowModality(Qt.WindowModal)
|
||||||
qconnect(self.form.buttonBox.helpRequested, lambda: openHelp("deckoptions"))
|
qconnect(self.form.buttonBox.helpRequested, lambda: openHelp("deck-options"))
|
||||||
qconnect(self.form.confOpts.clicked, self.confOpts)
|
qconnect(self.form.confOpts.clicked, self.confOpts)
|
||||||
qconnect(
|
qconnect(
|
||||||
self.form.buttonBox.button(QDialogButtonBox.RestoreDefaults).clicked,
|
self.form.buttonBox.button(QDialogButtonBox.RestoreDefaults).clicked,
|
||||||
|
|
|
@ -24,7 +24,7 @@ class DeckConf(QDialog):
|
||||||
self.ok = self.form.buttonBox.addButton(label, QDialogButtonBox.AcceptRole)
|
self.ok = self.form.buttonBox.addButton(label, QDialogButtonBox.AcceptRole)
|
||||||
self.mw.checkpoint(_("Options"))
|
self.mw.checkpoint(_("Options"))
|
||||||
self.setWindowModality(Qt.WindowModal)
|
self.setWindowModality(Qt.WindowModal)
|
||||||
qconnect(self.form.buttonBox.helpRequested, lambda: openHelp("filtered"))
|
qconnect(self.form.buttonBox.helpRequested, lambda: openHelp("filtered-decks"))
|
||||||
self.setWindowTitle(_("Options for %s") % self.deck["name"])
|
self.setWindowTitle(_("Options for %s") % self.deck["name"])
|
||||||
restoreGeom(self, "dyndeckconf")
|
restoreGeom(self, "dyndeckconf")
|
||||||
self.initialSetup()
|
self.initialSetup()
|
||||||
|
|
|
@ -538,7 +538,7 @@ class Editor:
|
||||||
form = aqt.forms.edithtml.Ui_Dialog()
|
form = aqt.forms.edithtml.Ui_Dialog()
|
||||||
form.setupUi(d)
|
form.setupUi(d)
|
||||||
restoreGeom(d, "htmlEditor")
|
restoreGeom(d, "htmlEditor")
|
||||||
qconnect(form.buttonBox.helpRequested, lambda: openHelp("editor"))
|
qconnect(form.buttonBox.helpRequested, lambda: openHelp("editing?id=features"))
|
||||||
form.textEdit.setPlainText(self.note.fields[field])
|
form.textEdit.setPlainText(self.note.fields[field])
|
||||||
d.show()
|
d.show()
|
||||||
form.textEdit.moveCursor(QTextCursor.End)
|
form.textEdit.moveCursor(QTextCursor.End)
|
||||||
|
|
|
@ -221,4 +221,4 @@ class FieldDialog(QDialog):
|
||||||
self.mw.taskman.with_progress(save, on_done, self)
|
self.mw.taskman.with_progress(save, on_done, self)
|
||||||
|
|
||||||
def onHelp(self):
|
def onHelp(self):
|
||||||
openHelp("fields")
|
openHelp("editing?id=customizing-fields")
|
||||||
|
|
|
@ -36,7 +36,7 @@ class Models(QDialog):
|
||||||
self.mw.checkpoint(_("Note Types"))
|
self.mw.checkpoint(_("Note Types"))
|
||||||
self.form = aqt.forms.models.Ui_Dialog()
|
self.form = aqt.forms.models.Ui_Dialog()
|
||||||
self.form.setupUi(self)
|
self.form.setupUi(self)
|
||||||
qconnect(self.form.buttonBox.helpRequested, lambda: openHelp("notetypes"))
|
qconnect(self.form.buttonBox.helpRequested, lambda: openHelp("editing?id=adding-a-note-type"))
|
||||||
self.models: List[pb.NoteTypeNameIDUseCount] = []
|
self.models: List[pb.NoteTypeNameIDUseCount] = []
|
||||||
self.setupModels()
|
self.setupModels()
|
||||||
restoreGeom(self, "models")
|
restoreGeom(self, "models")
|
||||||
|
@ -155,7 +155,7 @@ class Models(QDialog):
|
||||||
frm.latexHeader.setText(nt["latexPre"])
|
frm.latexHeader.setText(nt["latexPre"])
|
||||||
frm.latexFooter.setText(nt["latexPost"])
|
frm.latexFooter.setText(nt["latexPost"])
|
||||||
d.setWindowTitle(_("Options for %s") % nt["name"])
|
d.setWindowTitle(_("Options for %s") % nt["name"])
|
||||||
qconnect(frm.buttonBox.helpRequested, lambda: openHelp("latex"))
|
qconnect(frm.buttonBox.helpRequested, lambda: openHelp("math?id=latex"))
|
||||||
restoreGeom(d, "modelopts")
|
restoreGeom(d, "modelopts")
|
||||||
gui_hooks.models_advanced_will_show(d)
|
gui_hooks.models_advanced_will_show(d)
|
||||||
d.exec_()
|
d.exec_()
|
||||||
|
@ -239,4 +239,4 @@ class AddModel(QDialog):
|
||||||
QDialog.accept(self)
|
QDialog.accept(self)
|
||||||
|
|
||||||
def onHelp(self) -> None:
|
def onHelp(self) -> None:
|
||||||
openHelp("notetypes")
|
openHelp("editing?id=adding-a-note-type")
|
||||||
|
|
|
@ -19,7 +19,7 @@ class Preferences(QDialog):
|
||||||
self.form.setupUi(self)
|
self.form.setupUi(self)
|
||||||
self.form.buttonBox.button(QDialogButtonBox.Help).setAutoDefault(False)
|
self.form.buttonBox.button(QDialogButtonBox.Help).setAutoDefault(False)
|
||||||
self.form.buttonBox.button(QDialogButtonBox.Close).setAutoDefault(False)
|
self.form.buttonBox.button(QDialogButtonBox.Close).setAutoDefault(False)
|
||||||
qconnect(self.form.buttonBox.helpRequested, lambda: openHelp("profileprefs"))
|
qconnect(self.form.buttonBox.helpRequested, lambda: openHelp("preferences"))
|
||||||
self.silentlyClose = True
|
self.silentlyClose = True
|
||||||
self.prefs = self.mw.col.backend.get_preferences()
|
self.prefs = self.mw.col.backend.get_preferences()
|
||||||
self.setupLang()
|
self.setupLang()
|
||||||
|
|
|
@ -481,7 +481,7 @@ create table if not exists profiles
|
||||||
with open(p, "w", encoding="utf8") as file:
|
with open(p, "w", encoding="utf8") as file:
|
||||||
file.write(
|
file.write(
|
||||||
without_unicode_isolation(
|
without_unicode_isolation(
|
||||||
tr(TR.PROFILES_FOLDER_README, link=appHelpSite + "#startupopts")
|
tr(TR.PROFILES_FOLDER_README, link=appHelpSite + "files?id=startup-options")
|
||||||
)
|
)
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
|
@ -16,7 +16,7 @@ class StudyDeck(QDialog):
|
||||||
names=None,
|
names=None,
|
||||||
accept=None,
|
accept=None,
|
||||||
title=None,
|
title=None,
|
||||||
help="studydeck",
|
help="studying?id=keyboard-shortcuts",
|
||||||
current=None,
|
current=None,
|
||||||
cancel=True,
|
cancel=True,
|
||||||
parent=None,
|
parent=None,
|
||||||
|
|
|
@ -43,7 +43,7 @@ def tr(key: TRValue, **kwargs: Union[str, int, float]) -> str:
|
||||||
def openHelp(section):
|
def openHelp(section):
|
||||||
link = aqt.appHelpSite
|
link = aqt.appHelpSite
|
||||||
if section:
|
if section:
|
||||||
link += "#%s" % section
|
link += section
|
||||||
openLink(link)
|
openLink(link)
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue