Forum: GUI-Design mit VCL / FireMonkey / Common Controls
Delphi
by Neutral General,
25. Aug 2006
Also bei mir funktioniert
procedure TForm1.Button1Click(Sender: TObject);
var
hDesk : HWND;
hdcDesktop : HDC;
begin
hDesk := GetDesktopWindow;
hdcDesktop := GetWindowDC(hDesk);
Form1.Color := GetPixel(hdcDesktop, 81, 961);
Forum: GUI-Design mit VCL / FireMonkey / Common Controls
Delphi
by Neutral General,
25. Aug 2006
Vielleicht hilft das ja:
function TCanvas.GetPixel(X, Y: Integer): TColor;
begin
RequiredState();
GetPixel := Windows.GetPixel(FHandle, X, Y);
end;
So bekommt TCanvas seine Pixel :)