Subversion Repositories Scribus

Compare Revisions

Ignore whitespace Rev 7769 → Rev 7770

/branches/Version13x/Scribus/scribus/pageitem.cpp
3960,7 → 3960,7
 
void PageItem::updateGradientVectors()
{
switch (GrType)
/* switch (GrType)
{
case 0:
case 1:
4003,7 → 4003,7
break;
default:
break;
}
} */
//if (ScMW->view->SelItem.count()!=0 && this==ScMW->view->SelItem.at(0))
//if (m_Doc->m_Selection->count()!=0 && m_Doc->m_Selection->primarySelectionIsMyself(this))
// ScMW->propertiesPalette->updateColorSpecialGradient();
/branches/Version13x/Scribus/scribus/scribusdoc.cpp
4957,6 → 4957,50
{
currItem = m_Selection->itemAt(a);
currItem->GrType = typ;
switch (currItem->GrType)
{
case 0:
case 1:
currItem->GrStartX = 0;
currItem->GrStartY = currItem->height() / 2.0;
currItem->GrEndX = currItem->width();
currItem->GrEndY = currItem->height() / 2.0;
break;
case 2:
currItem->GrStartX = currItem->width() / 2.0;
currItem->GrStartY = 0;
currItem->GrEndX = currItem->width() / 2.0;
currItem->GrEndY = currItem->height();
break;
case 3:
currItem->GrStartX = 0;
currItem->GrStartY = 0;
currItem->GrEndX = currItem->width();
currItem->GrEndY = currItem->height();
break;
case 4:
currItem->GrStartX = 0;
currItem->GrStartY = currItem->height();
currItem->GrEndX = currItem->width();
currItem->GrEndY = 0;
break;
case 5:
currItem->GrStartX = currItem->width() / 2.0;
currItem->GrStartY = currItem->height() / 2.0;
if (currItem->width() >= currItem->height())
{
currItem->GrEndX = currItem->width();
currItem->GrEndY = currItem->height() / 2.0;
}
else
{
currItem->GrEndX = currItem->width() / 2.0;
currItem->GrEndY = currItem->height();
}
break;
default:
break;
}
if (typ != 8)
currItem->updateGradientVectors();
emit refreshItem(currItem);
8159,7 → 8203,7
currItem->DrawPolyL(&p, currItem->Clip);
p.restore();
currItem->updateClip();
currItem->updateGradientVectors();
// currItem->updateGradientVectors();
p.save();
if (currItem->width() < 0.0)
{
8197,7 → 8241,7
currItem->moveImageInFrame(dX,dY);
currItem->updateClip();
}
currItem->updateGradientVectors();
// currItem->updateGradientVectors();
if (redraw)
{
QRect newR(currItem->getRedrawBounding(viewScale));
/branches/Version13x/Scribus/scribus/pdflib.cpp
4601,7 → 4601,7
QPtrVector<VColorStop> cstops = currItem->fill_gradient.colorStops();
switch (currItem->GrType)
{
case 1:
/* case 1:
StartX = 0;
StartY = h2;
EndX = w;
4638,7 → 4638,12
EndX = w2;
EndY = h;
}
break;
break; */
case 1:
case 2:
case 3:
case 4:
case 5:
case 6:
case 7:
StartX = currItem->GrStartX;
/branches/Version13x/Scribus/scribus/plugins/scriptplugin/cmdsetprop.cpp
30,6 → 30,50
currItem->SetFarbe(&tmp, c2, shade2);
currItem->fill_gradient.addStop(tmp, 1.0, 0.5, 1.0, c2, shade2);
currItem->GrType = typ;
switch (currItem->GrType)
{
case 0:
case 1:
currItem->GrStartX = 0;
currItem->GrStartY = currItem->height() / 2.0;
currItem->GrEndX = currItem->width();
currItem->GrEndY = currItem->height() / 2.0;
break;
case 2:
currItem->GrStartX = currItem->width() / 2.0;
currItem->GrStartY = 0;
currItem->GrEndX = currItem->width() / 2.0;
currItem->GrEndY = currItem->height();
break;
case 3:
currItem->GrStartX = 0;
currItem->GrStartY = 0;
currItem->GrEndX = currItem->width();
currItem->GrEndY = currItem->height();
break;
case 4:
currItem->GrStartX = 0;
currItem->GrStartY = currItem->height();
currItem->GrEndX = currItem->width();
currItem->GrEndY = 0;
break;
case 5:
currItem->GrStartX = currItem->width() / 2.0;
currItem->GrStartY = currItem->height() / 2.0;
if (currItem->width() >= currItem->height())
{
currItem->GrEndX = currItem->width();
currItem->GrEndY = currItem->height() / 2.0;
}
else
{
currItem->GrEndX = currItem->width() / 2.0;
currItem->GrEndY = currItem->height();
}
break;
default:
break;
}
//ScCore->primaryMainWindow()->view->updateGradientVectors(currItem);
currItem->updateGradientVectors();
ScCore->primaryMainWindow()->view->RefreshItem(currItem);
/branches/Version13x/Scribus/scribus/plugins/fileloader/scribus13format/scribus13format.cpp
2561,7 → 2561,7
currItem->fill_gradient.addStop(tmpc, 1.0, 0.5, 1.0, GrColor, GrShade);
}
}
currItem->updateGradientVectors();
// currItem->updateGradientVectors();
}
//currItem->setRedrawBounding();
//currItem->OwnPage = view->OnPage(currItem);
/branches/Version13x/Scribus/scribus/plugins/fileloader/scribus134format/scribus134format.cpp
2480,7 → 2480,7
currItem->fill_gradient.addStop(tmpc, 1.0, 0.5, 1.0, GrColor, GrShade);
}
}
currItem->updateGradientVectors();
// currItem->updateGradientVectors();
}
//currItem->setRedrawBounding();
//currItem->OwnPage = view->OnPage(currItem);
/branches/Version13x/Scribus/scribus/pslib.cpp
2804,7 → 2804,7
QPtrVector<VColorStop> cstops = c->fill_gradient.colorStops();
switch (c->GrType)
{
case 1:
/* case 1:
StartX = 0;
StartY = h / 2.0;
EndX = w;
2841,7 → 2841,12
EndX = w / 2.0;
EndY = h;
}
break;
break; */
case 1:
case 2:
case 3:
case 4:
case 5:
case 6:
case 7:
StartX = c->GrStartX;