2005-09-06 09:21:05 -07:00
|
|
|
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 4; coding: utf-8 -*-
|
2005-09-09 02:54:58 -07:00
|
|
|
*
|
2005-09-02 16:27:25 -07:00
|
|
|
* mooeditwindow.h
|
|
|
|
*
|
2006-02-23 06:03:17 -08:00
|
|
|
* Copyright (C) 2004-2006 by Yevgen Muntyan <muntyan@math.tamu.edu>
|
2005-09-02 16:27:25 -07:00
|
|
|
*
|
|
|
|
* This program is free software; you can redistribute it and/or modify
|
|
|
|
* it under the terms of the GNU General Public License as published by
|
|
|
|
* the Free Software Foundation; either version 2 of the License, or
|
|
|
|
* (at your option) any later version.
|
|
|
|
*
|
|
|
|
* See COPYING file that comes with this distribution.
|
|
|
|
*/
|
|
|
|
|
|
|
|
#ifndef __MOO_EDIT_WINDOW_H__
|
|
|
|
#define __MOO_EDIT_WINDOW_H__
|
|
|
|
|
2005-10-13 07:08:18 -07:00
|
|
|
#include <mooedit/mooedit.h>
|
|
|
|
#include <mooutils/moowindow.h>
|
|
|
|
#include <mooutils/moobigpaned.h>
|
2005-09-02 16:27:25 -07:00
|
|
|
|
|
|
|
G_BEGIN_DECLS
|
|
|
|
|
|
|
|
|
|
|
|
#define MOO_TYPE_EDIT_WINDOW (moo_edit_window_get_type ())
|
|
|
|
#define MOO_EDIT_WINDOW(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), MOO_TYPE_EDIT_WINDOW, MooEditWindow))
|
|
|
|
#define MOO_EDIT_WINDOW_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), MOO_TYPE_EDIT_WINDOW, MooEditWindowClass))
|
|
|
|
#define MOO_IS_EDIT_WINDOW(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), MOO_TYPE_EDIT_WINDOW))
|
|
|
|
#define MOO_IS_EDIT_WINDOW_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), MOO_TYPE_EDIT_WINDOW))
|
|
|
|
#define MOO_EDIT_WINDOW_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), MOO_TYPE_EDIT_WINDOW, MooEditWindowClass))
|
|
|
|
|
|
|
|
|
|
|
|
typedef struct _MooEditWindow MooEditWindow;
|
|
|
|
typedef struct _MooEditWindowPrivate MooEditWindowPrivate;
|
|
|
|
typedef struct _MooEditWindowClass MooEditWindowClass;
|
|
|
|
|
|
|
|
struct _MooEditWindow
|
|
|
|
{
|
|
|
|
MooWindow parent;
|
2005-09-04 15:32:08 -07:00
|
|
|
MooBigPaned *paned;
|
2005-09-02 16:27:25 -07:00
|
|
|
MooEditWindowPrivate *priv;
|
|
|
|
};
|
|
|
|
|
|
|
|
struct _MooEditWindowClass
|
|
|
|
{
|
|
|
|
MooWindowClass parent_class;
|
2005-09-04 21:24:21 -07:00
|
|
|
|
|
|
|
/* these do not open or close document */
|
2005-09-07 04:19:26 -07:00
|
|
|
void (*new_doc) (MooEditWindow *window,
|
|
|
|
MooEdit *doc);
|
|
|
|
void (*close_doc) (MooEditWindow *window,
|
|
|
|
MooEdit *doc);
|
|
|
|
void (*close_doc_after) (MooEditWindow *window);
|
2005-09-02 16:27:25 -07:00
|
|
|
};
|
|
|
|
|
|
|
|
|
2005-09-07 04:19:26 -07:00
|
|
|
GType moo_edit_window_get_type (void) G_GNUC_CONST;
|
2005-09-02 16:27:25 -07:00
|
|
|
|
2005-09-07 04:19:26 -07:00
|
|
|
MooEdit *moo_edit_window_get_active_doc (MooEditWindow *window);
|
|
|
|
void moo_edit_window_set_active_doc (MooEditWindow *window,
|
|
|
|
MooEdit *edit);
|
2005-09-02 16:27:25 -07:00
|
|
|
|
2005-09-07 04:19:26 -07:00
|
|
|
GSList *moo_edit_window_list_docs (MooEditWindow *window);
|
|
|
|
guint moo_edit_window_num_docs (MooEditWindow *window);
|
|
|
|
|
|
|
|
void moo_edit_window_set_title_prefix (MooEditWindow *window,
|
|
|
|
const char *prefix);
|
2005-09-02 16:27:25 -07:00
|
|
|
|
2005-11-06 22:56:33 -08:00
|
|
|
/* sinks widget */
|
2005-09-08 00:46:48 -07:00
|
|
|
gboolean moo_edit_window_add_pane (MooEditWindow *window,
|
|
|
|
const char *user_id,
|
|
|
|
GtkWidget *widget,
|
|
|
|
MooPaneLabel *label,
|
|
|
|
MooPanePosition position);
|
|
|
|
gboolean moo_edit_window_remove_pane (MooEditWindow *window,
|
|
|
|
const char *user_id);
|
|
|
|
GtkWidget *moo_edit_window_get_pane (MooEditWindow *window,
|
|
|
|
const char *user_id);
|
|
|
|
|
2005-09-02 16:27:25 -07:00
|
|
|
|
2005-11-18 05:02:42 -08:00
|
|
|
typedef void (*MooAbortJobFunc) (gpointer job);
|
|
|
|
|
|
|
|
void moo_edit_window_add_stop_client (MooEditWindow *window,
|
|
|
|
gpointer client);
|
|
|
|
void moo_edit_window_remove_stop_client (MooEditWindow *window,
|
|
|
|
gpointer client);
|
|
|
|
void moo_edit_window_abort_jobs (MooEditWindow *window);
|
|
|
|
void moo_edit_window_job_started (MooEditWindow *window,
|
|
|
|
const char *name,
|
|
|
|
MooAbortJobFunc func,
|
|
|
|
gpointer job);
|
|
|
|
void moo_edit_window_job_finished (MooEditWindow *window,
|
|
|
|
gpointer job);
|
|
|
|
|
|
|
|
|
2005-09-02 16:27:25 -07:00
|
|
|
G_END_DECLS
|
|
|
|
|
|
|
|
#endif /* __MOO_EDIT_WINDOW_H__ */
|