Re: New IPython 5 prompt

Carl Smith <[email protected]> Sun, 21 Aug 2016 16:28:20 +0000
Newsgroups gmane.comp.python.ipython.user
Message-ID <CAP-uhDc7eAogWs5U+B3TaXTz+NN9XCR6yV4GzedBU52E8tk8iQ@mail.gmail.com>
--===============9205298011532538153==
Content-Type: multipart/alternative; boundary=001a113d7b4a1349d6053a976c5a

--001a113d7b4a1349d6053a976c5a
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: quoted-printable

Cool. That's a much cleaner example, and a nice, simple prompt. Perhaps
it's worth adding a couple of simple, self contained alternative propmts
like that to IPython. People can pick one of maybe three or four, or use
them as example code to define their own.

On Sun, 21 Aug 2016 17:12 Thomas Kluyver, <[email protected]> wrote:

> Thanks Carl! FWIW, here's my startup file for custom prompts, which
> produces a more compact prompt than the default, and (IMO) a nicer look f=
or
> multiline input:
> https://gist.github.com/takluyver/85b33db0836cdcc4baf252fd81937fa7
>
> On 21 August 2016 at 17:01, Carl Smith <[email protected]> wrote:
>
>> Sorry for the noise. Just thought to share my prompt code too.
>>
>> It changes the prompt based on whether you're entering a magic or
>> command, implicitly or explicitly etc. My config runs %rehashx when IPyt=
hon
>> starts to turn all of the OS X commands into magics (except `from` as it
>> conflicts with `%autocall` and `from x import y`). My prompts class has =
a
>> method (`rehash`) for updating its list of line magics, and I have a mag=
ic
>> named `%rehash` that wraps `%rehashx` and `CustomPrompts.rehash`, for wh=
en
>> new commands are added to the system during an IPython session.
>>
>> *from IPython.core.magic import register_line_magic as line_magic*
>> *from IPython.terminal.prompts import Prompts, Token*
>>
>> *class CustomPrompts(Prompts):*
>>
>> *    def __init__(self, shell):*
>>
>> *        self.cli =3D None*
>> *        self.shell =3D shell*
>> *        self.rehash()*
>>
>> *    def rehash(self):*
>>
>> *        self.commands =3D self.shell.magics_manager.magics["line"].keys=
()*
>>
>> *    def input_prompt(self, cli):*
>>
>> *        if not cli: return "=E2=96=B9 "*
>> *        text =3D cli.buffers["DEFAULT_BUFFER"].text*
>> *        if text.startswith("%") or text.startswith("!"): return ": "*
>> *        magic =3D "\n" not in text and text.split(" ")[0] in self.comma=
nds*
>> *        return "% " if magic else "=E2=96=B9 "*
>>
>> *    def in_prompt_tokens(self, cli=3DNone): return [*
>> *        (Token.Number, "("),*
>> *        (Token.Prompt, str(self.shell.execution_count)),*
>> *        (Token.Number, ")"),*
>> *        (Token.Prompt, self.input_prompt(cli))*
>> *        ]*
>>
>>     *def out_prompt_tokens(self): return [*
>> *        (Token.Number, "("),*
>> *        (Token.OutPrompt, str(self.shell.execution_count)),*
>> *        (Token.Number, ")"),*
>> *        (Token.OutPrompt, "=E2=96=B9 ")*
>> *        ]*
>>
>> *    def continuation_prompt_tokens(self, cli=3DNone, width=3DNone):*
>> *        if width is None: width =3D self._width()*
>> *        return [(Token.Prompt, " " * (width - 5) + "   =E2=96=B9 ")]*
>>
>> *    def rewrite_prompt_tokens(self): return [*
>> *        (Token.Number, ('=E2=96=B9' * (self._width() - 2))),*
>> *        (Token.Number, '=E2=96=B9 ')*
>> *        ]*
>>
>> *@line_magic*
>> *def rehash(silent=3DFalse):*
>>
>> *    % rehashx*
>> *    del ip.magics_manager.magics["line"]["from"]*
>> *    ip.prompts.rehash()*
>> *    if not silent: print("System magic updated.")*
>>
>> *ip =3D get_ipython()*
>> *ip.prompts =3D CustomPrompts(ip)*
>>
>> *% rehash quiet*
>>
>> *del rehash*
>>
>> I know the code's a bit messy. It's just what I had, and should offer
>> enough clues to figure out how to do most things.
>>
>> Hope it helps,
>>
>> -- Carl Smith
>> [email protected]
>>
>> On 21 August 2016 at 16:36, Carl Smith <[email protected]> wrote:
>>
>>> I have this in my ipython_config file:
>>>
>>> *from pygments.token import Token*
>>>
>>> *c.TerminalInteractiveShell.highlighting_style =3D 'lovelace'*
>>>
>>> *c.TerminalInteractiveShell.highlighting_style_overrides =3D {*
>>> *    Token.Prompt: '#00cccc',*
>>> *    Token.PromptNum: '#00bbcc bold',*
>>> *    Token.OutPrompt: '#cc00cc',*
>>> *    Token.OutPromptNum: '#bb00cc bold',*
>>> *    }*
>>>
>>> With a dark background, it looks really nice. It uses a teal/cyan colou=
r
>>> for inputs and hotpink for outputs, so if you like cyan, you might like
>>> this. You can use it as a starting point at least.
>>>
>>> Best,
>>>
>>> -- Carl Smith
>>> [email protected]
>>>
>>> On 21 August 2016 at 16:27, Carl Smith <[email protected]> wrote:
>>>
>>>> On 21 August 2016 at 16:05, Thomas Kluyver <[email protected]> wrote:
>>>>
>>>>>
>>>>> We appreciate this is a bit more fiddly for simple custom prompts, bu=
t
>>>>> the advantages of using prompt_toolkit outweigh it.
>>>>>
>>>>
>>>> =E2=80=8BAgreed=E2=80=8B. It is more complex, but once you understand =
the API, you can
>>>> easily do everything you could do before, and there's some really nice=
 new
