本文整理自网络,侵删。
procedure TForm1.FormKeyDown(Sender: TObject; var Key: Word;
Shift: TShiftState);
var
DC:HDC;
X Y:Integer;
begin
X:=Mouse.CursorPos.X;
Y:=Mouse.CursorPos.Y;
if Key<>VK_Return then Exit;
DC:=GetDC(0);
Color:=GetPixel(DC X Y);
end;
相关阅读 >>
Delphi api �c multibytetowidechar的用法
Delphi fileopendialog1 多选加载大量文件,不受中文文件名影响
pos、ansipos、fillchar在Delphi2010中unicode的问题
更多相关阅读请进入《Delphi》频道 >>