table, with zero linewidth

General TRichView support forum. Please post your questions here
Post Reply
Stef
Posts: 90
Joined: Mon Aug 29, 2005 9:56 am
Contact:

table, with zero linewidth

Post by Stef »

If I insert a table with zero linewidth, (calling RVE.format afterwards),
I don't see any (dotted) lines in my editor.

After closing and reopening the document,
the zero linewidths are beautiful displayed as dotted lines in RVE.

I probably set some property wrong, but cann't figure out which.
Any explanation / solution ?

cheers,
Sergey Tkachenko
Site Admin
Posts: 17566
Joined: Sat Aug 27, 2005 10:28 am
Contact:

Post by Sergey Tkachenko »

If you do not use RichViewActions, grid is controlled by the following variables

RichViewTableGridStyle: TPenStyle = psDot; // in editor
RichViewTableGridStyle2: TPenStyle = psClear; // in viewer and read-only editor
RichViewTableGridColor: TColor = clBtnFace;

These variables are not saved in files, so reloading must not affect them.
But read-only mode does.
Stef
Posts: 90
Joined: Mon Aug 29, 2005 9:56 am
Contact:

Post by Stef »

thanks Sergey, but I don't get it.

I've a table in a RVE, and a radiogroup that sets the linewidth by it's itemindex, like the code below

Code: Select all

  RVEx.BeginItemModify(ItemNo, Data);
  table.BorderWidth:=radiogroup.ItemIndex;
  // table.CellBorderWidth:=radiogroup.itemindex;
  RVEx.EndItemModify(ItemNo, Data);
  RVEx.Change;
end;
Borderwidths of 1,2,3 are working correctly,
but whether I use borderwidth or cellbortherwidth,
with itemindex=0, the borders disappears completly.
The RVE is not in readonly mode.

cheers,
Sergey Tkachenko
Site Admin
Posts: 17566
Joined: Sat Aug 27, 2005 10:28 am
Contact:

Post by Sergey Tkachenko »

I created a very simple project trying to reproduce this problem:
http://www.trichview.com/support/files/tablegrid.zip
But it works as expected, table grid is shown.
Stef
Posts: 90
Joined: Mon Aug 29, 2005 9:56 am
Contact:

Post by Stef »

thanks very much Sergey,

your example helped me very quickly to identify the problem,
after porting all my code to your example,
the problem arised,
then I saw I had made a stupid mistake,
I did add rvtoHideGridLines !!

Sorry for bothering you,
but I really have stared several evenings at this problem,
and couldn't find it.

cheers,
Post Reply