>>>> features and fixes. Prompt toolkit is awesome.
>>>>
>>>> -- Carl Smith
>>>> [email protected]
>>>>
>>>>
>>>
>>
>> _______________________________________________
>> IPython-User mailing list
>> [email protected]
>> https://mail.scipy.org/mailman/listinfo/ipython-user
>>
>> _______________________________________________
> IPython-User mailing list
> [email protected]
> https://mail.scipy.org/mailman/listinfo/ipython-user
>

--001a113d7b4a1349d6053a976c5a
Content-Type: text/html; charset=UTF-8
Content-Transfer-Encoding: quoted-printable

<p dir=3D"ltr">Cool. That&#39;s a much cleaner example, and a nice, simple =
prompt. Perhaps it&#39;s worth adding a couple of simple, self contained al=
ternative propmts like that to IPython. People can pick one of maybe three =
or four, or use them as example code to define their own. </p>
<br><div class=3D"gmail_quote"><div dir=3D"ltr">On Sun, 21 Aug 2016 17:12 T=
homas Kluyver, &lt;<a href=3D"mailto:[email protected]">[email protected]</a>=
&gt; wrote:<br></div><blockquote class=3D"gmail_quote" style=3D"margin:0 0 =
0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir=3D"ltr"><div>T=
hanks Carl! FWIW, here&#39;s my startup file for custom prompts, which prod=
uces a more compact prompt than the default, and (IMO) a nicer look for mul=
tiline input:<br><a href=3D"https://gist.github.com/takluyver/85b33db0836cd=
cc4baf252fd81937fa7" target=3D"_blank">https://gist.github.com/takluyver/85=
b33db0836cdcc4baf252fd81937fa7</a><br></div></div><div class=3D"gmail_extra=
"><br><div class=3D"gmail_quote"></div></div><div class=3D"gmail_extra"><di=
v class=3D"gmail_quote">On 21 August 2016 at 17:01, Carl Smith <span dir=3D=
"ltr">&lt;<a href=3D"mailto:[email protected]" target=3D"_blank">carl.in=
[email protected]</a>&gt;</span> wrote:<br></div></div><div class=3D"gmail_extr=
a"><div class=3D"gmail_quote"><blockquote class=3D"gmail_quote" style=3D"ma=
rgin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir=3D"lt=
r"><div class=3D"gmail_default" style=3D"font-family:monospace,monospace;fo=
nt-size:small;color:rgb(68,68,68)">Sorry for the noise. Just thought to sha=
re my prompt code too.</div><div class=3D"gmail_default" style=3D"font-fami=
ly:monospace,monospace;font-size:small;color:rgb(68,68,68)"><br></div><div =
class=3D"gmail_default" style=3D"font-family:monospace,monospace;font-size:=
small;color:rgb(68,68,68)">It changes the prompt based on whether you&#39;r=
e entering a magic or command, implicitly or explicitly etc. My config runs=
 %rehashx when IPython starts to turn all of the OS X commands into magics =
