<div dir="ltr"><div>The issue itself is general, but all the response are about editing, which seems for me less important then display.  My 'extension' tries to solve the display part. <br></div><br>Markdown dose not define any behavior for RTL text, and all I found online is some hacks (like the one I used). Real solution will be to extend markdown (marked?) both for implicit Right-to-left (like bidiweb is doing) and explicit (invent some 'set RTL' mark?). But that's seems for me event outside the scope of IPython. <br>

</div><div class="gmail_extra"><br><br><div class="gmail_quote">On Sun, Aug 25, 2013 at 11:05 PM, Kyle Kelley <span dir="ltr"><<a href="mailto:rgbkrk@gmail.com" target="_blank">rgbkrk@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 dir="ltr"><div><div>Oh. This is important for all the RTL languages. Great ideas.<br><br></div>It looks like @amitkot added this as an issue on GitHub: <a href="https://github.com/ipython/ipython/issues/3278" target="_blank">https://github.com/ipython/ipython/issues/3278</a>.<br>


<br></div>Wonder if there's a way to detect it when rendering it.<br></div><div class="gmail_extra"><br><br><div class="gmail_quote"><div><div class="h5">On Sun, Aug 25, 2013 at 2:54 PM, Ronen Abravanel <span dir="ltr"><<a href="mailto:ronena@gmail.com" target="_blank">ronena@gmail.com</a>></span> wrote:<br>


</div></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div><div class="h5"><div dir="ltr"><div><div><div>Hello all,<br><br></div>I'm planning a python class, and my hope is to present it as "live reavel"[1]  interactive presentation<br>


<br></div>On of my problems is that I want some of the text and explanations to be in Hebrew, e.g., be written from right to left, which markdown dose not support. <br>


<br></div>One option is to write html with dir=rtl inside the markdown block, but then I have to write all-html, which is incontinent.  <br><div><div><br></div><div>another option is to use this cool bidiweb[2]  script.<br>





</div><div>bidiweb can operate in two modes:<br></div><div>1. Process html (as returned from the markdown processor) and add dir=rtl when needed. <br></div><div>2. Post process the page  (searching for specific class and add right-to-left tags when needed)<br>





<br></div><div>In IPython 0.13, option seems cool, as pagedown, the markdown implementation used, supported post processing hook.<br><br></div><div>In IPython 1.0, I did the following:<br></div><div>custom.js:<br><br>"using strict";<br>




<br>requirejs.config({<br>    shim: {<br>        'bidiweb.style': ['bidiweb']<br>    }<br>});<br><br>$([IPython.events]).on('app_initialized.NotebookApp', function(){<br>
     require(['custom/bidiweb'],function(style){<br>        bidiweb.style('.rendered_html *');<br>     })<br><br>});<br><br><br></div><div>+custom.css with .rtl and .ltr definitions. <br></div><div><br></div>




<div>This work only partially: It's add RTL support to the markdown blocked that exists when the page is loaded, but when I add new markdown or edit existing one, the RTL is killed. <br></div><div>Is there any way to call bidiweb.style whenever a markdown blocked is update? or any good way to use mode 1 without changing IPython's code?<br>




<br><br>Thanks,<br></div><div>Ronen Abravanel<br></div>
<div><br><br><br>[1] <a href="http://www.youtube.com/watch?v=bCb2HJy-yc0" target="_blank">http://www.youtube.com/watch?v=bCb2HJy-yc0</a> I hoped it will be usable and published by the end of October. otherwise, I'll just present a notebook. <br>





[2] <a href="https://github.com/hasenj/bidiweb" target="_blank">https://github.com/hasenj/bidiweb</a><br></div></div></div>
<br></div></div>_______________________________________________<br>
IPython-dev mailing list<br>
<a href="mailto:IPython-dev@scipy.org" target="_blank">IPython-dev@scipy.org</a><br>
<a href="http://mail.scipy.org/mailman/listinfo/ipython-dev" target="_blank">http://mail.scipy.org/mailman/listinfo/ipython-dev</a><br>
<br></blockquote></div><br></div>
<br>_______________________________________________<br>
IPython-dev mailing list<br>
<a href="mailto:IPython-dev@scipy.org">IPython-dev@scipy.org</a><br>
<a href="http://mail.scipy.org/mailman/listinfo/ipython-dev" target="_blank">http://mail.scipy.org/mailman/listinfo/ipython-dev</a><br>
<br></blockquote></div><br></div>