Subversion Repositories Scribus

Compare Revisions

Ignore whitespace Rev 23269 → Rev 23270

/branches/Version14x/Scribus/scribus/pdflib_core.cpp
7014,8 → 7014,6
bool found = false;
bool alphaM = false;
bool realCMYK = false;
bool bitmapFromGS = false;
bool isEmbeddedPDF = false;
bool hasGrayProfile = false;
QString profInUse = Profil;
int afl = Options.Resolution;
7037,6 → 7035,8
ImInfo.ya = y;
ImInfo.origXsc = c->imageXScale();
ImInfo.origYsc = c->imageYScale();
ImInfo.isBitmapFromGS = false;
ImInfo.isEmbeddedPDF = false;
ShIm ImInfo2;
ImInfo2.origXsc = c->imageXScale();
ImInfo2.origYsc = c->imageYScale();
7075,7 → 7075,7
}
else
imageLoaded = PDF_EmbeddedPDF(c, fn, sx, sy, x, y, fromAN, Profil, Embedded, Intent, ImInfo, output);
isEmbeddedPDF = true;
ImInfo.isEmbeddedPDF = true;
ImInfo.Page = c->pixm.imgInfo.actualPageNumber;
}
if(!imageLoaded && extensionIndicatesPDF(ext) && c->effectsInUse.count() == 0 && Options.embedPDF)
7085,7 → 7085,7
{
if ((extensionIndicatesPDF(ext) || extensionIndicatesEPSorPS(ext)) && (c->pixm.imgInfo.type != ImageType7))
{
bitmapFromGS = true;
ImInfo.isBitmapFromGS = true;
if (Options.RecalcPic)
{
afl = qMin(Options.PicRes, Options.Resolution);
7588,27 → 7588,12
ImInfo = SharedImages[fn];
ImInfo.sxa *= sx / ImInfo.xa;
ImInfo.sya *= sy / ImInfo.ya;
/*
ImRes = SharedImages[fn].ResNum;
ImWid = SharedImages[fn].Width;
ImHei = SharedImages[fn].Height;
aufl = SharedImages[fn].reso;
sxn = SharedImages[fn].sxa * sx / SharedImages[fn].xa;
syn = SharedImages[fn].sya * sy / SharedImages[fn].ya;
*/
}
QString embedPre = "";
if ((bitmapFromGS) || (isEmbeddedPDF)) // compensate gsResolution setting
if ((ImInfo.isBitmapFromGS) || (ImInfo.isEmbeddedPDF)) // compensate gsResolution setting
{
if (isEmbeddedPDF)
if (ImInfo.isEmbeddedPDF)
{
// #9268 : per specs default color space is grayscale
/*if (Options.isGrayscale)
embedPre = "0 g 0 G";
else if (Options.UseRGB)
embedPre = "0 0 0 rg 0 0 0 RG";
else
embedPre = "0 0 0 0 k 0 0 0 0 K";*/
embedPre = "0 g 0 G";
embedPre += " 1 w 0 J 0 j [] 0 d\n"; // add default graphics stack parameters pdftex relies on them
}
/branches/Version14x/Scribus/scribus/pdflib_core.h
66,10 → 66,10
private:
struct ShIm
{
int ResNum;
int Width;
int Height;
int Page;
int ResNum;
int Width;
int Height;
int Page;
double reso;
double sxa;
double sya;
77,6 → 77,8
double ya;
double origXsc;
double origYsc;
bool isBitmapFromGS;
bool isEmbeddedPDF;
QMap<int, ImageLoadRequest> RequestProps;
};