(except `from` as it conflicts with `%autocall` and `from x import y`). My =
prompts class has a method (`rehash`) for updating its list of line magics,=
 and I have a magic named `%rehash` that wraps `%rehashx` and `CustomPrompt=
s.rehash`, for when new commands are added to the system during an IPython =
session.</div><div class=3D"gmail_default" style=3D"font-family:monospace,m=
onospace;font-size:small;color:rgb(68,68,68)"><br></div><div class=3D"gmail=
_default"><font face=3D"monospace, monospace" color=3D"#444444"><b>from IPy=
thon.core.magic import register_line_magic as line_magic</b></font><br></di=
v><div class=3D"gmail_default"><span><div class=3D"gmail_default"><font fac=
e=3D"monospace, monospace" color=3D"#444444"><b>from IPython.terminal.promp=
ts import Prompts, Token</b></font></div><div class=3D"gmail_default"><font=
 face=3D"monospace, monospace" color=3D"#444444"><b><br></b></font></div><d=
iv class=3D"gmail_default"><font face=3D"monospace, monospace" color=3D"#44=
4444"><b>class CustomPrompts(Prompts):</b></font></div><div class=3D"gmail_=
default"><font face=3D"monospace, monospace" color=3D"#444444"><b><br></b><=
/font></div></span><div class=3D"gmail_default"><font face=3D"monospace, mo=
nospace" color=3D"#444444"><b>=C2=A0 =C2=A0 def __init__(self, shell):</b><=
/font></div><div class=3D"gmail_default"><font face=3D"monospace, monospace=
" color=3D"#444444"><b><br></b></font></div><div class=3D"gmail_default"><f=
ont face=3D"monospace, monospace" color=3D"#444444"><b>=C2=A0 =C2=A0 =C2=A0=
 =C2=A0 self.cli =3D None</b></font></div><div class=3D"gmail_default"><fon=
t face=3D"monospace, monospace" color=3D"#444444"><b>=C2=A0 =C2=A0 =C2=A0 =
=C2=A0 self.shell =3D shell</b></font></div><div class=3D"gmail_default"><f=
ont face=3D"monospace, monospace" color=3D"#444444"><b>=C2=A0 =C2=A0 =C2=A0=
 =C2=A0 self.rehash()</b></font></div><div class=3D"gmail_default"><font fa=
ce=3D"monospace, monospace" color=3D"#444444"><b><br></b></font></div><div =
class=3D"gmail_default"><font face=3D"monospace, monospace" color=3D"#44444=
4"><b>=C2=A0 =C2=A0 def rehash(self):</b></font></div><div class=3D"gmail_d=
efault"><font face=3D"monospace, monospace" color=3D"#444444"><b><br></b></=
font></div><div class=3D"gmail_default"><font face=3D"monospace, monospace"=
 color=3D"#444444"><b>=C2=A0 =C2=A0 =C2=A0 =C2=A0 self.commands =3D self.sh=
ell.magics_manager.magics[&quot;line&quot;].keys()</b></font></div><div cla=
ss=3D"gmail_default"><font face=3D"monospace, monospace" color=3D"#444444">=
<b><br></b></font></div><div class=3D"gmail_default"><font face=3D"monospac=
e, monospace" color=3D"#444444"><b>=C2=A0 =C2=A0 def input_prompt(self, cli=
):</b></font></div><div class=3D"gmail_default"><font face=3D"monospace, mo=
nospace" color=3D"#444444"><b><br></b></font></div><div class=3D"gmail_defa=
ult"><font face=3D"monospace, monospace" color=3D"#444444"><b>=C2=A0 =C2=A0=
 =C2=A0 =C2=A0 if not cli: return &quot;=E2=96=B9 &quot;</b></font></div><d=
