Hallo,
ich versuche gerade einem Speedbutton ein Alignment beizubringen. Allerdings ist CreateParams nicht in der Basisklasse verhanden. Was nehme ich denn da?:
Delphi-Quellcode:
unit AlignSpeedButton;
interface
uses
Windows, Classes, Controls, StdCtrls, Buttons;
type
TAlignSpeedButton =
class(TSpeedButton)
private
FAlignment: TAlignment;
procedure SetAlignment (Value: TAlignment);
protected
procedure CreateParams(
var Params: TCreateParams);
override;
public
{ Public-Deklarationen }
published
property Alignment: TAlignment
read FAlignment
write SetAlignment;
end;
procedure Register;
implementation
procedure Register;
begin
RegisterComponents('
TEST', [TAlignSpeedButton]);
end;
procedure TAlignSpeedButton.SetAlignment(
const Value: TAlignment);
begin
if FAlignment <> Value
then
begin
FAlignment := Value;
Invalidate;
end;
end;
end.
Viele Grüße ...
[edit=mkinzler]Thread-Titel konkretisiert Mfg, mkinzler[/edit]