Sign in Join

Live chat for Free Pascal, Lazarus, Delphi and every Pascal programmer.

Mailing lists / lazarus / 2011-08

Alt key to set column selection mode is broken

8 messages · 3 people ·

Reply by email Subscribe to this list Your subscription

Read-only archive. Use j and k to move between messages.

Graeme Geldenhuys

Hi,

I have a suggestion to the Alt key for column section. Currently it doesn't work at all on Linux and probably *BSD too. The problem is two fold.

1) This is because the Alt+Click+Drag is already used by X11 to move windows around (without doing in from the title bar).

2) Even though the description of that feature says Alt key, Lazarus actually means "Left Alt" key only.

What if Lazarus changes that option to use the Right Alt key instead. Currently this is not used by X11, and seeing that Lazarus seem to differentiate between Left Alt and Right Alt anyway, this could be a solution that could work on all platforms?

Regards,
- Graeme -

fpGUI Toolkit - a cross-platform GUI toolkit using Free Pascal http://fpgui.sourceforge.net/

Reply by email

Flávio Etrusco
to Graeme Geldenhuys
Graeme Geldenhuys wrote 19 lines
Hi, I have a suggestion to the Alt key for column section. Currently it doesn't work at all on Linux and probably *BSD too. The problem is two fold. 1) This is because the Alt+Click+Drag is already used by X11 to move ? windows around (without doing in from the title bar). 2) Even though the description of that feature says Alt key, Lazarus ? actually means "Left Alt" key only. What if Lazarus changes that option to use the Right Alt key instead. Currently this is not used by X11, and seeing that Lazarus seem to differentiate between Left Alt and Right Alt anyway, this could be a solution that could work on all platforms? Regards, ?- Graeme -

Well, it'd better change to use any Alt then? Or be configurable? And add shortcuts to change or toggle the SelectionMode? ;-)

Regards,
Fl?vio

Reply by email

Martin
to Graeme Geldenhuys: I have a suggestion to the Alt key for column section. Currently it doesn't work at all…
Graeme Geldenhuys wrote 16 lines
Hi, I have a suggestion to the Alt key for column section. Currently it doesn't work at all on Linux and probably *BSD too. The problem is two fold. 1) This is because the Alt+Click+Drag is already used by X11 to move windows around (without doing in from the title bar). 2) Even though the description of that feature says Alt key, Lazarus actually means "Left Alt" key only. What if Lazarus changes that option to use the Right Alt key instead. Currently this is not used by X11, and seeing that Lazarus seem to differentiate between Left Alt and Right Alt anyway, this could be a solution that could work on all platforms?

I haven't checked it under Linux. But on windows, the right alt key, simply translate into ctrl-alt. You can test it using shift-alt and cursor keys for selection

That means on windows, using the mouse I can use either alt key (because ctrl+alt does not activate the mouse links)

Reply by email

Flávio Etrusco
to Martin
Show quoted text 7 lines
I haven't checked it under Linux. But on windows, the right alt key, simply translate into ctrl-alt. You can test it using shift-alt and cursor keys for selection That means on windows, using the mouse I can use either alt key (because ctrl+alt does not activate the mouse links)

This is weird, I could swear AltGr was working here, but it isn't. And here (Win7, Brazilian kbd, CapsLockBeGone=Shift) it doesn't detect ssCtrl either.

-Fl?vio

Reply by email

Flávio Etrusco
to Martin: I haven't checked it under Linux. But on windows, the right alt key, simply translate…
Martin wrote 27 lines
On 12/08/2011 08:38, Graeme Geldenhuys wrote: > > Hi, > > I have a suggestion to the Alt key for column section. Currently it > doesn't work at all on Linux and probably *BSD too. The problem is two > fold. > > 1) This is because the Alt+Click+Drag is already used by X11 to move > ? ?windows around (without doing in from the title bar). > > 2) Even though the description of that feature says Alt key, Lazarus > ? ?actually means "Left Alt" key only. > > What if Lazarus changes that option to use the Right Alt key instead. > Currently this is not used by X11, and seeing that Lazarus seem to > differentiate between Left Alt and Right Alt anyway, this could be a > solution that could work on all platforms? > I haven't checked it under Linux. But on windows, the right alt key, simply translate into ctrl-alt. You can test it using shift-alt and cursor keys for selection That means on windows, using the mouse I can use either alt key (because ctrl+alt does not activate the mouse links) --

Adding support for ssAltGr is as simple as adding in lcl\forms.pp, line 1764:

+  if GetKeyState(VK_RMENU) < 0 then Include(Result, ssAltGr);

Should we also support an independent left Alt state and leave ssAlt to mean any Alt? What about the other keys?

Best regards,
Fl?vio

Reply by email

Graeme Geldenhuys
to Flávio Etrusco
Fl?vio Etrusco wrote
Adding support for ssAltGr is as simple as adding in lcl\forms.pp, line 1764: + if GetKeyState(VK_RMENU) < 0 then Include(Result, ssAltGr);

All good and well, but I was actually referring to SynEdit (Lazarus's editor component), not a Form.

Regards,
- Graeme -

fpGUI Toolkit - a cross-platform GUI toolkit using Free Pascal http://fpgui.sourceforge.net/

Reply by email

Martin
to Flávio Etrusco: Adding support for ssAltGr is as simple as adding in lcl\forms.pp, line 1764: + if…
Fl?vio Etrusco wrote 13 lines
> I haven't checked it under Linux. But on windows, the right alt key, simply > translate into ctrl-alt. You can test it using shift-alt and cursor keys for > selection > > That means on windows, using the mouse I can use either alt key (because > ctrl+alt does not activate the mouse links) Adding support for ssAltGr is as simple as adding in lcl\forms.pp, line 1764: + if GetKeyState(VK_RMENU)< 0 then Include(Result, ssAltGr); Should we also support an independent left Alt state and leave ssAlt to mean any Alt? What about the other keys?

Does that work on all widgetsets?

And what about people relying on the current behaviour, where AltGr does map to alt-ctrl? Currently (nmopt sure if mapped by the lcl, or if send by windows) an application receives alt-ctrl, for AltGr. existing apps may rely on that

For example, on Windows (tested with windows, but I remember this was already true in the early days), using a german keymap (where altgr is used.

AltGr - Q is @, and you can use ctrl-alt-Q as well. There are several other such examples on the german keymap. And I believe there are other none english keymaps that work similar too.

I don't know how those work on Linux.
I don't know about Mac (does Mac have altgr?)

And none windows systems obviously could also use the "windows" key as modifier.
Actually, even on windows, you can have an app that uses the windows key....

Reply by email

Martin
to Graeme Geldenhuys: All good and well, but I was actually referring to SynEdit (Lazarus's editor component),…
Graeme Geldenhuys wrote 8 lines
On 08/12/2011 02:45 PM, Fl?vio Etrusco wrote: > Adding support for ssAltGr is as simple as adding in lcl\forms.pp, line 1764: > > + if GetKeyState(VK_RMENU)< 0 then Include(Result, ssAltGr); All good and well, but I was actually referring to SynEdit (Lazarus's editor component), not a Form.

SynEdit just looks at what it gets from the LCL, and what it is configured to do.

If you use a windows manager that steels away a key or mouse combination, then that is not synedits fault [1].
If synEdit never receives the alt-left mouse, that is your window manager.

The IDE has an advanced mouse setup, it can be changed there. So has your window manager.

[1] If you refer to the configuration used in the IDE, in the light of an ( [I ASSUME, according to you] "common") feature on linux of using alt-left-click, then that is not SynEdit but the IDE

Reply by email