PDFsharp & MigraDoc Foundation

PDFsharp - A .NET library for processing PDF & MigraDoc Foundation - Creating documents on the fly
It is currently Sun Jun 30, 2024 8:20 pm

All times are UTC


Forum rules


Please read this before posting on this forum: Forum Rules



Post new topic Reply to topic  [ 3 posts ] 
Author Message
 Post subject: Row/Cell shading
PostPosted: Thu Mar 07, 2013 4:53 pm 
Offline

Joined: Fri Mar 01, 2013 3:37 pm
Posts: 2
I've got two tables I'm making for a PDF. They both have zebra strips (i.e., alternating row colors). They both have cells that wrap their text, which makes the cell larger than the other cells in that row. On one table, the larger cell is not an issue because all of the other cells on the row are completely filled with the shading. On the other table, the larger cell stands out like a sore thumb because the other, smaller cells aren't shaded like the larger.

For example, the table that works would have a row that looks like this (code block used for fixed width font):

One row
Code:
------- ----- --------
------- ----- --------


the other table has rows that look like this:

Code:
------ ----- ------
       -----


where the dashes represent shading and the spaces represent the edge of a cell. I would like for the other table rows to have all of their cells have even shading, instead of the staggered effect which is quite unsightly.

What am I missing to accomplish this?


Top
 Profile  
Reply with quote  
 Post subject: Re: Row/Cell shading
PostPosted: Mon Mar 11, 2013 9:32 am 
Offline
PDFsharp Guru
User avatar

Joined: Mon Oct 16, 2006 8:16 am
Posts: 3100
Location: Cologne, Germany
I presume you set the shading of the cells. Set the shading of the row instead.

_________________
Regards
Thomas Hoevel
PDFsharp Team


Top
 Profile  
Reply with quote  
 Post subject: Re: Row/Cell shading
PostPosted: Mon Mar 11, 2013 1:53 pm 
Offline

Joined: Fri Mar 01, 2013 3:37 pm
Posts: 2
Thomas,

Yes, I set the shading of the cells, but that was after setting the shading of the rows. I tried both methods, yet I'm still not getting the behavior desired. The table that works has cell shading, so I figured that would do it. On the second table (the one that doesn't work properly), I added borders to the cells and noticed plenty of space that wasn't being shaded.

The code to generate the two tables is very similar. I wouldn't expect such a difference in the outcome.

Thank you for your help!


Top
 Profile  
Reply with quote  
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 3 posts ] 

All times are UTC


Who is online

Users browsing this forum: No registered users and 47 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Privacy Policy, Data Protection Declaration, Impressum
Powered by phpBB® Forum Software © phpBB Group