📄 childform.pas
字号:
unit childform;
interface
uses
Windows, Messages, SysUtils, Classes, Graphics, Controls, Forms, Dialogs,
ExtCtrls, StdCtrls, Buttons, ImgList, ComCtrls, ToolWin, Menus;
type
TForm2 = class(TForm)
Panel1: TPanel;
Panel2: TPanel;
Button1: TButton;
Panel3: TPanel;
Button2: TButton;
Panel4: TPanel;
Button3: TButton;
Panel5: TPanel;
Button4: TButton;
Image1: TImage;
Image2: TImage;
Image3: TImage;
Image4: TImage;
Image5: TImage;
Label1: TLabel;
Label2: TLabel;
Label3: TLabel;
Label4: TLabel;
Label5: TLabel;
Image6: TImage;
Label6: TLabel;
Image8: TImage;
Label8: TLabel;
Image9: TImage;
Label9: TLabel;
Image10: TImage;
Image11: TImage;
Image12: TImage;
Image13: TImage;
Image14: TImage;
Image15: TImage;
Label10: TLabel;
Label11: TLabel;
Label12: TLabel;
Label13: TLabel;
Label14: TLabel;
Label15: TLabel;
Image16: TImage;
Image17: TImage;
Image18: TImage;
Image22: TImage;
Label16: TLabel;
Label17: TLabel;
Label18: TLabel;
Label19: TLabel;
Image19: TImage;
Image20: TImage;
Image21: TImage;
Image23: TImage;
Image24: TImage;
Label20: TLabel;
Label21: TLabel;
Label22: TLabel;
Label23: TLabel;
Label24: TLabel;
Label7: TLabel;
Label25: TLabel;
procedure Button1Click(Sender: TObject);
procedure Button2Click(Sender: TObject);
procedure Button3Click(Sender: TObject);
procedure Button4Click(Sender: TObject);
private
{ Private declarations }
public
{ Public declarations }
end;
var
Form2: TForm2;
implementation
{$R *.DFM}
procedure TForm2.Button1Click(Sender: TObject);
begin
//panel2.top:=437;
panel3.top:=462;
panel4.top:=487;
panel5.top:=512;
//panel2.height:=125;
panel3.height:=75;
panel4.height:=50;
panel5.height:=25;
end;
procedure TForm2.Button2Click(Sender: TObject);
begin
if panel3.top=25 then //弹下去
begin
//panel2.top:=437;
//panel3.top:=462;
panel4.top:=487;
panel5.top:=512;
//panel2.height:=125;
//panel3.height:=75;
panel4.height:=50;
panel5.height:=25;
end
else //弹上来
begin
panel2.top:=0;
panel3.top:=25;
//panel4.top:=50;
//panel5.top:=75;
panel2.height:=537;
panel3.height:=512;
//panel4.height:=487;
//panel5.height:=462;
end;
end;
procedure TForm2.Button3Click(Sender: TObject);
begin
if panel4.top=50 then//弹下去
begin
//panel2.top:=437;
//panel3.top:=462;
//panel4.top:=487;
panel5.top:=512;
//panel2.height:=125;
//panel3.height:=75;
//panel4.height:=50;
panel5.height:=25;
end
else //弹上来
begin
panel2.top:=0;
panel3.top:=25;
panel4.top:=50;
//panel5.top:=75;
panel2.height:=537;
panel3.height:=512;
panel4.height:=487;
//panel5.height:=462;
end;
end;
procedure TForm2.Button4Click(Sender: TObject);
begin
if panel5.top=75 then//弹下去
begin
//panel2.top:=437;
//panel3.top:=462;
//panel4.top:=487;
//panel5.top:=512;
//panel2.height:=125;
//panel3.height:=75;
//panel4.height:=50;
//panel5.height:=25;
end
else //弹上来
begin
panel2.top:=0;
panel3.top:=25;
panel4.top:=50;
panel5.top:=75;
panel2.height:=537;
panel3.height:=512;
panel4.height:=487;
panel5.height:=462;
end;
end;
end.
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -