[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

GTK scrollbar position

From: Timo Savola
Subject: GTK scrollbar position
Date: Tue, 11 Apr 2006 20:00:44 +0300

I've noticed that the GTK version leaves a one-pixel gap between the
scroll bar and X window border.  This happens independent of the scroll
bar location (left/right).  When embedding Emacs into another GTK
application (using my XEmbed patches), it looks disconnected and ugly.

I tracked down the code snippet that is probably responsible for making
the crucial decision:  xterm.c:XTset_vertical_scroll_bar() places the
scroll bar at the center of the area reserved for it and in some
situations leaves empty pixels around it.

I made a patch that aligns the scroll bar to the left or right edge.  I
guess it is a matter of taste which way is best, or are there some
situations where this causes harm?  In my point of view this would be an
improvement even when not embedding Emacs.

Another approach would be to make the scroll bar's event box widget
wider; it would fill the gap by drawing background colour on the
right-hand side, but that would look ugly at least in the
scroll-bar-on-left case.


Attachment: gtk-scrollbar-position.patch
Description: Text Data

reply via email to

[Prev in Thread] Current Thread [Next in Thread]