Free Support Forum -

Table text to baseline

Aspose PDF .Net

I have a table with a row with two cells. The text in the left side cell is of a much larger size than the text in the right side cell. The text in the right side cell comes out aligned to the top edge of the cell. I would liks it to align with the bottom of the cell.

I tried adding an "IsBaseline" parameter to the TextInfo I am using to define the text in the right side cell as follows, but the parameter changed nothing. Is there any way to do this?

Dim TextInfo_00b As TextInfo = TextInfoBase.Clone()
TextInfo_00b.Alignment = AlignmentType.Left
TextInfo_00b.IsBaseline = True
TextInfo_00b.FontSize = 10
TextInfo_00b.FontName = "Impact"
TextInfo_00b.BackgroundColor = New Aspose.Pdf.Color(strHeader)
TextInfo_00b.Color = New Aspose.Pdf.Color("White")



This message was posted using Page2Forum from Set Vertical Alignment of Paragraph to Baseline or Topline - Aspose.Pdf for .NET

Hello Bruce,

Thanks for using our products.

In order to set the text as Bottom Aligned in the table cell, please try using the following code line.

Cell.VerticalAlignment = VerticalAlignmentType.Bottom

Besides this, in case you need to use the code snippet that you have shared above, please set the font value to 8 or some smaller value. Please take a look over the attached PDF document which is generated using the code that you have shared (with little modification).

In case it does not satisfy your requirement, please share some sample image which can show us the desired behavior.

We regret for your inconvenience.