Skip to main content
A newer version of this page is available. .

Units Members

Helper class with static methods used for unit conversion.

Methods

Name Description
CentimetersToDocumentsF(Single) static Converts a measurement from centimeters to documents. Returns the converted measurement as a Single.
CentimetersToTwipsF(Single) static Converts a measurement from centimeters to twips. Returns the converted measurement as a Single.
DocumentsToCentimetersF(Single) static Converts a measurement from documents to centimeters. Returns the converted measurement as a Single.
DocumentsToEmu(Int32) static Converts a measurement from documents to EMUs (English Metric Unit).
DocumentsToEmuD(Single) static Converts a measurement from EMUs (English Metric Unit) to documents (double-precision floating point value).
DocumentsToEmuF(Single) static Converts a measurement from EMUs (English Metric Unit) to documents represented by 64-bit integers.
DocumentsToEmuL(Int64) static Converts a measurement from document units (documents) to EMUs (English Metric Unit) represented by 64-bit integers.
DocumentsToHundredthsOfInch(Size) static Converts measurements in the Size structure from documents to hundredths of an inch.
DocumentsToHundredthsOfInch(Int32) static Converts a measurement from documents to hundredths of an inch. Returns the converted measurement as an Integer.
DocumentsToHundredthsOfMillimeter(Size) static Converts measurements from documents to hundredths of a millimeter.
DocumentsToHundredthsOfMillimeter(Int32) static Converts a measurement from documents to hundredths of an inch. Returns the converted measurement as an Integer.
DocumentsToInchesF(Single) static Converts a measurement from documents to inches. Returns the converted measurement as a Single.
DocumentsToMillimetersF(Single) static Converts a measurement from documents to millimeters. Returns the converted measurement as a Single.
DocumentsToPicasF(Single) static Converts a measurement from documents to picas. Returns the converted measurement as a Single.
DocumentsToPixels(Point, Single, Single) static Converts rectangle coordinates from documents to pixels.
DocumentsToPixels(Rectangle, Single, Single) static Converts point coordinates from documents to pixels.
DocumentsToPixels(RectangleF, Single, Single) static Converts a rectangle from documents to pixels.
DocumentsToPixels(Size, Single, Single) static Converts height and width from documents to pixels.
DocumentsToPixels(Int32, Single) static Converts a measurement from documents to pixels. Returns the converted measurement as an Integer.
DocumentsToPixelsF(Single, Single) static Converts a measurement from documents to pixels. Returns the converted measurement as a Double.
DocumentsToPoints(Int32) static Converts a measurement from documents to points. Returns the converted measurement as an Integer.
DocumentsToPointsF(Single) static Converts a measurement from documents to points. Returns the converted measurement as a Single.
DocumentsToPointsFRound(Single) static Converts a measurement from documents to points and rounds the result. Returns the converted measurement as a Single.
DocumentsToTwips(Rectangle) static Converts measurements from documents to twips.
DocumentsToTwips(RectangleF) static Converts measurements from documents to twips.
DocumentsToTwips(Size) static Converts measurements from documents to twips.
DocumentsToTwips(Int32) static Converts a measurement from documents to twips. Returns the converted measurement as an Integer.
DocumentsToTwipsF(Single) static Converts a measurement from documents to twips. Returns the converted measurement as a Single.
DocumentsToTwipsL(Int64) static Converts measurements from 64-bit signed integers to twips.
EmuToDocuments(Int32) static Converts a measurement from EMUs (English Metric Unit) to documents.
EmuToDocumentsD(Double) static Converts a measurement from EMUs (double-precision floating point value) to documents (floating point value).
EmuToDocumentsF(Int32) static Converts a measurement from EMUs (English Metric Unit) to documents (floating point value).
EmuToDocumentsL(Int64) static Converts a measurement from EMUs (English Metric Unit) to documents represented by 64-bit integers.
EmuToTwips(Int32) static Converts a measurement from EMUs (English Metric Unit) to twips.
EmuToTwipsD(Double) static Converts a measurement from EMUs (double-precision floating point value) to twips (floating point value).
EmuToTwipsF(Int32) static Converts a measurement from EMUs (English Metric Unit) to twips (floating point value).
EmuToTwipsL(Int64) static Converts a measurement from EMUs (English Metric Unit) to twips represented by 64-bit integers.
Equals(Object, Object) static Determines whether the specified object instances are considered equal. Inherited from Object.
Equals(Object) Determines whether the specified object is equal to the current object. Inherited from Object.
GetHashCode() Serves as the default hash function. Inherited from Object.
GetType() Gets the Type of the current instance. Inherited from Object.
HundredthsOfInchToDocuments(Size) static Converts measurements in the Size structure from hundredths of an inch to documents.
HundredthsOfInchToDocuments(Int32) static Converts a measurement from hundredths of an inch to documents. Returns the converted measurement as an Integer.
HundredthsOfInchToTwips(Size) static Converts measurements in the Size structure from hundredths of an inch to twips.
HundredthsOfInchToTwips(Int32) static Converts a measurement from hundredths of an inch to twips. Returns the converted measurement as an Integer.
HundredthsOfMillimeterToDocuments(Size) static Converts measurements from hundredths of a millimeter to documents.
HundredthsOfMillimeterToDocuments(Int32) static Converts a measurement from hundredths of a millimeter to documents. Returns the converted measurement as an Integer.
HundredthsOfMillimeterToDocumentsRound(Size) static Converts measurements from hundredths of a millimeter to documents and rounds them to the nearest whole value.
HundredthsOfMillimeterToPixels(Size, Single, Single) static Converts a measurement from hundredths of a millimeter to pixels.
HundredthsOfMillimeterToPixels(Int32, Single) static Converts a measurement from hundredths of a millimeter to pixels. Returns the converted measurement as an Integer.
HundredthsOfMillimeterToTwips(Size) static Converts measurements from hundredths of a millimeter to twips.
HundredthsOfMillimeterToTwips(Int32) static Converts a measurement from hundredths of a millimeter to twips. Returns the converted measurement as an Integer.
HundredthsOfMillimeterToTwipsRound(Size) static Converts measurements from hundredths of a millimeter to twips and rounds them to the whole number nearest to the twip value.
InchesToDocumentsF(Single) static Converts a measurement from inches to documents. Returns the converted measurement as a Single.
InchesToPointsF(Single) static Converts a measurement from inches to points. Returns the converted measurement as a Single.
InchesToTwipsF(Single) static Converts a measurement from inches to twips. Returns the converted measurement as a Single.
MemberwiseClone() protected Creates a shallow copy of the current Object. Inherited from Object.
MillimetersToDocumentsF(Single) static Converts a measurement from millimeters to documents. Returns the converted measurement as a Single.
MillimetersToPoints(Int32) static Converts a measurement from millimeters to points. Returns the converted measurement as an Integer.
MillimetersToPointsF(Single) static Converts a measurement from millimeters to points. Returns the converted measurement as a Single.
MillimetersToTwipsF(Single) static Converts a measurement from millimeters to twips. Returns the converted measurement as a Single.
MulDiv(Int32, Int32, Single) static Multiplies two integer values and then divides the result by a floating point value. The final result is cast to an integer (rounded to the nearest integer dropping the values after the decimal place).
MulDiv(Int32, Single, Int32) static Multiplies two integer values and then divides the result by another integer value. The final result is cast to an integer (rounded to the nearest integer dropping the values after the decimal place).
MulDivD(Double, Double, Double) static Multiplies two double-precision floating-point values and then divides the result by another double-precision floating-point value. The final result is cast to a Double (rounded to the nearest integer dropping the values after the decimal place).
MulDivF(Single, Single, Single) static Multiplies two floating point values and then divides the result by another floating point value.
PicasToDocumentsF(Single) static Converts a measurement from picas to documents. Returns the converted measurement as a Single.
PicasToTwipsF(Single) static Converts a measurement from picas to twips. Returns the converted measurement as a Single.
PixelsToDocuments(Double, Single) static Converts a measurement from pixels to documents. Returns the converted measurement as an Integer.
PixelsToDocuments(Point, Single, Single) static Converts point coordinates from pixels to documents.
PixelsToDocuments(Rectangle, Single, Single) static Converts a rectangle from pixels to documents.
PixelsToDocuments(RectangleF, Single, Single) static Converts rectangle coordinates from pixels to documents.
PixelsToDocuments(Size, Single, Single) static Converts measurements from pixels to documents.
PixelsToDocuments(Int32, Single) static Converts a measurement from pixels to documents. Returns the converted measurement as an Integer.
PixelsToDocumentsF(Single, Single) static Converts a measurement from pixels to documents. Returns the converted measurement as a Single.
PixelsToDocumentsRound(Size, Single, Single) static Converts measurements from pixels to documents and rounds them to the nearest whole number.
PixelsToHundredthsOfInch(Size, Single) static Converts measurements from pixels to hundredths of an inch.
PixelsToHundredthsOfInch(Int32, Single) static Converts a measurement from pixels to hundredths of an inch. Returns the converted measurement as an Integer.
PixelsToHundredthsOfMillimeter(Size, Single, Single) static Converts measurements from pixels to hundredths of a millimeter.
PixelsToHundredthsOfMillimeter(Int32, Single) static Converts a measurement from pixels to hundredths of a millimeter. Returns the converted measurement as an Integer.
PixelsToPoints(Int32, Single) static Converts a measurement from pixels to points.
PixelsToPointsF(Single, Single) static Converts a measurement from pixels to points.
PixelsToTwips(Rectangle, Single, Single) static Converts a rectangle from pixels to twips.
PixelsToTwips(Size, Single, Single) static Converts measurements from pixels to twips.
PixelsToTwips(Int32, Single) static Converts a measurement from pixels to twips. Returns the converted measurement as an Integer.
PixelsToTwipsF(Single, Single) static Converts a measurement from pixels to twips. Returns the converted measurement as a Single.
PixelsToTwipsL(Int64, Single) static Converts a measurement from pixels to twips. Returns the converted measurement as an Int64.
PixelsToTwipsRound(Size, Single, Single) static Converts measurements from pixels to twips and rounds their values to the nearest whole number.
PointsToDocuments(Int32) static Converts a measurement from points to documents. Returns the converted measurement as an Integer.
PointsToDocumentsF(Single) static Converts a measurement from points to documents. Returns the converted measurement as a Single.
PointsToPixels(Int32, Single) static Converts a measurement from points to pixels. Returns the converted measurement as an Integer.
PointsToPixelsF(Single, Single) static Converts a measurement from points to pixels. Returns the converted measurement as a Single.
PointsToTwips(Int32) static Converts a measurement from points to twips. Returns the converted measurement as an Integer.
PointsToTwipsF(Single) static Converts a measurement from points to twips. Returns the converted measurement as a Single.
ReferenceEquals(Object, Object) static Determines whether the specified Object instances are the same instance. Inherited from Object.
ToString() Returns a string that represents the current object. Inherited from Object.
TwipsToCentimetersF(Single) static Converts a measurement from twips to centimeters. Returns the converted measurement as a Single.
TwipsToDocuments(Rectangle) static Converts a rectangle from documents to twips.
TwipsToDocuments(RectangleF) static Converts rectangle coordinates from twips to documents.
TwipsToDocuments(Size) static Converts measurements from twips to documents.
TwipsToDocuments(Int32) static Converts a measurement from twips to documents. Returns the converted measurement as an Integer.
TwipsToDocumentsF(Single) static Converts a measurement from twips to documents. Returns the converted measurement as a Single.
TwipsToDocumentsL(Int64) static Converts a measurement from twips to documents. Returns the converted measurement as an Int64.
TwipsToEmu(Int32) static Converts a measurement from twips to EMUs (English Metric Unit).
TwipsToEmuD(Single) static Converts a measurement from twips (floating point value) to EMUs (double-precision floating point value).
TwipsToEmuF(Single) static Converts a measurement from twips (floating point value) to EMUs (English Metric Unit).
TwipsToEmuL(Int64) static Converts a measurement from twips to EMUs (English Metric Unit) represented by 64-bit integers.
TwipsToHundredthsOfInch(Size) static Converts measurements in the Size structure from twips to hundredths of an inch.
TwipsToHundredthsOfInch(Int32) static Converts a measurement from twips to hundredths of an inch. Returns the converted measurement as an Integer.
TwipsToHundredthsOfMillimeter(Size) static Converts measurements from twips to hundredths of a millimeter.
TwipsToInchesF(Single) static Converts a measurement from twips to inches. Returns the converted measurement as a Single.
TwipsToMillimetersF(Single) static Converts a measurement from twips to millimeters. Returns the converted measurement as a Single.
TwipsToPixels(Point, Single, Single) static Converts point coordinates from twips to pixels.
TwipsToPixels(Rectangle, Single, Single) static Converts a rectangle from twips to pixels.
TwipsToPixels(Size, Single, Single) static Converts height and width from twips to pixels.
TwipsToPixels(Int32, Single) static Converts a measurement from twips to pixels. Returns the converted measurement as an Integer.
TwipsToPixelsF(Single, Single) static Converts a measurement from twips to pixels. Returns the converted measurement as a Single.
TwipsToPixelsL(Int64, Single) static Converts a measurement from twips to pixels. Returns the converted measurement as an Int64.
TwipsToPointsF(Single) static Converts a measurement from twips to points. Returns the converted measurement as a Single.
TwipsToPointsFRound(Single) static Converts a measurement from twips to points and rounds the result. Returns the converted measurement as a Single.
See Also