unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
* Huge gap between fringe and scroll-bar
@ 2007-01-01  8:07 Leo
  2007-01-01 12:46 ` Jan Djärv
  0 siblings, 1 reply; 10+ messages in thread
From: Leo @ 2007-01-01  8:07 UTC (permalink / raw)


[-- Attachment #1: Type: text/plain, Size: 379 bytes --]

Emacs's native scroll-bar (--without-toolkit-scroll-bars) can have a
huge gap between fringe and scroll-bar. To see this:

  emacs -Q -l sb.el

Where sb.el has:
,----[ sb.el ]
| (setq initial-frame-alist
|       '((scroll-bar-width . 10)))
`----

As you can see the gap between the fringe and scroll-bar is close to
8 pixels. I see no gap for gtk scroll-bar though.

Screenshot:

[-- Attachment #2: E.png --]
[-- Type: image/png, Size: 284 bytes --]

[-- Attachment #3: Type: text/plain, Size: 37 bytes --]

To compare:

  emacs -Q

Screenshot:

[-- Attachment #4: E0.png --]
[-- Type: image/png, Size: 283 bytes --]

[-- Attachment #5: Type: text/plain, Size: 129 bytes --]


BTW, can I set scroll-bar width in X resource file?

-- 
Leo <sdl.web AT gmail.com>                         (GPG Key: 9283AA3F)

[-- Attachment #6: Type: text/plain, Size: 142 bytes --]

_______________________________________________
Emacs-devel mailing list
Emacs-devel@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-devel

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: Huge gap between fringe and scroll-bar
  2007-01-01  8:07 Huge gap between fringe and scroll-bar Leo
@ 2007-01-01 12:46 ` Jan Djärv
  2007-01-01 18:02   ` Leo
  0 siblings, 1 reply; 10+ messages in thread
From: Jan Djärv @ 2007-01-01 12:46 UTC (permalink / raw)
  Cc: emacs-devel

Leo skrev:
> Emacs's native scroll-bar (--without-toolkit-scroll-bars) can have a
> huge gap between fringe and scroll-bar. To see this:
> 
>   emacs -Q -l sb.el
> 
> Where sb.el has:
> ,----[ sb.el ]
> | (setq initial-frame-alist
> |       '((scroll-bar-width . 10)))
> `----
> 
> As you can see the gap between the fringe and scroll-bar is close to
> 8 pixels. I see no gap for gtk scroll-bar though.

The scroll bar width for the scroll bars are constrained to be equal to an
even character width.  So if you say scroll bar width 10, it is padded to an
even character width.  The GTK scroll bar is also padded, but it divides the
padding evenly at the left and right side of the scroll bar.  You can clearly
see this if you run Emacs with a different background, like

% emacs -bg gray50 -Q -xrm 'Emacs.scrollBarWidth: 10'

and then change the character size to different sizes (use the font menu at
Shift-Mouse-1 for example).

> 
> BTW, can I set scroll-bar width in X resource file?
> 

See above.

	Jan D.

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: Huge gap between fringe and scroll-bar
  2007-01-01 12:46 ` Jan Djärv
@ 2007-01-01 18:02   ` Leo
  2007-01-01 18:56     ` Jan Djärv
  2007-01-02  3:10     ` Richard Stallman
  0 siblings, 2 replies; 10+ messages in thread
From: Leo @ 2007-01-01 18:02 UTC (permalink / raw)


* Jan Djärv (2007-01-01 13:46 +0100) said:
  ^^^^^^^^^
> Leo skrev:
>> Emacs's native scroll-bar (--without-toolkit-scroll-bars) can have a
>> huge gap between fringe and scroll-bar. To see this:
>> 
>
>>   emacs -Q -l sb.el
>> 
>> Where sb.el has:
>> ,----[ sb.el ]
>> | (setq initial-frame-alist
>> |       '((scroll-bar-width . 10)))
>> `----
>> 
>> As you can see the gap between the fringe and scroll-bar is close to
>> 8 pixels. I see no gap for gtk scroll-bar though.
>
> The scroll bar width for the scroll bars are constrained to be equal
> to an even character width.  So if you say scroll bar width 10, it
> is padded to an even character width.  The GTK scroll bar is also
> padded, but it divides the padding evenly at the left and right side
> of the scroll bar.  You can clearly see this if you run Emacs with a
> different background, like
>
> % emacs -bg gray50 -Q -xrm 'Emacs.scrollBarWidth: 10'
>
> and then change the character size to different sizes (use the font
> menu at Shift-Mouse-1 for example).

I see now.

Before this post I did a search in Emacs info and can not find the
answer not even scrollBarWidth. Is there a complete list of X resource
options hidden somewhere?

Also is there any reason to make the width of scroll-bar take up even
character width? Because the gap is not pretty and very noticeable.

>
>> 
>> BTW, can I set scroll-bar width in X resource file?
>> 
>
> See above.

Thank you ;)

>
> 	Jan D.

-- 
Leo <sdl.web AT gmail.com>                         (GPG Key: 9283AA3F)

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: Huge gap between fringe and scroll-bar
  2007-01-01 18:02   ` Leo
@ 2007-01-01 18:56     ` Jan Djärv
  2007-01-02  1:15       ` Leo
  2007-01-02  3:10     ` Richard Stallman
  1 sibling, 1 reply; 10+ messages in thread
From: Jan Djärv @ 2007-01-01 18:56 UTC (permalink / raw)
  Cc: emacs-devel

Leo wrote:
> * Jan Djärv (2007-01-01 13:46 +0100) said:
>   ^^^^^^^^^
>> Leo skrev:
>>> Emacs's native scroll-bar (--without-toolkit-scroll-bars) can have a
>>> huge gap between fringe and scroll-bar. To see this:
>>>
>>>   emacs -Q -l sb.el
>>>
>>> Where sb.el has:
>>> ,----[ sb.el ]
>>> | (setq initial-frame-alist
>>> |       '((scroll-bar-width . 10)))
>>> `----
>>>
>>> As you can see the gap between the fringe and scroll-bar is close to
>>> 8 pixels. I see no gap for gtk scroll-bar though.
>> The scroll bar width for the scroll bars are constrained to be equal
>> to an even character width.  So if you say scroll bar width 10, it
>> is padded to an even character width.  The GTK scroll bar is also
>> padded, but it divides the padding evenly at the left and right side
>> of the scroll bar.  You can clearly see this if you run Emacs with a
>> different background, like
>>
>> % emacs -bg gray50 -Q -xrm 'Emacs.scrollBarWidth: 10'
>>
>> and then change the character size to different sizes (use the font
>> menu at Shift-Mouse-1 for example).
> 
> I see now.
> 
> Before this post I did a search in Emacs info and can not find the
> answer not even scrollBarWidth. Is there a complete list of X resource
> options hidden somewhere?

No, it seems to be missing from the manual.  I'll add it.

> 
> Also is there any reason to make the width of scroll-bar take up even
> character width? Because the gap is not pretty and very noticeable.
> 

It is easier to resize the frame that way in terms of whole character widths. 
  I think that is one of the things we said we should look into after the release.

	Jan D.

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: Huge gap between fringe and scroll-bar
  2007-01-01 18:56     ` Jan Djärv
@ 2007-01-02  1:15       ` Leo
  2007-01-02  9:45         ` Jan Djärv
  0 siblings, 1 reply; 10+ messages in thread
From: Leo @ 2007-01-02  1:15 UTC (permalink / raw)


[-- Attachment #1: Type: text/plain, Size: 675 bytes --]

* Jan Djärv (2007-01-01 19:56 +0100) said:
  ^^^^^^^^^
> It is easier to resize the frame that way in terms of whole
> character widths. I think that is one of the things we said we
> should look into after the release.

That's great.

For now, if users want to customize the native scroll-bar, what are
the options? For example in the following screenshot, there is a one
pixel wide black line surrounding the groove and the slider is one
pixel smaller than the groove. These are not optimal when the
scroll-bar-width is small. I'd like to make the slider as wide as the
groove and have solid background and foreground color. Is Emacs
capable of doing this at the moment?


[-- Attachment #2: E0.png --]
[-- Type: image/png, Size: 283 bytes --]

[-- Attachment #3: Type: text/plain, Size: 84 bytes --]

Regards,
-- 
Leo <sdl.web AT gmail.com>                         (GPG Key: 9283AA3F)

[-- Attachment #4: Type: text/plain, Size: 142 bytes --]

_______________________________________________
Emacs-devel mailing list
Emacs-devel@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-devel

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: Huge gap between fringe and scroll-bar
  2007-01-01 18:02   ` Leo
  2007-01-01 18:56     ` Jan Djärv
@ 2007-01-02  3:10     ` Richard Stallman
  2007-01-02  4:21       ` Leo
  1 sibling, 1 reply; 10+ messages in thread
From: Richard Stallman @ 2007-01-02  3:10 UTC (permalink / raw)
  Cc: emacs-devel

    Before this post I did a search in Emacs info and can not find the
    answer not even scrollBarWidth. Is there a complete list of X resource
    options hidden somewhere?

It is supposed to be in man/xresource.texi, but apparently this one
is missing.  I will add it.  If others are missing, we can add them
too.

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: Huge gap between fringe and scroll-bar
  2007-01-02  3:10     ` Richard Stallman
@ 2007-01-02  4:21       ` Leo
  2007-01-02  4:31         ` Nick Roberts
  0 siblings, 1 reply; 10+ messages in thread
From: Leo @ 2007-01-02  4:21 UTC (permalink / raw)


* Richard Stallman (2007-01-01 22:10 -0500) said:
  ^^^^^^^^^^^^^^^^
>     Before this post I did a search in Emacs info and can not find the
>     answer not even scrollBarWidth. Is there a complete list of X resource
>     options hidden somewhere?
>
> It is supposed to be in man/xresource.texi, but apparently this one
> is missing.  I will add it.  If others are missing, we can add them
> too.

Looks like xresources.texi has been merged in emacs.texi.

-- 
Leo <sdl.web AT gmail.com>                         (GPG Key: 9283AA3F)

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: Huge gap between fringe and scroll-bar
  2007-01-02  4:21       ` Leo
@ 2007-01-02  4:31         ` Nick Roberts
  2007-01-02  4:47           ` Leo
  0 siblings, 1 reply; 10+ messages in thread
From: Nick Roberts @ 2007-01-02  4:31 UTC (permalink / raw)
  Cc: emacs-devel

 > Looks like xresources.texi has been merged in emacs.texi.

emacs.texi `includes' xresources.texi to make the emacs manual but they're
separate files.

-- 
Nick                                           http://www.inet.net.nz/~nickrob

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: Huge gap between fringe and scroll-bar
  2007-01-02  4:31         ` Nick Roberts
@ 2007-01-02  4:47           ` Leo
  0 siblings, 0 replies; 10+ messages in thread
From: Leo @ 2007-01-02  4:47 UTC (permalink / raw)


* Nick Roberts (2007-01-02 17:31 +1300) said:
  ^^^^^^^^^^^^
>  > Looks like xresources.texi has been merged in emacs.texi.
>
> emacs.texi `includes' xresources.texi to make the emacs manual but
> they're separate files.

Thank you for clarifying this and sorry for my mistake.

-- 
Leo <sdl.web AT gmail.com>                         (GPG Key: 9283AA3F)

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: Huge gap between fringe and scroll-bar
  2007-01-02  1:15       ` Leo
@ 2007-01-02  9:45         ` Jan Djärv
  0 siblings, 0 replies; 10+ messages in thread
From: Jan Djärv @ 2007-01-02  9:45 UTC (permalink / raw)
  Cc: emacs-devel



Leo skrev:
> * Jan Djärv (2007-01-01 19:56 +0100) said:
>   ^^^^^^^^^
>> It is easier to resize the frame that way in terms of whole
>> character widths. I think that is one of the things we said we
>> should look into after the release.
> 
> That's great.
> 
> For now, if users want to customize the native scroll-bar, what are
> the options? For example in the following screenshot, there is a one
> pixel wide black line surrounding the groove and the slider is one
> pixel smaller than the groove. These are not optimal when the
> scroll-bar-width is small. I'd like to make the slider as wide as the
> groove and have solid background and foreground color. Is Emacs
> capable of doing this at the moment?

No, thses are hard coded.

	Jan D.

^ permalink raw reply	[flat|nested] 10+ messages in thread

end of thread, other threads:[~2007-01-02  9:45 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-01-01  8:07 Huge gap between fringe and scroll-bar Leo
2007-01-01 12:46 ` Jan Djärv
2007-01-01 18:02   ` Leo
2007-01-01 18:56     ` Jan Djärv
2007-01-02  1:15       ` Leo
2007-01-02  9:45         ` Jan Djärv
2007-01-02  3:10     ` Richard Stallman
2007-01-02  4:21       ` Leo
2007-01-02  4:31         ` Nick Roberts
2007-01-02  4:47           ` Leo

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).