1 //======================================================================== 2 // 3 // ViewerPreferences.h 4 // 5 // This file is licensed under the GPLv2 or later 6 // 7 // Copyright 2011 Pino Toscano <pino@kde.org> 8 // 9 //======================================================================== 10 11 #ifndef VIEWERPREFERENCES_H 12 #define VIEWERPREFERENCES_H 13 14 #include "goo/gtypes.h" 15 16 class Dict; 17 18 //------------------------------------------------------------------------ 19 // ViewerPreferences 20 //------------------------------------------------------------------------ 21 22 class ViewerPreferences { 23 public: 24 25 enum NonFullScreenPageMode { 26 nfpmUseNone, 27 nfpmUseOutlines, 28 nfpmUseThumbs, 29 nfpmUseOC 30 }; 31 enum Direction { 32 directionL2R, 33 directionR2L 34 }; 35 enum PrintScaling { 36 printScalingNone, 37 printScalingAppDefault 38 }; 39 enum Duplex { 40 duplexNone, 41 duplexSimplex, 42 duplexDuplexFlipShortEdge, 43 duplexDuplexFlipLongEdge 44 }; 45 46 ViewerPreferences(Dict *prefDict); 47 ~ViewerPreferences(); 48 getHideToolbar()49 GBool getHideToolbar() const { return hideToolbar; } getHideMenubar()50 GBool getHideMenubar() const { return hideMenubar; } getHideWindowUI()51 GBool getHideWindowUI() const { return hideWindowUI; } getFitWindow()52 GBool getFitWindow() const { return fitWindow; } getCenterWindow()53 GBool getCenterWindow() const { return centerWindow; } getDisplayDocTitle()54 GBool getDisplayDocTitle() const { return displayDocTitle; } getNonFullScreenPageMode()55 NonFullScreenPageMode getNonFullScreenPageMode() const { return nonFullScreenPageMode; } getDirection()56 Direction getDirection() const { return direction; } getPrintScaling()57 PrintScaling getPrintScaling() const { return printScaling; } getDuplex()58 Duplex getDuplex() const { return duplex; } 59 60 private: 61 62 void init(); 63 64 GBool hideToolbar; 65 GBool hideMenubar; 66 GBool hideWindowUI; 67 GBool fitWindow; 68 GBool centerWindow; 69 GBool displayDocTitle; 70 NonFullScreenPageMode nonFullScreenPageMode; 71 Direction direction; 72 PrintScaling printScaling; 73 Duplex duplex; 74 }; 75 76 #endif 77