[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Tab shuffling in emacs-w3m
>>>>> In [emacs-w3m : No.09287] Leo wrote:
> On 2007-03-27, Katsumi Yamaoka said:
>> If the mouse doesn't track the selected tab correctly, try
>> customizing the value of `w3m-tab-mouse-position-adjuster'. The
>> default value is '(0.1 . -0.5), but '(-0.33 . -2.5)) for example,
>> might be better for a certain font set.
> Indeed, I have just found out the mouse always falls out of the
> selected tab which prevents continuous shifting. Hope this can be made
> more robust!
I've changed the way to calculate the mouse position so that it
is based on pixel units rather than the number of characters.
However, you will still see it fails if you use a proportional
font for the tab faces. There seems to be no way to fix it
until Emacs itself supports it in any way. I made the new
variable for such people, though I was unwilling.
,----
| w3m-tab-track-mouse is a variable defined in `w3m-ems.elc'.
| Its value is t
|
| Documentation:
| Say whether to make the mouse track the selected tab.
| It controls the behavior of the commands `w3m-tab-previous-buffer',
| `w3m-tab-next-buffer', `w3m-tab-move-right', and `w3m-tab-move-left'
| invoked by the mouse.
|
| You may want to set this to nil if you use a proportional font for the
| tab faces. See also `w3m-tab-mouse-position-adjuster'.
`----
But if you use a fixed font, it is worth trying customising this
variable again.
,----
| w3m-tab-mouse-position-adjuster is a variable defined in w3m-ems.elc'.
| Its value is (0.5 . -4)
|
| Documentation:
| Values used to adjust the mouse position on tabs.
| It is used when the command `w3m-tab-previous-buffer',
| `w3m-tab-next-buffer', `w3m-tab-move-right', or `w3m-tab-move-left' is
| invoked by the mouse. The value consists of the cons of a floating
| point number M and an integer N that are applied to calculating of the
| mouse position, which is given in pixel units, as follows:
|
| (TAB_WIDTH + M) * ORDER + N
|
| Where TAB_WIDTH is the pixel width of a tab and ORDER is the order
| number in tabs. The result is rounded towards zero.
|
| Note that the calculation will always fail if you use a proportional
| font for the tab faces. See also `w3m-tab-track-mouse'.
`----
Regards,