Subversion Repositories Scribus

Compare Revisions

Ignore whitespace Rev 5583 → Rev 5584

/branches/Version13x/Scribus/scribus/fileloader.cpp
341,6 → 341,7
newReplacement = false;
ScMW->doc->guidesSettings.marginsShown = prefsManager->appPrefs.guidesSettings.marginsShown;
ScMW->doc->guidesSettings.framesShown = prefsManager->appPrefs.guidesSettings.framesShown;
ScMW->doc->guidesSettings.layerMarkersShown = prefsManager->appPrefs.guidesSettings.layerMarkersShown;
ScMW->doc->guidesSettings.gridShown = prefsManager->appPrefs.guidesSettings.gridShown;
ScMW->doc->guidesSettings.guidesShown = prefsManager->appPrefs.guidesSettings.guidesShown;
ScMW->doc->guidesSettings.colBordersShown = prefsManager->appPrefs.guidesSettings.colBordersShown;
588,7 → 589,37
la.transparency = pg.attribute("TRANS", "1").toDouble();
la.blendMode = pg.attribute("BLEND", "0").toInt();
la.outlineMode = pg.attribute("OUTL", "0").toInt();
la.markerColor = QColor(pg.attribute("LAYERC","#000000"));
if (pg.hasAttribute("LAYERC"))
la.markerColor = QColor(pg.attribute("LAYERC","#000000"));
else
{
QColor marker;
switch (la.LNr % 7)
{
case 0:
marker = Qt::black;
break;
case 1:
marker = Qt::red;
break;
case 2:
marker = Qt::green;
break;
case 3:
marker = Qt::blue;
break;
case 4:
marker = Qt::cyan;
break;
case 5:
marker = Qt::magenta;
break;
case 6:
marker = Qt::yellow;;
break;
}
la.markerColor = marker;
}
bool laex = false;
uint layerCount=doc->layerCount();
for (uint la2 = 0; la2 < layerCount; ++la2)
1057,6 → 1088,7
doc->guidesSettings.guidesShown = static_cast<bool>(dc.attribute("SHOWGUIDES", "1").toInt());
doc->guidesSettings.colBordersShown = static_cast<bool>(dc.attribute("showcolborders", "0").toInt());
doc->guidesSettings.framesShown = static_cast<bool>(dc.attribute("SHOWFRAME", "1").toInt());
doc->guidesSettings.layerMarkersShown = static_cast<bool>(dc.attribute("SHOWLAYERM", "0").toInt());
doc->guidesSettings.marginsShown = static_cast<bool>(dc.attribute("SHOWMARGIN", "1").toInt());
doc->guidesSettings.baseShown = static_cast<bool>(dc.attribute("SHOWBASE", "0").toInt());
doc->guidesSettings.showPic = static_cast<bool>(dc.attribute("SHOWPICT", "1").toInt());
1240,7 → 1272,37
la.transparency = pg.attribute("TRANS", "1").toDouble();
la.blendMode = pg.attribute("BLEND", "0").toInt();
la.outlineMode = pg.attribute("OUTL", "0").toInt();
la.markerColor = QColor(pg.attribute("LAYERC","#000000"));
if (pg.hasAttribute("LAYERC"))
la.markerColor = QColor(pg.attribute("LAYERC","#000000"));
else
{
QColor marker;
switch (la.LNr % 7)
{
case 0:
marker = Qt::black;
break;
case 1:
marker = Qt::red;
break;
case 2:
marker = Qt::green;
break;
case 3:
marker = Qt::blue;
break;
case 4:
marker = Qt::cyan;
break;
case 5:
marker = Qt::magenta;
break;
case 6:
marker = Qt::yellow;;
break;
}
la.markerColor = marker;
}
doc->Layers.append(la);
}
/* if(pg.tagName()=="Bookmark")
/branches/Version13x/Scribus/scribus/prefs.cpp
476,6 → 476,10
checkRuler->setText( tr( "Rulers relative to Page" ) );
checkRuler->setChecked(prefsData->guidesSettings.rulerMode);
pageBackgroundLayout->addWidget( checkRuler, 3, 0 );
checkLayerM = new QCheckBox( pageBackground, "checkLayerM" );
checkLayerM->setText( tr( "Show Layer Indicators" ) );
checkLayerM->setChecked(prefsData->guidesSettings.layerMarkersShown);
pageBackgroundLayout->addWidget( checkLayerM, 3, 1 );
tabViewLayout->addWidget( pageBackground );
 
groupScratch = new QGroupBox( tabView, "GroupBox7" );
724,6 → 728,7
QToolTip::add( checkLink, "<qt>" + tr("Enable or disable the display of linked frames.") + "</qt>");
QToolTip::add( checkControl, "<qt>" + tr("Display non-printing characters such as paragraph markers in text frames") + "</qt>");
QToolTip::add( checkFrame, "<qt>" + tr("Turns the display of frames on or off") + "</qt>");
QToolTip::add( checkLayerM, "<qt>" + tr("Turns the display of layer indicators on or off") + "</qt>");
QToolTip::add( checkPictures, "<qt>" + tr("Turns the display of pictures on or off") + "</qt>");
QToolTip::add( guiLangCombo, "<qt>" + tr( "Select your default language for Scribus to run with. Leave this blank to choose based on environment variables. You can still override this by passing a command line option when starting Scribus" )+"</qt>" );
QToolTip::add( GUICombo, "<qt>" + tr( "Choose the default window decoration and looks. Scribus inherits any available KDE or Qt themes, if Qt is configured to search KDE plugins." ) + "</qt>" );
867,8 → 872,8
checkLink->setChecked(prefsData->guidesSettings.linkShown);
checkControl->setChecked(prefsData->guidesSettings.showControls);
checkFrame->setChecked(prefsData->guidesSettings.framesShown);
checkLayerM->setChecked(prefsData->guidesSettings.layerMarkersShown);
checkRuler->setChecked(prefsData->guidesSettings.rulerMode);
checkRuler->setChecked(prefsData->guidesSettings.rulerMode);
topScratch->setDecimals( decimals );
topScratch->setValue(prefsData->ScratchTop * unitRatio);
leftScratch->setDecimals( decimals );
1393,6 → 1398,7
prefsManager->appPrefs.toolSettings.defSize = tabTools->sizeComboText->currentText().left(2).toInt() * 10;
prefsManager->appPrefs.guidesSettings.marginsShown = tabGuides->marginBox->isChecked();
prefsManager->appPrefs.guidesSettings.framesShown = checkFrame->isChecked();
prefsManager->appPrefs.guidesSettings.layerMarkersShown = checkLayerM->isChecked();
prefsManager->appPrefs.guidesSettings.rulerMode = checkRuler->isChecked();
prefsManager->appPrefs.guidesSettings.gridShown = tabGuides->checkGrid->isChecked();
prefsManager->appPrefs.guidesSettings.guidesShown = tabGuides->guideBox->isChecked();
/branches/Version13x/Scribus/scribus/reformdoc.cpp
289,6 → 289,10
checkFrame->setText( tr( "Show Frames" ) );
checkFrame->setChecked(doc->guidesSettings.framesShown);
pageBackgroundLayout->addWidget( checkFrame );
checkLayerM = new QCheckBox( pageBackground, "checkLayerM" );
checkLayerM->setText( tr( "Show Layer Indicators" ) );
checkLayerM->setChecked(doc->guidesSettings.layerMarkersShown);
pageBackgroundLayout->addWidget( checkLayerM );
checkRuler = new QCheckBox( pageBackground, "checkRuler" );
checkRuler->setText( tr( "Rulers relative to Page" ) );
checkRuler->setChecked(doc->guidesSettings.rulerMode);
428,6 → 432,7
QToolTip::add( checkLink, "<qt>" + tr("Enable or disable the display of linked text frames.") + "</qt>");
QToolTip::add( checkControl, "<qt>" + tr("Display non-printing characters such as paragraph markers in text frames") + "</qt>");
QToolTip::add( checkFrame, "<qt>" + tr("Turns the display of frames on or off") + "</qt>");
QToolTip::add( checkLayerM, "<qt>" + tr("Turns the display of layer indicators on or off") + "</qt>");
QToolTip::add( checkPictures, "<qt>" + tr("Turns the display of pictures on or off") + "</qt>");
QToolTip::add( backColor, "<qt>" + tr( "Color for paper" ) + "</qt>" );
QToolTip::add( checkUnprintable, "<qt>" + tr( "Mask the area outside the margins in the margin color" ) + "</qt>" );
495,6 → 500,7
checkPictures->setChecked(currDoc->guidesSettings.showPic);
checkLink->setChecked(currDoc->guidesSettings.linkShown);
checkFrame->setChecked(currDoc->guidesSettings.framesShown);
checkLayerM->setChecked(currDoc->guidesSettings.layerMarkersShown);
checkRuler->setChecked(currDoc->guidesSettings.rulerMode);
topScratch->setValue(currDoc->ScratchTop * unitRatio);
leftScratch->setValue(currDoc->ScratchLeft * unitRatio);
802,6 → 808,7
currDoc->papColor = colorPaper;
currDoc->guidesSettings.marginsShown = tabGuides->marginBox->isChecked();
currDoc->guidesSettings.framesShown = checkFrame->isChecked();
currDoc->guidesSettings.layerMarkersShown = checkLayerM->isChecked();
currDoc->guidesSettings.gridShown = tabGuides->checkGrid->isChecked();
currDoc->guidesSettings.guidesShown = tabGuides->guideBox->isChecked();
currDoc->guidesSettings.baseShown = tabGuides->baselineBox->isChecked();
/branches/Version13x/Scribus/scribus/scribusdoc.cpp
1163,7 → 1163,32
ll.outlineMode = false;
ll.transparency = 1.0;
ll.blendMode = 0;
ll.markerColor = QColor(0, 0, 0);
QColor marker;
switch (ll.LNr % 7)
{
case 0:
marker = Qt::black;
break;
case 1:
marker = Qt::red;
break;
case 2:
marker = Qt::green;
break;
case 3:
marker = Qt::blue;
break;
case 4:
marker = Qt::cyan;
break;
case 5:
marker = Qt::magenta;
break;
case 6:
marker = Qt::yellow;;
break;
}
ll.markerColor = marker;
Layers.append(ll);
if (activate)
setActiveLayer(ll.LNr);
/branches/Version13x/Scribus/scribus/prefsmanager.cpp
187,6 → 187,7
appPrefs.mainWinSettings.maximized = false;
appPrefs.guidesSettings.marginsShown = true;
appPrefs.guidesSettings.framesShown = true;
appPrefs.guidesSettings.layerMarkersShown = false;
appPrefs.guidesSettings.gridShown = false;
appPrefs.guidesSettings.guidesShown = false;
appPrefs.guidesSettings.colBordersShown = false;
897,6 → 898,7
dc.setAttribute("SHOWGUIDES", static_cast<int>(appPrefs.guidesSettings.guidesShown));
dc.setAttribute("showcolborders", static_cast<int>(appPrefs.guidesSettings.colBordersShown));
dc.setAttribute("FRV", static_cast<int>(appPrefs.guidesSettings.framesShown));
dc.setAttribute("SHOWLAYERM", static_cast<int>(appPrefs.guidesSettings.layerMarkersShown));
dc.setAttribute("SHOWMARGIN", static_cast<int>(appPrefs.guidesSettings.marginsShown));
dc.setAttribute("SHOWBASE", static_cast<int>(appPrefs.guidesSettings.baseShown));
dc.setAttribute("SHOWLINK", static_cast<int>(appPrefs.guidesSettings.linkShown));
1352,6 → 1354,7
appPrefs.guidesSettings.guidesShown = static_cast<bool>(dc.attribute("SHOWGUIDES", "1").toInt());
appPrefs.guidesSettings.colBordersShown = static_cast<bool>(dc.attribute("showcolborders", "0").toInt());
appPrefs.guidesSettings.framesShown = static_cast<bool>(dc.attribute("FRV", "1").toInt());
appPrefs.guidesSettings.layerMarkersShown = static_cast<bool>(dc.attribute("SHOWLAYERM", "0").toInt());
appPrefs.guidesSettings.marginsShown = static_cast<bool>(dc.attribute("SHOWMARGIN", "1").toInt());
appPrefs.guidesSettings.baseShown = static_cast<bool>(dc.attribute("SHOWBASE", "1").toInt());
appPrefs.guidesSettings.linkShown = static_cast<bool>(dc.attribute("SHOWLINK", "0").toInt());
/branches/Version13x/Scribus/scribus/scribusXml.cpp
863,7 → 863,32
la.flowControl = true;
la.transparency = 1.0;
la.blendMode = 0;
la.markerColor = QColor(0, 0, 0);
QColor marker;
switch (la.LNr % 7)
{
case 0:
marker = Qt::black;
break;
case 1:
marker = Qt::red;
break;
case 2:
marker = Qt::green;
break;
case 3:
marker = Qt::blue;
break;
case 4:
marker = Qt::cyan;
break;
case 5:
marker = Qt::magenta;
break;
case 6:
marker = Qt::yellow;;
break;
}
la.markerColor = marker;
la.outlineMode = false;
bool laex = false;
uint layerCount=doc->layerCount();
1189,6 → 1214,7
doc->guidesSettings.guidesShown = view->Prefs->guidesSettings.guidesShown;
doc->guidesSettings.colBordersShown = view->Prefs->guidesSettings.colBordersShown;
doc->guidesSettings.framesShown = view->Prefs->guidesSettings.framesShown;
doc->guidesSettings.layerMarkersShown = view->Prefs->guidesSettings.layerMarkersShown;
doc->guidesSettings.marginsShown = view->Prefs->guidesSettings.marginsShown;
doc->guidesSettings.baseShown = view->Prefs->guidesSettings.baseShown;
doc->guidesSettings.linkShown = view->Prefs->guidesSettings.linkShown;
1371,7 → 1397,32
la.flowControl = true;
la.blendMode = 0;
la.transparency = 1.0;
la.markerColor = QColor(0, 0, 0);
QColor marker;
switch (la.LNr % 7)
{
case 0:
marker = Qt::black;
break;
case 1:
marker = Qt::red;
break;
case 2:
marker = Qt::green;
break;
case 3:
marker = Qt::blue;
break;
case 4:
marker = Qt::cyan;
break;
case 5:
marker = Qt::magenta;
break;
case 6:
marker = Qt::yellow;;
break;
}
la.markerColor = marker;
la.outlineMode = false;
doc->Layers.append(la);
}
3016,6 → 3067,7
dc.setAttribute("SHOWGUIDES", static_cast<int>(doc->guidesSettings.guidesShown));
dc.setAttribute("showcolborders", static_cast<int>(doc->guidesSettings.colBordersShown));
dc.setAttribute("SHOWFRAME", static_cast<int>(doc->guidesSettings.framesShown));
dc.setAttribute("SHOWLAYERM", static_cast<int>(doc->guidesSettings.layerMarkersShown));
dc.setAttribute("SHOWMARGIN", static_cast<int>(doc->guidesSettings.marginsShown));
dc.setAttribute("SHOWBASE", static_cast<int>(doc->guidesSettings.baseShown));
dc.setAttribute("SHOWPICT", static_cast<int>(doc->guidesSettings.showPic));
/branches/Version13x/Scribus/scribus/prefsstructs.h
82,6 → 82,7
bool showControls;
bool rulerMode;
bool rulersShown;
bool layerMarkersShown;
bool before;
QColor guideColor;
QColor baseColor;
/branches/Version13x/Scribus/scribus/prefs.h
124,6 → 124,7
QCheckBox* checkPictures;
QCheckBox* checkControl;
QCheckBox* checkRuler;
QCheckBox* checkLayerM;
QPushButton* backColor;
QCheckBox* checkUnprintable;
QGroupBox* groupScratch;
/branches/Version13x/Scribus/scribus/reformdoc.h
122,6 → 122,7
QComboBox* pageOrientationComboBox;
QCheckBox* checkLink;
QCheckBox* checkFrame;
QCheckBox* checkLayerM;
QCheckBox* checkPictures;
QCheckBox* checkControl;
QCheckBox* checkRuler;
/branches/Version13x/Scribus/scribus/pageitem.cpp
847,6 → 847,14
p->setupPolygon(&PoLine);
if (doStroke)
p->strokePath();
if (itemType()==ImageFrame)
{
if (imageClip.size() != 0)
{
p->setupPolygon(&imageClip);
p->strokePath();
}
}
}
}
else
928,12 → 936,17
p->setupPolygon(&ContourLine);
p->strokePath();
}
if ((m_Doc->guidesSettings.framesShown) && (m_Doc->layerCount() > 1) && (!m_Doc->layerOutline(m_Doc->layerLevelFromNumber(LayerNr))))
if ((m_Doc->guidesSettings.layerMarkersShown) && (m_Doc->layerCount() > 1) && (!m_Doc->layerOutline(m_Doc->layerLevelFromNumber(LayerNr))))
{
p->setBrush(m_Doc->layerMarker(m_Doc->layerLevelFromNumber(LayerNr)));
p->setFillMode(ScPainter::Solid);
p->setLineWidth(0);
p->drawRect(3, 3, 10, 10);
double ofwh = 10;
double ofx = Width - ofwh/2;
double ofy = Height - ofwh*3;
p->setPenOpacity(1.0);
p->setBrushOpacity(1.0);
p->drawRect(ofx, ofy, ofwh, ofwh);
}
//CB disabled for now
//if (m_Doc->m_Selection->findItem(this)!=-1)
/branches/Version13x/Scribus/scribus/scribusview.cpp
1863,6 → 1863,7
pmen->insertSeparator();
ScMW->scrActions["viewShowMargins"]->addTo(pmen);
ScMW->scrActions["viewShowFrames"]->addTo(pmen);
ScMW->scrActions["viewShowLayerMarkers"]->addTo(pmen);
ScMW->scrActions["viewShowImages"]->addTo(pmen);
ScMW->scrActions["viewShowGrid"]->addTo(pmen);
ScMW->scrActions["viewShowGuides"]->addTo(pmen);
/branches/Version13x/Scribus/scribus/actionmanager.cpp
501,6 → 501,8
scrActions->insert(name, new ScrAction("", defKeys[name], mainWindow, name));
name="viewShowFrames";
scrActions->insert(name, new ScrAction("", defKeys[name], mainWindow, name));
name="viewShowLayerMarkers";
scrActions->insert(name, new ScrAction("", defKeys[name], mainWindow, name));
name="viewShowImages";
scrActions->insert(name, new ScrAction("", defKeys[name], mainWindow, name));
name="viewShowGrid";
527,6 → 529,7
 
(*scrActions)["viewShowMargins"]->setToggleAction(true);
(*scrActions)["viewShowFrames"]->setToggleAction(true);
(*scrActions)["viewShowLayerMarkers"]->setToggleAction(true);
(*scrActions)["viewShowImages"]->setToggleAction(true);
(*scrActions)["viewShowGrid"]->setToggleAction(true);
(*scrActions)["viewShowGuides"]->setToggleAction(true);
541,6 → 544,7
 
(*scrActions)["viewShowMargins"]->setOn(true);
(*scrActions)["viewShowFrames"]->setOn(true);
(*scrActions)["viewShowLayerMarkers"]->setOn(false);
(*scrActions)["viewShowImages"]->setOn(true);
(*scrActions)["viewShowGuides"]->setOn(true);
(*scrActions)["viewShowColumnBorders"]->setOn(false);
555,6 → 559,7
connect( (*scrActions)["viewFit20"], SIGNAL(activatedData(double)), mainWindow, SLOT(slotZoom(double)) );
connect( (*scrActions)["viewShowMargins"], SIGNAL(activated()), mainWindow, SLOT(ToggleMarks()) );
connect( (*scrActions)["viewShowFrames"], SIGNAL(activated()), mainWindow, SLOT(ToggleFrames()) );
connect( (*scrActions)["viewShowLayerMarkers"], SIGNAL(activated()), mainWindow, SLOT(ToggleLayerMarkers()) );
connect( (*scrActions)["viewShowImages"], SIGNAL(activated()), mainWindow, SLOT(TogglePics()) );
connect( (*scrActions)["viewShowGrid"], SIGNAL(activated()), mainWindow, SLOT(ToggleRaster()) );
connect( (*scrActions)["viewShowGuides"], SIGNAL(activated()), mainWindow, SLOT(ToggleGuides()) );
1260,6 → 1265,7
(*scrActions)["viewFit20"]->setTexts( tr("&Thumbnails"));
(*scrActions)["viewShowMargins"]->setTexts( tr("Show &Margins"));
(*scrActions)["viewShowFrames"]->setTexts( tr("Show &Frames"));
(*scrActions)["viewShowLayerMarkers"]->setTexts( tr("Show Layer Indicators"));
(*scrActions)["viewShowImages"]->setTexts( tr("Show &Images"));
(*scrActions)["viewShowGrid"]->setTexts( tr("Show &Grid"));
(*scrActions)["viewShowGuides"]->setTexts( tr("Show G&uides"));
1559,6 → 1565,7
defKeys.insert("viewFit20", QKeySequence());
defKeys.insert("viewShowMargins", QKeySequence());
defKeys.insert("viewShowFrames", QKeySequence());
defKeys.insert("viewShowLayerMarkers", QKeySequence());
defKeys.insert("viewShowImages", QKeySequence());
defKeys.insert("viewShowGrid", QKeySequence());
defKeys.insert("viewShowGuides", QKeySequence());
1759,7 → 1766,7
itmenu->second << "pageInsert" << "pageImport" << "pageDelete" << "pageCopy" << "pageMove" << "pageApplyMasterPage" << "pageCopyToMasterPage" << "pageManageGuides" << "pageManageMargins" << "viewSnapToGrid" << "viewSnapToGuides";
//View
++itmenu;
itmenu->second << "viewFitInWindow" << "viewFit50" << "viewFit75" << "viewFit100" << "viewFit200" << "viewFit20" << "viewShowMargins" << "viewShowFrames" << "viewShowImages" << "viewShowGrid" << "viewShowGuides" << "viewShowColumnBorders" << "viewShowBaseline" << "viewShowTextChain" << "viewShowTextControls" << "viewShowRulers" << "viewRulerMode";
itmenu->second << "viewFitInWindow" << "viewFit50" << "viewFit75" << "viewFit100" << "viewFit200" << "viewFit20" << "viewShowMargins" << "viewShowFrames" << "viewShowLayerMarkers" << "viewShowImages" << "viewShowGrid" << "viewShowGuides" << "viewShowColumnBorders" << "viewShowBaseline" << "viewShowTextChain" << "viewShowTextControls" << "viewShowRulers" << "viewRulerMode";
//Extras
++itmenu;
itmenu->second << "extrasManagePictures" << "extrasHyphenateText" << "extrasDeHyphenateText" << "extrasGenerateTableOfContents";
/branches/Version13x/Scribus/scribus/pageitem_textframe.cpp
3569,12 → 3569,17
}
if (m_Doc->guidesSettings.colBordersShown && !view->previewMode)
drawColumnBorders(p);
if ((m_Doc->guidesSettings.framesShown) && (m_Doc->layerCount() > 1) && (!m_Doc->layerOutline(m_Doc->layerLevelFromNumber(LayerNr))))
if ((m_Doc->guidesSettings.layerMarkersShown) && (m_Doc->layerCount() > 1) && (!m_Doc->layerOutline(m_Doc->layerLevelFromNumber(LayerNr))))
{
p->setBrush(m_Doc->layerMarker(m_Doc->layerLevelFromNumber(LayerNr)));
p->setFillMode(ScPainter::Solid);
p->setLineWidth(0);
p->drawRect(6, 6, 6, 6);
double ofwh = 10;
double ofx = Width - ofwh/2;
double ofy = Height - ofwh*3;
p->setPenOpacity(1.0);
p->setBrushOpacity(1.0);
p->drawRect(ofx, ofy, ofwh, ofwh);
}
//if (m_Doc->selection->findItem(this)!=-1)
// drawLockedMarker(p);
4522,7 → 4527,7
//TODO: CB clean
ScribusView* view = m_Doc->view();
double scp1 = 1 ;// / ScMW->view->scale();
double ofwh = 6 * scp1;
double ofwh = 10 * scp1;
//CB moved down while locked marker disabled
//double ofx = Width - ofwh/2;
//double ofy = Height - ofwh*3.0;
/branches/Version13x/Scribus/scribus/pageitem_imageframe.cpp
73,44 → 73,32
p->setupPolygon(&PoLine);
p->fillPath();
}
}
p->save();
p->save();
#ifdef HAVE_CAIRO
if (imageClip.size() != 0)
{
p->setupPolygon(&imageClip);
if (imageClip.size() != 0)
{
p->setupPolygon(&imageClip);
p->setClipPath();
}
p->setupPolygon(&PoLine);
p->setClipPath();
}
p->setupPolygon(&PoLine);
p->setClipPath();
#else
if (imageClip.size() != 0)
{
p->setupPolygon(&imageClip);
p->setClipPath2(&PoLine, true);
}
else
{
p->setupPolygon(&PoLine);
p->setClipPath();
}
#endif
if (Pfile.isEmpty())
{
if ((Frame) && (m_Doc->guidesSettings.framesShown))
if (imageClip.size() != 0)
{
p->setPen(black, 1, SolidLine, FlatCap, MiterJoin);
p->drawLine(FPoint(0, 0), FPoint(Width, Height));
p->drawLine(FPoint(0, Height), FPoint(Width, 0));
p->setupPolygon(&imageClip);
p->setClipPath2(&PoLine, true);
}
}
else
{
if ((!PicArt) || (!PicAvail))
else
{
p->setupPolygon(&PoLine);
p->setClipPath();
}
#endif
if (Pfile.isEmpty())
{
if ((Frame) && (m_Doc->guidesSettings.framesShown))
{
p->setPen(red, 1, SolidLine, FlatCap, MiterJoin);
p->setPen(black, 1, SolidLine, FlatCap, MiterJoin);
p->drawLine(FPoint(0, 0), FPoint(Width, Height));
p->drawLine(FPoint(0, Height), FPoint(Width, 0));
}
117,24 → 105,36
}
else
{
if (imageFlippedH())
if ((!PicArt) || (!PicAvail))
{
p->translate(Width * sc, 0);
p->scale(-1, 1);
if ((Frame) && (m_Doc->guidesSettings.framesShown))
{
p->setPen(red, 1, SolidLine, FlatCap, MiterJoin);
p->drawLine(FPoint(0, 0), FPoint(Width, Height));
p->drawLine(FPoint(0, Height), FPoint(Width, 0));
}
}
if (imageFlippedV())
else
{
p->translate(0, Height * sc);
p->scale(1, -1);
if (imageFlippedH())
{
p->translate(Width * sc, 0);
p->scale(-1, 1);
}
if (imageFlippedV())
{
p->translate(0, Height * sc);
p->scale(1, -1);
}
p->translate(LocalX*LocalScX*sc, LocalY*LocalScY*sc);
p->scale(LocalScX, LocalScY);
if (pixm.imgInfo.lowResType != 0)
p->scale(pixm.imgInfo.lowResScale, pixm.imgInfo.lowResScale);
p->drawImage(&pixm);
}
p->translate(LocalX*LocalScX*sc, LocalY*LocalScY*sc);
p->scale(LocalScX, LocalScY);
if (pixm.imgInfo.lowResType != 0)
p->scale(pixm.imgInfo.lowResScale, pixm.imgInfo.lowResScale);
p->drawImage(&pixm);
}
p->restore();
}
p->restore();
}
}
 
/branches/Version13x/Scribus/scribus/scribus.cpp
827,6 → 827,7
scrMenuMgr->addMenuSeparator("View");
scrMenuMgr->addMenuItem(scrActions["viewShowMargins"], "View");
scrMenuMgr->addMenuItem(scrActions["viewShowFrames"], "View");
scrMenuMgr->addMenuItem(scrActions["viewShowLayerMarkers"], "View");
scrMenuMgr->addMenuItem(scrActions["viewShowImages"], "View");
scrMenuMgr->addMenuItem(scrActions["viewShowGrid"], "View");
scrMenuMgr->addMenuItem(scrActions["viewShowGuides"], "View");
1985,6 → 1986,7
wsp->setScrollBarsEnabled(!(w->isMaximized()));
scrActions["viewShowMargins"]->setOn(doc->guidesSettings.marginsShown);
scrActions["viewShowFrames"]->setOn(doc->guidesSettings.framesShown);
scrActions["viewShowLayerMarkers"]->setOn(doc->guidesSettings.layerMarkersShown);
scrActions["viewShowGrid"]->setOn(doc->guidesSettings.gridShown);
scrActions["viewShowGuides"]->setOn(doc->guidesSettings.guidesShown);
scrActions["viewShowColumnBorders"]->setOn(doc->guidesSettings.colBordersShown);
2036,6 → 2038,7
propertiesPalette->Fonts->RebuildList(doc);
scrActions["viewShowMargins"]->setOn(doc->guidesSettings.marginsShown);
scrActions["viewShowFrames"]->setOn(doc->guidesSettings.framesShown);
scrActions["viewShowLayerMarkers"]->setOn(doc->guidesSettings.layerMarkersShown);
scrActions["viewShowGrid"]->setOn(doc->guidesSettings.gridShown);
scrActions["viewShowGuides"]->setOn(doc->guidesSettings.guidesShown);
scrActions["viewShowColumnBorders"]->setOn(doc->guidesSettings.colBordersShown);
5084,6 → 5087,7
doc->guidesSettings.colBordersShown = guidesStatus[10];
ToggleMarks();
ToggleFrames();
ToggleLayerMarkers();
ToggleRaster();
ToggleGuides();
ToggleColumnBorders();
5106,6 → 5110,7
guidesStatus[8] = !doc->guidesSettings.rulerMode;
guidesStatus[9] = !doc->guidesSettings.rulersShown;
guidesStatus[10] = !doc->guidesSettings.colBordersShown;
guidesStatus[11] = !doc->guidesSettings.layerMarkersShown;
doc->guidesSettings.marginsShown = false;
doc->guidesSettings.framesShown = false;
doc->guidesSettings.gridShown = false;
5116,10 → 5121,12
doc->guidesSettings.rulerMode = false;
doc->guidesSettings.rulersShown = false;
doc->guidesSettings.colBordersShown = false;
doc->guidesSettings.layerMarkersShown = false;
view->setRulersShown(doc->guidesSettings.rulersShown);
}
scrActions["viewShowMargins"]->setOn(doc->guidesSettings.marginsShown);
scrActions["viewShowFrames"]->setOn(doc->guidesSettings.framesShown);
scrActions["viewShowLayerMarkers"]->setOn(doc->guidesSettings.layerMarkersShown);
scrActions["viewShowGrid"]->setOn(doc->guidesSettings.gridShown);
scrActions["viewShowGuides"]->setOn(doc->guidesSettings.guidesShown);
scrActions["viewShowColumnBorders"]->setOn(doc->guidesSettings.colBordersShown);
5145,6 → 5152,13
view->DrawNew();
}
 
void ScribusMainWindow::ToggleLayerMarkers()
{
guidesStatus[0] = false;
doc->guidesSettings.layerMarkersShown = !doc->guidesSettings.layerMarkersShown;
view->DrawNew();
}
 
void ScribusMainWindow::ToggleRaster()
{
guidesStatus[0] = false;
/branches/Version13x/Scribus/scribus/scribus.h
375,6 → 375,7
/** \brief Schaltet Raender ein/aus */
void ToggleMarks();
void ToggleFrames();
void ToggleLayerMarkers();
void ToggleTextLinks();
void ToggleTextControls();
void ToggleColumnBorders();
589,7 → 590,7
int viewUndoPalette;
 
bool palettesStatus[10];
bool guidesStatus[10];
bool guidesStatus[12];
 
bool keyrep;
/** @brief Tells if an arrow key is pressed down */