向memo插入CheckBox一切正常,但由于memo不能调整行间距,想使用RichEdit,但却显示异常,如何处理?
for i := m + 1 to ustringlist.count - 1 do
begin
n := n + 1;
if Length(ustringlist[i]) > 0 then
begin
cb[i] := TCheckBox.Create(nil);
cb[i].Parent := uxuanxiangmemo;
cb[i].Left := 20;
cb[i].Top := (uwentmemo.Lines.count - 1) * uwentmemo.Font.Size + uwentmemo.Font.Size * 3 + 60 * (n - 1);
cb[i].Width := uwentmemo.Width - 50;
cb[i].Height := 80;
cb[i].Caption := ' ' + ustringlist[i];
cb[i].WordWrap := True;
cb[i].Font.Name := uwentmemo.Font.Name;
cb[i].Font.Size := uwentmemo.Font.Size - 1;
cb[i].Color := clWindow;
cb[i].Font.Color := clWindowText;
end;
end;