Subversion Repositories Scribus

Rev

Rev 4430 | Rev 5320 | Go to most recent revision | Details | Compare with Previous | Last modification | View Log | RSS feed

Rev Author Line No. Line
4430 cbradney 1
/*
2
For general Scribus (>=1.3.2) copyright and licensing information please refer
3
to the COPYING file provided with the program. Following this notice may exist
4
a copyright and/or license notice that predates the release of Scribus 1.3.2
5
for which a new license (GPL+exception) is in place.
6
*/
1307 fschmid 7
#ifndef TABPDF_OPTS_H
8
#define TABPDF_OPTS_H
2969 craig 9
 
1307 fschmid 10
#include <qtabwidget.h>
11
#include <qwidget.h>
12
#include <qlayout.h>
13
#include <qtooltip.h>
14
#include <qlistbox.h>
15
#include <qmap.h>
16
#include <qvaluelist.h>
17
#include <qbuttongroup.h>
18
#include <qgroupbox.h>
19
#include <qcheckbox.h>
20
#include <qcombobox.h>
21
#include <qradiobutton.h>
22
#include <qspinbox.h>
23
#include <qtabwidget.h>
24
#include <qwidget.h>
25
#include <qpushbutton.h>
26
#include <qtoolbutton.h>
27
#include <qlineedit.h>
28
#include <qlabel.h>
2969 craig 29
 
30
#include "scribusapi.h"
1307 fschmid 31
#include "bookmwin.h"
32
#include "mspinbox.h"
33
 
1972 craig 34
class PDFOptions;
4259 craig 35
class PDFExportDialog;
1972 craig 36
 
