-
Notifications
You must be signed in to change notification settings - Fork 54
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Ability to scroll the REPL panel #60
Comments
What about Ctr+Shift+? I kind of expect it to work on terminals I use in Unix systems. |
Ah, good point. I often use Shift+PgUp/PgDown to scroll by pages. I guess Ctrl+Shift+Up/Down is sometimes used to scroll one line at a time? I have never used that and I didn't know about it until just now. |
After the refactoring of REPL history (in #253) is merged, this could be achieved by adding an offset to the latest line:
Unless I am missing something this only requires adding Ctr+ Shift+ ?, the offset and generalizing What do you think @byorgey, should I change it to |
A better way would probably be to render all of the REPL history into a scrollable It could get expensive to render the entire REPL history in memory when it gets large. We could have a (configurable?) limit to the amount you can scroll, just like most terminal apps. |
I do not see how it would be more expensive then what we do now, currently we have the whole history loaded in the memory so we could share it with brick. 😉 I am not sure if the As another though, if we add this history scrolling, then it would be nice to have a separating line above input with the " . . . " like in logger, so it would be obvious that the history is being scrolled. |
Well, having brick render the entire history (and then only show a part of it) could be more expensive.
You might be right, I don't know. We'll have to play with it.
Agreed. That is not hard to add. |
I also note that brick |
I think making a scrollable brick |
@byorgey OK, I am convinced, let REPL is not as bad as messages, there will be fewer entries and they will not get appended while you scroll. But if we figure out how to do messages well, then REPL could also benefit from a slight speedup. 🙂 |
- Add scrollbars on both the inventory and info panels - Get rid of `. . .` at top and bottom of info panel, since we now have scrollbar as a visual indicator when there is more content - Allow scrolling the REPL history (closes #60) - PgUp/PgDown can be used to scroll (Shift+PgUp/Dn were not recognized on my system) - Hitting any other key causes the view to jump back to the very bottom - A computation finishing + printing an output also causes the view to jump to the bottom - The REPL history is cached so that it only gets re-rendered whenever a new history entry (i.e. input or output) is added; this is needed since the history could get quite large. - Also, fix the height of the key hint menus to 2 lines, even when the panel-specific menu (second line) is blank, so the world panel does not keep resizing as we move the focus between panels. Thanks to @jtdaugherty for releasing `brick-1.10` with a new ability to specify blank space to the side of scrollbars; see jtdaugherty/brick#484 . Also towards #1461 .
The user can scroll through their history using up/down, but perhaps it would be nice to allow scrolling the entire REPL itself, so they can actually look at what they did in context? I am not sure of the best way to do this (maybe with the mouse?).
The text was updated successfully, but these errors were encountered: