##// END OF EJS Templates
Allow docs to build without PyQt installed....
Thomas Kluyver -
Show More
@@ -3,7 +3,6 b' from IPython.utils.text import indent, wrap_paragraphs'
3 from IPython.terminal.ipapp import TerminalIPythonApp
3 from IPython.terminal.ipapp import TerminalIPythonApp
4 from IPython.kernel.zmq.kernelapp import IPKernelApp
4 from IPython.kernel.zmq.kernelapp import IPKernelApp
5 from IPython.html.notebookapp import NotebookApp
5 from IPython.html.notebookapp import NotebookApp
6 from IPython.qt.console.qtconsoleapp import IPythonQtConsoleApp
7
6
8 def document_config_options(classes):
7 def document_config_options(classes):
9 lines = []
8 lines = []
@@ -66,9 +65,16 b" if __name__ == '__main__':"
66 nbclasses = set(NotebookApp().classes) - set(kernel_classes)
65 nbclasses = set(NotebookApp().classes) - set(kernel_classes)
67 write_doc('notebook', 'IPython notebook options', nbclasses,
66 write_doc('notebook', 'IPython notebook options', nbclasses,
68 preamble="Any of the :doc:`kernel` can also be used.")
67 preamble="Any of the :doc:`kernel` can also be used.")
69 qtclasses = set(IPythonQtConsoleApp().classes) - set(kernel_classes)
68
70 write_doc('qtconsole', 'IPython Qt console options', qtclasses,
69 try:
71 preamble="Any of the :doc:`kernel` can also be used.")
70 from IPython.qt.console.qtconsoleapp import IPythonQtConsoleApp
71 except ImportError:
72 print("WARNING: Could not import qtconsoleapp. Config options for the "
73 "Qt Console will not be documented.")
74 else:
75 qtclasses = set(IPythonQtConsoleApp().classes) - set(kernel_classes)
76 write_doc('qtconsole', 'IPython Qt console options', qtclasses,
77 preamble="Any of the :doc:`kernel` can also be used.")
72
78
73 with open('source/config/options/generated', 'w'):
79 with open('source/config/options/generated', 'w'):
74 pass No newline at end of file
80 pass
General Comments 0
You need to be logged in to leave comments. Login now