ACAT.Extensions.Default.FunctionalAgents.LectureManager.LectureManagerMainForm.getNextPara C# (CSharp) Method

getNextPara() private method

Gets the paragraph object of the next paragraph
private getNextPara ( ) : Paragraph
return Paragraph
        private Paragraph getNextPara()
        {
            if (textBox1.SelectionLength == 0)
            {
                foreach (var para in _paragraphs)
                {
                    if (textBox1.SelectionStart == para.Start && para.Sentences.Any())
                    {
                        return para;
                    }
                }
            }

            return _paragraphs.FirstOrDefault(para => para.Start > textBox1.SelectionStart);
        }