iv class=3D"gmail_default"><font face=3D"monospace, monospace" color=3D"#44=
4444"><b>=C2=A0 =C2=A0 =C2=A0 =C2=A0 text =3D cli.buffers[&quot;DEFAULT_BUF=
FER&quot;].text</b></font></div><div class=3D"gmail_default"><font face=3D"=
monospace, monospace" color=3D"#444444"><b>=C2=A0 =C2=A0 =C2=A0 =C2=A0 if t=
ext.startswith(&quot;%&quot;) or text.startswith(&quot;!&quot;): return &qu=
ot;: &quot;</b></font></div><div class=3D"gmail_default"><font face=3D"mono=
space, monospace" color=3D"#444444"><b>=C2=A0 =C2=A0 =C2=A0 =C2=A0 magic =
=3D &quot;\n&quot; not in text and text.split(&quot; &quot;)[0] in self.com=
mands</b></font></div><div class=3D"gmail_default"><font face=3D"monospace,=
 monospace" color=3D"#444444"><b>=C2=A0 =C2=A0 =C2=A0 =C2=A0 return &quot;%=
 &quot; if magic else &quot;=E2=96=B9 &quot;</b></font></div><div class=3D"=
gmail_default"><font face=3D"monospace, monospace" color=3D"#444444"><b><br=
></b></font></div><div class=3D"gmail_default"><font face=3D"monospace, mon=
ospace" color=3D"#444444"><b>=C2=A0 =C2=A0 def in_prompt_tokens(self, cli=
=3DNone): return [</b></font></div><div class=3D"gmail_default"><font face=
=3D"monospace, monospace" color=3D"#444444"><b>=C2=A0 =C2=A0 =C2=A0 =C2=A0 =
(Token.Number, &quot;(&quot;),</b></font></div><div class=3D"gmail_default"=
><font face=3D"monospace, monospace" color=3D"#444444"><b>=C2=A0 =C2=A0 =C2=
=A0 =C2=A0 (Token.Prompt, str(self.shell.execution_count)),</b></font></div=
><div class=3D"gmail_default"><font face=3D"monospace, monospace" color=3D"=
#444444"><b>=C2=A0 =C2=A0 =C2=A0 =C2=A0 (Token.Number, &quot;)&quot;),</b><=
/font></div><div class=3D"gmail_default"><font face=3D"monospace, monospace=
" color=3D"#444444"><b>=C2=A0 =C2=A0 =C2=A0 =C2=A0 (Token.Prompt, self.inpu=
t_prompt(cli))</b></font></div><div class=3D"gmail_default"><font face=3D"m=
onospace, monospace" color=3D"#444444"><b>=C2=A0 =C2=A0 =C2=A0 =C2=A0 ]</b>=
</font></div><div class=3D"gmail_default"><font face=3D"monospace, monospac=
e" color=3D"#444444"><br></font></div><div class=3D"gmail_default"><font fa=
ce=3D"monospace, monospace" color=3D"#444444">=C2=A0 =C2=A0 <b>def out_prom=
pt_tokens(self): return [</b></font></div><div class=3D"gmail_default"><fon=
t face=3D"monospace, monospace" color=3D"#444444"><b>=C2=A0 =C2=A0 =C2=A0 =
=C2=A0 (Token.Number, &quot;(&quot;),</b></font></div><div class=3D"gmail_d=
efault"><font face=3D"monospace, monospace" color=3D"#444444"><b>=C2=A0 =C2=
=A0 =C2=A0 =C2=A0 (Token.OutPrompt, str(self.shell.execution_count)),</b></=
font></div><div class=3D"gmail_default"><font face=3D"monospace, monospace"=
 color=3D"#444444"><b>=C2=A0 =C2=A0 =C2=A0 =C2=A0 (Token.Number, &quot;)&qu=
ot;),</b></font></div><div class=3D"gmail_default"><font face=3D"monospace,=
 monospace" color=3D"#444444"><b>=C2=A0 =C2=A0 =C2=A0 =C2=A0 (Token.OutProm=
pt, &quot;=E2=96=B9 &quot;)</b></font></div><div class=3D"gmail_default"><f=
ont face=3D"monospace, monospace" color=3D"#444444"><b>=C2=A0 =C2=A0 =C2=A0=
 =C2=A0 ]</b></font></div><div class=3D"gmail_default"><font face=3D"monosp=
ace, monospace" color=3D"#444444"><b><br></b></font></div><div class=3D"gma=
il_default"><font face=3D"monospace, monospace" color=3D"#444444"><b>=C2=A0=
 =C2=A0 def continuation_prompt_tokens(self, cli=3DNone, width=3DNone):</b>=
