When the file (buffer) I have open in GNU Emacs (24) has fewer lines than can be displayed in the current window (frame), I can - by default - scroll down using the scroll bar and have the top lines disappear up ("overscroll").
How can I turn this off, so I can not scroll when the entire buffer is shown in the frame?
I can patch gtkutil.c in the Emacs sources but a more elegant solution would be nice.