>>>>> "Lars" == Lars Gullik Bjønnes <[EMAIL PROTECTED]> writes:

Lars> paragraph in paragraph

Lars> heading paragraph 1

Lars> subheading paragraph 2

Lars> How do we store this?

Lars> One option is to let para 2 be inside para 1.

Yes, but it only makes sense becasue you have some context and know
that headings can have paragraph childs. In this case, I'd rather
have:

class Heading : public Paragraph {
        vector<Paragraph> subpar;
}

Which means that a Heading is a special case of paragraph. I really
think that they are different concepts. Basically, an inset is only a
part of a sentence; a paragraph is a whole sentence. We will not want
to do that same actions on those different things.

JMarc

Reply via email to