</font></div><div class=3D"gmail_default"><font face=3D"monospace, monospac=
e" color=3D"#444444"><b>=C2=A0 =C2=A0 =C2=A0 =C2=A0 if width is None: width=
 =3D self._width()</b></font></div><div class=3D"gmail_default"><font face=
=3D"monospace, monospace" color=3D"#444444"><b>=C2=A0 =C2=A0 =C2=A0 =C2=A0 =
return [(Token.Prompt, &quot; &quot; * (width - 5) + &quot; =C2=A0 =E2=96=
=B9 &quot;)]</b></font></div><div class=3D"gmail_default"><font face=3D"mon=
ospace, monospace" color=3D"#444444"><b><br></b></font></div><div class=3D"=
gmail_default"><font face=3D"monospace, monospace" color=3D"#444444"><b>=C2=
=A0 =C2=A0 def rewrite_prompt_tokens(self): return [</b></font></div><div c=
lass=3D"gmail_default"><font face=3D"monospace, monospace" color=3D"#444444=
"><b>=C2=A0 =C2=A0 =C2=A0 =C2=A0 (Token.Number, (&#39;=E2=96=B9&#39; * (sel=
f._width() - 2))),</b></font></div><div class=3D"gmail_default"><font face=
=3D"monospace, monospace" color=3D"#444444"><b>=C2=A0 =C2=A0 =C2=A0 =C2=A0 =
(Token.Number, &#39;=E2=96=B9 &#39;)</b></font></div><div class=3D"gmail_de=
fault"><font face=3D"monospace, monospace" color=3D"#444444"><b>=C2=A0 =C2=
=A0 =C2=A0 =C2=A0 ]</b></font></div></div><div class=3D"gmail_default" styl=
e=3D"font-family:monospace,monospace;font-size:small;color:rgb(68,68,68)"><=
br></div><div class=3D"gmail_default"><div class=3D"gmail_default"><font fa=
ce=3D"monospace, monospace" color=3D"#444444"><b>@line_magic</b></font></di=
v><div class=3D"gmail_default"><font face=3D"monospace, monospace" color=3D=
"#444444"><b>def rehash(silent=3DFalse):</b></font></div><div class=3D"gmai=
l_default"><font face=3D"monospace, monospace" color=3D"#444444"><b><br></b=
></font></div><div class=3D"gmail_default"><font face=3D"monospace, monospa=
ce" color=3D"#444444"><b>=C2=A0 =C2=A0 % rehashx</b></font></div><div class=
=3D"gmail_default"><font face=3D"monospace, monospace" color=3D"#444444"><b=
>=C2=A0 =C2=A0 del ip.magics_manager.magics[&quot;line&quot;][&quot;from&qu=
ot;]</b></font></div><div class=3D"gmail_default"><font face=3D"monospace, =
monospace" color=3D"#444444"><b>=C2=A0 =C2=A0 ip.prompts.rehash()</b></font=
></div><div class=3D"gmail_default"><font face=3D"monospace, monospace" col=
or=3D"#444444"><b>=C2=A0 =C2=A0 if not silent: print(&quot;System magic upd=
ated.&quot;)</b></font></div><div style=3D"color:rgb(68,68,68);font-family:=
monospace,monospace;font-size:small"><b><br></b></div><div><div style=3D"co=
lor:rgb(68,68,68);font-family:monospace,monospace;font-size:small"><b>ip =
=3D get_ipython()</b></div><div style=3D"color:rgb(68,68,68);font-family:mo=
nospace,monospace;font-size:small"><b>ip.prompts =3D CustomPrompts(ip)</b><=
/div><div style=3D"color:rgb(68,68,68);font-family:monospace,monospace;font=
-size:small"><b><br></b></div><div><font face=3D"monospace, monospace" colo=
r=3D"#444444"><b>% rehash quiet</b></font><br></div><div><font face=3D"mono=
space, monospace" color=3D"#444444"><b>del rehash<br></b></font></div></div=
></div><div class=3D"gmail_default" style=3D"font-family:monospace,monospac=
e;font-size:small;color:rgb(68,68,68)"><br></div><div class=3D"gmail_defaul=
t" style=3D"font-family:monospace,monospace;font-size:small;color:rgb(68,68=
,68)">I know the code&#39;s a bit messy. It&#39;s just what I had, and shou=
ld offer enough clues to figure out how to do most things.</div><div class=
=3D"gmail_default" style=3D"font-family:monospace,monospace;font-size:small=
;color:rgb(68,68,68)"><br></div><div class=3D"gmail_default" style=3D"font-=
family:monospace,monospace;font-size:small;color:rgb(68,68,68)">Hope it hel=
ps,</div></div><div class=3D"gmail_extra"><br clear=3D"all"><div><div data-=
smartmail=3D"gmail_signature"><div dir=3D"ltr"><div><div dir=3D"ltr"><div><=
div dir=3D"ltr"><span style=3D"color:rgb(115,115,115);font-style:italic;lin=
e-height:18px"><font face=3D"monospace, monospace" size=3D"1">-- Carl Smith=
</font></span><br></div></div><div><span style=3D"color:rgb(115,115,115);fo=
nt-style:italic;line-height:18px"><font face=3D"monospace, monospace" size=
=3D"1"><a href=3D"mailto:[email protected]" target=3D"_blank">carl.input=
@gmail.com</a></font></span></div></div></div></div></div></div><div><div>
<br><div class=3D"gmail_quote">On 21 August 2016 at 16:36, Carl Smith <span=
 dir=3D"ltr">&lt;<a href=3D"mailto:[email protected]" target=3D"_blank">=
