View ViewWidget +Desktop uses +DesktopWidget +SVGView +SVGViewWidget
(interface) == (abstract base class)
This feels weird to me. Ideally (I think) Desktop/SVGView should not need to know anything about the widgets attached to them -- they are basically "model" classes.
So the knowledge would be more one-way, where the widgets know about the model class, but not vice-versa.
I wondered about the existing circularity. Some of the needed callbacks would be only used by singular classes, and where the reference to the widget itself is returned, it is used by Gtk-specific classes. In these cases, Desktop is best not involved at all.
Bryce asked:
Do you think we would really need both C and C++ implementations?
Maybe not, although it would make switching easy. But replace C with Mac or native Windows or ... So the abstraction is needed anyway. Nearly 10 years ago, I created and maintained the yarec package that had ncurses and Gtk UIs in one binary, so the idea is not new. However, I don't propose full Gtk and Gtkmm inkscape in one binary!
Thanks for the feedback, to which I might write more later, ralf