|
@@ -21,6 +21,7 @@ type
|
|
|
ButtonLabel: TLabel;
|
|
|
FontSizeSlider: TDemoSlider;
|
|
|
BorderWidthSlider: TDemoSlider;
|
|
|
+ BorderRadiusSlider: TDemoSlider;
|
|
|
end;
|
|
|
|
|
|
var
|
|
@@ -37,7 +38,7 @@ begin
|
|
|
Stylesheet.Add('#ButtonDiv {'
|
|
|
+'background:#44c767;'
|
|
|
+'border:1px solid #18ab29;'
|
|
|
- +'border-radius:28px;'
|
|
|
+ +'border-radius:16px;'
|
|
|
+'padding:16px 31px;'
|
|
|
+'font-size:15px; font-family:Arial; font-weight:bold;'
|
|
|
+'color:#fff;'
|
|
@@ -49,7 +50,7 @@ begin
|
|
|
with FontSizeSlider do begin
|
|
|
Name:='FontSizeSlider';
|
|
|
Caption:='Font Size:';
|
|
|
- Style:='width: 100px';
|
|
|
+ Style:='width: 150px';
|
|
|
ValueFormat:='%.0fpx';
|
|
|
MinPosition:=5;
|
|
|
MaxPosition:=40;
|
|
@@ -62,7 +63,7 @@ begin
|
|
|
with BorderWidthSlider do begin
|
|
|
Name:='BorderWidthSlider';
|
|
|
Caption:='Border Width:';
|
|
|
- Style:='width: 100px';
|
|
|
+ Style:='width: 150px';
|
|
|
ValueFormat:='%.0fpx';
|
|
|
MinPosition:=0;
|
|
|
MaxPosition:=10;
|
|
@@ -71,6 +72,19 @@ begin
|
|
|
OnChange:=@OnPropChange;
|
|
|
end;
|
|
|
|
|
|
+ BorderRadiusSlider:=TDemoSlider.Create(Self);
|
|
|
+ with BorderRadiusSlider do begin
|
|
|
+ Name:='BorderRadiusSlider';
|
|
|
+ Caption:='Border Radius:';
|
|
|
+ Style:='width: 150px';
|
|
|
+ ValueFormat:='%.0fpx';
|
|
|
+ MinPosition:=0;
|
|
|
+ MaxPosition:=50;
|
|
|
+ Position:=16;
|
|
|
+ Parent:=Self;
|
|
|
+ OnChange:=@OnPropChange;
|
|
|
+ end;
|
|
|
+
|
|
|
ButtonDiv:=TDiv.Create(Self);
|
|
|
with ButtonDiv do begin
|
|
|
Name:='ButtonDiv';
|
|
@@ -79,6 +93,7 @@ begin
|
|
|
ButtonLabel:=TLabel.Create(Self);
|
|
|
with ButtonLabel do begin
|
|
|
Name:='ButtonLabel';
|
|
|
+ Caption:='Button Text';
|
|
|
Parent:=ButtonDiv;
|
|
|
end;
|
|
|
|
|
@@ -96,6 +111,8 @@ begin
|
|
|
ButtonDiv.Style:=
|
|
|
'font-size:'+FloatToStr(FontSizeSlider.Position)+'px;'
|
|
|
+'border-width:'+FloatToStr(BorderWidthSlider.Position)+'px;'
|
|
|
+ +'border-radius:'+FloatToStr(BorderRadiusSlider.Position)+'px;'
|
|
|
+ ;
|
|
|
end;
|
|
|
|
|
|
end.
|