Show More
@@ -163,3 +163,21 b' c = get_config()' | |||
|
163 | 163 | # Only write to the database every n commands - this can save disk |
|
164 | 164 | # access (and hence power) over the default of writing on every command. |
|
165 | 165 | # c.HistoryManager.db_cache_size = 0 |
|
166 | ||
|
167 | #----------------------------------------------------------------------------- | |
|
168 | # QtConsole configuration | |
|
169 | #----------------------------------------------------------------------------- | |
|
170 | ||
|
171 | # set the preferred font and font size: | |
|
172 | # c.ConsoleWidget.font_family = "Anonymous Pro" | |
|
173 | # c.ConsoleWidget.font_size = 10 | |
|
174 | ||
|
175 | # set the syntax-highlighting style: | |
|
176 | # c.IPythonWidget.syntax_style = 'perldoc' | |
|
177 | ||
|
178 | # Configure the prompts: | |
|
179 | # c.IPythonWidget.in_prompt = 'In [<span class="in-prompt-number">%i</span>]: ' | |
|
180 | # c.IPythonWidget.out_prompt = 'Out[<span class="out-prompt-number">%i</span>]: ' | |
|
181 | ||
|
182 | # set the editor - this must be a *GUI* editor, like notepad/gedit/TextMate | |
|
183 | # c.IPythonWidget.editor = 'mate -w' |
@@ -222,7 +222,7 b' class IPythonQtConsoleApp(BaseIPythonApplication):' | |||
|
222 | 222 | pure = Bool(False, config=True, |
|
223 | 223 | help="Use a pure Python kernel instead of an IPython kernel.") |
|
224 | 224 | plain = Bool(False, config=True, |
|
225 | help="Use a pure Python kernel instead of an IPython kernel.") | |
|
225 | help="Use a plaintext widget instead of rich text (plain can't print/save).") | |
|
226 | 226 | |
|
227 | 227 | def _pure_changed(self, name, old, new): |
|
228 | 228 | kind = 'plain' if self.plain else 'rich' |
@@ -59,16 +59,16 b' input and the drawing eventloop.' | |||
|
59 | 59 | **************** |
|
60 | 60 | |
|
61 | 61 | An additional function, :func:`pastefig`, will be added to the global namespace if you |
|
62 |
specify the `` |
|
|
62 | specify the ``pylab`` argument. This takes the active figures in matplotlib, and embeds | |
|
63 | 63 | them in your document. This is especially useful for saving_ your work. |
|
64 | 64 | |
|
65 | 65 | .. _inline: |
|
66 | 66 | |
|
67 |
`` |
|
|
67 | ``pylab=inline`` | |
|
68 | 68 | ****************** |
|
69 | 69 | |
|
70 | 70 | If you want to have all of your figures embedded in your session, instead of calling |
|
71 |
:func:`pastefig`, you can specify `` |
|
|
71 | :func:`pastefig`, you can specify ``pylab=inline``, and each time you make a plot, it | |
|
72 | 72 | will show up in your document, as if you had called :func:`pastefig`. |
|
73 | 73 | |
|
74 | 74 | |
@@ -89,8 +89,8 b' context menu.' | |||
|
89 | 89 | |
|
90 | 90 | .. Note:: |
|
91 | 91 | |
|
92 |
Saving is only available to richtext Qt widgets, |
|
|
93 | ``--rich`` flag, or with ``--pylab``, which always uses a richtext widget. | |
|
92 | Saving is only available to richtext Qt widgets, which are used by default, but | |
|
93 | if you pass the ``--plain`` flag, saving will not be available to you. | |
|
94 | 94 | |
|
95 | 95 | |
|
96 | 96 | See these examples of :download:`png/html<figs/jn.html>` and :download:`svg/xhtml |
@@ -101,23 +101,22 b' Colors and Highlighting' | |||
|
101 | 101 | ======================= |
|
102 | 102 | |
|
103 | 103 | Terminal IPython has always had some coloring, but never syntax highlighting. There are a |
|
104 |
few simple color choices, specified by the `` |
|
|
104 | few simple color choices, specified by the ``colors`` flag or ``%colors`` magic: | |
|
105 | 105 | |
|
106 | 106 | * LightBG for light backgrounds |
|
107 | 107 | * Linux for dark backgrounds |
|
108 | 108 | * NoColor for a simple colorless terminal |
|
109 | 109 | |
|
110 |
The Qt widget has full support for the `` |
|
|
111 | aliases for the colors (the old names still work): dark=Linux, light=LightBG, bw=NoColor. | |
|
110 | The Qt widget has full support for the ``colors`` flag used in the terminal shell. | |
|
112 | 111 | |
|
113 | 112 | The Qt widget, however, has full syntax highlighting as you type, handled by the |
|
114 |
`pygments`_ library. The `` |
|
|
115 |
be found by pygments, and there are several already installed. The `` |
|
|
113 | `pygments`_ library. The ``style`` argument exposes access to any style by name that can | |
|
114 | be found by pygments, and there are several already installed. The ``colors`` argument, | |
|
116 | 115 | if unspecified, will be guessed based on the chosen style. Similarly, there are default |
|
117 |
styles associated with each `` |
|
|
116 | styles associated with each ``colors`` option. | |
|
118 | 117 | |
|
119 | 118 | |
|
120 |
Screenshot of ``ipython-qtconsole |
|
|
119 | Screenshot of ``ipython-qtconsole colors=linux``, which uses the 'monokai' theme by | |
|
121 | 120 | default: |
|
122 | 121 | |
|
123 | 122 | .. image:: figs/colors_dark.png |
@@ -129,7 +128,7 b' default:' | |||
|
129 | 128 | on your system. |
|
130 | 129 | |
|
131 | 130 | You can also pass the filename of a custom CSS stylesheet, if you want to do your own |
|
132 |
coloring, via the `` |
|
|
131 | coloring, via the ``stylesheet`` argument. The default LightBG stylesheet: | |
|
133 | 132 | |
|
134 | 133 | .. sourcecode:: css |
|
135 | 134 | |
@@ -142,6 +141,14 b' coloring, via the ``--stylesheet`` argument. The default LightBG stylesheet:' | |||
|
142 | 141 | .out-prompt { color: darkred; } |
|
143 | 142 | .out-prompt-number { font-weight: bold; } |
|
144 | 143 | |
|
144 | Fonts | |
|
145 | ===== | |
|
146 | ||
|
147 | The QtConsole has configurable via the ConsoleWidget. To change these, set the ``font_family`` | |
|
148 | or ``font_size`` traits of the ConsoleWidget. For instance, to use 9pt Anonymous Pro:: | |
|
149 | ||
|
150 | $> ipython-qtconsole ConsoleWidget.font_family="Anonymous Pro" ConsoleWidget.font_size=9 | |
|
151 | ||
|
145 | 152 | Process Management |
|
146 | 153 | ================== |
|
147 | 154 | |
@@ -160,7 +167,7 b' do not have to all be qt frontends - any IPython frontend can connect and run co' | |||
|
160 | 167 | When you start ipython-qtconsole, there will be an output line, like:: |
|
161 | 168 | |
|
162 | 169 | To connect another client to this kernel, use: |
|
163 |
- |
|
|
170 | --external shell=62109 iopub=62110 stdin=62111 hb=62112 | |
|
164 | 171 | |
|
165 | 172 | Other frontends can connect to your kernel, and share in the execution. This is great for |
|
166 | 173 | collaboration. The `-e` flag is for 'external'. Starting other consoles with that flag |
@@ -169,9 +176,9 b' have to specify each port individually, but for now this copy-paste method is be' | |||
|
169 | 176 | |
|
170 | 177 | By default (for security reasons), the kernel only listens on localhost, so you can only |
|
171 | 178 | connect multiple frontends to the kernel from your local machine. You can specify to |
|
172 |
listen on an external interface by specifying the `` |
|
|
179 | listen on an external interface by specifying the ``ip`` argument:: | |
|
173 | 180 | |
|
174 |
$> ipython-qtconsole |
|
|
181 | $> ipython-qtconsole ip=192.168.1.123 | |
|
175 | 182 | |
|
176 | 183 | If you specify the ip as 0.0.0.0, that refers to all interfaces, so any computer that can |
|
177 | 184 | see yours can connect to the kernel. |
@@ -208,10 +215,6 b' Regressions' | |||
|
208 | 215 | There are some features, where the qt console lags behind the Terminal frontend. We hope |
|
209 | 216 | to have these fixed by 0.11 release. |
|
210 | 217 | |
|
211 | * Configuration: The Qt frontend and ZMQ kernel are not yet hooked up to the IPython | |
|
212 | configuration system | |
|
213 | * History Persistence: Currently the history of a GUI session does | |
|
214 | not persist between sessions. | |
|
215 | 218 | * !cmd input: Due to our use of pexpect, we cannot pass input to subprocesses launched |
|
216 | 219 | using the '!' escape. (this will not be fixed). |
|
217 | 220 |
General Comments 0
You need to be logged in to leave comments.
Login now