C# winform check if control is physicaly visible

后端 未结 9 1635
有刺的猬
有刺的猬 2020-12-09 01:58

Is it possible to determine if at least one pixel of a control can be seen (by a property or maybe using event notification).

NB : I am not looking for the Visible p

9条回答
  •  粉色の甜心
    2020-12-09 02:44

    You may use Layout event of controls. it is triggered when control comes to screen and tries to layout its child controls.

    For example, let's say there is GroupBox inside a TabPage.
    When relevant tab clicked, layout event will fire for first tabpage then for GroupBox
    You may use it combined with visibility property

提交回复
热议问题