Single Row Borders in FlowDocument Tables

I have a FlowDocument table in which I want to tweak the layout a bit. I think something like a thin line separating the sub-states in the invoice from the total, or something like the line under the heading, usually used in standard Word 2007+ styles. I was hoping I could just add an empty TableRow and set the height to a few pixel units, but I did not find a property to force the row height as I wish.

Is there a way (or hack) to make a thin border line below or above the whole line in System.Windows.Documents.Table?

+4
source share
2 answers

Developed a hack. Setting FontSize to something small allowed me to compress the line height.

<TableRow Background="Black" FontSize="0.01"> <TableCell ColumnSpan="2" /> </TableRow> 

The above works, but the line is still quite thick. Any suggestions for lowering the height even further?

+2
source

When I print this out, it just looks like a feint line.

 <TableRow FontSize="0.008"> <TableCell Padding="0" BorderBrush="Gray" BorderThickness="0.5" ColumnSpan="5" /> </TableRow> 

Make sure the table CellSpacing="0"

I define TableColumns for vertical lines between columns:

 <Table.Columns> <TableColumn Width="140" Name="colItems" /> <TableColumn Width="0" Name="colSpace1" /> <TableColumn Name="colDescription" /> <TableColumn Width="0" Name="colSpace2" /> <TableColumn Width="150" Name="colAmount"/> </Table.Columns> 

Then in the TableRowGroup for the title bar:

 <TableRow FontSize="14"> <TableCell TextAlignment="Center" Padding="0,4,0,2"> <Paragraph>ITEMS</Paragraph> </TableCell> <TableCell BorderBrush="Gray" BorderThickness="0.5" /> <TableCell TextAlignment="Center" Padding="0,4,0,2"> <Paragraph>DESCRIPTION</Paragraph> </TableCell> <TableCell BorderBrush="Gray" BorderThickness="0.5" /> <TableCell TextAlignment="Center" Padding="0,4,0,2"> <Paragraph>AMOUNT</Paragraph> </TableCell> </TableRow> 

Oliver

+9
source

All Articles