r14571 by fschmid - DRW Importer: do not scale the linewidth of items in a group when creating a group.

scribus-commit scribus-commit at lists.scribus.net
Sun Jan 24 13:00:21 CET 2010


Revision: 14571
Author: fschmid
Date: 2010-01-24T11:56:09.456210Z
Commit message: DRW Importer: do not scale the linewidth of items in a group when creating a group.

Changeset: 
M  /trunk/Scribus/scribus/plugins/import/drw/importdrw.cpp

Diffs:
Index: scribus/plugins/import/drw/importdrw.cpp
===================================================================
--- scribus/plugins/import/drw/importdrw.cpp	(revision 14570)
+++ scribus/plugins/import/drw/importdrw.cpp	(revision 14571)
@@ -855,19 +855,10 @@
 				for (int dre = 0;  dre < popped.GElements.count(); ++dre)
 				{
 					tmpSel->addItem(popped.GElements.at(dre), true);
-					popped.GElements.at(dre)->Groups.push(m_Doc->GroupCounter);
 				}
 				uint selectedItemCount = tmpSel->count();
 				if (selectedItemCount > 0)
 				{
-					popped.groupItem->Groups.push(m_Doc->GroupCounter);
-					if (popped.itemGroupName.isEmpty())
-						popped.groupItem->setItemName( tr("Group%1").arg(popped.groupItem->Groups.top()));
-					else
-						popped.groupItem->setItemName(popped.itemGroupName);
-					popped.groupItem->AutoName = false;
-					popped.groupItem->isGroupControl = true;
-					popped.groupItem->groupsLastItem = tmpSel->itemAt(selectedItemCount - 1);
 					if ((tmpSel->width() != 0) && (tmpSel->height() != 0) && (popped.width != 0) && (popped.height != 0))
 					{
 						double scx = 1.0;
@@ -878,6 +869,19 @@
 							scy = popped.height / tmpSel->height();
 						m_Doc->scaleGroup(scx, scy, true, tmpSel);
 					}
+					for (uint i = 0; i < selectedItemCount; ++i)
+					{
+						PageItem *item = tmpSel->itemAt(i);
+						item->Groups.push(m_Doc->GroupCounter);
+					}
+					popped.groupItem->Groups.push(m_Doc->GroupCounter);
+					if (popped.itemGroupName.isEmpty())
+						popped.groupItem->setItemName( tr("Group%1").arg(popped.groupItem->Groups.top()));
+					else
+						popped.groupItem->setItemName(popped.itemGroupName);
+					popped.groupItem->AutoName = false;
+					popped.groupItem->isGroupControl = true;
+					popped.groupItem->groupsLastItem = tmpSel->itemAt(selectedItemCount - 1);
 				}
 				m_Doc->GroupCounter++;
 				tmpSel->clear();




More information about the scribus-commit mailing list