kpresenter
KPrPageEffects.h
00001 // -*- Mode: c++; c-basic-offset: 4; indent-tabs-mode: nil; tab-width: 4; -*- 00002 /* This file is part of the KDE project 00003 Copyright (C) 1998, 1999 Reginald Stadlbauer <reggie@kde.org> 00004 Copyright (C) 2002 Ariya Hidayat <ariya@kde.org> 00005 Copyright (C) 2002 Harri Porten <porten@kde.org> 00006 Copyright (C) 2004 Thorsten Zachmann <zachmann@kde.org> 00007 00008 This library is free software; you can redistribute it and/or 00009 modify it under the terms of the GNU Library General Public 00010 License as published by the Free Software Foundation; either 00011 version 2 of the License, or (at your option) any later version. 00012 00013 This library is distributed in the hope that it will be useful, 00014 but WITHOUT ANY WARRANTY; without even the implied warranty of 00015 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 00016 Library General Public License for more details. 00017 00018 You should have received a copy of the GNU Library General Public License 00019 along with this library; see the file COPYING.LIB. If not, write to 00020 the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, 00021 * Boston, MA 02110-1301, USA. 00022 */ 00023 00024 #ifndef PAGEEFFECTS_H 00025 #define PAGEEFFECTS_H 00026 00027 #include "global.h" 00028 #include <qvaluelist.h> 00029 00030 00031 class QPaintDevice; 00032 class QPixmap; 00033 00034 00035 class KPrPageEffects 00036 { 00037 public: 00049 KPrPageEffects( QPaintDevice *dst, const QPixmap &pageTo, PageEffect effect, EffectSpeed speed ); 00050 00051 ~KPrPageEffects(); 00052 00057 bool doEffect(); 00058 00062 void finish(); 00063 protected: 00064 bool effectNone() const; 00065 bool effectCloseHorizontal() const; 00066 bool effectCloseVertical() const; 00067 bool effectCloseFromAllDirections() const; 00068 bool effectOpenHorizontal() const; 00069 bool effectOpenVertical() const; 00070 bool effectOpenFromAllDirections() const; 00071 bool effectInterlockingHorizontal1() const; 00072 bool effectInterlockingHorizontal2() const; 00073 bool effectInterlockingVertical1() const; 00074 bool effectInterlockingVertical2() const; 00075 bool effectSurround1() const; 00076 bool effectFlyAway1(); 00077 bool effectBlindsHorizontal() const; 00078 bool effectBlindsVertical() const; 00079 bool effectBoxIn() const; 00080 bool effectBoxOut() const ; 00081 bool effectCheckboardAcross() const; 00082 bool effectCheckboardDown() const; 00083 bool effectCoverDown() const; 00084 bool effectUncoverDown() const; 00085 bool effectCoverUp() const; 00086 bool effectUncoverUp(); 00087 bool effectCoverLeft() const; 00088 bool effectUncoverLeft(); 00089 bool effectCoverRight() const; 00090 bool effectUncoverRight(); 00091 bool effectCoverLeftUp() const; 00092 bool effectUncoverLeftUp(); 00093 bool effectCoverLeftDown() const; 00094 bool effectUncoverLeftDown(); 00095 bool effectCoverRightUp() const; 00096 bool effectUncoverRightUp(); 00097 bool effectCoverRightDown() const; 00098 bool effectUncoverRightDown(); 00099 bool effectDissolve(); 00100 bool effectStripesLeftUp() const; 00101 bool effectStripesLeftDown() const; 00102 bool effectStripesRightUp() const; 00103 bool effectStripesRigthDown() const; 00104 bool effectMelting(); 00105 00106 QPaintDevice *m_dst; 00107 const QPixmap m_pageTo; 00108 QPixmap m_pageFrom; 00109 PageEffect m_effect; 00110 PageEffect m_randomEffect; 00111 EffectSpeed m_speed; 00112 QValueList<int> m_list; 00113 int m_effectStep; 00114 int m_stepWidth; 00115 int m_stepHeight; 00116 int m_width; 00117 int m_height; 00118 bool m_finished; 00119 }; 00120 00121 #endif /* PAGEEFFECTS_H */