Hello
I have a problem with an html widget when the focus is on the html widget and not focused for example on an editbox within the frm component.
When I press for example 'shift+-' the userKey trigger is not fired. Other key combinations do not work either.
Any ideas how to get this to work?
Thanks
Observations:
Shift++ works but I think that is because + is a gold key
I tried this but it did not help
putitem/id sProperties, "UnifaceKeys", "Shift+-"
$properties($sHtmlField$) = sProperties
This does work, for example with esc but shift(-) is not part of the functionality
putitem/id sProperties, "UnifaceKeys", "DefaultKeys"
$properties($sHtmlField$) = sProperties
------------------------------
Osman Shariff
Freelance Uniface Consultant - France
Private message me if you need help with a project
English, French, German
------------------------------
Hello
I have a problem with an html widget when the focus is on the html widget and not focused for example on an editbox within the frm component.
When I press for example 'shift+-' the userKey trigger is not fired. Other key combinations do not work either.
Any ideas how to get this to work?
Thanks
Observations:
Shift++ works but I think that is because + is a gold key
I tried this but it did not help
putitem/id sProperties, "UnifaceKeys", "Shift+-"
$properties($sHtmlField$) = sProperties
This does work, for example with esc but shift(-) is not part of the functionality
putitem/id sProperties, "UnifaceKeys", "DefaultKeys"
$properties($sHtmlField$) = sProperties
------------------------------
Osman Shariff
Freelance Uniface Consultant - France
Private message me if you need help with a project
English, French, German
------------------------------
okay... so my conclusion based on some tests is thus:-
unifacekeys does work as it says in the documentation. It works with alt, ctrl, shift.
There are 2 keyboard codes (typewriter and keypad) for each of these (alt, ctrl, shift).
I'm thinking that unifacekeys works with typewriter keycodes (128, 129,130 ) but not keypad codes(136,137,138).
If this is the case then a workaround is necessary or maybe a patch can be added at a later date ?
Can anyone confirm or deny this assumption?
Thanks in advance
------------------------------
Osman Shariff
Freelance Uniface Consultant - France
Private message me if you need help with a project
English, French, German
------------------------------
okay... so my conclusion based on some tests is thus:-
unifacekeys does work as it says in the documentation. It works with alt, ctrl, shift.
There are 2 keyboard codes (typewriter and keypad) for each of these (alt, ctrl, shift).
I'm thinking that unifacekeys works with typewriter keycodes (128, 129,130 ) but not keypad codes(136,137,138).
If this is the case then a workaround is necessary or maybe a patch can be added at a later date ?
Can anyone confirm or deny this assumption?
Thanks in advance
------------------------------
Osman Shariff
Freelance Uniface Consultant - France
Private message me if you need help with a project
English, French, German
------------------------------
Hi Osman
Patch 10.4.02-033 added the ability to attach a keyword to a key combination in the ini file ([userkeys]). When the key combination is used, the keyword is passed to the user key to take action. This works on all widgets, including the HTML widget.
Kind regards,
Mike
------------------------------
Michael Taylor
Rocket Internal - All Brands
------------------------------
Hi Osman
Patch 10.4.02-033 added the ability to attach a keyword to a key combination in the ini file ([userkeys]). When the key combination is used, the keyword is passed to the user key to take action. This works on all widgets, including the HTML widget.
Kind regards,
Mike
------------------------------
Michael Taylor
Rocket Internal - All Brands
------------------------------
Thanks Michael,
I did some tests and it works really good. I tested both alt and shift together with an html widget and it works too.
What didn't work is shift and numlock minus(-).
It works perfectly well for an edit box using the keyboard translation table, but not with the html widget. Even after I included [userkeys] in the ini file.
------------------------------
Osman Shariff
Freelance Uniface Consultant - France
Private message me if you need help with a project
English, French, German
------------------------------
Hello
I have a problem with an html widget when the focus is on the html widget and not focused for example on an editbox within the frm component.
When I press for example 'shift+-' the userKey trigger is not fired. Other key combinations do not work either.
Any ideas how to get this to work?
Thanks
Observations:
Shift++ works but I think that is because + is a gold key
I tried this but it did not help
putitem/id sProperties, "UnifaceKeys", "Shift+-"
$properties($sHtmlField$) = sProperties
This does work, for example with esc but shift(-) is not part of the functionality
putitem/id sProperties, "UnifaceKeys", "DefaultKeys"
$properties($sHtmlField$) = sProperties
------------------------------
Osman Shariff
Freelance Uniface Consultant - France
Private message me if you need help with a project
English, French, German
------------------------------
Userkeys
When using userkeys in uniface, it is important to use the Shift key with some precautions.
For instance, the Shift+- does not work. Windows key '-' = 45 gets through but is not picked up.
Defining Shift++ does not work since the '+' is part of the syntax definition of the userkey, and even when we split this up, it does not work as expected.
What works are the following
capital_h=Shift+H
OpenBracket=Shift+9
Star=Shift+8
Try to avoid conflicting key combinations. For instance, the Ctrl+Z and Ctrl+C (Clipboard). To make things easier, I would recommend creating a form with an editbox and an HTML widget which only has a simple line of html. Edit the userkeys section in the usys.ini and add to the component level triggers the userkey trigger.
Trigger userkey
Message/info $result
End
Play around with this and see what works. Avoid using the same key-combinations as defined in the menu accelerator table, since the latter has precedence over the userkeys.
Success in finding the right key.
------------------------------
Jasper DeKeijzer
Rocket Internal - All Brands
------------------------------
Userkeys
When using userkeys in uniface, it is important to use the Shift key with some precautions.
For instance, the Shift+- does not work. Windows key '-' = 45 gets through but is not picked up.
Defining Shift++ does not work since the '+' is part of the syntax definition of the userkey, and even when we split this up, it does not work as expected.
What works are the following
capital_h=Shift+H
OpenBracket=Shift+9
Star=Shift+8
Try to avoid conflicting key combinations. For instance, the Ctrl+Z and Ctrl+C (Clipboard). To make things easier, I would recommend creating a form with an editbox and an HTML widget which only has a simple line of html. Edit the userkeys section in the usys.ini and add to the component level triggers the userkey trigger.
Trigger userkey
Message/info $result
End
Play around with this and see what works. Avoid using the same key-combinations as defined in the menu accelerator table, since the latter has precedence over the userkeys.
Success in finding the right key.
------------------------------
Jasper DeKeijzer
Rocket Internal - All Brands
------------------------------
Thanks Jasper, these were my finding too.
Sadly, I have no choice but to use shift+-, but I have a workaround so no worries.
I like the new userkeys functionality even though there is very little written about it. Maybe an update in the documention would be nice.
------------------------------
Osman Shariff
Freelance Uniface Consultant - France
Private message me if you need help with a project
English, French, German
------------------------------
Thanks Jasper, these were my finding too.
Sadly, I have no choice but to use shift+-, but I have a workaround so no worries.
I like the new userkeys functionality even though there is very little written about it. Maybe an update in the documention would be nice.
------------------------------
Osman Shariff
Freelance Uniface Consultant - France
Private message me if you need help with a project
English, French, German
------------------------------
There is a blog post, which you can find here:
https://community.rocketsoftware.com/blogs/kathy-larson1/2023/06/27/using-keyboard-shortcuts?CommunityKey=edb92b7f-cb45-44f3-9782-c48a111007d6
------------------------------
Jasper DeKeijzer
Rocket Internal - All Brands
------------------------------