r17990 by fschmid - PDF-Import: fixed incorrect import of button colors.
scribus-commit
scribus-commit at lists.scribus.net
Thu Dec 27 18:17:43 UTC 2012
Author: fschmid
Date: Thu Dec 27 18:17:43 2012
New Revision: 17990
URL: http://scribus.net/websvn/listing.php?repname=Scribus&sc=1&rev=17990
Log:
PDF-Import: fixed incorrect import of button colors.
Modified:
trunk/Scribus/scribus/plugins/import/pdf/slaoutput.cpp
Modified: trunk/Scribus/scribus/plugins/import/pdf/slaoutput.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=17990&path=/trunk/Scribus/scribus/plugins/import/pdf/slaoutput.cpp
==============================================================================
--- trunk/Scribus/scribus/plugins/import/pdf/slaoutput.cpp (original)
+++ trunk/Scribus/scribus/plugins/import/pdf/slaoutput.cpp Thu Dec 27 18:17:43 2012
@@ -568,16 +568,24 @@
if (retVal)
{
AnnotAppearanceCharacs *achar = ano->getAppearCharacs();
+ bool fgFound = false;
+ bool bgFound = false;
if (achar)
{
AnnotColor *bgCol = achar->getBackColor();
if (bgCol)
+ {
+ bgFound = true;
CurrColorFill = getAnnotationColor(bgCol);
+ }
else
CurrColorFill = CommonStrings::None;
AnnotColor *fgCol = achar->getBorderColor();
if (fgCol)
+ {
+ fgFound = true;
CurrColorStroke = getAnnotationColor(fgCol);
+ }
else
{
fgCol = achar->getBackColor();
@@ -602,8 +610,10 @@
gfx = new Gfx(xref, Adev, pdfDoc->getPage(m_actPage)->getResourceDict(), catalog, annota->getRect(), NULL);
#endif
annota->draw(gfx, false);
- CurrColorFill = Adev->CurrColorFill;
- CurrColorStroke = Adev->CurrColorStroke;
+ if (!bgFound)
+ CurrColorFill = Adev->CurrColorFill;
+ if (!fgFound)
+ CurrColorStroke = Adev->CurrColorStroke;
CurrColorText = Adev->CurrColorText;
fontSize = Adev->m_fontSize;
fontName = UnicodeParsedString(Adev->m_fontName);
More information about the scribus-commit
mailing list