TAdvPopupTouchKeyBoard Error

Developer Platform: Delphi 10.1 Update 2 on Windows Server 2012 R2

Greetings all,

I
am trying to load a custom keyboard configuration file into a
TAdvPopupTouchKeyBoard component with the call :
PopKb1.Keyboard.LoadKeybdLayout(KbFile)

This custom keyboard was designed with, works with and was saved from a TAdvTouchKeyBoard component.

I've
tried to load the configuration file on both the unit OnCreate and
OnShow event and regardless where they are loaded the program fails when
you try and load the custom keyboard configuration file.

The
point of failure appears to be in the AdvTouchKeyboard unit at line 1472
("With Keys do") in procedure LoadKeybdLayout(Filename: string) when
the line is executed.

Keys appears to be a poperty value in the
TAdvTouchKeyCollection and while the compiler doesn't complain about
Keys specifically, the function does not advance past this line.

When running in debug mode from the IDE this is the error I get (TMS source code + error msg).



When
run outside of the IDE this is the error I get and I am pretty sure it
is at the same breakpoint as when I remove the load call it runs without
error but I get the default keyboard.



I also have one on other question :-)

How do you change the display font size on the special keys like skRetrun, skBackSpace and skHome?

Thank
you in advance for looking into my problems and hopefully resolving my
issues as I really like this component but the default popup keyboard is
just so ahhhhh - "ugly". No offense intended...

All the best - Kevin

I'm sorry - the two error messages didn't make it. I will try it again. Best - Kevin












I cannot see the images here.
To load the custom keyboard, please try to do this from the TAdvPopupTouchKeyboard.OnKeyboardCreated event.

The size of the keys is set with TAdvTouchKeyItem.Height / TAdvTouchKeyItem.Width


Thanks for OnKeyboardCreated event Bruno. I had my code in the wrong place :-)

I also apologize for the error images not making it. I'm new to the forum and tried to upload them as jpg's rather than png's.

One question remains for you Bruno.

The Font Size and Style (bold) of my custom keyboard design are not being applied to the new popup.

Not only to the regular keys but to the special keys like skRetrun, skBackSpace and skHome.

I
went through AdvTouchKeyboard.pas but do not see any properties
available to control these characteristics when using LoadKeybdLayout().

Since my custom keys are larger I would like the key font to be larger too.

The
Font settings in TAdvTouchKeyboard are not being applied when
LoadKeybdLayout is used even though I can see them on the form.

And these font settings are not being applied to the special keys like KeyBackSpace.

Thanks in advance for your assistance Bruno

Font setting is not stored in the keyboard layout file, it is just the layout keys collection.

You could apply font setting in code from the OnKeyboardCreated event by setting it programmatically there via AdvPopupTouchKeyBoard.Keyboard.Font.

Thank you Bruno...

I found that property today while experimenting with the possibilities of the OnKeyboardCreated event.

But I still am still unable to change the font properties on special keys.

That is my only remaining problem that is not solved with the TAdvTouchKeyboard.

I've been looking through the source code looking for it hahahaha.

If you tell me where I can find it then everything will be "wonderful".

Thanks again for opening the doors that you have so far. I greatly appreciate the product support.

Keys that have more than one letter, such as the special keys that have text like 'Back' with four letters, have their font set from AdvPopupTouchKeyboard.Keyboard.SmallFont

Thanks a million Bruno !!

It would have been a long time before I thought about looking in that direction.

Again - Thanks to you and TMS for the excellent support and producing products that are as configurable as they are.

All the best - Kevin