Project Home
Project Home
Documents
Documents
Wiki
Wiki
Discussion Forums
Discussions
Project Information
Project Info
Forum Topic - Determining Widget Visibility: (3 Items)
   
Determining Widget Visibility  
Hi,

what would be the most effective way to determine whether a widget is currently -at least partially- visible?

Or, maybe even better, what would be the recommended method to detect that a widget has become completely invisible or -
if only partially- visible again?

Thanks,
- Thomas
Re: Determining Widget Visibility  
You can try to use the PtGetVisibleTiles(). This will give a list of tiles that visible in the window. It doesn't answer
 the question if the window is obstructed in any way.
If you need the answer on the global scale, you will need to use PtGetVisibleTiles() and do more clipping/intersection 
with the available regions that are opaque to rendering – the phin and phview source code could be used to check how to
 query regions.
Re: Determining Widget Visibility  
Thanks, Misha... 

I actually had a look at that and decided it'd propably be way too expensive for what the customer is trying to do. 
Thought there might be some flag holding this information that I had missed. Propably the best solution will be to re-
design the application...

- Thomas