I have a MigraDoc table where I specify a row height of 0.75 cm and the text is aligned vertically in the middle of the cell. When I set cell.Format.Shading.Color to something not white, there is still a part of the cell next to the border that is shown as white around all four sides.
I found that I can remove the white section to the left and right of the text by setting column.LeftPadding = 0 and column.RightPadding = 0. However, I cannot figure out how to get white bars at the top / bottom of the text to disappear without affecting the vertical alignment of the text . If I change the height of the line of the paragraph to 0.75 cm, the bars will disappear, but the text will be aligned to the bottom edge of the cell. I cannot set the color of the shading of the columns, because each cell in the column contains a different color. Does anyone know a way to make the paragraph fill the cell vertically (or else get the background color of the form in the cell)?
Here is an example of my code (in C #) where the table is of type MigraDoc.DocumentObjectModel.Tables.Table:
... // Add a column at index
Jeff g
source share