summaryrefslogtreecommitdiffstats
path: root/kcharselect/kcharselectdia.h
blob: a6a298b76944a2cd70d2e4add858017a7ae4870d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
/******************************************************************/
/* KCharSelectDia - (c) by Reginald Stadlbauer 1999               */
/* Author: Reginald Stadlbauer                                    */
/* E-Mail: reggie@kde.org                                         */
/******************************************************************/

#ifndef kcharselectdia_h
#define kcharselectdia_h


#include <tqlayout.h>
#include <tqlineedit.h>
#include <tqclipboard.h>

#include <kpushbutton.h>
#include <kcharselect.h>
#include <kmainwindow.h>

static const char *version = "v1.1"; 

/******************************************************************/
/* class KCharSelectDia                                           */
/******************************************************************/

class KCharSelectDia : public KMainWindow
{
  Q_OBJECT
  

public:
  KCharSelectDia(TQWidget *parent,const char *name,const TQChar &_chr,const TQString &_font,int _tableNum, bool direction);

  static bool selectChar(TQString &_font,TQChar &_chr,int _tableNum);

  int chr() { return vChr; }
  TQString font() { return vFont; }

protected:
  void closeEvent(TQCloseEvent *) { _exit(); }

  TQGridLayout *grid;
  KCharSelect *charSelect;
  TQLineEdit   *lined;
  KPushButton *bClip,*bClear;
  KPushButton *bHelp;

  TQChar vChr;
  TQString vFont;
  int pointSize;
  bool entryDirection;

protected slots:
  void charChanged(const TQChar &_chr);
  void fontSelected(const TQString &_font);
  void add()
  { add(vChr); }
  void add(const TQChar &_chr);
  void toClip();
  void toClipUTF8();
  void toClipHTML();
  void fromClip();
  void fromClipUTF8();
  void flipText();
  void toggleEntryDirection();
  void lineEditChanged();
  void _exit();
  void clear();
  void help();

};

#endif