cancel
Showing results for 
Search instead for 
Did you mean: 

How to know active container?

Ezgi
Senior

Hi,

I have two containers on my screen. Two of them is visible. However I want to know which one is appearing on the screen. Is there a function about it or a way?

1 REPLY 1
Yoann KLEIN
ST Employee

Hello @Ezgi Şanver​ ,

I'm not sure to understand exactly why you want to know programmatically which element is appearing on the screen. Can you provide me the user case ?

But, if you want to control which element is appearing or not on the screen, you can use the setVisible(bool) method from the Drawable class.

Otherwise, in TouchGFXDesigner, the order in which you place the elements in the "widget list" has an influence on which the element is in foreground or in background on the screen. For example :

0693W00000KaNYNQA3.pngHope that this helped you,

/Yoann

Yoann KLEIN
ST Software Developer | TouchGFX