beta-0.89.2
[luatex.git] / source / libs / poppler / poppler-src / poppler / PageTransition.h
blob82f080f418c5aab97915082a21260424d17d955f
1 /* PageTransition.cc
2 * Copyright (C) 2005, Net Integration Technologies, Inc.
3 * Copyright (C) 2015, Arseniy Lartsev <arseniy@alumni.chalmers.se>
5 * This program is free software; you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License as published by
7 * the Free Software Foundation; either version 2, or (at your option)
8 * any later version.
10 * This program is distributed in the hope that it will be useful,
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 * GNU General Public License for more details.
15 * You should have received a copy of the GNU General Public License
16 * along with this program; if not, write to the Free Software
17 * Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston, MA 02110-1301, USA.
20 #ifndef PAGE_TRANSITION_H
21 #define PAGE_TRANSITION_H
23 #ifdef USE_GCC_PRAGMAS
24 #pragma interface
25 #endif
27 #include "Object.h"
29 //------------------------------------------------------------------------
30 // PageTransition
31 //------------------------------------------------------------------------
33 // if changed remember to keep in sync with frontend enums
34 enum PageTransitionType {
35 transitionReplace = 0,
36 transitionSplit,
37 transitionBlinds,
38 transitionBox,
39 transitionWipe,
40 transitionDissolve,
41 transitionGlitter,
42 transitionFly,
43 transitionPush,
44 transitionCover,
45 transitionUncover,
46 transitionFade
49 // if changed remember to keep in sync with frontend enums
50 enum PageTransitionAlignment {
51 transitionHorizontal = 0,
52 transitionVertical
55 // if changed remember to keep in sync with frontend enums
56 enum PageTransitionDirection {
57 transitionInward = 0,
58 transitionOutward
61 class PageTransition {
62 public:
63 // Construct a Page Transition.
64 PageTransition (Object *trans);
66 // Destructor.
67 ~PageTransition ();
69 // Was the Page Transition created successfully?
70 GBool isOk() { return ok; }
72 // Get type
73 PageTransitionType getType() { return type; }
75 // Get duration
76 double getDuration() { return duration; }
78 // Get alignment
79 PageTransitionAlignment getAlignment() { return alignment; }
81 // Get direction
82 PageTransitionDirection getDirection() { return direction; }
84 // Get angle
85 int getAngle() { return angle; }
87 // Get scale
88 double getScale() { return scale; }
90 // Is rectangular?
91 GBool isRectangular() { return rectangular; }
93 private:
95 PageTransitionType type; // transition style
96 double duration; // duration of the effect in seconds
97 PageTransitionAlignment alignment; // dimension of the effect
98 PageTransitionDirection direction; // direction of motion
99 int angle; // direction in degrees
100 double scale; // scale
101 GBool rectangular; // is the area to be flown in rectangular?
102 GBool ok; // set if created successfully
105 #endif /* PAGE_TRANSITION_H */