[email protected]</a>&gt;</span> wrote:<br><blockquote class=3D"gmail_qu=
ote" style=3D"margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex=
"><div dir=3D"ltr"><div class=3D"gmail_default" style=3D"font-family:monosp=
ace,monospace;font-size:small;color:rgb(68,68,68)">I have this in my ipytho=
n_config file:</div><div class=3D"gmail_default" style=3D"font-family:monos=
pace,monospace;font-size:small;color:rgb(68,68,68)"><br></div><div class=3D=
"gmail_default"><div class=3D"gmail_default" style=3D"color:rgb(68,68,68);f=
ont-family:monospace,monospace;font-size:small"><b>from pygments.token impo=
rt Token</b></div><div class=3D"gmail_default" style=3D"color:rgb(68,68,68)=
;font-family:monospace,monospace;font-size:small"><b><br></b></div><div><di=
v><font face=3D"monospace, monospace" color=3D"#444444"><b>c.TerminalIntera=
ctiveShell.highlighting_style =3D &#39;lovelace&#39;</b></font></div></div>=
<div style=3D"color:rgb(68,68,68);font-family:monospace,monospace;font-size=
:small"><div><b><br></b></div><div><b>c.TerminalInteractiveShell.highlighti=
ng_style_overrides =3D {</b></div><div><b>=C2=A0 =C2=A0 Token.Prompt: &#39;=
#00cccc&#39;,</b></div><div><b>=C2=A0 =C2=A0 Token.PromptNum: &#39;#00bbcc =
bold&#39;,</b></div><div><b>=C2=A0 =C2=A0 Token.OutPrompt: &#39;#cc00cc&#39=
;,</b></div><div><b>=C2=A0 =C2=A0 Token.OutPromptNum: &#39;#bb00cc bold&#39=
;,</b></div><div><b>=C2=A0 =C2=A0 }</b></div><div><br></div><div>With a dar=
k background, it looks really nice. It uses a teal/cyan colour for inputs a=
nd hotpink for outputs, so if you like cyan, you might like this. You can u=
se it as a starting point at least.</div><div><br></div><div>Best,</div></d=
iv></div></div><div class=3D"gmail_extra"><br clear=3D"all"><div><div data-=
smartmail=3D"gmail_signature"><div dir=3D"ltr"><div><div dir=3D"ltr"><div><=
div dir=3D"ltr"><span style=3D"color:rgb(115,115,115);font-style:italic;lin=
e-height:18px"><font face=3D"monospace, monospace" size=3D"1">-- Carl Smith=
</font></span><br></div></div><div><span style=3D"color:rgb(115,115,115);fo=
nt-style:italic;line-height:18px"><font face=3D"monospace, monospace" size=
=3D"1"><a href=3D"mailto:[email protected]" target=3D"_blank">carl.input=
@gmail.com</a></font></span></div></div></div></div></div></div><div><div>
<br><div class=3D"gmail_quote">On 21 August 2016 at 16:27, Carl Smith <span=
 dir=3D"ltr">&lt;<a href=3D"mailto:[email protected]" target=3D"_blank">=
