IVsTextView.CenterLines Method

Places the specified lines of text in the center of the view.

Namespace:  Microsoft.VisualStudio.TextManager.Interop
Assembly:  Microsoft.VisualStudio.TextManager.Interop (in Microsoft.VisualStudio.TextManager.Interop.dll)

Syntax

'宣言
Function CenterLines ( _
    iTopLine As Integer, _
    iCount As Integer _
) As Integer
'使用
Dim instance As IVsTextView
Dim iTopLine As Integer
Dim iCount As Integer
Dim returnValue As Integer

returnValue = instance.CenterLines(iTopLine, _
    iCount)
int CenterLines(
    int iTopLine,
    int iCount
)
int CenterLines(
    [InAttribute] int iTopLine, 
    [InAttribute] int iCount
)
function CenterLines(
    iTopLine : int, 
    iCount : int
) : int

Parameters

  • iTopLine
    Type: System.Int32

    [in] First line to place in the center of the view.

  • iCount
    Type: System.Int32

    [in] Total number of lines to place in the center of the view.

Return Value

Type: System.Int32

If the method succeeds, it returns S_OK. If it fails, it returns an error code.

Remarks

COM Signature

From textmgr.idl:

HRESULT IVsTextView::CenterLines(
   [in] long iTopLine, 
   [in] long iCount
);

Permissions

See Also

Reference

IVsTextView Interface

IVsTextView Members

Microsoft.VisualStudio.TextManager.Interop Namespace