Thema: Delphi nonVCL Style ändern

Einzelnen Beitrag anzeigen

Benutzerbild von Luckie
Luckie

Registriert seit: 29. Mai 2002
37.621 Beiträge
 
Delphi 2006 Professional
 
#6

Re: nonVCL Style ändern

  Alt 6. Dez 2004, 16:35
also, wenn du eine Dialog Ressource hast, dann guck dir mal MSDN-Library durchsuchenWM_CTLCOLORDLG an. Bei einem Button ist es nicht so einfach, den musst du komplett selber zeichen, also subclassen. Es gibt zwar die Nachricht MSDN-Library durchsuchenWM_CTLCOLORBTN, aber
Zitat:
By default, the DefWindowProc function selects the default system colors for the button. Buttons with the BS_PUSHBUTTON, BS_DEFPUSHBUTTON, or BS_PUSHLIKE styles do not use the returned brush. Buttons with these styles are always drawn with the default system colors. Drawing push buttons requires several different brushes-face, highlight and shadow-but the WM_CTLCOLORBTN message allows only one brush to be returned. To provide a custom appearance for push buttons, use an owner-drawn button.
Michael
Ein Teil meines Codes würde euch verunsichern.
  Mit Zitat antworten Zitat