<html>
<head>
<meta content="text/html; charset=ISO-8859-1"
http-equiv="Content-Type">
</head>
<body bgcolor="#FFFFFF" text="#000000">
OK. I have finally figured this out by myself :-)<br>
<br>
'selected_cell_type_changed.Notebook' is<br>
actually what I was looking for.<br>
<br>
I was misled by the naming. My first thought was<br>
that the 'selected_cell_type_changed.Notebook' signal<br>
was <i>only</i> triggered when the selected "cell type" was<br>
changed, actually it is triggered either when the<br>
"selected cell" or the "selected cell type" are changed...<br>
<br>
Best regards,<br>
<br>
David<br>
<br>
<div class="moz-cite-prefix">Le 26/08/14 21:15, Trémouilles David a
écrit :<br>
</div>
<blockquote cite="mid:53FCDCCB.3090208@gmail.com" type="cite">Hello,
<br>
<br>
In the IPython notebook, I would like to trigger a javascript
<br>
function when the notebook currently selected cell changes.
<br>
<br>
I have found this kind of solution:
<br>
<br>
%%javascript
<br>
$([IPython.events]).on('select.Cell', function (event, data) {
<br>
console.log("changed...")
<br>
});
<br>
<br>
However it only works when the cell is changed by clicking on
<br>
another one but not when navigating with the up and down arrow
key...
<br>
Is there any simple solution to trigger a javascript function
<br>
whenever the selected cell changes ?
<br>
<br>
(I'm using the current ipython github repo head.)
<br>
<br>
Thanks in advance,
<br>
<br>
David
<br>
</blockquote>
<br>
</body>
</html>