Concepts
Units
Length units of measure.
FluentWriter uses points as the default unit of measure of font size and inches for all other spatial properties. Most Fluent API methods accept an optional unit parameter for specifying alternative measurement units.
Available Units
| Unit | Description |
|---|---|
| Unit.Twip | Twentieths of an Imperial Point (twip) |
| Unit.EMU | English Metric Unit (EMU) |
| Unit.Point | Point (1/72 inch) |
| Unit.Millimeter | Millimeter |
| Unit.Centimeter | Centimeter |
| Unit.Meter | Meter |
| Unit.Inch | Inch |
| Unit.Feet | Feet |
Example
Unit types can be optionally specified in most of length-related API methods. As an example, the following code snippets are equivalent:
using FluentWriter.Common;
paragraph.Margin(1)
paragraph.Margin(1/12f, Unit.Feet)
paragraph.Margin(72, Unit.Point)