Fixed double click on tab

46 views
Skip to first unread message

Neil Hodgson

unread,
Oct 15, 2009, 6:33:05 AM10/15/09
to scite-interest
There was a bug where double clicking on a tab closed that buffer.
This has now been fixed in CVS.

Neil

mozers

unread,
Oct 18, 2009, 6:14:41 AM10/18/09
to Neil Hodgson
Thursday, October 15, 2009, 2:33:05 PM, Neil wrote:

> There was a bug where double clicking on a tab closed that buffer.
> This has now been fixed in CVS.

I am shocked.
Why did you decide that it is - a bug???
Most of the known programs allow you to close the tab by double clicking.
Very badly that now this useful possibility is absent in SciTE :(((

--
mozers
<http://scite.net.ru>

Juan Giordana

unread,
Oct 18, 2009, 6:38:15 AM10/18/09
to scite-i...@googlegroups.com
On Sun, Oct 18, 2009 at 10:14 AM, mozers <moz...@gmail.com> wrote:
> I am shocked.
> Why did you decide that it is - a bug???
> Most of the known programs allow you to close the tab by double clicking.
> Very badly that now this useful possibility is absent in SciTE :(((
>

Agree

Neil Hodgson

unread,
Oct 18, 2009, 7:58:43 AM10/18/09
to scite-i...@googlegroups.com
mozers:

>>    There was a bug where double clicking on a tab closed that buffer.
>> This has now been fixed in CVS.
>
> I am shocked.

I mentioned this on September 12 on the Scintilla list.

> Why did you decide that it is - a bug???

I was selecting buffers in SciTE by clicking on their tabs and they
were closing for no reason.

> Most of the known programs allow you to close the tab by double clicking.

Like what? Firefox - No. Chrome - No. Internet Explorer - No.
Safari - No. Visual Studio - No.

Neil

mozers

unread,
Oct 18, 2009, 9:09:01 AM10/18/09
to Neil Hodgson
Sunday, October 18, 2009, 3:58:43 PM, Neil wrote:

> I mentioned this on September 12 on the Scintilla list.

I didn't believe it. I thought that it is my bad english.

> I was selecting buffers in SciTE by clicking on their tabs and they
> were closing for no reason.

Selecting buffer is implemented by a single click.

> Like what? Firefox - No. Chrome - No. Internet Explorer - No.
> Safari - No. Visual Studio - No.

I have this opportunity in Total Commander, Maxthon,... continue?

There is no reason to remove good revision.
If you do not like it personally, then add the parameter buffer.close.ondoubleclick.

--
mozers
<http://scite.net.ru>

Neil Hodgson

unread,
Oct 18, 2009, 6:16:33 PM10/18/09
to scite-i...@googlegroups.com
mozers:

>>    I was selecting buffers in SciTE by clicking on their tabs and they
>> were closing for no reason.
>
> Selecting buffer is implemented by a single click.

And if you accidentally click a second time it closes.

>>    Like what? Firefox - No. Chrome - No. Internet Explorer - No.
>> Safari - No. Visual Studio - No.
>
> I have this opportunity in Total Commander, Maxthon,... continue?

None of which are common or used by me. This is not a standard.

http://www.codinghorror.com/blog/archives/000096.html
"Many users never fully learn the distinction between single-click
and double-click. So they give up and simply.. double-click
everything."

Generally double clicking is an expansive action - either something
is opened or the selection is increased. Having double click be a
destructive action is not on.

> There is no reason to remove good revision.

It closes buffers when that is not the user's intent.

> If you do not like it personally, then add the parameter buffer.close.ondoubleclick.

I have spent too much time already debugging this.

Neil

Philippe Lhoste

unread,
Oct 19, 2009, 5:53:21 AM10/19/09
to scite-i...@googlegroups.com
On 19/10/2009 00:16, Neil Hodgson wrote:
>>> Like what? Firefox - No. Chrome - No. Internet Explorer - No.
>>> Safari - No. Visual Studio - No.
>> I have this opportunity in Total Commander, Maxthon,... continue?
>
> None of which are common or used by me. This is not a standard.

The TabMixPlus extension allows to close a tab (or do other actions) on double-click,
Ctrl+click, Shift+click, Alt+click. But is is part of a very flexible setting, something
overkill in SciTE.

> Generally double clicking is an expansive action - either something
> is opened or the selection is increased. Having double click be a
> destructive action is not on.
>
>> There is no reason to remove good revision.
>
> It closes buffers when that is not the user's intent.
>
>> If you do not like it personally, then add the parameter buffer.close.ondoubleclick.
>
> I have spent too much time already debugging this.

I guessed it wasn't a real bug but well...
Somehow, I agree with Neil, doing such action on a double-click isn't such a good idea.
Perhaps somebody can propose a patch to close a tab on a Ctrl+click, for example. It is
less likely to happen by accident, I like the idea of Ctrl giving "control" on the click
behavior... :-)

--
Philippe Lhoste
-- (near) Paris -- France
-- http://Phi.Lho.free.fr
-- -- -- -- -- -- -- -- -- -- -- -- -- --

Frank Wunderlich

unread,
Oct 19, 2009, 3:50:10 PM10/19/09
to scite-i...@googlegroups.com
mozers, 18.10.2009 15:09:

> If you do not like it personally, then add the parameter
> buffer.close.ondoubleclick.

i like this feature too, closing a tab without calling a menu. another
possibility were implementing a close-button on each tab (like firefox
and some IDEs/other editors), but this can be a lot of work.
i think the best way is to make it configurable (default disabled)

regards Frank

Neil Hodgson

unread,
Oct 19, 2009, 7:45:32 PM10/19/09
to scite-i...@googlegroups.com
Frank Wunderlich:

> i like this feature too, closing a tab without calling a menu.

You can already use Middle Click on Tab or Ctrl+W. Both of these
actions are shared with the current releases of Firefox, Chrome,
Safari, and Internet Explorer so there is a much better chance that
users will be aware of them.

Neil

mozers

unread,
Oct 20, 2009, 1:37:26 AM10/20/09
to Neil Hodgson
Tuesday, October 20, 2009, 3:45:32 AM, Neil wrote:

> You can already use Middle Click on Tab or Ctrl+W. Both of these
> actions are shared with the current releases of Firefox, Chrome,
> Safari, and Internet Explorer so there is a much better chance that
> users will be aware of them.

Your answer, Neil, you need to put in the FAQ.
Because you upset a many users and they will ask.

--
mozers
<http://scite.net.ru>

Neil Hodgson

unread,
Oct 20, 2009, 1:55:51 AM10/20/09
to scite-i...@googlegroups.com
mozers:

> Your answer, Neil, you need to put in the FAQ.
> Because you upset a many users and they will ask.

How will these users have known about double clicking?

Neil

Philippe Lhoste

unread,
Oct 20, 2009, 6:50:52 AM10/20/09
to scite-i...@googlegroups.com
On 20/10/2009 01:45, Neil Hodgson wrote:
> You can already use Middle Click on Tab or Ctrl+W. Both of these

Ah, middle click closes a tab? Good to know.
Ctrl+W only closes the current window. Useful, of course, but not the same function.

hongwei hou

unread,
Oct 20, 2009, 9:32:36 AM10/20/09
to scite-i...@googlegroups.com


2009/10/20 Philippe Lhoste <Phi...@gmx.net>
I know when it is used in Windows,but in GTK,it seems not to work,can it be fixed?

Neil Hodgson

unread,
Oct 20, 2009, 6:24:53 PM10/20/09
to scite-i...@googlegroups.com
hongwei hou:

> I know when it is used in Windows,but in GTK,it seems not to work,can it be
> fixed?

Middle click on tab to close works for me on GTK+ 2.16 on Fedora
11. The code (in SciTEGTK::TabBarRelease) responds to mouse button 2
so it is possible your mouse buttons are mapped differently.

Neil

hongwei hou

unread,
Oct 21, 2009, 12:56:40 AM10/21/09
to scite-i...@googlegroups.com


2009/10/21 Neil Hodgson <nyama...@gmail.com>

Thanks ,it works!

hongwei hou

unread,
Oct 21, 2009, 1:30:12 AM10/21/09
to scite-i...@googlegroups.com


2009/10/21 Neil Hodgson <nyama...@gmail.com>
I found in devhelp that "the button which was pressed or released, numbered from 1 to 5. Normally button 1 is the left mouse button, 2 is the middle button, and 3 is the right button. On 2-button mice, the middle button can often be simulated by pressing both mouse buttons together" My mouse is the normal one having idler wheel ,I try to modiy it to event->type == GDK_2BUTTON_PRESS instead of event->button == 2 in line 2585, how to fix it,thanking very much!

Neil Hodgson

unread,
Oct 21, 2009, 3:09:59 AM10/21/09
to scite-i...@googlegroups.com
hongwei hou:

> I found in devhelp that "the button which was pressed or released, numbered
> from 1 to 5. Normally button 1 is the left mouse button, 2 is the middle
> button, and 3 is the right button. On 2-button mice, the middle button can
> often be simulated by pressing both mouse buttons together" My mouse is the
> normal one having idler wheel ,I try to modiy it to event->type ==
> GDK_2BUTTON_PRESS instead of event->button == 2 in line 2585, how to fix
> it,thanking very much!

Most mice now have clickable scroll wheels so check whether
clicking the scroll wheel works for you.

If not then there is an X Window System option Emulate3Buttons that
it may be possible to set. This used to be the default but does not
appear to be so on my current installations. The option goes into your
X configuration file which is normally /etc/X11/xorg.conf. Search the
web for Emulate3Buttons for information about this option.

Neil

Reply all
Reply to author
Forward
0 new messages