Fixed cells
Posted: Tue Mar 04, 2008 11:04 am
Is it possible to make table cells of fixed size?
Support forums for TRichView, ScaleRichView, Report Workshop and RVMedia components
https://writeally.com/forums/
Hi, Sergey!Sergey Tkachenko wrote:You can include rvtoIgnoreContentWidth and rvtoIgnoreContentHeight in table.Options. In this mode, width and heights of all cells are calculated basing on their BestWidth and BestHeight properties, sizes of cells contents are ignored.
Code: Select all
table := TRVTableItemInfo.CreateEx(2, 2, RichViewEdit1.RVData);
table.Options := table.Options + [rvtoIgnoreContentWidth, rvtoIgnoreContentHeight];
for r := 0 to table.RowCount-1 do
for c := 0 to table.ColCount-1 do begin
table.Cells[r,c].BestWidth := 100;
table.Cells[r,c].BestHeight := 100;
end;
RichViewEdit1.InsertItem('', table);