SearchTextBox.cs
/// <summary>
/// returns the position of the start of the current line.
/// </summary>
/// <returns></returns>
returns the position of the start of the current line.
returns the position of the start of the current line .
private int GetLineStart()
        {
            int i = 0;
            int textPosition = this.SelectionStart;
            if (textPosition >= this.Text.Length)
            {
                textPosition--;
            }
            int lineStart = 0;
            for (i = textPosition; i > 0; i--)
            {
                if (this.Text[i] == '\n')
                {
                    lineStart = i + 1;
                    break;
                }
            }
            return lineStart;
        }
private int GetLineStart ( ) { int i = 0 ; int textPosition = this . SelectionStart ; if ( textPosition >= this . Text . Length ) { textPosition -- ; } int lineStart = 0 ; for ( i = textPosition ; i > 0 ; i -- ) { if ( this . Text [ i ] == ' \n ' ) { lineStart = i + 1 ; break ; } } return lineStart ; }
returns the position of the start of the current line.
returns the position of the start of the current line .
None