After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 676075 - Incorrect scrollbar position after the "less" command.
Incorrect scrollbar position after the "less" command.
Status: RESOLVED FIXED
Product: vte
Classification: Core
Component: general
0.32.x
Other Linux
: Normal normal
: ---
Assigned To: VTE Maintainers
VTE Maintainers
[needed-next][commit 488d7a2d37ba66fb...
Depends on:
Blocks:
 
 
Reported: 2012-05-15 07:52 UTC by Kunshan Wang
Modified: 2014-04-06 18:20 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
screenshot (92.65 KB, image/png)
2012-05-15 07:52 UTC, Kunshan Wang
  Details
Fix (654 bytes, patch)
2013-09-29 23:57 UTC, Egmont Koblinger
committed Details | Review

Description Kunshan Wang 2012-05-15 07:52:49 UTC
Created attachment 214063 [details]
screenshot

0. Open gnome-terminal.
1. Fill the terminal with lines of texts (e.g. by using 'find /' and then interrupt). Note that the "current position" in the vertical scroll bar is at the bottom and this is correct.
2. Use the less command to read a text file (e.g. less /etc/fstab).
3. Press 'q' to quite the 'less' command.

Expected:
After 'less' exited and returned to the shell, the "current position" of the scroll bar should be at the bottom.

What actually happened:
After 'less' exited and returned to the shell, the "current position" of the scroll bar is at the top. Press the ENTER key and the position goes back to the bottom.

Always reproducible using Fedora 17 beta. gnome-terminal-3.4.1.1-1.fc17
Comment 1 Egmont Koblinger 2013-09-29 15:37:05 UTC
Confirmed with vte 0.34.8. I'll try to take a look.
Comment 2 Egmont Koblinger 2013-09-29 23:32:59 UTC
Quick workaround: remove the "if" guard (but keep the inner three lines) of vte_terminal_queue_adjustment_value_changed().

When switching screens, the screen's scroll_delta doesn't change, hence updating the scrollbar is skipped. But the scrollbar is per-terminal and not per-screen.

I'm yet to figure out the nice solution...
Comment 3 Egmont Koblinger 2013-09-29 23:57:29 UTC
Created attachment 256046 [details] [review]
Fix

Not the nicest way to fix it, but probably will do.
Comment 4 Behdad Esfahbod 2013-09-30 00:32:37 UTC
Committed to vte-0-34.  Thanks.