![]() |
![]() |
Layer.CreateParagraphText
Function CreateParagraphText(Left As Double, Top As Double, Right As Double, Bottom As Double, [Text As String], [LanguageID As cdrTextLanguage = cdrLanguageNone], [CharSet As cdrTextCharSet = cdrCharSetMixed], [Font As String], [Size As Single], [Bold As cdrTriState = cdrUndefined], [Italic As cdrTriState = cdrUndefined], [Underline As cdrFontLine = cdrMixedFontLine], [Alignment As cdrAlignment = cdrMixedAlignment]) As Shape
Member of Layer
The CreateParagraphText method creates a paragraph-text object at a given point on a layer.
Parameters
|
Description
|
Left
|
Specifies the distance from the left side of the paragraph-text frame to the left side of the page frame. The left coordinate is measured in document units.
|
Top
|
Specifies the distance from the top side of the paragraph-text frame to the top of the page frame. The top coordinate is measured in document units.
|
Right
|
Specifies the distance from the right side of the paragraph-text frame to the right side of the page frame. The right coordinate is measured in document units.
|
Bottom
|
Specifies the distance from the bottom of the paragraph-text frame to the bottom of the page frame. The bottom coordinate is measured in document units.
|
Text
|
Determines the content of the newly created paragraph text. The value of the Text parameter becomes the actual text created with the CreateParagraphText method.
This parameter is optional.
|
LanguageID
|
Specifies the language
This parameter is optional, and its default value is cdrLanguageNone (0).
|
CharSet
|
Specifies the character set
This parameter is optional, and its default value is cdrCharSetMixed (-1).
|
Font
|
Specifies the font
This parameter is optional.
|
Size
|
Specifies the font size
This parameter is optional, and its default value is 0.
|
Bold
|
Specifies whether to apply bold
This parameter is optional, and its default value is cdrUndefined (-2).
|
Italic
|
Specifies whether to apply italic
This parameter is optional, and its default value is cdrUndefined (-2).
|
Underline
|
Specifies an underline
This parameter is optional, and its default value is cdrMixedFontLine (7).
|
Alignment
|
Specifies an alignment
This parameter is optional, and its default value is cdrMixedAlignment (6).
|
The following code example creates a paragraph-text object, formatted in boldface Times New Roman font:
Sub Test() Dim s As Shape Set s = ActiveLayer.CreateParagraphText(0, 0, 4, 4, "Paragraph Text", , , _ "Times New Roman", 24, cdrTrue, cdrTrue, , cdrCenterAlignment) End Sub
![]() |
![]() |
![]() |
Copyright 2007 Corel Corporation. All rights reserved.