• Skip to content
  • Skip to link menu
Trinity API Reference
  • Trinity API Reference
  • tdeui
 

tdeui

  • tdeui
ktabbar.h
1/* This file is part of the KDE libraries
2 Copyright (C) 2003 Stephan Binner <binner@kde.org>
3 Copyright (C) 2003 Zack Rusin <zack@kde.org>
4
5 This library is free software; you can redistribute it and/or
6 modify it under the terms of the GNU Library General Public
7 License as published by the Free Software Foundation; either
8 version 2 of the License, or (at your option) any later version.
9
10 This library is distributed in the hope that it will be useful,
11 but WITHOUT ANY WARRANTY; without even the implied warranty of
12 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 Library General Public License for more details.
14
15 You should have received a copy of the GNU Library General Public License
16 along with this library; see the file COPYING.LIB. If not, write to
17 the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
18 Boston, MA 02110-1301, USA.
19*/
20
21#ifndef KTABBAR_H
22#define KTABBAR_H
23
24#include <tqtabbar.h>
25
26#include <tdelibs_export.h>
27
28class TQTimer;
29class TQPushButton;
30class KTabBarPrivate;
31
35class TDEUI_EXPORT KTabBar: public TQTabBar
36{
37 TQ_OBJECT
38
39public:
40 KTabBar( TQWidget* parent=0, const char* name=0 );
41 virtual ~KTabBar();
42
43 virtual void setTabEnabled( int, bool );
44
45 const TQColor &tabColor( int ) const;
46 void setTabColor( int, const TQColor& );
47 void resetTabColor( int );
48
49 virtual int insertTab( TQTab *, int index = -1 );
50 virtual void removeTab( TQTab * );
51
52 void setTabReorderingEnabled( bool enable );
53 bool isTabReorderingEnabled() const;
54
55 void setHoverCloseButton( bool );
56 bool hoverCloseButton() const;
57
58 void setHoverCloseButtonDelayed( bool );
59 bool hoverCloseButtonDelayed() const;
60
61 void setTabCloseActivatePrevious( bool );
62 bool tabCloseActivatePrevious() const;
63
64signals:
65 void contextMenu( int, const TQPoint & );
66 void mouseDoubleClick( int );
67 void mouseMiddleClick( int );
68 void initiateDrag( int );
69 void testCanDecode(const TQDragMoveEvent *e, bool &accept /* result */);
70 void receivedDropEvent( int, TQDropEvent * );
71 void moveTab( int, int );
72 void closeRequest( int );
73#ifndef TQT_NO_WHEELEVENT
74 void wheelDelta( int );
75#endif
76
77protected:
78 virtual void mouseDoubleClickEvent( TQMouseEvent *e );
79 virtual void mousePressEvent( TQMouseEvent *e );
80 virtual void mouseMoveEvent( TQMouseEvent *e );
81 virtual void mouseReleaseEvent( TQMouseEvent *e );
82#ifndef TQT_NO_WHEELEVENT
83 virtual void wheelEvent( TQWheelEvent *e );
84#endif
85
86 virtual void dragMoveEvent( TQDragMoveEvent *e );
87 virtual void dropEvent( TQDropEvent *e );
88
89 virtual void paintLabel( TQPainter*, const TQRect&, TQTab*, bool ) const;
90
91protected slots:
92 virtual void closeButtonClicked();
93 virtual void onLayoutChange();
94 virtual void enableCloseButton();
95 virtual void activateDragSwitchTab();
96
97private:
98 TQPoint mDragStart;
99 int mReorderStartTab;
100 int mReorderPreviousTab;
101 TQMap<int, TQColor> mTabColors;
102 TQTab *mHoverCloseButtonTab, *mDragSwitchTab;
103 TQPushButton *mHoverCloseButton;
104 TQTimer *mEnableCloseButtonTimer, *mActivateDragSwitchTabTimer;
105
106 bool mHoverCloseButtonEnabled;
107 bool mHoverCloseButtonDelayed;
108 bool mTabReorderingEnabled;
109 bool mTabCloseActivatePrevious;
110
111 KTabBarPrivate * d;
112};
113
114#endif
KTabBar
Definition: ktabbar.h:36

tdeui

Skip menu "tdeui"
  • Main Page
  • Namespace List
  • Class Hierarchy
  • Alphabetical List
  • Class List
  • File List
  • Namespace Members
  • Class Members
  • Related Pages

tdeui

Skip menu "tdeui"
  • arts
  • dcop
  • dnssd
  • interfaces
  •   kspeech
  •     interface
  •     library
  •   tdetexteditor
  • kate
  • kded
  • kdoctools
  • kimgio
  • kjs
  • libtdemid
  • libtdescreensaver
  • tdeabc
  • tdecmshell
  • tdecore
  • tdefx
  • tdehtml
  • tdeinit
  • tdeio
  •   bookmarks
  •   httpfilter
  •   kpasswdserver
  •   kssl
  •   tdefile
  •   tdeio
  •   tdeioexec
  • tdeioslave
  •   http
  • tdemdi
  •   tdemdi
  • tdenewstuff
  • tdeparts
  • tdeprint
  • tderandr
  • tderesources
  • tdespell2
  • tdesu
  • tdeui
  • tdeunittest
  • tdeutils
  • tdewallet
Generated for tdeui by doxygen 1.9.4
This website is maintained by Timothy Pearson.