Hello!

Hello!

I am working on another library that should go into ARLibs.
This is something a tad more complex, i.e. an abstraction layer for document editing controls (such as TMemo or TRichEdit, or an image editing control, whatever). There are several interfaces that really need to be part of the document host, i.e. the panel which will contain the actual editing control.
So... I was thinking to do something like this:

1) Declare a base class implementing the interface I need
2) Declare, inside the document host, several protected classes inherited from the former which will form the base for all the various bits and pieces (selection, caret, the document subject to which implement observers, etc.).

Now, the thing is: I am wondering whether this will clutter the unit and make it difficult to read. Please note that the concept works as I've already tried it in a quick test, so it's all a matter of how to do this in the best possible way :)

Maybe I need a few, always general, descendants so that the actual protected classes are a bit more evolved.

What is your thinking?

A

Comments