[Gambas-user] Key codes from keysymdef

Bruce Steers bsteers4 at gmail.com
Thu Nov 5 14:45:35 CET 2020


I have this so far..
https://gitlab.com/bsteers4/sripted/-/blob/master/.src/MacroRecorder.class

>From this project..
https://gitlab.com/bsteers4/sripted
A basic Scripting text editor that works for bash and gambas scripts. fully
utilising gambas Highlighting/modes customisable for each mode type.
(Requires  gambas 3.15.90 for sh highlight features  but not to run, it'll
use C highlight on older gambas)

I've opened a discussion about it and explained some stuff about the state
of the project here..
https://forum.gambas.one/viewtopic.php?f=6&t=940

I'm not sure i understand the ISO_Level_3_Shift thing but i've got it to
produce Benoíts "í" char by checking String.Code >127
as far as i know ISO_Level_5_Shift is for Shift-AltGr but im not sure about
it all.

I't a working macro recorder class that is easily added to any project. it
just needs a text object of some kind.

but it also needs an expert eye.
Any advice would be welcomed about the macro recorder and AltGr/Shift-AltGr
methods or anything else i'm not understanding.
Gambas team, feel free to rip the macro code (half of it's Benoíts anyway
lol) i used/ripped code and styles from the Desktop.class both to ensure a
compatible style for better understand for others and because i wanted to
do Desktop.SandKey() but a bit differently.
and also because...
Once it's perfected it needs adding to the Gambas IDE because gambas would
be awesome with a keystroke macro recorder :)
(hence the trying to keep the code "Benoít friendly" ;) )

Many thanks all.
Wishing Well
BruceS

On Thu, 5 Nov 2020 at 00:12, Bruce Steers <bsteers4 at gmail.com> wrote:

> Is this the wrong way to find the alt key hits?
>
> Select Key.Code
> Case key["Alt_L"]
>  Return "[Alt_L]"
> Case Key["ISO_Level3_Shift"]
>  Return "[ISO_Level3_Shift]"  ' AltGr
> Case Key["ISO_Level5_Shift"]
>  Return "[ISO_Level5_Shift]"  ' AltGr+Shif
> End Select
>
> Note. I don't want to use the Key.Alt bool as it's not up for the task i need.
> i was under the impression that i could use the above method after reading
> the wiki Key.Code page.
>
> I need to differ between Alt AltGr and Shift-AltGr
> Or can i only get Key.Alt ?
>
> My macro recorder has 2 blocks...
> AltGr and right windows key (Super_R I believe)
>
> Have i missed a memo or something with the above code? ;)
>
> Tobias, I see your name in c_key.c .
> I also spotted the text that said "Need anything Just Ask"
>
> I need my macro recorder to know AltGr, and Super_R / Super_L
>
>
> Ps.
> Key.AltGrkey says "Key symbol not found" if i try to use it
>
>
> Many thanks for any info folks.
>
> BruceS
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.gambas-basic.org/pipermail/user/attachments/20201105/b4988872/attachment.htm>


More information about the User mailing list