public Paragraph getParagraph(int i){ int nr = 0; int offset = 0; for( Section s: sections ){ nr = s.nrOfParagraphs(); if( nr+offset > i )return s.getParagraph(i-offset); offset += nr; } return null; }
public Paragraph getParagraph(int i){ int nr = 0; int offset = 0; for( Section s: sections ){ nr = s.nrOfParagraphs(); if( nr+offset > i )return s.getParagraph(i-offset); offset += nr; } return null; }