1,183
社区成员
发帖
与我相关
我的任务
分享
unit Unit1;
interface
uses
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
Dialogs, StdCtrls;
type
TForm1 = class(TForm)
Label1: TLabel;
private
procedure WMGetMinMaxInfo(var Message: TWMGetMinMaxInfo); message WM_GETMINMAXINFO;
{ Private declarations }
public
{ Public declarations }
end;
var
Form1 : TForm1;
implementation
procedure TForm1.WMGetMinMaxInfo(var Message: TWMGetMinMaxInfo);
begin
with Message.MinMaxInfo^ do
begin
ptMaxSize.X := 1000; {最大化时宽度}
ptMaxSize.Y := 1000; {最大化时高度}
ptMaxPosition.X := 10; {最大化时左上角横坐标}
ptMaxPosition.Y := 10; {最大化时左上角纵坐标}
end;
Message.Result := 0; {告诉Windows你改变了 minmaxinfo}
inherited;
end;
{$R *.dfm}
end.
procedure TForm1.WMGetMinMaxInfo(var Message: TWMGetMinMaxInfo);
begin
with Message.MinMaxInfo^ do
begin
ptMaxSize.X := 1000; {最大化时宽度}
ptMaxSize.Y := 1000; {最大化时高度}
ptMaxPosition.X := 10; {最大化时左上角横坐标}
ptMaxPosition.Y := 10; {最大化时左上角纵坐标}
end;
Message.Result := 0; {告诉Windows你改变了 minmaxinfo}
inherited;
end;