24#include <tqstringlist.h>
25#include <tqtabwidget.h>
26#include <tqvalidator.h>
29#include <tdelistview.h>
37class OutlineSlideItem;
43class KPrRenamePageValidator :
public TQValidator
46 KPrRenamePageValidator(
const TQStringList & list=TQStringList() )
47 : TQValidator( 0, 0 ), mStringList( list ) {}
48 virtual State validate( TQString & input,
int & pos )
const;
51 TQStringList mStringList;
57 KPrSideBarBase(KPrDocument *_doc, KPrView *_view);
58 void setViewMasterPage(
bool _b );
62 bool m_viewMasterPage;
65class KPrThumbBar :
public TDEIconView,
public KPrSideBarBase
71 KPrThumbBar(TQWidget *parent, KPrDocument *d, KPrView *v);
73 void setCurrentPage(
int pg );
74 void updateItem(
int pagenr,
bool sticky =
false );
75 void addItem(
int pos );
76 void moveItem(
int oldPos,
int newPos );
77 void removeItem(
int pos );
78 void refreshItems (
bool offset =
false );
79 TQRect tip(
const TQPoint &pos, TQString &title);
84 void showPage(
int i );
90 void itemClicked(TQIconViewItem *i);
91 void slotContentsMoving(
int x,
int y);
92 void slotRefreshItems();
95 TQPixmap getSlideThumb(
int slideNr)
const;
97 ThumbToolTip *m_thumbTip;
102class KPrOutline:
public TDEListView,
public KPrSideBarBase
108 KPrOutline( TQWidget *parent, KPrDocument *d, KPrView *v );
110 void setCurrentPage(
int pg );
111 TQSize sizeHint()
const {
return TQSize( 145, TDEListView::sizeHint().height() ); }
112 void updateItem(
int pagenr,
bool sticky =
false);
113 void addItem(
int pos );
114 void moveItem(
int oldPos,
int newPos );
115 void removeItem(
int pos );
118 void contentsDropEvent( TQDropEvent *e );
119 void moveItem( TQListViewItem *i, TQListViewItem *firstAfter, TQListViewItem *newAfter );
120 OutlineSlideItem* slideItem(
int pageNumber );
121 bool acceptDrag( TQDropEvent* e )
const;
123 virtual TQDragObject* dragObject();
126 void showPage(
int i );
127 void movePage(
int from,
int to );
128 void selectPage(
int i,
bool );
132 void renamePageTitle();
135 void itemClicked( TQListViewItem *i );
136 void slotDropped( TQDropEvent *e, TQListViewItem *parent, TQListViewItem *target );
137 void rightButtonPressed( TQListViewItem *i,
const TQPoint &pnt,
int c );
138 void slotContextMenu( TDEListView*, TQListViewItem *item,
const TQPoint &p );
141 TQListViewItem *m_movedItem, *m_movedAfter;
144class KPrSideBar:
public TQTabWidget
150 KPrSideBar(TQWidget *parent, KPrDocument *d, KPrView *v);
151 void setCurrentPage(
int pg ) {
152 m_outline->setCurrentPage(pg);
153 m_thb->setCurrentPage(pg);
155 void setOn(
int ,
bool ) { };
157 void updateItem( KPrPage *page );
158 void addItem(
int pos );
159 void moveItem(
int oldPos,
int newPos );
160 void removeItem(
int pos );
162 KPrOutline *outline()
const {
return m_outline; };
163 KPrThumbBar *thumbBar()
const {
return m_thb; };
165 void setViewMasterPage(
bool _masterPage );
167 void showPage(
int i );
168 void movePage(
int from,
int to );
169 void selectPage(
int i,
bool );
173 void renamePageTitle() { m_outline->renamePageTitle(); };
174 void currentChanged(TQWidget *tab);
177 KPrOutline *m_outline;