home *** CD-ROM | disk | FTP | other *** search
/ Personal Computer World 2009 February / PCWFEB09.iso / Software / Linux / SLAX 6.0.8 / slax-6.0.8.iso / slax / base / 006-devel.lzm / usr / include / KoCharSelectDia.h < prev    next >
Encoding:
C/C++ Source or Header  |  2007-05-30  |  2.3 KB  |  77 lines

  1. /* This file is part of the KDE project
  2.    Copyright (C) 1998, 1999 Reginald Stadlbauer <reggie@kde.org>
  3.  
  4.    This library is free software; you can redistribute it and/or
  5.    modify it under the terms of the GNU Library General Public
  6.    License as published by the Free Software Foundation; either
  7.    version 2 of the License, or (at your option) any later version.
  8.  
  9.    This library is distributed in the hope that it will be useful,
  10.    but WITHOUT ANY WARRANTY; without even the implied warranty of
  11.    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
  12.    Library General Public License for more details.
  13.  
  14.    You should have received a copy of the GNU Library General Public License
  15.    along with this library; see the file COPYING.LIB.  If not, write to
  16.    the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
  17.  * Boston, MA 02110-1301, USA.
  18. */
  19.  
  20. #ifndef KOCHARSELECTDIA_H
  21. #define KOCHARSELECTDIA_H
  22.  
  23. #include <kdialogbase.h>
  24. #include <koffice_export.h>
  25.  
  26. class QWidget;
  27. class QGridLayout;
  28. class QPushButton;
  29. class KCharSelect;
  30. class KButtonBox;
  31.  
  32. /******************************************************************/
  33. /* class KoCharSelectDia                                           */
  34. /******************************************************************/
  35.  
  36. class KOFFICEUI_EXPORT KoCharSelectDia : public KDialogBase
  37. {
  38.     Q_OBJECT
  39.  
  40. public:
  41.  
  42.     // constructor - destructor
  43.     KoCharSelectDia( QWidget *parent, const char *name, const QChar &_chr,
  44.                      const QString &_font, bool _enableFont, bool _modal=true );
  45.  
  46.     //constructor when you want to insert multi char
  47.     KoCharSelectDia( QWidget *parent, const char *name, const QString &_font,
  48.                      const QChar &_chr, bool _modal=true );
  49.     ~KoCharSelectDia();
  50.     // select char dialog
  51.     KOFFICEUI_EXPORT static bool selectChar( QString &_font, QChar &_chr, bool _enableFont = true, QWidget* parent = 0, const char* name = 0);
  52.  
  53.     // internal
  54.     QChar chr() const;
  55.     QString font() const;
  56.     void closeDialog();
  57.  
  58. private:
  59.     void initDialog(const QChar &_chr, const QString &_font, bool _enableFont);
  60.  
  61. private slots:
  62.     void slotUser1();
  63.     void slotDoubleClicked();
  64.  
  65. protected:
  66.     // dialog objects
  67.     QGridLayout *grid;
  68.     KButtonBox *bbox;
  69.     QPushButton *bOk, *bCancel;
  70.     KCharSelect *charSelect;
  71.  
  72.  signals:
  73.     void insertChar(QChar,const QString &);
  74. };
  75.  
  76. #endif
  77.