This repository has been archived on 2024-12-25. You can view files and clone it, but cannot push or open issues or pull requests.
OldPascalProjects/Graphics/Controls/cc6_CheckBoxes2.pas
2024-03-10 20:32:51 +03:00

33 lines
836 B
ObjectPascal
Raw Permalink Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

// Модуль Controls - флажки
uses WPFObjects,Controls;
begin
Window.Title := 'Модуль Controls - флажки';
LeftPanel(170);
var tb := TextBlock('Параметры круга:');
tb.Margin := 12;
var cb1 := new CheckBoxWPF('Заливка');
var cb2 := new CheckBoxWPF('Жирная граница');
var cb3 := new CheckBoxWPF('С текстом');
var c := new CircleWPF(GraphWindow.Center,60,Colors.White,1);
cb1.Click := procedure -> begin
if cb1.Checked then
c.Color := Colors.Green
else c.Color := Colors.White
end;
cb2.Click := procedure -> begin
if cb2.Checked then
c.BorderWidth := 4
else c.BorderWidth := 1
end;
cb3.Click := procedure -> begin
if cb3.Checked then
c.Text := 'Текст'
else c.Text := ''
end;
end.