source: wkhtmltox/trunk/fuentes/src/lib/imagesettings.hh @ 51

Last change on this file since 51 was 51, checked in by mabarracus, 4 years ago

wip

File size: 2.2 KB
Line 
1// -*- mode: c++; tab-width: 4; indent-tabs-mode: t; eval: (progn (c-set-style "stroustrup") (c-set-offset 'innamespace 0)); -*-
2// vi:set ts=4 sts=4 sw=4 noet :
3//
4// Copyright 2010 wkhtmltopdf authors
5//
6// This file is part of wkhtmltopdf.
7//
8// wkhtmltopdf is free software: you can redistribute it and/or modify
9// it under the terms of the GNU Lesser General Public License as published by
10// the Free Software Foundation, either version 3 of the License, or
11// (at your option) any later version.
12//
13// wkhtmltopdf is distributed in the hope that it will be useful,
14// but WITHOUT ANY WARRANTY; without even the implied warranty of
15// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
16// GNU General Public License for more details.
17//
18// You should have received a copy of the GNU Lesser General Public License
19// along with wkhtmltopdf.  If not, see <http://www.gnu.org/licenses/>.
20
21#ifndef __IMAGESETTINGS_HH__
22#define __IMAGESETTINGS_HH__
23
24#include <QString>
25#include <wkhtmltox/loadsettings.hh>
26#include <wkhtmltox/websettings.hh>
27
28#include <wkhtmltox/dllbegin.inc>
29namespace wkhtmltopdf {
30namespace settings {
31
32/*! \brief Settings for cropping image */
33struct DLL_PUBLIC CropSettings {
34        CropSettings();
35        //! Cropping left/x coord
36        int left;
37        //! Cropping top/y coord
38        int top;
39        //! Cropping width/w dime
40        int width;
41        //! Cropping height/h dime
42        int height;
43};
44
45/*! \brief Class holding all user settings.
46
47    This class holds all the user settings, settings can be filled in by hand,
48    or with other methods.
49    \sa CommandLineParser::parse()
50*/
51struct DLL_PUBLIC ImageGlobal {
52        ImageGlobal();
53
54        //! Crop related settings
55        CropSettings crop;
56        //! Scale related settings
57        // ScaleSettings scale;
58
59        LoadGlobal loadGlobal;
60        LoadPage loadPage;
61        Web web;
62
63        //! Be less verbose
64        bool quiet;
65
66        bool transparent;
67
68        //! Should we use the graphics system
69        bool useGraphics;
70
71        QString in;
72        //! The file for output
73        QString out;
74        //! The output format
75        QString fmt;
76
77        //! Set the screen width
78        int screenWidth;
79
80        //! Set the screen height
81        int screenHeight;
82
83        //! Image Quality
84        int quality;
85
86        bool smartWidth;
87
88        QString get(const char * name);
89        bool set(const char * name, const QString & value);
90};
91
92#include <wkhtmltox/dllend.inc>
93}
94}
95#endif //__IMAGESETTINGS_HH__
Note: See TracBrowser for help on using the repository browser.