PDFsharp & MigraDoc Foundation

PDFsharp - A .NET library for processing PDF & MigraDoc Foundation - Creating documents on the fly
It is currently Fri Dec 09, 2022 3:02 am

All times are UTC


Forum rules


Please read this before posting on this forum: Forum Rules



Post new topic Reply to topic  [ 2 posts ] 
Author Message
 Post subject: Cell padding
PostPosted: Mon Dec 15, 2014 10:05 am 
Offline

Joined: Tue Apr 29, 2014 10:21 am
Posts: 27
Is there any way to add cell padding other than increasing border width?
I am currently using borders for styling so don't want to use them for padding.
But if I have to...
Example of cell padding:
Image


Top
 Profile  
Reply with quote  
 Post subject: Re: Cell padding
PostPosted: Mon Dec 15, 2014 10:19 am 
Offline

Joined: Tue Apr 29, 2014 10:21 am
Posts: 27
Ok I found it. Borders.Distance

Code:
        ' Create a new style called DataCell based on style Normal - Distance adds padding
        style = document.Styles.AddStyle("DataCell", "Normal")
        style.ParagraphFormat.Alignment = ParagraphAlignment.Left
        style.ParagraphFormat.Borders.Width = 1
        style.ParagraphFormat.Borders.Distance = "3pt"


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

All times are UTC


Who is online

Users browsing this forum: Bing [Bot] and 28 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