Subversion Repositories Scribus

Rev

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

Rev Author Line No. Line
5783 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
*/
7
/***************************************************************************
8
 *   Copyright (C) 2006 by Craig Bradney                                   *
9
 *   mrb@scribus.info                                                      *
10
 *                                                                         *
11
 *   This program is free software; you can redistribute it and/or modify  *
12
 *   it under the terms of the GNU General Public License as published by  *
13
 *   the Free Software Foundation; either version 2 of the License, or     *
14
 *   (at your option) any later version.                                   *
15
 *                                                                         *
16
 *   This program is distributed in the hope that it will be useful,       *
17
 *   but WITHOUT ANY WARRANTY; without even the implied warranty of        *
18
 *   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the         *
19
 *   GNU General Public License for more details.                          *
20
 *                                                                         *
21
 *   You should have received a copy of the GNU General Public License     *
22
 *   along with this program; if not, write to the                         *
23
 *   Free Software Foundation, Inc.,                                       *
24
 *   59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.             *
25
 ***************************************************************************/
26
 
27
#include "cmsettings.h"
28
#include "scribusdoc.h"
29
 
30
CMSettings::CMSettings(ScribusDoc* doc, const QString& profileName) :
31
m_Doc(doc),
32
m_ProfileName(profileName)
33
{
34
}
35
 
36
CMSettings::~CMSettings()
37
{
38
}
5788 jghali 39
 
40
bool CMSettings::useColorManagement() const
41
{
42
#ifdef HAVE_CMS
43
        return m_Doc->CMSSettings.CMSinUse;
44
#else
45
        return false;
46
#endif
47
}
48
 
49
#ifdef HAVE_CMS
50
cmsHPROFILE CMSettings::monitorProfile() const
51
{
52
        if(m_Doc->CMSSettings.CMSinUse)
53
                return m_Doc->DocOutputProf;
54
        return NULL;
55
}
56
 
57
cmsHPROFILE CMSettings::printerProfile() const
58
{
59
        if(m_Doc->CMSSettings.CMSinUse)
60
                return m_Doc->DocPrinterProf;
61
        return NULL;
62
}
63
 
64
cmsHTRANSFORM CMSettings::rgbColorDisplayTransform() const  // stdTransRGBMonG
65
{
66
        if(m_Doc->CMSSettings.CMSinUse)
67
                return m_Doc->stdTransRGBMon;
68
        return NULL;
69
}
70
 
71
cmsHTRANSFORM CMSettings::rgbColorProofingTransform() const  // stdProofG
72
{
73
        if(m_Doc->CMSSettings.CMSinUse)
74
                return m_Doc->stdProof;
75
        return NULL;
76
}
77
 
78
cmsHTRANSFORM CMSettings::rgbImageDisplayTransform() const   // stdTransImgG
79
{
80
        if(m_Doc->CMSSettings.CMSinUse)
81
                return m_Doc->stdTransImg;
82
        return NULL;
83
}
84
 
85
cmsHTRANSFORM CMSettings::rgbImageProofingTransform() const  // stdProofImgG
86
{
87
        if(m_Doc->CMSSettings.CMSinUse)
88
                return m_Doc->stdProofImg;
89
        return NULL;
90
}
91
 
92
cmsHTRANSFORM CMSettings::rgbToCymkColorTransform() const // stdTransCMYKG
93
{
94
        if(m_Doc->CMSSettings.CMSinUse)
95
                return m_Doc->stdTransCMYK;
96
        return NULL;
97
}
98
 
99
cmsHTRANSFORM CMSettings::rgbGamutCheckTransform() const // stdProofGCG
100
{
101
        if(m_Doc->CMSSettings.CMSinUse)
102
                return m_Doc->stdProofGC;
103
        return NULL;
104
}
105
 
106
cmsHTRANSFORM CMSettings::cmykColorDisplayTransform() const // stdTransCMYKMonG
107
{
108
        if(m_Doc->CMSSettings.CMSinUse)
109
                return m_Doc->stdTransCMYKMon;
110
        return NULL;
111
}
112
 
113
cmsHTRANSFORM CMSettings::cmykColorProofingTransform() const // stdProofCMYKG
114
{
115
        if(m_Doc->CMSSettings.CMSinUse)
116
                return m_Doc->stdProofCMYK;
117
        return NULL;
118
}
119
 
120
cmsHTRANSFORM CMSettings::cmykToRgbColorTransform() const  // stdTransRGBG
121
{
122
        if(m_Doc->CMSSettings.CMSinUse)
123
                return m_Doc->stdTransRGB;
124
        return NULL;
125
}
126
 
127
cmsHTRANSFORM CMSettings::cmykGamutCheckTransform() const //stdProofCMYKGCG
128
{
129
        if(m_Doc->CMSSettings.CMSinUse)
130
                return m_Doc->stdProofCMYKGC;
131
        return NULL;
132
}
133
 
134
int CMSettings::colorRenderingIntent() const
135
{
136
        return m_Doc->IntentColors;
137
}
138
 
139
int CMSettings::imageRenderingIntent() const
140
{
141
        return m_Doc->IntentImages;
142
}
143
 
144
bool CMSettings::useBlackPoint() const
145
{
146
        return m_Doc->CMSSettings.BlackPoint;
147
}
148
 
149
bool CMSettings::doSoftProofing() const
150
{
151
        return m_Doc->CMSSettings.SoftProofOn;
152
}
153
 
154
bool CMSettings::doGamutCheck() const
155
{
156
        return m_Doc->CMSSettings.GamutCheck;
157
}
158
 
159
#endif