unit1.pas

来自「在深度历险网站上发布的所有delphi程序原码。对初学delphi者很有用。」· PAS 代码 · 共 46 行

PAS
46
字号
unit Unit1;

interface

uses
  Windows, Messages, SysUtils, Classes, Graphics, Controls, Forms,
  Dialogs, StdCtrls, ExtCtrls;

type
  TForm1 = class(TForm)
    procedure FormResize(Sender: TObject);
    procedure FormPaint(Sender: TObject);
  private
    { Private declarations }
    procedure WMMove(var message: TWMMove); message WM_MOVE;
  public
    { Public declarations }
  end;

var
  Form1: TForm1;

implementation

{$R *.DFM}

procedure TForm1.FormResize(Sender: TObject);
begin
  PaintDesktop(Canvas.Handle);
end;

procedure TForm1.FormPaint(Sender: TObject);
begin
  PaintDesktop(Canvas.Handle);
end;

procedure TForm1.WMMove(var message: TWMMove);
begin
  inherited;

  PaintDesktop(Canvas.Handle);
end;

end.

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?