• Skip to content
  • Skip to link menu
KDE 4.1 API Reference
  • KDE API Reference
  • kdelibs
  • Sitemap
  • Contact Us
 

KDEUI

ktabbar.h

Go to the documentation of this file.
00001 /* This file is part of the KDE libraries
00002     Copyright (C) 2003 Stephan Binner <binner@kde.org>
00003     Copyright (C) 2003 Zack Rusin <zack@kde.org>
00004 
00005     This library is free software; you can redistribute it and/or
00006     modify it under the terms of the GNU Library General Public
00007     License as published by the Free Software Foundation; either
00008     version 2 of the License, or (at your option) any later version.
00009 
00010     This library is distributed in the hope that it will be useful,
00011     but WITHOUT ANY WARRANTY; without even the implied warranty of
00012     MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
00013     Library General Public License for more details.
00014 
00015     You should have received a copy of the GNU Library General Public License
00016     along with this library; see the file COPYING.LIB.  If not, write to
00017     the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
00018     Boston, MA 02110-1301, USA.
00019 */
00020 
00021 #ifndef KTABBAR_H
00022 #define KTABBAR_H
00023 
00024 #include <kdeui_export.h>
00025 
00026 #include <QtGui/QTabBar>
00027 
00031 class KDEUI_EXPORT KTabBar: public QTabBar
00032 {
00033     Q_OBJECT
00034 
00035   public:
00041     explicit KTabBar( QWidget* parent = 0 );
00042 
00046     virtual ~KTabBar();
00047 
00053     void setTabReorderingEnabled( bool enable );
00054 
00058     bool isTabReorderingEnabled() const;
00059 
00068     KDE_DEPRECATED void setHoverCloseButton( bool );
00069 
00071     KDE_DEPRECATED bool hoverCloseButton() const;
00072 
00080     KDE_DEPRECATED void setHoverCloseButtonDelayed( bool );
00081 
00083     KDE_DEPRECATED bool hoverCloseButtonDelayed() const;
00084 
00092     void setCloseButtonEnabled( bool );
00093 
00099     bool isCloseButtonEnabled() const;
00100 
00106     void setTabCloseActivatePrevious( bool );
00107 
00112     bool tabCloseActivatePrevious() const;
00113 
00120     int selectTab( const QPoint &position ) const;
00121 
00122   Q_SIGNALS:
00124     void contextMenu( int, const QPoint& );
00126     void emptyAreaContextMenu( const QPoint& );
00128     QT_MOC_COMPAT void mouseDoubleClick( int );
00130     void tabDoubleClicked( int );
00132     void newTabRequest();
00134     void mouseMiddleClick( int );
00135     void initiateDrag( int );
00136     void testCanDecode( const QDragMoveEvent*, bool& );
00137     void receivedDropEvent( int, QDropEvent* );
00138     void moveTab( int, int );
00139     void closeRequest( int );
00140 #ifndef QT_NO_WHEELEVENT
00141     void wheelDelta( int );
00142 #endif
00143 
00144   protected:
00145     virtual void mouseDoubleClickEvent( QMouseEvent *event );
00146     virtual void mousePressEvent( QMouseEvent *event );
00147     virtual void mouseMoveEvent( QMouseEvent *event );
00148     virtual void mouseReleaseEvent( QMouseEvent *event );
00149 #ifndef QT_NO_WHEELEVENT
00150     virtual void wheelEvent( QWheelEvent *event );
00151 #endif
00152 
00153     virtual void dragEnterEvent( QDragEnterEvent *event );
00154     virtual void dragMoveEvent( QDragMoveEvent *event );
00155     virtual void dropEvent( QDropEvent *event );
00156 
00157     virtual void paintEvent( QPaintEvent *event );
00158     virtual void leaveEvent( QEvent *event );
00159     virtual QSize tabSizeHint( int index ) const;
00160 
00161   protected Q_SLOTS:
00163     QT_MOC_COMPAT void closeButtonClicked();
00165     QT_MOC_COMPAT void enableCloseButton();
00166     virtual void activateDragSwitchTab();
00167 
00168   protected:
00169     virtual void tabLayoutChange();
00170 
00171   private:
00172     QPoint closeButtonPos( int tabIndex ) const;
00173     QRect closeButtonRect( int tabIndex ) const;
00174 
00175   private:
00176     class Private;
00177     Private* const d;
00178 };
00179 
00180 #endif

KDEUI

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

kdelibs

Skip menu "kdelibs"
  • DNSSD
  • Interfaces
  •   KHexEdit
  •   KMediaPlayer
  •   KSpeech
  •   KTextEditor
  • Kate
  • kconf_update
  • KDE3Support
  •   KUnitTest
  • KDECore
  • KDED
  • KDEsu
  • KDEUI
  • KDocTools
  • KFile
  • KHTML
  • KImgIO
  • KInit
  • KIO
  • KIOSlave
  • KJS
  •   KJS-API
  •   WTF
  • kjsembed
  • KNewStuff
  • KParts
  • Kross
  • KUtils
  • Nepomuk
  • Solid
  • Sonnet
  • ThreadWeaver
Generated for kdelibs by doxygen 1.5.4
This website is maintained by Adriaan de Groot and Allen Winter.
KDE® and the K Desktop Environment® logo are registered trademarks of KDE e.V. | Legal