kword

defs.h

00001 /* This file is part of the KDE project
00002    Copyright (C) 1998, 1999 Reginald Stadlbauer <reggie@kde.org>, Torben Weis <weis@kde.org>
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 defs_h
00021 #define defs_h
00022 
00023 #include <qtextstream.h>
00024 #include <qstring.h>
00025 #include <KoGlobal.h>
00026 #include "KWFactory.h"
00027 
00028 // Try to add new defines and enums in the most appropriate class
00029 // instead of in this file. Only very global things should be here.
00030 
00031 #define KWBarIcon( x ) BarIcon( x, KWFactory::instance() )
00032 
00033 #define DEBUGRECT(rc) (rc).x() << "," << (rc).y() << " " << (rc).width() << "x" << (rc).height()
00034 #define DEBUGREGION(reg) { QMemArray<QRect>rs=reg.rects(); for (int i=0;i<rs.size();++i) \
00035                            kdDebug()<<"  "<<DEBUGRECT(rs[i] )<<endl; }
00036 
00037 const unsigned int s_minFrameWidth=4;
00038 const unsigned int s_minFrameHeight=11;
00039 
00051 enum FrameSetType { FT_BASE = 0, FT_TEXT = 1, FT_PICTURE = 2, FT_PART = 3,
00052                     FT_FORMULA = 4, FT_CLIPART = 5,
00053                     FT_TABLE = 10 };
00054 // This has to remain here because of KWDocument::refreshDocStructure()
00055 
00056 // This one has better remain here, otherwise kwdoc.cc needs docstruct.h
00057 enum TypeStructDocItem {Arrangement=1, Tables=2, Pictures=4, TextFrames=16, Embedded=32, FormulaFrames=64};
00058 
00059 // This one has better remain here, otherwise kwtexframeset.h needs footnote.h
00060 // Yes, if gcc was faster we would choose more modular code over compilation speed...
00061 enum NoteType { FootNote, EndNote };
00062 
00063 enum SeparatorLinePos { SLP_LEFT = 0, SLP_CENTERED = 1, SLP_RIGHT = 2};
00064 enum SeparatorLineLineType { SLT_SOLID = 0, SLT_DASH = 1, SLT_DOT = 2, SLT_DASH_DOT = 3, SLT_DASH_DOT_DOT = 4};
00065 
00066 // Shared between sortdia.h and kwtextframeset.h
00067 enum SortType { KW_SORTINCREASE, KW_SORTDECREASE };
00068 
00073 enum MouseMeaning { MEANING_NONE = 0, MEANING_MOUSE_INSIDE, MEANING_MOUSE_INSIDE_TEXT,
00074                     MEANING_MOUSE_OVER_LINK, MEANING_MOUSE_OVER_FOOTNOTE,
00075                     MEANING_MOUSE_MOVE, MEANING_MOUSE_SELECT, MEANING_ACTIVATE_PART,
00076                     MEANING_TOPLEFT, MEANING_TOP, MEANING_TOPRIGHT, MEANING_RIGHT,
00077                     MEANING_BOTTOMRIGHT, MEANING_BOTTOM, MEANING_BOTTOMLEFT, MEANING_LEFT,
00078                     MEANING_RESIZE_COLUMN, MEANING_RESIZE_ROW, MEANING_SELECT_RANGE,
00079                     MEANING_SELECT_COLUMN, MEANING_SELECT_ROW, MEANING_FORBIDDEN };
00080 
00081 enum InsertPagePos { KW_INSERTPAGEAFTER=0 , KW_INSERTPAGEBEFORE=1 };
00082 
00083 
00084 #endif
KDE Home | KDE Accessibility Home | Description of Access Keys