GH_TextRenderingConstants

Contains app wide text-rendering constants. When you are drawing your own texts use these constants instead of TextRenderingHint::****

Properties

CenterCenter

#
public static StringFormat CenterCenter { get; }
Gets the String format for Center Center alignment. Do not dispose or modify this StringFormat instance.

FarCenter

#
public static StringFormat FarCenter { get; }
Gets the String format for Far (horizontal) Center (vertical) alignment. Do not dispose or modify this StringFormat instance.

GH_CrispText

#
public static TextRenderingHint GH_CrispText { get; }
Gets the Grasshopper default text rendering hint for crisply drawn strings. By default this hint is TextRenderingHint.ClearTypeGridFit, but it can be changed in the settings.

GH_SmoothText

#
public static TextRenderingHint GH_SmoothText { get; }
Gets the Grasshopper default text rendering hint for smoothly drawn strings. By default this hint is TextRenderingHint.AntiAlias, but it can be changed in the settings.

NearCenter

#
public static StringFormat NearCenter { get; }
Gets the String format for Near (horizontal) Center (vertical) alignment. Do not dispose or modify this StringFormat instance.

Methods

StringFormat

#
public static StringFormat StringFormat(StringAlignment horizontalAlignment, StringAlignment verticalAlignment)
Get a precooked StringFormat instance. Do not modify or dispose instances returned by this method. The format uses NoWrap flags and EllipsisCharacter trimming.
horizontalAlignment (StringAlignment)Alignment
verticalAlignment (StringAlignment)Line alignment