+ // for wxLayoutLine usage only
+ void IncNumLines() { m_numLines++; }
+ void DecNumLines() { m_numLines--; }
+
+ /// get the line by number
+ wxLayoutLine *GetLine(CoordType index) const
+ {
+ wxASSERT_MSG( (0 <= index) && (index < (CoordType)m_numLines),
+ "invalid index" );
+
+ wxLayoutLine *line;
+ CoordType n = index;
+ for ( line = m_FirstLine; line && n-- > 0; line = line->GetNextLine() )
+ ;
+
+ if ( line )
+ {
+ // should be the right one
+ wxASSERT( line->GetLineNumber() == index );
+ }
+
+ return line;
+ }
+