mirror of
https://github.com/kovidgoyal/calibre.git
synced 2025-07-09 03:04:10 -04:00
Allow running the template preferences without a gui
This commit is contained in:
parent
f54c3fba1e
commit
445066a381
@ -505,7 +505,11 @@ class ConfigWidget(ConfigWidgetBase, Ui_Form):
|
|||||||
|
|
||||||
|
|
||||||
if __name__ == '__main__':
|
if __name__ == '__main__':
|
||||||
from calibre import Application
|
from calibre.gui2 import Application
|
||||||
|
from calibre.gui2.ui import get_gui
|
||||||
|
from calibre.library import db
|
||||||
app = Application([])
|
app = Application([])
|
||||||
|
app.current_db = db()
|
||||||
|
get_gui.ans = app
|
||||||
test_widget('Advanced', 'TemplateFunctions')
|
test_widget('Advanced', 'TemplateFunctions')
|
||||||
del app
|
del app
|
||||||
|
Loading…
x
Reference in New Issue
Block a user