Subversion Repositories Scribus

Rev

Rev 18394 | Rev 19829 | 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
 
9905 fschmid 10
#include <QTabWidget>
11
#include <QMap>
9803 fschmid 12
#include <QList>
9905 fschmid 13
class QGridLayout;
14
class QHBoxLayout;
15
class QVBoxLayout;
16
class QGroupBox;
17
class QCheckBox;
18
class QComboBox;
19
class QRadioButton;
20
class QPushButton;
21
class QToolButton;
22
class QLineEdit;
23
class QLabel;
24
class QSpinBox;
25
class QListWidget;
26
class QListWidgetItem;
2969 craig 27
 
28
#include "scribusapi.h"
1307 fschmid 29
#include "bookmwin.h"
30
 
1972 craig 31
class PDFOptions;
4259 craig 32
class PDFExportDialog;
5880 jghali 33
class ScribusDoc;
9905 fschmid 34
class ScrSpinBox;
1972 craig 35
 
2969 craig 36
class SCRIBUS_API TabPDFOptions : public QTabWidget
1307 fschmid 37
{
38
        Q_OBJECT
39
 
40
public:
18394 fschmid 41
        TabPDFOptions(QWidget* parent, PDFOptions & Optionen,
42
                                        const SCFonts &AllFonts,
43
                                        const ProfilesL & PDFXProfiles,
44
                                        const QMap<QString, int> & DocFonts,
19828 jghali 45
                                        int unitIndex, ScribusDoc *mdoc);
1307 fschmid 46
        ~TabPDFOptions() {};
12677 jghali 47
 
5553 subik 48
        void restoreDefaults(PDFOptions & Optionen,
49
                                                 const SCFonts &AllFonts,
50
                                                 const ProfilesL & PDFXProfiles,
51
                                                 const QMap<QString, int> & DocFonts,
19828 jghali 52
                                                 int unitIndex, ScribusDoc *mdoc);
1307 fschmid 53
 
12677 jghali 54
        void storeValues(PDFOptions& options);
55
 
9703 fschmid 56
        void unitChange(QString unit, int docUnitIndex, double invUnitConversion);
4256 craig 57
 
19828 jghali 58
        QStringList fontsToEmbed();
59
        QStringList fontsToOutline();
60
 
4253 craig 61
        // GUI member pointers
62
        // Remember to initialize these in the initializer list of the ctor when
63
        // you add new ones. Add them in the same order here and in the initalizer
64
        // list. To help out, the members are sorted alphabetically by name.
65
        QCheckBox* AddSec;
1307 fschmid 66
        QCheckBox* Article;
8602 cbradney 67
        ScrSpinBox* BleedBottom;
68
        ScrSpinBox* BleedLeft;
69
        ScrSpinBox* BleedRight;
70
        ScrSpinBox* BleedTop;
4253 craig 71
        QCheckBox* CheckBM;
72
        QCheckBox* CheckBox1;
1307 fschmid 73
        QComboBox* CMethod;
4649 fschmid 74
        QCheckBox* ClipMarg;
1307 fschmid 75
        QComboBox* ComboBind;
4253 craig 76
        QCheckBox* Compression;
77
        QRadioButton* continuousPages;
78
        QCheckBox* CopySec;
79
        QComboBox* CQuality;
80
        QRadioButton* doublePageLeft;
81
        QRadioButton* doublePageRight;
82
        QCheckBox* DSColor;
12141 avox 83
        QCheckBox* EmbedPDF;
4253 craig 84
        QCheckBox* EmbedProfs;
85
        QCheckBox* EmbedProfs2;
86
        QCheckBox* Encry;
1307 fschmid 87
        QComboBox* ImageP;
4253 craig 88
        QComboBox* IntendI;
89
        QComboBox* IntendS;
90
        QToolButton* MirrorH;
91
        QToolButton* MirrorV;
92
        QCheckBox* ModifySec;
1307 fschmid 93
        QCheckBox* NoEmbedded;
4253 craig 94
        QComboBox* OutCombo;
9905 fschmid 95
        QListWidget* Pages;
1307 fschmid 96
        QLineEdit* PassOwner;
97
        QLineEdit* PassUser;
4253 craig 98
        QComboBox* PDFVersionCombo;
99
        QComboBox* PrintProfC;
1307 fschmid 100
        QCheckBox* PrintSec;
4253 craig 101
        QSpinBox* Resolution;
102
        QComboBox* RotateDeg;
103
        QRadioButton* singlePage;
104
        QComboBox* SolidPr;
105
        QRadioButton* useBookmarks;
4197 fschmid 106
        QRadioButton* useFullScreen;
4253 craig 107
        QCheckBox* useLayers;
108
        QRadioButton* useLayers2;
109
        QCheckBox* UseLPI;
110
        QCheckBox* useSpot;
4197 fschmid 111
        QRadioButton* useThumbnails;
12141 avox 112
        QSpinBox* ValC;  // == PicRes
4253 craig 113
        // End GUI member pointers
114
 
3388 fschmid 115
signals:
116
        void noInfo();
117
        void hasInfo();
118
 
1307 fschmid 119
public slots:
6944 fschmid 120
        void doDocBleeds();
1307 fschmid 121
        void ToggleEncr();
122
        void EnablePDFX(int a);
123
        void DoDownsample();
124
        void RemoveEmbed();
125
        void PutToEmbed();
7107 tsoots 126
        void RemoveOutline();
127
        void PutToOutline();
9905 fschmid 128
        void SelAFont(QListWidgetItem*);
129
        void SelEFont(QListWidgetItem*);
130
        void SelSFont(QListWidgetItem*);
1307 fschmid 131
        void EmbedAll();
7107 tsoots 132
        void OutlineAll();
1307 fschmid 133
        void PagePr();
19828 jghali 134
        void SetPgEff(QListWidgetItem* current, QListWidgetItem* previous);
1307 fschmid 135
        void SetEffOpts(int nr);
136
        void ValidDI(int nr);
137
        void PDFMirror();
138
        void Rotation(int value);
139
        void DoEffects();
140
        void EffectOnAll();
141
        void SelRange(bool e);
142
        void EnablePr(int a);
143
        void EnablePG();
144
        void EnablePGI();
145
        void EnablePGI2();
146
        void EnableLPI(int a);
147
        void EnableLPI2();
148
        void SelLPIcol(int);
149
        void enableCMS(bool enable);
3388 fschmid 150
        void checkInfo();
1307 fschmid 151
 
6657 cbradney 152
protected slots:
153
        void createPageNumberRange();
17921 fschmid 154
        void handleCompressionMethod(int ind);
6657 cbradney 155
 
1307 fschmid 156
protected:
4259 craig 157
        // PDFExportDialog should really privately inherit from us, but it can't
158
        // since it needs to be a dialog not a tab widget. Allow it access to
159
        // protected and private members instead. If we ever clean up the direct
160
        // widget access in this class, it might be able to privately inheirit and
161
        // be added to a very thin dialog class instead.
162
        friend class PDFExportDialog;
9803 fschmid 163
        QList<PDFPresentationData> EffVal;
4259 craig 164
        QString SelLPIcolor;
4258 craig 165
 
4259 craig 166
        // PDFExportDialog needs access to these GUI members
167
        // but they don't need to be exposed to the rest of Scribus.
168
        QComboBox* actionCombo;
169
        QRadioButton* AllPages;
170
        QCheckBox* CheckBox10;
171
        QComboBox* EDirection;
172
        QComboBox* EDirection_2;
173
        QComboBox* EDirection_2_2;
174
        QSpinBox* EffectTime;
175
        QComboBox* EffectType;
176
        QCheckBox* fitWindow;
177
        QCheckBox* hideMenuBar;
178
        QCheckBox* hideToolBar;
179
        QLineEdit* InfoString;
180
        QSpinBox* LPIangle;
181
        QSpinBox* LPIfreq;
182
        QComboBox* LPIfunc;
183
        QLineEdit* PageNr;
184
        QSpinBox* PageTime;
185
 
186
private:
187
        // Private GUI member pointers, should not be used outside the class its
188
        // self.  Please ry to keep members here genuinely private, ie don't use
189
        // them even from friends. If you need to access it from a friend like
190
        // PDFExportDialog please move it to the protected section.
191
 
4255 craig 192
        QLabel* actionLabel;
9905 fschmid 193
        QListWidget* AvailFlist;
194
        QGroupBox* BleedGroup;
195
        QGridLayout* BleedGroupLayout;
196
        QGroupBox* MarkGroup;
197
        QGridLayout* MarkGroupLayout;
6921 fschmid 198
        QCheckBox* cropMarks;
199
        QCheckBox* bleedMarks;
200
        QCheckBox* registrationMarks;
201
        QCheckBox* colorMarks;
202
        QCheckBox* docInfoMarks;
17401 jghali 203
        ScrSpinBox* markLength;
8602 cbradney 204
        ScrSpinBox* markOffset;
9905 fschmid 205
        QGroupBox* CBox;
206
        QGridLayout* CBoxLayout;
207
        QGroupBox* ColorGroup;
208
        QHBoxLayout* ColorGroupLayout;
4255 craig 209
        QLabel* ColorText1;
9905 fschmid 210
        QGroupBox* Effects;
211
        QGridLayout* EffectsLayout;
7070 fschmid 212
        QPushButton* EmbedFonts;
9905 fschmid 213
        QListWidget* EmbedList;
4255 craig 214
        QPushButton* EonAllPg;
215
        QPushButton* FromEmbed;
7107 tsoots 216
        QPushButton* FromOutline;
9905 fschmid 217
        QGroupBox* GroupBox1;
218
        QGridLayout* GroupBox1Layout;
219
        QGroupBox* GroupBox9;
220
        QGridLayout* GroupBox9Layout;
221
        QGroupBox* groupDisplay;
222
        QVBoxLayout* groupDisplayLayout;
223
        QGroupBox* GroupFont;
224
        QHBoxLayout* GroupFontLayout;
225
        QGroupBox* groupJava;
226
        QHBoxLayout* groupJavaLayout;
227
        QGroupBox* groupNavigation;
228
        QVBoxLayout* groupNavigationLayout;
229
        QGroupBox* GroupPass;
230
        QGridLayout* GroupPassLayout;
231
        QGroupBox* GroupSecSet;
232
        QVBoxLayout* GroupSecSetLayout;
233
        QGridLayout* Layout11;
234
        QHBoxLayout *pageNumberSelectorLayout;
235
        QGridLayout* Layout11a;
236
        QHBoxLayout* Layout13;
237
        QVBoxLayout* Layout4_2;
238
        QVBoxLayout* Layout5_2;
239
        QHBoxLayout* Layout5_2a;
240
        QVBoxLayout* Layout6;
241
        QHBoxLayout* LayoutSpecial;
4255 craig 242
        QComboBox* LPIcolor;
9905 fschmid 243
        QGroupBox* LPIgroup;
244
        QGridLayout* LPIgroupLayout;
4255 craig 245
        QRadioButton* OnlySome;
9905 fschmid 246
        QGroupBox* pageLayout;
247
        QVBoxLayout* pageLayoutLayout;
4255 craig 248
        QCheckBox* PagePrev;
249
        QLabel* PDFX1;
250
        QLabel* PDFX2;
251
        QCheckBox* PrintSec2;
9905 fschmid 252
        QGroupBox* ProfsGroup;
253
        QGridLayout* ProfsGroupLayout;
4255 craig 254
        QLabel* ProfsTxt1;
255
        QLabel* ProfsTxt2;
256
        QLabel* ProfsTxt3;
257
        QLabel* ProfsTxt4;
6921 fschmid 258
        QLabel* BleedTxt1;
259
        QLabel* BleedTxt2;
260
        QLabel* BleedTxt3;
261
        QLabel* BleedTxt4;
262
        QLabel* MarkTxt1;
17401 jghali 263
        QLabel* MarkTxt2;
6944 fschmid 264
        QCheckBox *docBleeds;
9905 fschmid 265
        QGroupBox* RangeGroup;
266
        QVBoxLayout* RangeGroupLayout;
267
        QHBoxLayout* RotationLayout;
7107 tsoots 268
        QPushButton* OutlineFonts;
9905 fschmid 269
        QListWidget* OutlineList;
4255 craig 270
        QWidget* tabColor;
9905 fschmid 271
        QVBoxLayout* tabColorLayout;
4255 craig 272
        QWidget* tabFonts;
273
        QWidget* tabGeneral;
9905 fschmid 274
        QVBoxLayout* tabLayout;
275
        QVBoxLayout* tabLayout_3;
276
        QGridLayout* tabLayout_5;
4255 craig 277
        QWidget* tabPDFX;
9905 fschmid 278
        QVBoxLayout* tabPDFXLayout;
4255 craig 279
        QWidget* tabPresentation;
280
        QWidget* tabSecurity;
9905 fschmid 281
        QVBoxLayout* tabSecurityLayout;
4255 craig 282
        QWidget* tabSpecial;
9905 fschmid 283
        QVBoxLayout* tabSpecialLayout;
4255 craig 284
        QLabel* TextCom1;
285
        QLabel* TextCom2;
286
        QLabel* TextFont1;
287
        QLabel* TextFont1_2;
288
        QLabel* TextFont1_2a;
289
        QLabel* TextLabel1;
290
        QLabel* TextLabel1e;
291
        QLabel* TextLabel1x;
292
        QLabel* TextLabel2;
293
        QLabel* TextLabel2e;
294
        QLabel* TextLabel3;
295
        QLabel* TextLabel3e;
296
        QLabel* TextLabel4e;
297
        QLabel* TextLabel5e;
298
        QLabel* TextLabel6e;
299
        QLabel* textLPI1;
300
        QLabel* textLPI2;
301
        QLabel* textLPI3;
302
        QLabel* TextSec1;
303
        QLabel* TextSec2;
6657 cbradney 304
        QPushButton* pageNrButton;
4255 craig 305
        QPushButton* ToEmbed;
7107 tsoots 306
        QPushButton* ToOutline;
4255 craig 307
        QRadioButton* useViewDefault;
9905 fschmid 308
        QGroupBox* X3Group;
309
        QGridLayout* X3GroupLayout;
4255 craig 310
        // end protected GUI member pointers
4197 fschmid 311
 
4259 craig 312
        // Non-GUI protected members
313
        QString unit;
314
        double unitRatio;
18330 jghali 315
        ScribusDoc* const m_Doc;
4260 craig 316
        const SCFonts & AllFonts;
317
        PDFOptions & Opts;
4259 craig 318
        bool cms;
8468 fschmid 319
        QMap<QString, QString> AnnotationFonts;
4259 craig 320
 
1307 fschmid 321
};
322
#endif