Subversion Repositories Scribus

Compare Revisions

Ignore whitespace Rev 22436 → Rev 22437

/trunk/Scribus/scribus/palettes/paletteloader_cxf.cpp
61,6 → 61,17
{
ScColor color;
 
const CxfReflectanceSpectrum* spectrum = dynamic_cast<const CxfReflectanceSpectrum*>(object->color(cxfReflectanceSpectrum));
if (spectrum)
{
ScLab labVal = m_spectrumConvertor.toLab(spectrum->wavelengths(), spectrum->values());
color.setLabColor(labVal.L, labVal.a, labVal.b);
color.setSpotColor(false);
color.setRegistrationColor(false);
m_colors->tryAddColor(object->name(), color);
return true;
}
 
const CxfColorCIELab* cxfLabColor = dynamic_cast<const CxfColorCIELab*>(object->color(cxfColorCIELab));
if (cxfLabColor)
{
110,16 → 121,5
}
}
 
const CxfReflectanceSpectrum* spectrum = dynamic_cast<const CxfReflectanceSpectrum*>(object->color(cxfReflectanceSpectrum));
if (spectrum)
{
ScLab labVal = m_spectrumConvertor.toLab(spectrum->wavelengths(), spectrum->values());
color.setLabColor(labVal.L, labVal.a, labVal.b);
color.setSpotColor(false);
color.setRegistrationColor(false);
m_colors->tryAddColor(object->name(), color);
return true;
}
 
return false;
}
/trunk/Scribus/scribus/ui/colorsandfills.cpp
1069,7 → 1069,7
QString wdir = dirs->get("colors", ".");
QString docexts("*.sla *.sla.gz *.scd *.scd.gz");
QString aiepsext(FormatsManager::instance()->extensionListForFormat(FormatsManager::EPS|FormatsManager::PS|FormatsManager::AI, 0));
QString ooexts(" *.acb *.aco *.ase *.skp *.soc *.gpl *.xml *.sbz");
QString ooexts(" *.acb *.aco *.ase *.cxf *.gpl *.sbz *.skp *.soc *.xml");
ooexts += extra;
QString filter = tr("All Supported Formats (%1);;Documents (%2);;Other Files (%3);;All Files (*)").arg(docexts+" "+aiepsext+ooexts).arg(docexts).arg(aiepsext+ooexts);
CustomFDialog dia(this, wdir, tr("Import Colors"), filter, fdHidePreviewCheckBox | fdDisableOk);
/trunk/Scribus/scribus/util_color.cpp
32,6 → 32,7
#include "palettes/paletteloader_adobe_aco.h"
#include "palettes/paletteloader_adobe_ase.h"
#include "palettes/paletteloader_autocad_acb.h"
#include "palettes/paletteloader_cxf.h"
#include "palettes/paletteloader_ps.h"
#include "palettes/paletteloader_sk1.h"
#include "palettes/paletteloader_swatchbook.h"
700,6 → 701,16
}
return false;
}
else if (ext == "cxf") // Adobe swatch exchange format
{
PaletteLoader_CxF cxfLoader;
if (cxfLoader.isFileSupported(fileName))
{
cxfLoader.setupTargets(&EditColors, dialogGradients);
return cxfLoader.importFile(fileName, merge);
}
return false;
}
else if (ext == "skp") // Sk1 palette
{
PaletteLoader_sK1 sk1PalLoader;