<br><br><div class="gmail_quote">On Wed, Aug 29, 2012 at 2:25 PM, G B <span dir="ltr"><<a href="mailto:g.c.b.at.work@gmail.com" target="_blank">g.c.b.at.work@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
Excellent! I went with the tarball option, and after fiddling a bit realized I needed to move aside the eggs left behind by the Superpack. After that, I now have an italic h3.<div><br></div><div>Thanks for the handholding on this-- I'm a step closer to my dream of live documentation.</div>
<div><br></div><div>If I can ask a few follow up questions:</div><div><br></div>What other customizations can be put into the static directory-- javascript? Or is this css only?<br></blockquote><div><br></div><div>You can override literally everything in the static dir (js or css). CSS is obviously a lot less hazardous than js, so do that at your own risk,</div>
<div>but for instance you can use this to install local mathjax, or test out a newer release of CodeMirror or jQuery without touching the IPython install.</div><div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<br><div>In an attempt to check for myself, I did a 'ipython profile create foo' from the command line, and the generated profile_foo directory does not contain a 'static' subdirectory. An earlier comment suggested that there should be one. Is there still a remnant of the old install interfering?</div>
</blockquote><div><br></div><div>No, my comment was unclear. I only meant to imply that `custom.css` should never return a 404, because it exists, regardless of whether you create your own in a profile.</div><div><br></div>
<div>Creating a profile does not create a static dir.</div><div><br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div class="HOEnZb"><div class="h5">
<div><br></div><div><br></div><div><br></div><div><br></div><div><div class="gmail_quote">On Mon, Aug 27, 2012 at 4:02 PM, MinRK <span dir="ltr"><<a href="mailto:benjaminrk@gmail.com" target="_blank">benjaminrk@gmail.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><br><br><div class="gmail_quote"><div>On Mon, Aug 27, 2012 at 3:52 PM, G B <span dir="ltr"><<a href="mailto:g.c.b.at.work@gmail.com" target="_blank">g.c.b.at.work@gmail.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div>Interesting-- I had to create the static directory in my profile, so I'm probably not using master. I think I installed this from here: </div><div><a href="http://fonnesbeck.github.com/ScipySuperpack/" target="_blank">http://fonnesbeck.github.com/ScipySuperpack/</a></div>
<div>though, sadly, I might be remembering that wrong. It was a weekend of great frustration as I updated to Mountain Lion and then rebuilt a gazillion tools I use daily. If I remember correctly, that installer made my life very much more pleasant-- but I'd long since forsaken careful documentation of my installation procedures in favor of flailing madly to get the *#^$ thing working again.</div>
<div><br></div></blockquote><div><br></div></div><div>Superpack is great, but it's everything up to date *as of the superpack build*, and the custom js/css was introduced since the one you installed.</div><div>
<div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div></div><div>Anyway, leaving the epic tales to the minstrels and returning to the point:</div>`import IPython; print IPython.sys_info()` returns:<div><div style="vertical-align:baseline;line-height:17px;color:rgb(34,34,34);text-align:right;font:inherit;width:11ex;font-family:monospace;margin:0px;border:0px;padding:0.4em">
</div><div style="vertical-align:baseline;line-height:17px;text-align:left;font:inherit;font-family:monospace;margin:0px;border:0px;padding:0em 0.4em">
<pre style="margin-top:0px;margin-bottom:0px;padding:0px;border:0px;font:inherit;vertical-align:baseline;font-family:monospace,sans-serif;white-space:pre-wrap">{'commit_hash': '6ed621a',
'commit_source': 'installation',
'default_encoding': 'UTF-8',
'ipython_path': '/Library/Python/2.7/site-packages/ipython-0.14.dev-py2.7.egg/IPython',
'ipython_version': '0.14.dev',
'os_name': 'posix',
'platform': 'Darwin-12.1.0-x86_64-i386-64bit',
'sys_executable': '/usr/bin/python',
'sys_platform': 'darwin',
'sys_version': '2.7.2 (default, Jun 20 2012, 16:23:33) \n[GCC 4.2.1 Compatible Apple Clang 4.0 (tags/Apple/clang-418.0.60)]'}</pre></div></div></blockquote><div><br></div></div><div>That's too old. You can update to current IPython master with:</div>
<div><br></div><div>pip install <a href="https://github.com/ipython/ipython/tarball/master" target="_blank">https://github.com/ipython/ipython/tarball/master</a></div><div><br></div><div>or to stay up to date:</div><div>
<br></div><div>git clone git://<a href="http://github.com/ipython/ipython" target="_blank">github.com/ipython/ipython</a></div>
<div>cd ipython</div><div>python setupegg.py develop</div><div><br></div><div><br></div><div>Then just `git pull` in the ipython dir when you want to update.</div><div><div><div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div><div style="vertical-align:baseline;line-height:17px;text-align:left;font:inherit;font-family:monospace;margin:0px;border:0px;padding:0em 0.4em"><pre style="margin-top:0px;margin-bottom:0px;padding:0px;border:0px;font:inherit;vertical-align:baseline;font-family:monospace,sans-serif;white-space:pre-wrap">
<br></pre><pre style="margin-top:0px;margin-bottom:0px;padding:0px;border:0px;font:inherit;vertical-align:baseline;font-family:monospace,sans-serif;white-space:pre-wrap"><br></pre><pre style="margin-top:0px;margin-bottom:0px;padding:0px;border:0px;font:inherit;vertical-align:baseline;font-family:monospace,sans-serif;white-space:pre-wrap">
(Taking a tangent again: I guess I've been over conditioned by exposure to Apple on the iPython vs IPython spellings. My fingers have been quite stubborn about demoting the case of the leading 'I', forcing me to always have to re-edit the cell every time I type "import iPython". You'd think the pain would force a change in behavior, but...)</pre>
<pre style="margin-top:0px;margin-bottom:0px;padding:0px;border:0px;font:inherit;vertical-align:baseline;font-family:monospace,sans-serif;white-space:pre-wrap"><br></pre><pre style="margin-top:0px;margin-bottom:0px;padding:0px;border:0px;font:inherit;vertical-align:baseline;font-family:monospace,sans-serif;white-space:pre-wrap">
<br></pre></div><div><div><br><div class="gmail_quote">On Mon, Aug 27, 2012 at 3:27 PM, MinRK <span dir="ltr"><<a href="mailto:benjaminrk@gmail.com" target="_blank">benjaminrk@gmail.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<br><br><div class="gmail_quote"><div>On Mon, Aug 27, 2012 at 3:02 PM, G B <span dir="ltr"><<a href="mailto:g.c.b.at.work@gmail.com" target="_blank">g.c.b.at.work@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div>Back at it after the weekend...</div><div><br></div><a href="http://127.0.0.1:8888/static/css/custom.css" target="_blank">http://127.0.0.1:8888/static/css/custom.css</a><br>returns a 404, page not found<div><br></div>
</blockquote><div><br></div></div><div><div>What do you get from `import IPython; print IPython.sys_info()`?</div><div><br></div><div>Because if that's giving a 404, then you are probably not using master, which is where this was introduced. That file exists, whether or not you have defined one in your profile.</div>
</div><div><div><br></div><div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div></div>
<div>Inspecting the elements show no evidence of picking up my custom.css file either. I'm pretty sure I'm placing things in the right profile (profile_default) as I'm not including a --profile flag on startup and the kernel information is being put into ~/.python/profile_default/security as I'd expect.</div>
</blockquote><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div><br></div><div>I don't know if this makes a difference, but I've set c.NotebookManager.notebook_dir to ~/Documents/iPython Notebooks/</div></blockquote><div><br></div></div><div>It doesn't, but then again, there is no such thing as an iPython Notebook. There are IPython Notebooks, though :)</div>
<span><font color="#888888">
<div> </div><div>-MinRK</div></font></span><div><div><div><br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div><div><div><br><br><br><br><div class="gmail_quote">
On Sat, Aug 25, 2012 at 1:42 AM, Matthias BUSSONNIER <span dir="ltr"><<a href="mailto:bussonniermatthias@gmail.com" target="_blank">bussonniermatthias@gmail.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><br>
Le 25 août 2012 à 01:43, G B a écrit :<br>
<div><br>
> It doesn't seem to be getting picked up. I'm running iPython 0.14 on OS X 10.8.1, browsing from Safari.<br>
><br>
> Just to make sure I'm not being overly literal in interpreting your response:<br>
><br>
> My configuration directory is ~/.ipython<br>
><br>
> I've put a file called 'custom.css' into ~/.ipython/profile_default/static/css/<br>
><br>
> I also created a directory tree at ~/.ipython/profile/profile_default/static/css/ but that also didn't work. I believe the tree at ~/.ipython/profile_default/ is the correct one, but I'd like to confirm that.<br>
</div>You are right on this one.<br>
<div><br>
<br>
><br>
> In custom.css, I put a simple:<br>
> h3 {font-style:italic;}<br>
<br>
</div>I did the same and it works for me<br>
.ipython/profile_default/static/css/custom.css<br>
<div><br>
><br>
> Looking at the page as loaded, the h3 elements do not carry the italic style, and the custom.css style doesn't seem to be included at all. Do I need to change a configuration parameter somewhere to tell iPython to look for custom.css?<br>
</div>Any file in<br>
.ipython/profile_default/static/<br>
will overwrite their equivalent if you launch profile_default of course.<br>
otherwise put the files in the correct profile or make a symlink.<br>
<div><br>
> I've closed the open notebook pages and shut down the notebook server and the relaunched the server, which opens a fresh page. Do I need to do all that, or just refresh the page to pick up a new custom.css?<br>
</div>>From the test I did, you don't have to restart, just reload.<br>
<div><br>
> I'm pretty much new to everything I'm doing here-- I'm not a seasoned Python developer, I've been using iPython for days, I've only toyed with HTML and CSS in the past... It's quite likely that I'm doing something wrong at a very basic level.<br>
> Any ideas? Thanks for the patience...<br>
<br>
</div>what does<br>
<a href="http://127.0.0.1:8888/static/css/custom.css" target="_blank">http://127.0.0.1:8888/static/css/custom.css</a><br>
give you ? Your file or not ?<br>
<br>
Try Safari "web inspector" (Dev menu > web inspector, or Cmd+Alt+i)<br>
First tab (Element)<br>
Click Magnifying glass at the bottom and click on a h3 element.<br>
You should be able to inspect its css, where it inherits from on the right now ... etc<br>
It's a little difficult to explain by mail but by looking at the difference tabs you should be able to determine which file is loaded and why a css is not applied to an element.<br>
<br>
keep us informed.<br>
<span><font color="#888888">--<br>
Matthias<br>
</font></span><div><div><br>
><br>
> Thanks--<br>
> Greg<br>
><br>
> On Fri, Aug 24, 2012 at 1:14 AM, Matthias BUSSONNIER <<a href="mailto:bussonniermatthias@gmail.com" target="_blank">bussonniermatthias@gmail.com</a>> wrote:<br>
><br>
> Le 24 août 2012 à 01:36, G B a écrit :<br>
><br>
> > Is there a way to modify the notebook stylesheet? I'd like to emphasize the markdown cells and de-emphasize the code cells to make for a more human readable document... The config file doesn't seem to list a parameter for the stylesheet though.<br>
> Which version are you using ?<br>
> In 0.12-0.13 the easiest is to write CSS in a markdown cell.<br>
> In 0.14 you can overwrite the default css or ad your own on a per profile basis<br>
> by creating a .ipython/profile/profile_xxx/static/css/custom.css file with the rules you want inside.<br>
> --<br>
> Matthias<br>
><br>
><br>
> ><br>
> > Thanks!<br>
> > Greg<br><br>
_______________________________________________<br>
IPython-User mailing list<br>
<a href="mailto:IPython-User@scipy.org" target="_blank">IPython-User@scipy.org</a><br>
<a href="http://mail.scipy.org/mailman/listinfo/ipython-user" target="_blank">http://mail.scipy.org/mailman/listinfo/ipython-user</a><br>
</div></div></blockquote></div><br></div></div></div>
<br>_______________________________________________<br>
IPython-User mailing list<br>
<a href="mailto:IPython-User@scipy.org" target="_blank">IPython-User@scipy.org</a><br>
<a href="http://mail.scipy.org/mailman/listinfo/ipython-user" target="_blank">http://mail.scipy.org/mailman/listinfo/ipython-user</a><br>
<br></blockquote></div></div></div><br>
<br>_______________________________________________<br>
IPython-User mailing list<br>
<a href="mailto:IPython-User@scipy.org" target="_blank">IPython-User@scipy.org</a><br>
<a href="http://mail.scipy.org/mailman/listinfo/ipython-user" target="_blank">http://mail.scipy.org/mailman/listinfo/ipython-user</a><br>
<br></blockquote></div><br></div></div></div>
<br>_______________________________________________<br>
IPython-User mailing list<br>
<a href="mailto:IPython-User@scipy.org" target="_blank">IPython-User@scipy.org</a><br>
<a href="http://mail.scipy.org/mailman/listinfo/ipython-user" target="_blank">http://mail.scipy.org/mailman/listinfo/ipython-user</a><br>
<br></blockquote></div></div></div><br>
<br>_______________________________________________<br>
IPython-User mailing list<br>
<a href="mailto:IPython-User@scipy.org" target="_blank">IPython-User@scipy.org</a><br>
<a href="http://mail.scipy.org/mailman/listinfo/ipython-user" target="_blank">http://mail.scipy.org/mailman/listinfo/ipython-user</a><br>
<br></blockquote></div><br></div>
</div></div><br>_______________________________________________<br>
IPython-User mailing list<br>
<a href="mailto:IPython-User@scipy.org">IPython-User@scipy.org</a><br>
<a href="http://mail.scipy.org/mailman/listinfo/ipython-user" target="_blank">http://mail.scipy.org/mailman/listinfo/ipython-user</a><br>
<br></blockquote></div><br>