[IPython-User] autoscrolling such that the selected cell remains visible

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

[IPython-User] autoscrolling such that the selected cell remains visible

Christoph Groth
Dear all,

Thank you for the recent changes that made the ipython notebook
much more keyboard-friendly.

I would like to make a suggestion that IMHO would make interaction
with the notebook even more fluid: The notebook window could
scroll such that the selected cell always remains completely
visible (whenever possible, i.e. whenever that cell fits into the
window).

Already now when moving from cell to cell with the keyboard the
browser window scrolls to make cells visible.  But this is not
true for _partially_ visible cells.  (At least not for me with
IPython 2.1 and Firefox 24.)  Imagine the case where the user
moves through the notebook with the keyboard and arrives at the
last cell.  Currently, to make it completely visible, one needs to
press another key (either page-down, or insert cell below).

The selected=visible principle could be also applied to cells in
evaluation:  Once the output of the selected cell appears, I think
it would make sense to scroll such that the now larger cell
remains completely visible.

Another application: Currently, appearing output of inactive cells
can move the selected cell out of view.  Would it be possible to
scroll to keep the selected cell visible also in this case?

All the best,
Christoph
_______________________________________________
IPython-User mailing list
[hidden email]
http://mail.scipy.org/mailman/listinfo/ipython-user
Reply | Threaded
Open this post in threaded view
|

Re: autoscrolling such that the selected cell remains visible

Brian Granger-3
Christoph,

On Fri, Jun 6, 2014 at 7:13 AM, Christoph Groth
<[hidden email]> wrote:

> Dear all,
>
> Thank you for the recent changes that made the ipython notebook
> much more keyboard-friendly.
>
> I would like to make a suggestion that IMHO would make interaction
> with the notebook even more fluid: The notebook window could
> scroll such that the selected cell always remains completely
> visible (whenever possible, i.e. whenever that cell fits into the
> window).
>
> Already now when moving from cell to cell with the keyboard the
> browser window scrolls to make cells visible.  But this is not
> true for _partially_ visible cells.  (At least not for me with
> IPython 2.1 and Firefox 24.)  Imagine the case where the user
> moves through the notebook with the keyboard and arrives at the
> last cell.  Currently, to make it completely visible, one needs to
> press another key (either page-down, or insert cell below).
>
> The selected=visible principle could be also applied to cells in
> evaluation:  Once the output of the selected cell appears, I think
> it would make sense to scroll such that the now larger cell
> remains completely visible.
>
> Another application: Currently, appearing output of inactive cells
> can move the selected cell out of view.  Would it be possible to
> scroll to keep the selected cell visible also in this case?

You are right that this is a (huge) point of annoyance. However, for
the most part, I think we are convinced that what you are proposing is
not possible. The issue is that browsers make a set of decisions about
scrolling, based on the focused element that 1) we can't always
override and 2) don't always do exactly the right thing. In the past,
we have tried to "fix" some of this, but what happens is that our
logic "argues" with the browsers decisions in a way that leads to
utter chaos. In some cases, we are override the browser default
behavior, but not always (as far as we know).

That is not to say that we can't improve the UI in this area, but only
that it is just a super complicated problem (the keyboard and focus
management in the notebook is one of the most complex parts of
IPython) that has constraints that are outside our control. We welcome
people to experiment with improving the situation and we will continue
to work on it ourselves in the meantime.

Cheers,

Brian

> All the best,
> Christoph
> _______________________________________________
> IPython-User mailing list
> [hidden email]
> http://mail.scipy.org/mailman/listinfo/ipython-user



--
Brian E. Granger
Cal Poly State University, San Luis Obispo
@ellisonbg on Twitter and GitHub
[hidden email] and [hidden email]
_______________________________________________
IPython-User mailing list
[hidden email]
http://mail.scipy.org/mailman/listinfo/ipython-user