another try at how to handle "multiple documents"

This is ANOTHER, configurable try at a Document/View model.

Don't get put away by the fact that the thing is called MDI, actually
the MFC-like MDI does not even work yet.

It consists of a GnomeMDI object, that controls how the MDI will look
like and a GnomeDocument object that defines common stuff for any
document type: actual documents are derived from it. Any GtkWidget can
serve as a view: the example uses GtkHex from GHex. Both objects are
implemented on top of GtkObject.

GnomeMDI currently supports multiple toplevel window, a notebook with
ability to drag pages (each containing one view) into new toplevel
windows (by dragging the page to the root window) and a "modal" app that
show only one view at a time, letting user select documents from a menu.
The MS-like MDI does not work right now (this would require a lot of
work on the widgets and anyway most people seem to dislike it ;)).

It also supports multiple views of the same document and takes care of
updating the views when the document data is changed.

The dynamic mode changing also does not work yet (ie, you have to choose
mode before adding any documents), but would be easy to implement!

To test just build mditest (a simple hex editor) and run it. Currently
supported options are --book for notebook mode, --toplevel for multiple
toplevel windows and --modal for a modal app with a list of documents.

This stuff still requires much work, but I would like some feedback
first. You can get the source tarball at:




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]