dock-item.h revision 946a87d87ab78d94239cf87d386e8595382db822
/**
* \brief A custom wrapper around gdl-dock-item
*
* Author:
* Gustav Broberg <broberg@kth.se>
*
* Copyright (C) 2007 Authors
*
* Released under GNU GPL. Read the file 'COPYING' for more information.
*/
#ifndef INKSCAPE_UI_WIGET_DOCK_ITEM_H
#define INKSCAPE_UI_WIGET_DOCK_ITEM_H
#include <gtkmm/buttonbox.h>
enum Placement {
TOP = GDL_DOCK_TOP,
};
~DockItem();
void get_position(int& x, int& y);
void move(int x, int y);
bool isAttached() const;
bool isFloating() const;
bool isIconified() const;
State getPrevState() const;
Placement getPlacement() const;
void hide();
void show();
void show_all();
void present();
int _prev_position;
/** Interface widgets, will be packed like
* gdl_dock_item -> _frame -> _dock_item_box -> (_dock_item_action_area)
*/
/** Internal signal handlers */
void _onHide();
void _onHideWindow();
void _onShow();
void _onResponse(int response_id);
void _onDragBegin();
void _onDragEnd(bool cancelled);
/** GdlDockItem signal proxy structures */
/** Internal helpers */
Gtk::Window *_getWindow(); //< gives the parent window, if the dock item has one (i.e. it's floating)
/** In order to emulate a signal_response signal like the one for Gtk::Dialog we inject a new
* signal into GdlDockItem. This signal will be emitted when a button in the dock item added
* through the addButton(..., response_id) method, is clicked.
*/
DockItem();
};
} // namespace Widget
} // namespace UI
} // namespace Inkscape
#endif // INKSCAPE_UI_WIGET_DOCK_ITEM_H
/*
Local Variables:
mode:c++
c-file-style:"stroustrup"
c-file-offsets:((innamespace . 0)(inline-open . 0)(case-label . +))
indent-tabs-mode:nil
fill-column:99
End:
*/
// vim: filetype=cpp:expandtab:shiftwidth=4:tabstop=8:softtabstop=4:encoding=utf-8:textwidth=99 :