2 # ---------------------------------------------------------------------
4 # Copyright (c) CREATIS (Centre de Recherche en Acquisition et Traitement de l'Image
6 # Authors : Eduardo Davila, Frederic Cervenansky, Claire Mouton
7 # Previous Authors : Laurent Guigues, Jean-Pierre Roux
8 # CreaTools website : www.creatis.insa-lyon.fr/site/fr/creatools_accueil
10 # This software is governed by the CeCILL-B license under French law and
11 # abiding by the rules of distribution of free software. You can use,
12 # modify and/ or redistribute the software under the terms of the CeCILL-B
13 # license as circulated by CEA, CNRS and INRIA at the following URL
14 # http://www.cecill.info/licences/Licence_CeCILL-B_V1-en.html
15 # or in the file LICENSE.txt.
17 # As a counterpart to the access to the source code and rights to copy,
18 # modify and redistribute granted by the license, users are provided only
19 # with a limited warranty and the software's author, the holder of the
20 # economic rights, and the successive licensors have only limited
23 # The fact that you are presently reading this means that you have had
24 # knowledge of the CeCILL-B license and that you accept its terms.
25 # ------------------------------------------------------------------------ */
28 //---------------------------------------------------------------------------
29 // $RCSfile: TreeMultiItemWindow.h,v $
30 // $Source: /cvs/creatis/bbtk/kernel/src/ThirdParty/wx/treemultictrl/TreeMultiItemWindow.h,v $
32 // $Date: 2012/11/16 08:49:16 $
33 //---------------------------------------------------------------------------
34 // Author: Jorgen Bodde
35 // Copyright: (c) Jorgen Bodde
36 // License: wxWidgets License
37 //---------------------------------------------------------------------------
39 #ifndef __TREEMULTIITEMWINDOW_HPP_
40 #define __TREEMULTIITEMWINDOW_HPP_
43 #pragma interface "TreeMultiItemWindow.cpp"
50 #include <wx/dynarray.h>
52 #include "TreeMultiItemBase.h"
54 class TreeMultiItemWindow : public TreeMultiItemBase
57 /** The simple control, or complex sizer that represents this window
58 in the TreeMultiCtrl */
61 /** Top and front extra spacings, added to X, Y */
62 int _topSpacing, _frontSpacing;
68 TreeMultiItemWindow(TreeMultiItemNode *parent, const wxString &name = wxEmptyString);
69 virtual ~TreeMultiItemWindow();
72 virtual TreeMultiItemWindow *IsTreeMultiItemWindow() const {
73 return (TreeMultiItemWindow *)this;
76 /** Assigns the given window to this TreeMultiItemWindow, and also destroys the
77 present window. If the assigned window is 0, this item is not drawn
78 and removed from the tree visually */
79 void AssignWindow(wxWindow *wnd);
81 /** Get window method */
82 wxWindow *GetWindow() {
86 /* Sets front spacing */
87 void SetFrontSpacing(int frontSpacing) {
88 _frontSpacing = frontSpacing;
90 /* Gets front spacing */
91 int GetFrontSpacing() const {
94 /* Sets top spacing */
95 void SetTopSpacing(int topSpacing) {
96 _topSpacing = topSpacing;
98 /* Gets top spacing */
99 int GetTopSpacing() const {
103 /* Sets horizontal span, meaning when this is set the window
104 attached may be resized horizontally when the window is resized */
105 void SetHorizontalSpan(bool span) {
109 /* Sets horizontal span, meaning when this is set the window
110 attached may be resized horizontally when the window is resized */
111 bool GetHorizontalSpan() const {
116 /** Inherited from base, to enable or disable window */
117 virtual void SetCheckboxState(int state);