StringFormat Class
Collapse the table of content
Expand the table of content

StringFormat Class

 

Encapsulates text layout information (such as alignment, orientation and tab stops) display manipulations (such as ellipsis insertion and national digit substitution) and OpenType features. This class cannot be inherited.

Namespace:   System.Drawing
Assembly:  System.Drawing (in System.Drawing.dll)

System.Object
  System.MarshalByRefObject
    System.Drawing.StringFormat

public sealed class StringFormat : MarshalByRefObject, ICloneable, 
	IDisposable

NameDescription
System_CAPS_pubmethodStringFormat()

Initializes a new StringFormat object.

System_CAPS_pubmethodStringFormat(StringFormat)

Initializes a new StringFormat object from the specified existing StringFormat object.

System_CAPS_pubmethodStringFormat(StringFormatFlags)

Initializes a new StringFormat object with the specified StringFormatFlags enumeration.

System_CAPS_pubmethodStringFormat(StringFormatFlags, Int32)

Initializes a new StringFormat object with the specified StringFormatFlags enumeration and language.

NameDescription
System_CAPS_pubpropertyAlignment

Gets or sets horizontal alignment of the string.

System_CAPS_pubpropertyDigitSubstitutionLanguage

Gets the language that is used when local digits are substituted for western digits.

System_CAPS_pubpropertyDigitSubstitutionMethod

Gets the method to be used for digit substitution.

System_CAPS_pubpropertyFormatFlags

Gets or sets a StringFormatFlags enumeration that contains formatting information.

System_CAPS_pubpropertySystem_CAPS_staticGenericDefault

Gets a generic default StringFormat object.

System_CAPS_pubpropertySystem_CAPS_staticGenericTypographic

Gets a generic typographic StringFormat object.

System_CAPS_pubpropertyHotkeyPrefix

Gets or sets the HotkeyPrefix object for this StringFormat object.

System_CAPS_pubpropertyLineAlignment

Gets or sets the vertical alignment of the string.

System_CAPS_pubpropertyTrimming

Gets or sets the StringTrimming enumeration for this StringFormat object.

NameDescription
System_CAPS_pubmethodClone()

Creates an exact copy of this StringFormat object.

System_CAPS_pubmethodCreateObjRef(Type)

Creates an object that contains all the relevant information required to generate a proxy used to communicate with a remote object.(Inherited from MarshalByRefObject.)

System_CAPS_pubmethodDispose()

Releases all resources used by this StringFormat object.

System_CAPS_pubmethodEquals(Object)

Determines whether the specified object is equal to the current object.(Inherited from Object.)

System_CAPS_protmethodFinalize()

Allows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection.(Overrides Object.Finalize().)

System_CAPS_pubmethodGetHashCode()

Serves as the default hash function. (Inherited from Object.)

System_CAPS_pubmethodGetLifetimeService()

Retrieves the current lifetime service object that controls the lifetime policy for this instance.(Inherited from MarshalByRefObject.)

System_CAPS_pubmethodGetTabStops(Single)

Gets the tab stops for this StringFormat object.

System_CAPS_pubmethodGetType()

Gets the Type of the current instance.(Inherited from Object.)

System_CAPS_pubmethodInitializeLifetimeService()

Obtains a lifetime service object to control the lifetime policy for this instance.(Inherited from MarshalByRefObject.)

System_CAPS_pubmethodSetDigitSubstitution(Int32, StringDigitSubstitute)

Specifies the language and method to be used when local digits are substituted for western digits.

System_CAPS_pubmethodSetMeasurableCharacterRanges(CharacterRange[])

Specifies an array of CharacterRange structures that represent the ranges of characters measured by a call to the MeasureCharacterRanges method.

System_CAPS_pubmethodSetTabStops(Single, Single[])

Sets tab stops for this StringFormat object.

System_CAPS_pubmethodToString()

Converts this StringFormat object to a human-readable string.(Overrides Object.ToString().)

Many common formats are provided through the StringFormatFlags enumeration. StringFormat objects can be changed.

.NET Framework
Available since 1.1

Any public static (Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.

Return to top
Show:
© 2016 Microsoft