Using Stamper Class for appending headers and footers for ODF

Product: PdfNet

Product Version: 10.3.8

Using Stamper class for appending headers and footers

Hi,
In the Stamper Class Constructor what are the use of parameters titles a and b (Class Stamper). It just says “the a” and “the b” which I couldn’t find out what they really mean. “the a” seems to be the font size, then what is the other parameter?
One more question is there a way I can specify the font of a stamper object (.SetFont()) to use something like a general sans font?

I’m using c#

Thank you!

1 Like

Thank you for posting your question to our forum. We will provide you with an update as soon as possible.

1 Like

Thank you for contacting us about this and apologies for the confusion with the API. We will update the documentation to better reflect this.

size_type Specifies how the stamp will be sized and a and b will depend on the size_type:

e_relative_scale: Stamp size is relative to the size of the crop box of the destination page.

  • a is a percentage of the width of the crop box (e.g.: 0.5 is 50% of the width of the crop box)
  • b is a percentage of the height of the crop box. If a <= 0 then only b will be used. If b <= 0 then only a will be used.

e_absolute_scale: Stamp size is explicitly set.

  • a sets the width of of the stamp’s bounding box.
  • b sets the height of the stamp’s bounding box. The width and height are constant, regardless of the size of the destination page’s bounding box.

e_font_size: This type only applies to text stamps.

  • a sets the font size.
  • b is ignored.
1 Like

Thank you for the clarification! If I’m using e_font_size I suppose setting 0 to “b” is no harm then? since its ignored?

1 Like

Yes, you may set it to any value as it is ignored.

1 Like