Einzelnen Beitrag anzeigen

Benutzerbild von MaBuSE
MaBuSE

Registriert seit: 23. Sep 2002
Ort: Frankfurt am Main (in der Nähe)
1.837 Beiträge
 
Delphi 10 Seattle Enterprise
 
#6

Re: Beschriftung im Colordialog ändern?

  Alt 15. Dez 2004, 09:41
Zitat von GeorgPeifer:
@MaBuSE danke schonmal für die Anregung.. jetzt fehlen nur noch der Text für Benutzerdefinierte Farben.. die anderen habe ich jetzt
Hier ist ein Beispiel mit fast allen Controlls:
(das Label "Benutzerdefinierte Farben:" habe ich nicht herausgefunden)

Delphi-Quellcode:
procedure TForm1.ColorDialog1Show(Sender: TObject);
var
  i: word;
begin
  SetWindowText(ColorDialog1.Handle, 'Mein Farbendialog');

  SetWindowText(GetDlgItem(ColorDialog1.Handle, 1), '&Ok');
  SetWindowText(GetDlgItem(ColorDialog1.Handle, 2), '&Cancel');
  SetWindowText(GetDlgItem(ColorDialog1.Handle, 719), 'Farben wählen');
  SetWindowText(GetDlgItem(ColorDialog1.Handle, 712), 'Farben hinzufügen');
  SetWindowText(GetDlgItem(ColorDialog1.Handle, 723), 'Farbt.');
  SetWindowText(GetDlgItem(ColorDialog1.Handle, 724), 'Sätt.');
  SetWindowText(GetDlgItem(ColorDialog1.Handle, 725), 'Hell.');
  SetWindowText(GetDlgItem(ColorDialog1.Handle, 726), 'Rot');
  SetWindowText(GetDlgItem(ColorDialog1.Handle, 727), 'Grün');
  SetWindowText(GetDlgItem(ColorDialog1.Handle, 728), 'Blau');

  SetWindowText(GetDlgItem(ColorDialog1.Handle, 730), 'Farbe');
  SetWindowText(GetDlgItem(ColorDialog1.Handle, 731), '|Basis');

  SetWindowText(GetDlgItem(ColorDialog1.Handle, 65535), 'Grundfarben');

// hiermit kann man leicht die Nummern herausfinden ;-)
// for i := 0 to high(i) do SetWindowText(GetDlgItem(ColorDialog1.Handle, i), PChar(intToStr(i)));
end;

procedure TForm1.BitBtn1Click(Sender: TObject);
begin
  ColorDialog1.Execute
end;
(°¿°) MaBuSE - proud to be a DP member
(°¿°) MaBuSE - proud to be a "Rüsselmops" ;-)
  Mit Zitat antworten Zitat