/branches/Version133x/Scribus/scribus/mpalette.cpp |
---|
3283,10 → 3283,7 |
if (c == NULL) |
return; |
bool setter = c->listBox()->currentItem() == 0 ? true : false; |
if (setter == true) |
CurItem->setCustomLineStyle(""); |
else |
CurItem->setCustomLineStyle(c->text()); |
doc->itemSelection_SetLineStyle(setter ? QString("") : c->text()); |
LStyle->setEnabled(setter); |
LSize->setEnabled(setter); |
LJoinStyle->setEnabled(setter); |
/branches/Version133x/Scribus/scribus/scribusdoc.cpp |
---|
5908,6 → 5908,29 |
changed(); |
} |
void ScribusDoc::itemSelection_SetLineStyle(const QString & name, Selection* customSelection) |
{ |
Selection* itemSelection = (customSelection!=0) ? customSelection : m_Selection; |
uint docSelectionCount = itemSelection->count(); |
if (docSelectionCount != 0) |
{ |
if (docSelectionCount > 1) |
undoManager->beginTransaction(Um::SelectionGroup, Um::IGroup, Um::LineStyle, name, Um::ILineStyle); |
for (uint aa = 0; aa < docSelectionCount; ++aa) |
{ |
PageItem *currItem = itemSelection->itemAt(aa); |
currItem->setCustomLineStyle(name); |
if (docSelectionCount == 1) |
emit refreshItem(currItem); |
} |
if (docSelectionCount > 1) |
{ |
undoManager->commit(); |
emit updateContents(); |
} |
changed(); |
} |
} |
void ScribusDoc::itemSelection_SetParagraphStyle(int s) |
{ |
/branches/Version133x/Scribus/scribus/scribusdoc.h |
---|
858,6 → 858,7 |
void itemSelection_DoHyphenate(); |
void itemSelection_DoDeHyphenate(); |
void itemSelection_SendToLayer(int layerNumber); |
void itemSelection_SetLineStyle(const QString & name, Selection* customSelection=0); |
void itemSelection_SetParagraphStyle(int s); |
void itemSelection_SetImageOffset(double x, double y, Selection* customSelection=0); |
void itemSelection_SetImageScale(double x, double y, Selection* customSelection=0); |