2969 craig 37
class SCRIBUS_API TabPDFOptions : public QTabWidget
1307 fschmid 38
{
39
        Q_OBJECT
40
 
41
public:
4260 craig 42
        TabPDFOptions(  QWidget* parent, PDFOptions & Optionen,
43
                        const SCFonts &AllFonts,
44
                        const ProfilesL & PDFXProfiles,
45
                        const QMap<QString,int> & DocFonts,
46
                        const QValueList<PDFPresentationData> & Eff,
47
                        int unitIndex, double PageH, double PageB,
48
                        ScribusView *vie = 0 );
1307 fschmid 49
        ~TabPDFOptions() {};
1828 fschmid 50
        void restoreDefaults();
1307 fschmid 51
 
4256 craig 52
        void unitChange(int newUnitIndex);
53
 
4253 craig 54
        // GUI member pointers
55
        // Remember to initialize these in the initializer list of the ctor when
56
        // you add new ones. Add them in the same order here and in the initalizer
57
        // list. To help out, the members are sorted alphabetically by name.
58
        QCheckBox* AddSec;
1307 fschmid 59
        QCheckBox* Article;
4253 craig 60
        MSpinBox* BleedBottom;
61
        MSpinBox* BleedLeft;
62
        MSpinBox* BleedRight;
63
        MSpinBox* BleedTop;
64
        QCheckBox* CheckBM;
65
        QCheckBox* CheckBox1;
1307 fschmid 66
        QComboBox* CMethod;
4649 fschmid 67
        QCheckBox* ClipMarg;
1307 fschmid 68
        QComboBox* ComboBind;
4253 craig 69
        QCheckBox* Compression;
70
        QRadioButton* continuousPages;
71
        QCheckBox* CopySec;
72
        QComboBox* CQuality;
73
        QRadioButton* doublePageLeft;
74
        QRadioButton* doublePageRight;
75
        QCheckBox* DSColor;
76
        QCheckBox* EmbedProfs;
77
        QCheckBox* EmbedProfs2;
78
        QCheckBox* Encry;
1307 fschmid 79
        QComboBox* ImageP;
4253 craig 80
        QComboBox* IntendI;
81
        QComboBox* IntendS;
82
        QToolButton* MirrorH;
83
        QToolButton* MirrorV;
84
        QCheckBox* ModifySec;
1307 fschmid 85
        QCheckBox* NoEmbedded;
4253 craig 86
        QComboBox* OutCombo;
87
        QListBox* Pages;
1307 fschmid 88
        QLineEdit* PassOwner;
89
        QLineEdit* PassUser;
4253 craig 90
        QComboBox* PDFVersionCombo;
91
        QComboBox* PrintProfC;
1307 fschmid 92
        QCheckBox* PrintSec;
4253 craig 93
        QSpinBox* Resolution;
94
        QComboBox* RotateDeg;
95
        QRadioButton* singlePage;
96
        QComboBox* SolidPr;
97
        QRadioButton* useBookmarks;
4197 fschmid 98
        QRadioButton* useFullScreen;
4253 craig 99
        QCheckBox* useLayers;
100
        QRadioButton* useLayers2;
101
        QCheckBox* UseLPI;
102
        QCheckBox* useSpot;
4197 fschmid 103
        QRadioButton* useThumbnails;
4253 craig 104
        QSpinBox* ValC;
105
        // End GUI member pointers
106
 
3388 fschmid 107
signals:
108
        void noInfo();
109
        void hasInfo();
110
 
1307 fschmid 111
public slots:
112
        void ToggleEncr();
113
        void BleedChanged();
114
        void EnablePDFX(int a);
115
        void DoDownsample();
116
        void RemoveEmbed();
117
        void PutToEmbed();
118
        void RemoveSubset();
119
        void PutToSubset();
120
        void SelAFont(QListBoxItem*);
121
        void SelEFont(QListBoxItem*);
122
        void SelSFont(QListBoxItem*);
123
        void EmbedAll();
124
        void SubsetAll();
125
        void PagePr();
126
        void SetPgEff(int nr);
127
        void SetEffOpts(int nr);
128
        void ValidDI(int nr);
129
        void PDFMirror();
130
        void Rotation(int value);
131
        void DoEffects();
132
        void EffectOnAll();
133
        void SelRange(bool e);
134
        void EnablePr(int a);
135
        void EnablePG();
136
        void EnablePGI();
137
        void EnablePGI2();
138
        void EnableLPI(int a);
139
        void EnableLPI2();
140
        void SelLPIcol(int);
141
        void enableCMS(bool enable);
3388 fschmid 142
        void checkInfo();
1307 fschmid 143
 
144
protected:
4259 craig 145
        // PDFExportDialog should really privately inherit from us, but it can't
146
        // since it needs to be a dialog not a tab widget. Allow it access to
147
        // protected and private members instead. If we ever clean up the direct
148
        // widget access in this class, it might be able to privately inheirit and
149
        // be added to a very thin dialog class instead.
150
        friend class PDFExportDialog;
151
        int PgSel;
152
        QValueList<PDFPresentationData> EffVal;
153
        QString SelLPIcolor;
154
        QValueList<QString> FontsToEmbed;
155
        QValueList<QString> FontsToSubset;
4258 craig 156
 
4259 craig 157
        // PDFExportDialog needs access to these GUI members
158
        // but they don't need to be exposed to the rest of Scribus.
159
        QComboBox* actionCombo;
160
        QRadioButton* AllPages;
161
        QCheckBox* CheckBox10;
162
        QComboBox* EDirection;
163
        QComboBox* EDirection_2;
164
        QComboBox* EDirection_2_2;
165
        QSpinBox* EffectTime;
166
        QComboBox* EffectType;
167
        QCheckBox* fitWindow;
168
        QCheckBox* hideMenuBar;
169
        QCheckBox* hideToolBar;
170
        QLineEdit* InfoString;
171
        QSpinBox* LPIangle;
172
        QSpinBox* LPIfreq;
173
        QComboBox* LPIfunc;
174
        QLineEdit* PageNr;
175
        QSpinBox* PageTime;
176
 
177
private:
178
        // Private GUI member pointers, should not be used outside the class its
179
        // self.  Please ry to keep members here genuinely private, ie don't use
180
        // them even from friends. If you need to access it from a friend like
181
        // PDFExportDialog please move it to the protected section.
182
 
4255 craig 183
        QLabel* actionLabel;
184
        QListBox* AvailFlist;
185
        QGroupBox* BleedGroup;
186
        QGridLayout* BleedGroupLayout;
187
        QLabel* BleedIcon;
188
        QGroupBox* CBox;
1307 fschmid 189
        QGridLayout* CBoxLayout;
4255 craig 190
        QGroupBox* ColorGroup;
191
        QHBoxLayout* ColorGroupLayout;
192
        QLabel* ColorText1;
193
        QGroupBox* Effects;
194
        QGridLayout* EffectsLayout;
195
        QCheckBox* EmbedFonts;
196
        QListBox* EmbedList;
197
        QPushButton* EonAllPg;
198
        QPushButton* FromEmbed;
199
        QPushButton* FromSubset;
200
        QGroupBox* GroupBox1;
201
        QGridLayout* GroupBox1Layout;
202
        QGridLayout* GroupBox2Layout;
203
        QGroupBox* GroupBox9;
204
        QGridLayout* GroupBox9Layout;
205
        QGroupBox* groupDisplay;
206
        QVBoxLayout* groupDisplayLayout;
207
        QGroupBox* GroupFont;
208
        QHBoxLayout* GroupFontLayout;
209
        QGroupBox* groupJava;
210
        QHBoxLayout* groupJavaLayout;
211
        QButtonGroup* groupNavigation;
212
        QVBoxLayout* groupNavigationLayout;
213
        QGroupBox* GroupPass;
214
        QGridLayout* GroupPassLayout;
215
        QGroupBox* GroupSecSet;
216
        QVBoxLayout* GroupSecSetLayout;
217
        QGridLayout* Layout11;
218
        QGridLayout* Layout11a;
219
        QHBoxLayout* Layout13;
220
        QHBoxLayout* Layout2;
1307 fschmid 221
        QVBoxLayout* Layout3;
222
        QVBoxLayout* Layout4_2;
223
        QVBoxLayout* Layout5_2;
224
        QHBoxLayout* Layout5_2a;
225
        QVBoxLayout* Layout6;
4255 craig 226
        QHBoxLayout* LayoutSpecial;
227
        QComboBox* LPIcolor;
228
        QGroupBox* LPIgroup;
229
        QGridLayout* LPIgroupLayout;
230
        QRadioButton* OnlySome;
231
        QButtonGroup* pageLayout;
232
        QVBoxLayout* pageLayoutLayout;
233
        QCheckBox* PagePrev;
234
        QLabel* PDFX1;
235
        QLabel* PDFX2;
236
        QCheckBox* PrintSec2;
237
        QGroupBox* ProfsGroup;
238
        QGridLayout* ProfsGroupLayout;
239
        QLabel* ProfsTxt1;
240
        QLabel* ProfsTxt2;
241
        QLabel* ProfsTxt3;
242
        QLabel* ProfsTxt4;
243
        QButtonGroup* RangeGroup;
244
        QVBoxLayout* RangeGroupLayout;
245
        QCheckBox* SubsetFonts;
246
        QListBox* SubsetList;
247
        QWidget* tabColor;
248
        QVBoxLayout* tabColorLayout;
249
        QWidget* tabFonts;
250
        QWidget* tabGeneral;
251
        QVBoxLayout* tabLayout;
252
        QVBoxLayout* tabLayout_3;
1307 fschmid 253
        QGridLayout* tabLayout_5;
254
        QGridLayout* tabOptionsGridLayout;
4255 craig 255
        QWidget* tabPDFX;
1307 fschmid 256
        QVBoxLayout* tabPDFXLayout;
4255 craig 257
        QWidget* tabPresentation;
258
        QWidget* tabSecurity;
1307 fschmid 259
        QVBoxLayout* tabSecurityLayout;
4255 craig 260
        QWidget* tabSpecial;
4197 fschmid 261
        QVBoxLayout* tabSpecialLayout;
4255 craig 262
        QLabel* TextCom1;
263
        QLabel* TextCom2;
264
        QLabel* TextFont1;
265
        QLabel* TextFont1_2;
266
        QLabel* TextFont1_2a;
267
        QLabel* TextLabel1;
268
        QLabel* TextLabel1e;
269
        QLabel* TextLabel1x;
270
        QLabel* TextLabel2;
271
        QLabel* TextLabel2e;
272
        QLabel* TextLabel3;
273
        QLabel* TextLabel3e;
274
        QLabel* TextLabel4e;
275
        QLabel* TextLabel5e;
276
        QLabel* TextLabel6e;
277
        QLabel* textLPI1;
278
        QLabel* textLPI2;
279
        QLabel* textLPI3;
280
        QLabel* TextSec1;
281
        QLabel* TextSec2;
282
        QPushButton* ToEmbed;
283
        QPushButton* ToSubset;
284
        QRadioButton* useViewDefault;
285
        QGroupBox* X3Group;
286
        QGridLayout* X3GroupLayout;
287
        // end protected GUI member pointers
4197 fschmid 288
 
4259 craig 289
        // Non-GUI protected members
290
        QString unit;
291
        int precision;
292
        double unitRatio;
293
        ScribusView * const view;
4260 craig 294
        const SCFonts & AllFonts;
295
        PDFOptions & Opts;
4259 craig 296
        double pageH;
297
        double pageB;
298
        bool cms;
299
 
1307 fschmid 300
};
301
#endif