C# winform check if control is physicaly visible

后端 未结 9 1633
有刺的猬
有刺的猬 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:49

    You can check for visibility of parent control.

        protected override void OnParentVisibleChanged(EventArgs e)
        {
            base.OnParentVisibleChanged(e);
            isVisible = true;
        }
    

提交回复
热议问题