var
MyForm:TclStyleForm;
MyVertBox:TClVertScrollBox;
lbl1,lbl2:TclProLabel;
contentListview : TClProListView;
contentDesignerPanel : TClProListViewDesignerPanel;
procedure AddDataToListview;
begin
contentListview.clLoadProListViewDataFromDataset(Clomosy.ClDataSetFromJSON('[
{"lbl1":"Entrance","lbl2":1},
{"lbl1":"Problem solving test","lbl2":2},
{"lbl1":"Programs","lbl2":3},
{"lbl1":"Summary","lbl2":4}
]'));
end;
begin
MyForm := TclStyleForm.Create(Self);
MyForm.clSetStyle(MyForm.LightSB);
MyVertBox:= MyForm.AddNewVertScrollBox(MyForm,'MyVertBox');
MyVertBox.Align := alClient;
contentListview := MyForm.AddNewProListView(MyVertBox,'contentListview');
clComponent.SetupComponent(contentListview,'{"Align":"Client","MarginRight":5,"MarginLeft":5, "ListType":"Cart",
"ItemHeight" : 50,"ItemWidth":'+IntToStr((contentListview.Width)/2)+',"ItemColumnCount" : 2,"ItemSpace" : 5,
"BackgroundColor":"null"}');
contentListview.ListType := 'Vertical';
contentDesignerPanel := MyForm.AddNewProListViewDesignerPanel(contentListview,'contentDesignerPanel');
clComponent.SetupComponent(contentDesignerPanel,'{"BorderColor":"#3b485c","BorderWidth":1,"RoundHeight":5,
"RoundWidth":5,"BackgroundColor":"null"}');
contentListview.SetDesignerPanel(contentDesignerPanel);
lbl1:=MyForm.AddNewProLabel(contentDesignerPanel,'lbl1','Topic is here maybe variables,loops');
clComponent.SetupComponent(lbl1,'{"Align":"Left","TextColor":"#000000",
"TextBold":"yes","TextSize":16,"TextHorizontalAlign":"left",
"TextVerticalAlign":"center","AutoSize":"horizontal"}');
contentDesignerPanel.AddPanelObject(lbl1,clCaption);
lbl2:=MyForm.AddNewProLabel(contentDesignerPanel,'lbl2','Topic is here maybe variables,loops');
clComponent.SetupComponent(lbl2,'{"Align":"Right","TextColor":"#000000",
"TextBold":"yes","TextSize":16,"TextHorizontalAlign":"left",
"TextVerticalAlign":"center","AutoSize":"horizontal"}');
contentDesignerPanel.AddPanelObject(lbl2,clText);
AddDataToListview;
MyForm.Run;
end;