[IPython-dev] ipython notebook "current cell changed signal"

Trémouilles David david.trem at gmail.com
Wed Aug 27 07:04:26 EDT 2014


Yes indeed, this might be considered as a bug.
I'll let you (core developers) decide whether or not...

Is there any plan to propose and document
a kind of notebook javascript API ? (I did not
find such document in the IPython docs but
it could be that I was not enough persistent (?))

Anyway, thanks to all of you for IPython. It rocks!

David

Le 27/08/14 11:34, Thomas Kluyver a écrit :
> That could be a bug - if the events don't make sense at present, be 
> aware that we may fix them in a future release.
>
>
> On 27 August 2014 10:17, Trémouilles David <david.trem at gmail.com 
> <mailto:david.trem at gmail.com>> wrote:
>
>     OK. I have finally figured this out by myself :-)
>
>     'selected_cell_type_changed.Notebook' is
>     actually what I was looking for.
>
>     I was misled by the naming. My first thought was
>     that the 'selected_cell_type_changed.Notebook' signal
>     was /only/ triggered when the selected "cell type" was
>     changed, actually it is triggered either when the
>     "selected cell" or the "selected cell type" are changed...
>
>     Best regards,
>
>     David
>
>     Le 26/08/14 21:15, Trémouilles David a écrit :
>>     Hello,
>>
>>     In the IPython notebook, I would like to trigger a javascript
>>     function when the notebook currently selected cell changes.
>>
>>     I have found this kind of solution:
>>
>>     %%javascript
>>     $([IPython.events]).on('select.Cell', function (event, data) {
>>                console.log("changed...")
>>             });
>>
>>     However it only works when the cell is changed by clicking on
>>     another one but not when navigating with the up and down arrow
>>     key...
>>     Is there any simple solution to trigger a javascript function
>>     whenever the selected cell changes ?
>>
>>     (I'm using the current ipython github repo head.)
>>
>>     Thanks in advance,
>>
>>     David
>
>
>     _______________________________________________
>     IPython-dev mailing list
>     IPython-dev at scipy.org <mailto:IPython-dev at scipy.org>
>     http://mail.scipy.org/mailman/listinfo/ipython-dev
>
>
>
>
> _______________________________________________
> IPython-dev mailing list
> IPython-dev at scipy.org
> http://mail.scipy.org/mailman/listinfo/ipython-dev

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20140827/06845971/attachment.html>


More information about the IPython-dev mailing list