Subversion Repositories Scribus

Rev

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