[email protected]</a>&gt;</span> wrote:<br><blockquote class=3D"gmail_qu=
ote" style=3D"margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex=
"><div dir=3D"ltr"><span><div class=3D"gmail_default" style=3D"font-family:=
monospace,monospace;font-size:small;color:rgb(68,68,68)"><span style=3D"fon=
t-family:arial,sans-serif;color:rgb(34,34,34)">On 21 August 2016 at 16:05, =
Thomas Kluyver </span><span dir=3D"ltr" style=3D"font-family:arial,sans-ser=
if;color:rgb(34,34,34)">&lt;<a href=3D"mailto:[email protected]" target=3D"_=
blank">[email protected]</a>&gt;</span><span style=3D"font-family:arial,sans=
-serif;color:rgb(34,34,34)"> wrote:</span><br></div></span><div class=3D"gm=
ail_extra"><div class=3D"gmail_quote"><span><blockquote class=3D"gmail_quot=
e" style=3D"margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204)=
;padding-left:1ex"><div dir=3D"ltr"><span><div class=3D"gmail_extra"><div c=
lass=3D"gmail_quote"><br></div></div></span><div class=3D"gmail_extra">We a=
ppreciate this is a bit more fiddly for simple custom prompts, but the adva=
ntages of using prompt_toolkit outweigh it.</div></div></blockquote><div><b=
r></div></span><div><div class=3D"gmail_default" style=3D"font-family:monos=
pace,monospace;font-size:small;color:rgb(68,68,68)">=E2=80=8BAgreed=E2=80=
=8B. It is more complex, but once you understand the API, you can easily do=
 everything you could do before, and there&#39;s some really nice new featu=
res and fixes. Prompt toolkit is awesome.</div></div><span><font color=3D"#=
888888"><div class=3D"gmail_default" style=3D"font-family:monospace,monospa=
ce;font-size:small;color:rgb(68,68,68)"><br></div><div><div><div data-smart=
mail=3D"gmail_signature"><div dir=3D"ltr"><div dir=3D"ltr"><div><div dir=3D=
"ltr"><span style=3D"color:rgb(115,115,115);font-style:italic;line-height:1=
8px"><font face=3D"monospace, monospace" size=3D"1">-- Carl Smith</font></s=
pan><br></div></div><div><span style=3D"color:rgb(115,115,115);font-style:i=
talic;line-height:18px"><font face=3D"monospace, monospace" size=3D"1"><a h=
ref=3D"mailto:[email protected]" target=3D"_blank">[email protected]<=
/a></font></span></div><div><span style=3D"color:rgb(115,115,115);font-styl=
e:italic;line-height:18px"><br></span></div></div></div></div></div></div><=
/font></span></div></div></div>
</blockquote></div><br></div></div></div>
</blockquote></div><br></div></div></div>
<br></blockquote></div></div><div class=3D"gmail_extra"><div class=3D"gmail=
_quote"><blockquote class=3D"gmail_quote" style=3D"margin:0 0 0 .8ex;border=
-left:1px #ccc solid;padding-left:1ex">____________________________________=
___________<br>
IPython-User mailing list<br>
<a href=3D"mailto:[email protected]" target=3D"_blank">IPython-User@sc=
ipy.org</a><br>
<a href=3D"https://mail.scipy.org/mailman/listinfo/ipython-user" rel=3D"nor=
eferrer" target=3D"_blank">https://mail.scipy.org/mailman/listinfo/ipython-=
user</a><br>
<br></blockquote></div></div>
_______________________________________________<br>
IPython-User mailing list<br>
<a href=3D"mailto:[email protected]" target=3D"_blank">IPython-User@sc=
ipy.org</a><br>
<a href=3D"https://mail.scipy.org/mailman/listinfo/ipython-user" rel=3D"nor=
eferrer" target=3D"_blank">https://mail.scipy.org/mailman/listinfo/ipython-=
user</a><br>
</blockquote></div>

--001a113d7b4a1349d6053a976c5a--

--===============9205298011532538153==
Content-Type: text/plain; charset="us-ascii"
MIME-Version: 1.0
Content-Transfer-Encoding: 7bit
Content-Disposition: inline

_______________________________________________
IPython-User mailing list
[email protected]
https://mail.scipy.org/mailman/listinfo/ipython-user

--===============9205298011532538153==--