/*
 * 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 (in long time_stamp);
			Document newDocument (in boolean force);
		};

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

			Document getActiveDocument ();
			Window getWindowInWorkspace (in long workspace);

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