[]
        
(Showing Draft Content)

C1.Xaml.Pdf.C1WordDocument.DrawString

DrawString Method

DrawString(string, Font, Brush, Rect, StringFormat)

Draws the specified text string in the specified rectangle with the specified Brush and C1.Util.Font objects using the formatting attributes of the specified C1.Util.StringFormat object.

Declaration
public int DrawString(string text, Font font, Brush brush, Rect rc, StringFormat sf)
Public Function DrawString(text As String, font As Font, brush As Brush, rc As Rect, sf As StringFormat) As Integer
Parameters
Type Name Description
string text

String to draw.

Font font

C1.Util.Font object that defines the appearance and size of the drawn text.

Brush brush

Brush object that defines the color of the drawn text.

Rect rc

The rectangle structure that specifies the location of the drawn text, in points from the top left corner of the page.

StringFormat sf

C1.Util.StringFormat object that specifies formatting attributes applied to the drawn text.

Returns
Type Description
int

DrawString(string, Font, Color, Rect, StringFormat)

Draws the specified text string in the specified rectangle with the specified Brush and C1.Util.Font objects using the formatting attributes of the specified C1.Util.StringFormat object.

Declaration
public int DrawString(string text, Font font, Color color, Rect rc, StringFormat sf)
Public Function DrawString(text As String, font As Font, color As Color, rc As Rect, sf As StringFormat) As Integer
Parameters
Type Name Description
string text

String to draw.

Font font

C1.Util.Font object that defines the appearance and size of the drawn text.

Color color

The color of the drawn text.

Rect rc

The rectangle structure that specifies the location of the drawn text, in points from the top left corner of the page.

StringFormat sf

C1.Util.StringFormat object that specifies formatting attributes applied to the drawn text.

Returns
Type Description
int

The index of first character that was not printed because it did not fit in the specified rectangle.