kformula/flake
FormulaToolWidget.h
Go to the documentation of this file.00001 /* This file is part of the KDE project 00002 Copyright (C) 2007 Martin Pfeiffer <hubipete@gmx.net> 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., 51 Franklin Street, Fifth Floor, 00017 Boston, MA 02110-1301, USA. 00018 */ 00019 00020 #ifndef FORMULATOOLWIDGET_H 00021 #define FORMULATOOLWIDGET_H 00022 00023 #include <QTabWidget> 00024 #include <QMenu> 00025 #include "ui_FormulaToolWidget.h" 00026 00027 class KoFormulaTool; 00028 class QTableWidgetItem; 00029 00038 class FormulaToolWidget : public QTabWidget, Ui::mainTabWidget { 00039 Q_OBJECT 00040 public: 00042 explicit FormulaToolWidget( KoFormulaTool* tool, QWidget* parent = 0 ); 00043 00045 ~FormulaToolWidget(); 00046 00048 void setFormulaTool( KoFormulaTool* tool ); 00049 00050 public slots: 00051 void insertSymbol(QTableWidgetItem* item); 00052 00053 private: 00054 void setupButton(QToolButton* button, QMenu& menu, const QString& text, QList<QString>, int length=8); 00055 00056 static QList<QString> symbolsInRange(int start, int length); 00057 00058 private: 00060 KoFormulaTool* m_tool; 00061 00062 QMenu m_scriptsMenu; 00063 QMenu m_fractionMenu; 00064 QMenu m_tableMenu; 00065 QMenu m_fenceMenu; 00066 QMenu m_rootMenu; 00067 QMenu m_arrowMenu; 00068 QMenu m_greekMenu; 00069 QMenu m_miscMenu; 00070 QMenu m_relationMenu; 00071 QMenu m_operatorMenu; 00072 QMenu m_alterTableMenu; 00073 QMenu m_rowMenu; 00074 }; 00075 00076 #endif // FORMULATOOLWIDGET_H
