/*
 * Interface for gedit
 */

#include <Bonobo.idl>

module GNOME {

	module Gedit {

		/* URIs are just plain strings, but we use a typedef to make
		 * the interface definitions clearer.
		 */
		typedef string URI;
		typedef sequence<URI> URIList;

		interface Document : Bonobo::Unknown {
			exception DocumentReadOnly {};

			void insert (in long offset, in string str,
					    in long length)
				raises (DocumentReadOnly);
		};

		interface Window : Bonobo::Unknown {
			oneway void openURIList (in URIList locations,
						 in string enc_charset,
						 in long line_pos);
			oneway void grabFocus ();
			Document newDocument ();
		};

		interface Application : Bonobo::Unknown {
			Window newWindow ();

			Document getActiveDocument ();
			Window getActiveWindow ();

			oneway void quit ();
		};
	};
};
