gpt4 book ai didi

Delphi隐藏表单: Is there a difference between Form. Hide and Form.Visible :=False?

转载 作者:行者123 更新时间:2023-12-01 18:57:14 27 4
gpt4 key购买 nike

我正在查看两份代码,其中一份有 myForm.Hide,另一份有 myForm.Visible := False。我不记得为什么要更改此设置,如果是修复错误或是否有任何区别。

最佳答案

隐藏没有区别。 VCL代码为:

procedure TCustomForm.Hide;
begin
Visible := False;
end;

但是Show有点不同:

procedure TCustomForm.Show;
begin
Visible := True;
BringToFront;
end;

关于Delphi隐藏表单: Is there a difference between Form. Hide and Form.Visible :=False?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/5436743/

27 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com