Skip to main content
K.Daube
Community Expert
Community Expert
Dec 7, 2018 3:00 PM UTC
Question

Centering a TextLine

Dear friends,

Again I was mislead by the name of a property

oTextLine.TextLineType = Constants.FV_TEXTLINE_CENTER;

I thought that this would be useful to center the text within a given space. But I could not find how to use it.

I found a straight-forward method:

Towards the end of my function I have inserted (aLenght is the space width):

  textLen = oTextLine.Width;

  boundLeft = (aLength*CM - textLen)/2;

  oTextLine.BasePointX = x0*CM + boundLeft;

This topic is closed to new replies. Start a new post to keep the conversation going.