cancel
Showing results for 
Search instead for 
Did you mean: 

Active touch area on a FlexButton

justin11
Associate III

Im interested to know what the actve areas of a flex button is ?

for example is the active area just limited to the text or icon within the flex button or is it active with the complete rectangluar frame of the button ?

We are noticing a number of failed touch clicks. i can see within our debug tool that the touch has ben registered, but the click action has not been done.

also how does TouchGFX handel buttons that are really close or even overlapping.

Does transparecys effect the buttons sensativity ?

we are using touchGFX 4.20 and unfortunalty we are unable to upgrade this as its within a production product.

4 REPLIES 4
GaetanGodart
ST Employee

Hello @justin11 ,

 

The touch area of a flexButton is the whole widget.
You can test that by adding a flex button and reducing the size of the box in it to 0 by 0, the click will still be detected.
So it is the complete rectangular frame of the button yes.

So the touch on the display has been detected but the button is not clicked?
Are the coordinates of the touch correct (within the button)?

If buttons are very close, it doesn't matter, the one touched is the one clicked.
If elements are overlapping, the one which will be clicked is the one visible there.
For instance, if you have button left and button right that overlap, if button right is over button left, if you touch the overlapping area, you will be clicking on the right button (the one above).
Transparency doesn't affect this behavior.
You should be able to put your button to full transparency and it would still work. It is a good trick to know for design.

Are you able to share your project (or create a new project with just the button issue) and share it there?

 

Regards,

Gaetan Godart
Software engineer at ST (TouchGFX)
GaetanGodart
ST Employee

Hello again @justin11 ,

 

Have you been able to have a look at my comment?
Have you solved your problem?

If you haven't, can you tell us what hardware you are using?

 

Regards,

Gaetan Godart
Software engineer at ST (TouchGFX)

Hi,

I've not been able to look at this yet, hope to get to it next week.

I can track the x,y of the touch so it should help me identify whats going on.

I had to add some delays, to try to help with touch "bounce" from a user. We had issues where the back button on one page was in the same place as a different button on the new page and that lead to that button also being triggered.

    bool getTouchNavBounce ()
    {
        if ( osKernelSysTick () > touch_nav_touched + TOUCH_BOUNCE_TICK )
        {
            touch_nav_touched = osKernelSysTick ();
            return true;
        }
        else
        {
            return false;
        }
    }

 

GaetanGodart
ST Employee

Ok no problem!

"We had issues where the back button on one page was in the same place as a different button on the new page and that lead to that button also being triggered."
I have never heard of that.

I assume you have a custom board (not one of the discovery board with provided TBS) so there could be an issue transferring the click from the screen to the TouchGFX code.

 

Regards,

Gaetan Godart
Software engineer at ST (TouchGFX)