SymbolDialog.h
Go to the documentation of this file.
/***************************************************************************
File : SymbolDialog.h
Project : QtiPlot
--------------------------------------------------------------------
Copyright : (C) 2006 by Ion Vasilief, Tilman Hoener zu Siederdissen
Email (use @ for *) : ion_vasilief*yahoo.fr, thzs*gmx.net
Description : Tool window to select special text characters
***************************************************************************/
/***************************************************************************
* *
* This program is free software; you can redistribute it and/or modify *
* it under the terms of the GNU General Public License as published by *
* the Free Software Foundation; either version 2 of the License, or *
* (at your option) any later version. *
* *
* This program is distributed in the hope that it will be useful, *
* but WITHOUT ANY WARRANTY; without even the implied warranty of *
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
* GNU General Public License for more details. *
* *
* You should have received a copy of the GNU General Public License *
* along with this program; if not, write to the Free Software *
* Foundation, Inc., 51 Franklin Street, Fifth Floor, *
* Boston, MA 02110-1301 USA *
* *
***************************************************************************/
#ifndef SYMBOLDIALOG_H
#define SYMBOLDIALOG_H
#include <QDialog>
class QPushButton;
class QSizePolicy;
class QGroupBox;
class QShortcut;
class QHBoxLayout;
class QVBoxLayout;
class QGridLayout;
class QButtonGroup;
class SymbolDialog : public QDialog
{
Q_OBJECT
public:
enum CharSet{
lowerGreek = 0,
upperGreek = 1,
mathSymbols = 2,
arrowSymbols = 3,
numberSymbols = 4,
latexArrowSymbols = 5,
latexMathSymbols = 6
};
SymbolDialog(CharSet charSet, QWidget* parent = 0, Qt::WFlags fl = 0 );
private:
void initLowerGreekChars();
void initUpperGreekChars();
void initMathSymbols();
void initArrowSymbols();
void initNumberSymbols();
void initLatexArrowSymbols();
void initLatexMathSymbols();
QButtonGroup * buttons;
QPushButton * closeButton;
int numButtons;
QVBoxLayout * mainLayout;
QGridLayout * gridLayout;
protected:
void focusInEvent( QFocusEvent * event );
public slots:
virtual void languageChange();
void getChar(int btnIndex);
void addCurrentChar();
signals:
void addLetter(const QString&);
};
#endif // exportDialog_H
SymbolDialog::focusInEvent
void focusInEvent(QFocusEvent *event)
Event handler: When the dialog gets the focus the first button is set to react on [return]...
Definition: SymbolDialog.cpp:689
SymbolDialog::upperGreek
Definition: SymbolDialog.h:51
SymbolDialog::CharSet
CharSet
Character set.
Definition: SymbolDialog.h:49
SymbolDialog::gridLayout
QGridLayout * gridLayout
Definition: SymbolDialog.h:87
SymbolDialog::latexArrowSymbols
Definition: SymbolDialog.h:55
SymbolDialog::latexMathSymbols
Definition: SymbolDialog.h:56
SymbolDialog::initLatexArrowSymbols
void initLatexArrowSymbols()
Show default LaTeX arrow symbols.
Definition: SymbolDialog.cpp:577
SymbolDialog::languageChange
virtual void languageChange()
Change language (reset title)
Definition: SymbolDialog.cpp:683
SymbolDialog
Tools window to select special text characters.
Definition: SymbolDialog.h:43
SymbolDialog::numberSymbols
Definition: SymbolDialog.h:54
SymbolDialog::addLetter
void addLetter(const QString &)
Emitted when a letter is to be added.
SymbolDialog::addCurrentChar
void addCurrentChar()
Find and emit char from current button ([return] pressed)
Definition: SymbolDialog.cpp:665
SymbolDialog::lowerGreek
Definition: SymbolDialog.h:50
SymbolDialog::arrowSymbols
Definition: SymbolDialog.h:53
SymbolDialog::initArrowSymbols
void initArrowSymbols()
Show arrow symbols.
Definition: SymbolDialog.cpp:535
SymbolDialog::initLowerGreekChars
void initLowerGreekChars()
Show lowercase Greek characters.
Definition: SymbolDialog.cpp:89
SymbolDialog::SymbolDialog
SymbolDialog(CharSet charSet, QWidget *parent=0, Qt::WFlags fl=0)
Constructor.
Definition: SymbolDialog.cpp:40
SymbolDialog::closeButton
QPushButton * closeButton
Definition: SymbolDialog.h:84
SymbolDialog::initNumberSymbols
void initNumberSymbols()
Show number symbols.
Definition: SymbolDialog.cpp:145
SymbolDialog::buttons
QButtonGroup * buttons
Definition: SymbolDialog.h:83
SymbolDialog::initMathSymbols
void initMathSymbols()
Show mathematical symbols.
Definition: SymbolDialog.cpp:167
SymbolDialog::initLatexMathSymbols
void initLatexMathSymbols()
Show default LaTeX math symbols.
Definition: SymbolDialog.cpp:361
SymbolDialog::mainLayout
QVBoxLayout * mainLayout
Definition: SymbolDialog.h:86
SymbolDialog::getChar
void getChar(int btnIndex)
Find and emit char from pressed button.
Definition: SymbolDialog.cpp:675
SymbolDialog::mathSymbols
Definition: SymbolDialog.h:52
SymbolDialog::numButtons
int numButtons
Definition: SymbolDialog.h:85
SymbolDialog::initUpperGreekChars
void initUpperGreekChars()
Show uppercase Greek characters.
Definition: SymbolDialog.cpp:102