Commit 1f098e57 authored by Martin Nordholts's avatar Martin Nordholts

app: Add GimpDockColumns

Add a new widget GimpDockColumns inheriting from GtkHBox that will
contain several GimpDocks making it possible to have columns of
dockables.
parent 9106c75b
......@@ -126,6 +126,8 @@ libappwidgets_a_sources = \
gimpdnd-xds.h \
gimpdock.c \
gimpdock.h \
gimpdockcolumns.c \
gimpdockcolumns.h \
gimpdockable.c \
gimpdockable.h \
gimpdockbook.c \
......
/* GIMP - The GNU Image Manipulation Program
* Copyright (C) 1995 Spencer Kimball and Peter Mattis
*
* gimpdockcolumns.c
* Copyright (C) 2009 Martin Nordholts <martinn@src.gnome.org>
*
* 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 3 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
#include "config.h"
#include <gtk/gtk.h>
#include "widgets-types.h"
#include "gimpdockcolumns.h"
struct _GimpDockColumnsPrivate
{
int dummy;
};
G_DEFINE_TYPE (GimpDockColumns, gimp_dock_columns, GTK_TYPE_HBOX)
#define parent_class gimp_dock_columns_parent_class
static void
gimp_dock_columns_class_init (GimpDockColumnsClass *klass)
{
g_type_class_add_private (klass, sizeof (GimpDockColumnsPrivate));
}
static void
gimp_dock_columns_init (GimpDockColumns *dock_columns)
{
dock_columns->p = G_TYPE_INSTANCE_GET_PRIVATE (dock_columns,
GIMP_TYPE_DOCK_COLUMNS,
GimpDockColumnsPrivate);
}
/* GIMP - The GNU Image Manipulation Program
* Copyright (C) 1995 Spencer Kimball and Peter Mattis
*
* gimpdockcolumns.h
* Copyright (C) 2009 Martin Nordholts <martinn@src.gnome.org>
*
* 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 3 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
#ifndef __GIMP_DOCK_COLUMNS_H__
#define __GIMP_DOCK_COLUMNS_H__
#define GIMP_TYPE_DOCK_COLUMNS (gimp_dock_columns_get_type ())
#define GIMP_DOCK_COLUMNS(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), GIMP_TYPE_DOCK_COLUMNS, GimpDockColumns))
#define GIMP_DOCK_COLUMNS_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), GIMP_TYPE_DOCK_COLUMNS, GimpDockColumnsClass))
#define GIMP_IS_DOCK_COLUMNS(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), GIMP_TYPE_DOCK_COLUMNS))
#define GIMP_IS_DOCK_COLUMNS_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), GIMP_TYPE_DOCK_COLUMNS))
#define GIMP_DOCK_COLUMNS_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), GIMP_TYPE_DOCK_COLUMNS, GimpDockColumnsClass))
typedef struct _GimpDockColumnsClass GimpDockColumnsClass;
typedef struct _GimpDockColumnsPrivate GimpDockColumnsPrivate;
/**
* A widget containing GimpDocks so that dockables are arranged in
* columns.
*/
struct _GimpDockColumns
{
GtkHBox parent_instance;
GimpDockColumnsPrivate *p;
};
struct _GimpDockColumnsClass
{
GtkHBoxClass parent_class;
};
GType gimp_dock_columns_get_type (void) G_GNUC_CONST;
#endif /* __GIMP_DOCK_COLUMNS_H__ */
......@@ -37,6 +37,7 @@ typedef struct _GimpControllerWheel GimpControllerWheel;
/* docks */
typedef struct _GimpDock GimpDock;
typedef struct _GimpDockColumns GimpDockColumns;
typedef struct _GimpDockSeparator GimpDockSeparator; /* not a dock */
typedef struct _GimpDockWindow GimpDockWindow;
typedef struct _GimpMenuDock GimpMenuDock;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment