Partager via


ITextParagraphPropertiesFactoryService.Create Method

Creates a TextParagraphProperties for the provided configuration.

Namespace:  Microsoft.VisualStudio.Text.Formatting
Assembly:  Microsoft.VisualStudio.Text.UI.Wpf (in Microsoft.VisualStudio.Text.UI.Wpf.dll)

Syntax

'Declaration
Function Create ( _
    formattedLineSource As IFormattedLineSource, _
    textProperties As TextFormattingRunProperties, _
    line As IMappingSpan, _
    lineStart As IMappingPoint, _
    lineSegment As Integer _
) As TextParagraphProperties
TextParagraphProperties Create(
    IFormattedLineSource formattedLineSource,
    TextFormattingRunProperties textProperties,
    IMappingSpan line,
    IMappingPoint lineStart,
    int lineSegment
)
TextParagraphProperties^ Create(
    IFormattedLineSource^ formattedLineSource, 
    TextFormattingRunProperties^ textProperties, 
    IMappingSpan^ line, 
    IMappingPoint^ lineStart, 
    int lineSegment
)
abstract Create : 
        formattedLineSource:IFormattedLineSource * 
        textProperties:TextFormattingRunProperties * 
        line:IMappingSpan * 
        lineStart:IMappingPoint * 
        lineSegment:int -> TextParagraphProperties
function Create(
    formattedLineSource : IFormattedLineSource, 
    textProperties : TextFormattingRunProperties, 
    line : IMappingSpan, 
    lineStart : IMappingPoint, 
    lineSegment : int
) : TextParagraphProperties

Parameters

  • lineSegment
    Type: Int32

    The segment number of the line segment that has been currently formatted. This is a zero-based index and is applicable to word-wrapped lines. If a line is word-wrapped into 4 segments, you will receive 4 calls for the line with line segments of 0, 1, 2, and 3.

Return Value

Type: TextParagraphProperties
A TextParagraphProperties to be used when the line is being formatted.

Remarks

You can return a TextFormattingParagraphProperties which has a convenient set of basic properties.

.NET Framework Security

See Also

Reference

ITextParagraphPropertiesFactoryService Interface

Microsoft.VisualStudio.Text.Formatting Namespace