21 #ifndef __KATE_VIEWSPACE_CONTAINER_H__
22 #define __KATE_VIEWSPACE_CONTAINER_H__
25 #include "../interfaces/viewmanager.h"
27 #include <kate/view.h>
28 #include <kate/document.h>
35 class KateViewSpaceContainer:
public TQVBox
39 friend class KateViewSpace;
40 friend class KateVSStatusBar;
43 KateViewSpaceContainer (TQWidget *parent, KateViewManager *viewManager);
45 ~KateViewSpaceContainer ();
47 inline TQPtrList<Kate::View> &viewList () {
return m_viewList; };
51 void saveViewConfiguration(TDEConfig *config,
const TQString& group);
54 void restoreViewConfiguration (TDEConfig *config,
const TQString& group);
61 bool createView ( Kate::Document *doc =0L );
63 bool deleteView ( Kate::View *view,
bool delViewSpace =
true);
65 void moveViewtoSplit (Kate::View *view);
66 void moveViewtoStack (Kate::View *view);
72 void saveSplitterConfig(
KateMDI::Splitter* s,
int idx=0, TDEConfig* config=0L,
const TQString& viewConfGrp=
"");
77 void restoreSplitter ( TDEConfig* config,
const TQString &group, TQWidget* parent ,
const TQString& viewConfGrp);
79 void removeViewSpace (KateViewSpace *viewspace);
84 Kate::View* activeView ();
85 KateViewSpace* activeViewSpace ();
88 uint viewSpaceCount ();
90 bool isViewActivationBlocked(){
return m_blockViewCreationAndActivation;};
93 void closeViews(uint documentNumber);
94 KateMainWindow *mainWindow();
95 friend class KateViewManager;
98 void activateView ( Kate::View *view );
99 void activateSpace ( Kate::View* v );
100 void slotViewChanged();
101 void reactivateActiveView();
102 void slotPendingDocumentNameChanged();
104 void documentCreated (Kate::Document *doc);
105 void documentDeleted (uint docNumber);
119 void splitViewSpace( KateViewSpace* vs=0L,
bool isHoriz=
true,
bool atTop=
false );
121 bool getShowFullPath()
const {
return showFullPath; }
123 void activateView ( uint documentNumber );
124 void activateView (
int documentNumber ) { activateView((uint) documentNumber); };
127 void slotSplitViewSpaceHoriz () { splitViewSpace(); }
129 void slotSplitViewSpaceVert () { splitViewSpace( 0L,
false ); }
131 void slotCloseCurrentViewSpace();
135 void setActiveSpace ( KateViewSpace* vs );
136 void setActiveView ( Kate::View* view );
138 void setShowFullPath(
bool enable);
140 void activateNextView();
141 void activatePrevView();
144 void statusChanged (Kate::View *,
int,
int,
int,
bool,
int,
const TQString &);
149 KateViewManager *m_viewManager;
150 TQPtrList<KateViewSpace> m_viewSpaceList;
151 TQPtrList<Kate::View> m_viewList;
153 bool m_blockViewCreationAndActivation;
155 bool m_activeViewRunning;
157 bool m_pendingViewCreation;
158 TQGuardedPtr<Kate::Document> m_pendingDocument;
This class is needed because TQSplitter cant return an index for a widget.