kdeui Library API Documentation

ktabctl.h

00001 /* This file is part of the KDE libraries
00002     Copyright (C) 1997 Alexander Sanda (alex@darkstar.ping.at)
00003 
00004     This library is free software; you can redistribute it and/or
00005     modify it under the terms of the GNU Library General Public
00006     License as published by the Free Software Foundation; either
00007     version 2 of the License, or (at your option) any later version.
00008 
00009     This library is distributed in the hope that it will be useful,
00010     but WITHOUT ANY WARRANTY; without even the implied warranty of
00011     MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
00012     Library General Public License for more details.
00013 
00014     You should have received a copy of the GNU Library General Public License
00015     along with this library; see the file COPYING.LIB.  If not, write to
00016     the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
00017     Boston, MA 02111-1307, USA.
00018 */
00019 /*
00020  * $Id: ktabctl.h,v 1.14 2003/07/17 12:55:51 binner Exp $
00021 */
00022 
00023 #ifndef KTABCTL_H
00024 #define KTABCTL_H
00025 
00026 #include <qwidget.h>
00027 #include <qtabbar.h>
00028 #include <qmemarray.h>
00029 
00046 class KTabCtl : public QWidget
00047 {
00048     Q_OBJECT
00049 
00050 public:
00051     KTabCtl(QWidget *parent = 0, const char *name = 0);
00052    ~KTabCtl();
00053 
00054     void show();
00055     void setFont(const QFont & font);
00056     void setTabFont( const QFont &font );
00057 
00058     void addTab(QWidget *, const QString&);
00059     bool isTabEnabled(const QString& );
00060     void setTabEnabled(const QString&, bool);
00061     void setBorder(bool);
00062     void setShape( QTabBar::Shape shape );
00063     virtual QSize sizeHint() const;
00064 
00065 protected:
00066     void paintEvent(QPaintEvent *);
00067     void resizeEvent(QResizeEvent *);
00068 
00069 signals:
00070     void tabSelected(int);
00071     
00072 protected slots:
00073     void showTab(int i);
00074 
00075 protected:
00076     void setSizes();
00077     QRect getChildRect() const;
00078 
00079     QTabBar * tabs;
00080     QMemArray<QWidget *> pages;
00081     int bh;
00082     bool blBorder;
00083 protected:
00084     virtual void virtual_hook( int id, void* data );
00085 private:
00086     class KTabCtrlPrivate* d;
00087 };
00088 #endif
KDE Logo
This file is part of the documentation for kdeui Library Version 3.2.2.
Documentation copyright © 1996-2004 the KDE developers.
Generated on Fri Jan 21 09:57:29 2005 by doxygen 1.3.6 written by Dimitri van Heesch, © 1997-2003