ActionComponents  04.05.00
Customizable UI and time-saving tools for Android development with Xamarin and Visual Studio.
Foundation.NSString Class Reference

Simulates an iOS NSString to ease the porting of UI code from iOS to Android. A NSString can be implicitly converted to and from a standard C# String. More...

Public Member Functions

 NSString ()
 Initializes a new instance of the T:Foundation.NSString class. More...
 
 NSString (String text)
 Initializes a new instance of the T:Foundation.NSString class. More...
 
void DrawString (CGRect rect, UIFont font, UILineBreakMode mode, UITextAlignment alignment)
 Draws the string into the canvas from the current context of the UIGraphics class using the given properties. More...
 
void DrawString (CGRect rect, UIFont font, UILineBreakMode mode, UITextAlignment alignment, TextBlockAlignment verticalAlignment)
 Draws the string into the canvas from the current context of the UIGraphics class using the given properties. More...
 
void DrawString (CGRect rect, UIStringAttributes attributes)
 Draws the string into the current graphics context inside of the given rect with the given attributes. More...
 
CGRect GetBoundingRect (CGSize size, NSStringDrawingOptions options, UIStringAttributes attributes, CGPoint location)
 Gets the bounding rect for the string. More...
 

Static Public Member Functions

static implicit operator String (NSString text)
 Converts the NSString to a String. More...
 
static implicit operator NSString (String text)
 Converts the String to a NSString. More...
 

Properties

String Text [get, set]
 Gets or sets the text of the string. More...
 

Detailed Description

Simulates an iOS NSString to ease the porting of UI code from iOS to Android. A NSString can be implicitly converted to and from a standard C# String.

Constructor & Destructor Documentation

Foundation.NSString.NSString ( )

Initializes a new instance of the T:Foundation.NSString class.

Here is the caller graph for this function:

Foundation.NSString.NSString ( String  text)

Initializes a new instance of the T:Foundation.NSString class.

Parameters
textText.

Member Function Documentation

void Foundation.NSString.DrawString ( CGRect  rect,
UIFont  font,
UILineBreakMode  mode,
UITextAlignment  alignment 
)

Draws the string into the canvas from the current context of the UIGraphics class using the given properties.

Parameters
rectRect.
fontFont.
modeMode.
alignmentAlignment.

Here is the caller graph for this function:

void Foundation.NSString.DrawString ( CGRect  rect,
UIFont  font,
UILineBreakMode  mode,
UITextAlignment  alignment,
TextBlockAlignment  verticalAlignment 
)

Draws the string into the canvas from the current context of the UIGraphics class using the given properties.

Parameters
rectRect.
fontFont.
modeMode.
alignmentAlignment.
verticalAlignmentvertical alignment.

Here is the call graph for this function:

void Foundation.NSString.DrawString ( CGRect  rect,
UIStringAttributes  attributes 
)

Draws the string into the current graphics context inside of the given rect with the given attributes.

Parameters
rectRect.
attributesAttributes.

Here is the call graph for this function:

CGRect Foundation.NSString.GetBoundingRect ( CGSize  size,
NSStringDrawingOptions  options,
UIStringAttributes  attributes,
CGPoint  location 
)

Gets the bounding rect for the string.

Returns
The bounding rect.
Parameters
sizeSize.
optionsOptions.
attributesAttributes.
locationLocation.

Here is the call graph for this function:

Here is the caller graph for this function:

static implicit Foundation.NSString.operator NSString ( String  text)
static

Converts the String to a NSString.

Returns
The implicitly converted NSString.
Parameters
textText.

Here is the call graph for this function:

static implicit Foundation.NSString.operator String ( NSString  text)
static

Converts the NSString to a String.

Returns
The implicitly converted String.
Parameters
textText.

Property Documentation

String Foundation.NSString.Text
getset

Gets or sets the text of the string.

The text.