r16237 by jghali - merge trunk revisions up to r16236

scribus-commit scribus-commit at lists.scribus.net
Mon Jan 10 01:03:44 CET 2011


Author: jghali
Date: Mon Jan 10 00:03:44 2011
New Revision: 16237

URL: http://scribus.info/websvn/listing.php?repname=Scribus&sc=1&rev=16237
Log:
merge trunk revisions up to r16236

Added:
    branches/ScribusOIF/doc/en/images/multipledup_copies.png
      - copied unchanged from r16236, trunk/Scribus/doc/en/images/multipledup_copies.png
    branches/ScribusOIF/doc/en/images/multipledup_rotation.png
      - copied unchanged from r16236, trunk/Scribus/doc/en/images/multipledup_rotation.png
    branches/ScribusOIF/doc/en/images/multipledup_rows.png
      - copied unchanged from r16236, trunk/Scribus/doc/en/images/multipledup_rows.png
    branches/ScribusOIF/doc/en/images/sadie4by2b.png
      - copied unchanged from r16236, trunk/Scribus/doc/en/images/sadie4by2b.png
    branches/ScribusOIF/doc/en/images/transform_dialogb.png
      - copied unchanged from r16236, trunk/Scribus/doc/en/images/transform_dialogb.png
    branches/ScribusOIF/doc/en/images/transform_translaterotation.png
      - copied unchanged from r16236, trunk/Scribus/doc/en/images/transform_translaterotation.png
    branches/ScribusOIF/doc/en/images/transform_translaterotation1.png
      - copied unchanged from r16236, trunk/Scribus/doc/en/images/transform_translaterotation1.png
    branches/ScribusOIF/doc/en/images/transform_translatescaling.png
      - copied unchanged from r16236, trunk/Scribus/doc/en/images/transform_translatescaling.png
    branches/ScribusOIF/doc/en/images/transform_translateskewing.png
      - copied unchanged from r16236, trunk/Scribus/doc/en/images/transform_translateskewing.png
    branches/ScribusOIF/doc/en/images/transform_translateskewing1.png
      - copied unchanged from r16236, trunk/Scribus/doc/en/images/transform_translateskewing1.png
    branches/ScribusOIF/doc/en/multiple_transform.html
      - copied unchanged from r16236, trunk/Scribus/doc/en/multiple_transform.html
Modified:
    branches/ScribusOIF/README.MacOSX
    branches/ScribusOIF/doc/en/menu.xml
    branches/ScribusOIF/scribus/canvasmode_normal.cpp
    branches/ScribusOIF/scribus/pageitem.cpp
    branches/ScribusOIF/scribus/plugins/fileloader/scribus134format/scribus134format.cpp
    branches/ScribusOIF/scribus/plugins/fileloader/scribus150format/scribus150format.cpp
    branches/ScribusOIF/scribus/plugins/import/svg/svgplugin.cpp
    branches/ScribusOIF/scribus/plugins/import/svg/svgplugin.h
    branches/ScribusOIF/scribus/scribus.cpp
    branches/ScribusOIF/scribus/scribusdoc.cpp
    branches/ScribusOIF/scribus/scribusdoc.h
    branches/ScribusOIF/scribus/ui/newfile.cpp

Modified: branches/ScribusOIF/README.MacOSX
URL: http://scribus.info/websvn/diff.php?repname=Scribus&rev=16237&path=/branches/ScribusOIF/README.MacOSX
==============================================================================
--- branches/ScribusOIF/README.MacOSX (original)
+++ branches/ScribusOIF/README.MacOSX Mon Jan 10 00:03:44 2011
@@ -1,3 +1,5 @@
+This file is Obsolete....
+
 Some preliminary notes:
 
 Scribus.app contains some files for the OSX application bundle infrastructure:

Modified: branches/ScribusOIF/doc/en/menu.xml
URL: http://scribus.info/websvn/diff.php?repname=Scribus&rev=16237&path=/branches/ScribusOIF/doc/en/menu.xml
==============================================================================
--- branches/ScribusOIF/doc/en/menu.xml (original)
+++ branches/ScribusOIF/doc/en/menu.xml Mon Jan 10 00:03:44 2011
@@ -32,6 +32,7 @@
 			<submenuitem file="WwRenderframes.html" text="Working with Render Frames" />
 			<submenuitem file="WwShapes.html" text="Working with Shapes" />
 			<submenuitem file="EditingShapes.html" text="Editing Shapes" />
+			<submenuitem file="multiple_transform.html" text="Multiple Duplicate and Transform" />
 			<submenuitem file="WwLines.html" text="Working with Lines and Line Styles" />
 			<submenuitem file="WwFill.html" text="Working with Fill: Colors, Gradients and Patterns" />
 			<submenuitem text="Working with Layers" file="layers.html" />

Modified: branches/ScribusOIF/scribus/canvasmode_normal.cpp
URL: http://scribus.info/websvn/diff.php?repname=Scribus&rev=16237&path=/branches/ScribusOIF/scribus/canvasmode_normal.cpp
==============================================================================
--- branches/ScribusOIF/scribus/canvasmode_normal.cpp (original)
+++ branches/ScribusOIF/scribus/canvasmode_normal.cpp Mon Jan 10 00:03:44 2011
@@ -1299,7 +1299,7 @@
 		fmtCode++;
 		fmt = LoadSavePlugin::getFormatById(fmtCode);
 	}
-	allFormats += "*.sce *.SCE;;";
+	allFormats += "*.sce *.SCE);;";
 	formats.append("Scribus Objects (*.sce *.SCE)");
 	qSort(formats);
 	allFormats += formats.join(";;");

Modified: branches/ScribusOIF/scribus/pageitem.cpp
URL: http://scribus.info/websvn/diff.php?repname=Scribus&rev=16237&path=/branches/ScribusOIF/scribus/pageitem.cpp
==============================================================================
--- branches/ScribusOIF/scribus/pageitem.cpp (original)
+++ branches/ScribusOIF/scribus/pageitem.cpp Mon Jan 10 00:03:44 2011
@@ -2510,11 +2510,12 @@
 		return; // nothing to do -> return
 	if (newName.isEmpty())
 		return;
+	QString oldName = AnName;
 	AnName = generateUniqueCopyName(newName);
 	if (UndoManager::undoEnabled())
 	{
 		SimpleState *ss = new SimpleState(Um::Rename, QString(Um::FromTo).arg(AnName).arg(newName));
-		ss->set("OLD_NAME", AnName);
+		ss->set("OLD_NAME", oldName);
 		ss->set("NEW_NAME", newName);
 		undoManager->action(this, ss);
 	}
@@ -3699,8 +3700,10 @@
 	{
 		QRectF baseRect(getBoundingRect());
 		QList<PageItem*>* items = OnMasterPage.isEmpty() ? &m_Doc->DocItems : &m_Doc->MasterItems;
-		for(int idx = (allItems ? items->count()-1 : ItemNr-1); idx >= 0 ; --idx)
-		{
+		for(int idx = items->count()-1; idx >= 0 ; --idx)
+		{
+			if ((items->at(idx) == this) && (!allItems))
+				break;
 			if(idx != static_cast<int>(ItemNr)) // avoids itself
 			{
 				if(items->at(idx)->asTextFrame()) // do not bother with no text frames

Modified: branches/ScribusOIF/scribus/plugins/fileloader/scribus134format/scribus134format.cpp
URL: http://scribus.info/websvn/diff.php?repname=Scribus&rev=16237&path=/branches/ScribusOIF/scribus/plugins/fileloader/scribus134format/scribus134format.cpp
==============================================================================
--- branches/ScribusOIF/scribus/plugins/fileloader/scribus134format/scribus134format.cpp (original)
+++ branches/ScribusOIF/scribus/plugins/fileloader/scribus134format/scribus134format.cpp Mon Jan 10 00:03:44 2011
@@ -448,7 +448,7 @@
 			if (groupStack.count() > 0)
 			{
 				groupStack.top().append(itemInfo.item);
-				if (static_cast<int>(itemInfo.item->ItemNr) == groupStack2.top())
+				while (static_cast<int>(itemInfo.item->ItemNr) == groupStack2.top())
 				{
 					if (tagName == "PAGEOBJECT")
 						groupStackP.push(groupStack.pop());
@@ -457,6 +457,8 @@
 					else
 						groupStackM.push(groupStack.pop());
 					groupStack2.pop();
+					if (groupStack2.count() == 0)
+						break;
 				}
 			}
 			if (itemInfo.isGroupFlag)
@@ -2054,10 +2056,12 @@
 		if (groupStack.count() > 0)
 		{
 			groupStack.top().append(itemInfo.item);
-			if (static_cast<int>(itemInfo.item->ItemNr) == groupStack2.top())
+			while (static_cast<int>(itemInfo.item->ItemNr) == groupStack2.top())
 			{
 				groupStackP.push(groupStack.pop());
 				groupStack2.pop();
+				if (groupStack2.count() == 0)
+					break;
 			}
 		}
 		if (itemInfo.isGroupFlag)
@@ -2738,6 +2742,8 @@
 		doc->GroupCounter++;
 		break;
 	case PageItem::Symbol:
+	case PageItem::RegularPolygon:
+	case PageItem::Arc:
 	case PageItem::Multiple:
 		Q_ASSERT(false);
 		break;

Modified: branches/ScribusOIF/scribus/plugins/fileloader/scribus150format/scribus150format.cpp
URL: http://scribus.info/websvn/diff.php?repname=Scribus&rev=16237&path=/branches/ScribusOIF/scribus/plugins/fileloader/scribus150format/scribus150format.cpp
==============================================================================
--- branches/ScribusOIF/scribus/plugins/fileloader/scribus150format/scribus150format.cpp (original)
+++ branches/ScribusOIF/scribus/plugins/fileloader/scribus150format/scribus150format.cpp Mon Jan 10 00:03:44 2011
@@ -316,7 +316,7 @@
 			if (groupStack.count() > 0)
 			{
 				groupStack.top().append(itemInfo.item);
-				if (static_cast<int>(itemInfo.item->ItemNr) == groupStack2.top())
+				while (static_cast<int>(itemInfo.item->ItemNr) == groupStack2.top())
 				{
 					if ((tagName == "PAGEOBJECT") || (tagName == "ITEM"))
 						groupStackP.push(groupStack.pop());
@@ -325,6 +325,8 @@
 					else
 						groupStackM.push(groupStack.pop());
 					groupStack2.pop();
+					if (groupStack2.count() == 0)
+						break;
 				}
 			}
 			if (itemInfo.isGroupFlag)
@@ -687,7 +689,7 @@
 			if (groupStack.count() > 0)
 			{
 				groupStack.top().append(itemInfo.item);
-				if (static_cast<int>(itemInfo.item->ItemNr) == groupStack2.top())
+				while (static_cast<int>(itemInfo.item->ItemNr) == groupStack2.top())
 				{
 					if (tagName == "PAGEOBJECT")
 						groupStackP.push(groupStack.pop());
@@ -696,6 +698,8 @@
 					else
 						groupStackM.push(groupStack.pop());
 					groupStack2.pop();
+					if (groupStack2.count() == 0)
+						break;
 				}
 			}
 			if (itemInfo.isGroupFlag)
@@ -1196,7 +1200,7 @@
 			if (groupStack.count() > 0)
 			{
 				groupStack.top().append(itemInfo.item);
-				if (static_cast<int>(itemInfo.item->ItemNr) == groupStack2.top())
+				while (static_cast<int>(itemInfo.item->ItemNr) == groupStack2.top())
 				{
 					if (tagName == "PAGEOBJECT")
 						groupStackP.push(groupStack.pop());
@@ -1205,6 +1209,8 @@
 					else
 						groupStackM.push(groupStack.pop());
 					groupStack2.pop();
+					if (groupStack2.count() == 0)
+						break;
 				}
 			}
 			if (itemInfo.isGroupFlag)
@@ -2957,10 +2963,12 @@
 		if (groupStack.count() > 0)
 		{
 			groupStack.top().append(itemInfo.item);
-			if (static_cast<int>(itemInfo.item->ItemNr) == groupStack2.top())
+			while (static_cast<int>(itemInfo.item->ItemNr) == groupStack2.top())
 			{
 				groupStackP.push(groupStack.pop());
 				groupStack2.pop();
+				if (groupStack2.count() == 0)
+					break;
 			}
 		}
 		if (itemInfo.isGroupFlag)
@@ -4169,7 +4177,7 @@
 				if (groupStack.count() > 0)
 				{
 					groupStack.top().append(itemInfo.item);
-					if (static_cast<int>(itemInfo.item->ItemNr) == groupStack2.top())
+					while (static_cast<int>(itemInfo.item->ItemNr) == groupStack2.top())
 					{
 						if (tagName == "PAGEOBJECT")
 							groupStackP.push(groupStack.pop());
@@ -4178,6 +4186,8 @@
 						else
 							groupStack.pop();
 						groupStack2.pop();
+						if (groupStack2.count() == 0)
+							break;
 					}
 				}
 				if (itemInfo.isGroupFlag)

Modified: branches/ScribusOIF/scribus/plugins/import/svg/svgplugin.cpp
URL: http://scribus.info/websvn/diff.php?repname=Scribus&rev=16237&path=/branches/ScribusOIF/scribus/plugins/import/svg/svgplugin.cpp
==============================================================================
--- branches/ScribusOIF/scribus/plugins/import/svg/svgplugin.cpp (original)
+++ branches/ScribusOIF/scribus/plugins/import/svg/svgplugin.cpp Mon Jan 10 00:03:44 2011
@@ -197,8 +197,8 @@
 	{
 		if (dia->importFailed)
 			QMessageBox::warning(mw, CommonStrings::trWarning, tr("The file could not be imported"), 1, 0, 0);
-		else if (dia->unsupported)
-			QMessageBox::warning(mw, CommonStrings::trWarning, tr("SVG file contains some unsupported features"), 1, 0, 0);
+	//	else if (dia->unsupported)
+	//		QMessageBox::warning(mw, CommonStrings::trWarning, tr("SVG file contains some unsupported features"), 1, 0, 0);
 	}
 
 	delete dia;
@@ -232,6 +232,7 @@
 	unsupported = false;
 	importFailed = false;
 	importCanceled = true;
+	firstLayer = true;
 	importedColors.clear();
 	importedGradients.clear();
 	importedPatterns.clear();
@@ -433,7 +434,7 @@
 			m_gc.top()->matrix = matrix;
 		}
 	}
-	QList<PageItem*> Elements = parseGroup( docElem );
+	QList<PageItem*> Elements = parseDoc( docElem );
 	if (flags & LoadSavePlugin::lfCreateDoc)
 	{
 		m_Doc->documentInfo().setTitle(docTitle);
@@ -471,7 +472,7 @@
 			}
 		}
 	}
-	if (Elements.count() > 1)
+	if ((Elements.count() > 1) && (!(flags & LoadSavePlugin::lfCreateDoc)))
 	{
 		m_Doc->groupObjectsList(Elements);
 	}
@@ -1086,14 +1087,152 @@
 {
 	FPointArray clipPath;
 	QList<PageItem*> GElements, gElements;
-	double BaseX = m_Doc->currentPage()->xOffset();
-	double BaseY = m_Doc->currentPage()->yOffset();
-	groupLevel++;
-	setupNode(e);
-	parseClipPathAttr(e, clipPath);
-	m_gc.top()->forGroup = true;
-	int z = m_Doc->itemAdd(PageItem::Group, PageItem::Rectangle, BaseX, BaseY, 1, 1, 0, CommonStrings::None, CommonStrings::None, true);
-	PageItem *neu = m_Doc->Items->at(z);
+	if ((importerFlags & LoadSavePlugin::lfCreateDoc) && (e.hasAttribute("inkscape:groupmode")) && (e.attribute("inkscape:groupmode") == "layer"))
+	{
+		setupNode(e);
+		QString LayerName = e.attribute("inkscape:label", "Layer");
+		double trans = m_gc.top()->Opacity;
+		int currentLayer = 0;
+		if (!firstLayer)
+			currentLayer = m_Doc->addLayer(LayerName, true);
+		else
+			m_Doc->changeLayerName(currentLayer, LayerName);
+		m_Doc->setLayerVisible(currentLayer, true);
+		m_Doc->setLayerLocked(currentLayer, false);
+		m_Doc->setLayerPrintable(currentLayer, true);
+		m_Doc->setLayerTransparency(currentLayer, trans);
+		firstLayer = false;
+		for ( QDomNode n = e.firstChild(); !n.isNull(); n = n.nextSibling() )
+		{
+			QDomElement b = n.toElement();
+			if( b.isNull() || isIgnorableNode(b) )
+				continue;
+			SvgStyle svgStyle;
+			parseStyle( &svgStyle, b);
+			if (!svgStyle.Display) 
+				continue;
+			QList<PageItem*> el = parseElement(b);
+			for (int ec = 0; ec < el.count(); ++ec)
+				GElements.append(el.at(ec));
+		}
+		delete( m_gc.pop() );
+	}
+	else
+	{
+		double BaseX = m_Doc->currentPage()->xOffset();
+		double BaseY = m_Doc->currentPage()->yOffset();
+		groupLevel++;
+		setupNode(e);
+		parseClipPathAttr(e, clipPath);
+		m_gc.top()->forGroup = true;
+		int z = m_Doc->itemAdd(PageItem::Group, PageItem::Rectangle, BaseX, BaseY, 1, 1, 0, CommonStrings::None, CommonStrings::None, true);
+		PageItem *neu = m_Doc->Items->at(z);
+		for ( QDomNode n = e.firstChild(); !n.isNull(); n = n.nextSibling() )
+		{
+			QDomElement b = n.toElement();
+			if( b.isNull() || isIgnorableNode(b) )
+				continue;
+			SvgStyle svgStyle;
+			parseStyle( &svgStyle, b);
+			if (!svgStyle.Display) 
+				continue;
+			QList<PageItem*> el = parseElement(b);
+			for (int ec = 0; ec < el.count(); ++ec)
+				gElements.append(el.at(ec));
+		}
+		groupLevel--;
+		SvgStyle *gc = m_gc.top();
+		if (clipPath.size() == 0)
+		{
+			if (gc->clipPath.size() != 0)
+				clipPath = gc->clipPath.copy();
+		}
+		if (gElements.count() == 0 || (gElements.count() < 2 && (clipPath.size() == 0) && (gc->Opacity == 1.0)))
+		{
+			// Unfortunately we have to take the long route here, or we risk crash on undo/redo
+			// FIXME : create group object after parsing grouped objects
+			/*m_Doc->Items->takeAt(z);
+			delete neu;*/
+			Selection tmpSelection(m_Doc, false);
+			tmpSelection.addItem(neu);
+			m_Doc->itemSelection_DeleteItem(&tmpSelection);
+			for (int a = 0; a < m_Doc->Items->count(); ++a)
+			{
+				m_Doc->Items->at(a)->ItemNr = a;
+			}
+			for (int gr = 0; gr < gElements.count(); ++gr)
+			{
+				GElements.append(gElements.at(gr));
+			}
+		}
+		else
+		{
+			double minx =  std::numeric_limits<double>::max();
+			double miny =  std::numeric_limits<double>::max();
+			double maxx = -std::numeric_limits<double>::max();
+			double maxy = -std::numeric_limits<double>::max();
+			GElements.append(neu);
+			for (int gr = 0; gr < gElements.count(); ++gr)
+			{
+				PageItem* currItem = gElements.at(gr);
+				double x1, x2, y1, y2;
+				currItem->getVisualBoundingRect(&x1, &y1, &x2, &y2);
+				minx = qMin(minx, x1);
+				miny = qMin(miny, y1);
+				maxx = qMax(maxx, x2);
+				maxy = qMax(maxy, y2);
+			}
+			double gx = minx;
+			double gy = miny;
+			double gw = maxx - minx;
+			double gh = maxy - miny;
+			neu->setXYPos(gx, gy);
+			neu->setWidthHeight(gw, gh);
+			if (clipPath.size() != 0)
+			{
+				QTransform mm = gc->matrix;
+				neu->PoLine = clipPath.copy();
+				neu->PoLine.map(mm);
+				neu->PoLine.translate(-gx + BaseX, -gy + BaseY);
+				clipPath.resize(0);
+
+			}
+			else
+				neu->SetRectFrame();
+			neu->Clip = FlattenPath(neu->PoLine, neu->Segments);
+			if( !e.attribute("id").isEmpty() )
+				neu->setItemName(e.attribute("id"));
+			else
+				neu->setItemName( tr("Group%1").arg(m_Doc->GroupCounter));
+			neu->AutoName = false;
+			neu->setFillTransparency(1 - gc->Opacity);
+			neu->gXpos = neu->xPos() - gx;
+			neu->gYpos = neu->yPos() - gy;
+			neu->groupWidth = gw;
+			neu->groupHeight = gh;
+			for (int gr = 0; gr < gElements.count(); ++gr)
+			{
+				PageItem* currItem = gElements.at(gr);
+				currItem->gXpos = currItem->xPos() - gx;
+				currItem->gYpos = currItem->yPos() - gy;
+				currItem->gWidth = gw;
+				currItem->gHeight = gh;
+				neu->groupItemList.append(currItem);
+				m_Doc->Items->removeAll(currItem);
+			}
+			neu->setRedrawBounding();
+			neu->setTextFlowMode(PageItem::TextFlowDisabled);
+			m_Doc->GroupCounter++;
+			m_Doc->renumberItemsInListOrder();
+		}
+		delete( m_gc.pop() );
+	}
+	return GElements;
+}
+
+QList<PageItem*> SVGPlug::parseDoc(const QDomElement &e)
+{
+	QList<PageItem*> GElements;
 	for ( QDomNode n = e.firstChild(); !n.isNull(); n = n.nextSibling() )
 	{
 		QDomElement b = n.toElement();
@@ -1105,94 +1244,8 @@
 			continue;
 		QList<PageItem*> el = parseElement(b);
 		for (int ec = 0; ec < el.count(); ++ec)
-			gElements.append(el.at(ec));
-	}
-	groupLevel--;
-	SvgStyle *gc = m_gc.top();
-	if (clipPath.size() == 0)
-	{
-		if (gc->clipPath.size() != 0)
-			clipPath = gc->clipPath.copy();
-	}
-	if (gElements.count() == 0 || (gElements.count() < 2 && (clipPath.size() == 0) && (gc->Opacity == 1.0)))
-	{
-		// Unfortunately we have to take the long route here, or we risk crash on undo/redo
-		// FIXME : create group object after parsing grouped objects
-		/*m_Doc->Items->takeAt(z);
-		delete neu;*/
-		Selection tmpSelection(m_Doc, false);
-		tmpSelection.addItem(neu);
-		m_Doc->itemSelection_DeleteItem(&tmpSelection);
-		for (int a = 0; a < m_Doc->Items->count(); ++a)
-		{
-			m_Doc->Items->at(a)->ItemNr = a;
-		}
-		for (int gr = 0; gr < gElements.count(); ++gr)
-		{
-			GElements.append(gElements.at(gr));
-		}
-	}
-	else
-	{
-		double minx =  std::numeric_limits<double>::max();
-		double miny =  std::numeric_limits<double>::max();
-		double maxx = -std::numeric_limits<double>::max();
-		double maxy = -std::numeric_limits<double>::max();
-		GElements.append(neu);
-		for (int gr = 0; gr < gElements.count(); ++gr)
-		{
-			PageItem* currItem = gElements.at(gr);
-			double x1, x2, y1, y2;
-			currItem->getVisualBoundingRect(&x1, &y1, &x2, &y2);
-			minx = qMin(minx, x1);
-			miny = qMin(miny, y1);
-			maxx = qMax(maxx, x2);
-			maxy = qMax(maxy, y2);
-		}
-		double gx = minx;
-		double gy = miny;
-		double gw = maxx - minx;
-		double gh = maxy - miny;
-		neu->setXYPos(gx, gy);
-		neu->setWidthHeight(gw, gh);
-		if (clipPath.size() != 0)
-		{
-			QTransform mm = gc->matrix;
-			neu->PoLine = clipPath.copy();
-			neu->PoLine.map(mm);
-			neu->PoLine.translate(-gx + BaseX, -gy + BaseY);
-			clipPath.resize(0);
-
-		}
-		else
-			neu->SetRectFrame();
-		neu->Clip = FlattenPath(neu->PoLine, neu->Segments);
-		if( !e.attribute("id").isEmpty() )
-			neu->setItemName(e.attribute("id"));
-		else
-			neu->setItemName( tr("Group%1").arg(m_Doc->GroupCounter));
-		neu->AutoName = false;
-		neu->setFillTransparency(1 - gc->Opacity);
-		neu->gXpos = neu->xPos() - gx;
-		neu->gYpos = neu->yPos() - gy;
-		neu->groupWidth = gw;
-		neu->groupHeight = gh;
-		for (int gr = 0; gr < gElements.count(); ++gr)
-		{
-			PageItem* currItem = gElements.at(gr);
-			currItem->gXpos = currItem->xPos() - gx;
-			currItem->gYpos = currItem->yPos() - gy;
-			currItem->gWidth = gw;
-			currItem->gHeight = gh;
-			neu->groupItemList.append(currItem);
-			m_Doc->Items->removeAll(currItem);
-		}
-		neu->setRedrawBounding();
-		neu->setTextFlowMode(PageItem::TextFlowDisabled);
-		m_Doc->GroupCounter++;
-		m_Doc->renumberItemsInListOrder();
-	}
-	delete( m_gc.pop() );
+			GElements.append(el.at(ec));
+	}
 	return GElements;
 }
 

Modified: branches/ScribusOIF/scribus/plugins/import/svg/svgplugin.h
URL: http://scribus.info/websvn/diff.php?repname=Scribus&rev=16237&path=/branches/ScribusOIF/scribus/plugins/import/svg/svgplugin.h
==============================================================================
--- branches/ScribusOIF/scribus/plugins/import/svg/svgplugin.h (original)
+++ branches/ScribusOIF/scribus/plugins/import/svg/svgplugin.h Mon Jan 10 00:03:44 2011
@@ -246,6 +246,7 @@
 	void parseClipPathAttr(const QDomElement &e, FPointArray& clipPath);
 	QList<PageItem*> parseA(const QDomElement &e);
 	QList<PageItem*> parseGroup(const QDomElement &e);
+	QList<PageItem*> parseDoc(const QDomElement &e);
 	QList<PageItem*> parseElement(const QDomElement &e);
 	QList<PageItem*> parseCircle(const QDomElement &e);
 	QList<PageItem*> parseEllipse(const QDomElement &e);
@@ -308,6 +309,7 @@
 	double inGroupXOrigin;
 	double inGroupYOrigin;
 	int importerFlags;
+	bool firstLayer;
 };
 
 #endif

Modified: branches/ScribusOIF/scribus/scribus.cpp
URL: http://scribus.info/websvn/diff.php?repname=Scribus&rev=16237&path=/branches/ScribusOIF/scribus/scribus.cpp
==============================================================================
--- branches/ScribusOIF/scribus/scribus.cpp (original)
+++ branches/ScribusOIF/scribus/scribus.cpp Mon Jan 10 00:03:44 2011
@@ -3393,7 +3393,7 @@
 		fmtCode++;
 		fmt = LoadSavePlugin::getFormatById(fmtCode);
 	}
-	allFormats += "*.sce *.SCE;;";
+	allFormats += "*.sce *.SCE);;";
 	formats.append("Scribus Objects (*.sce *.SCE)");
 	qSort(formats);
 	allFormats += formats.join(";;");
@@ -8278,7 +8278,7 @@
 			if (!pdfViewer.isEmpty())
 			{
 				QStringList args;
-				args << doc->pdfOptions().fileName;
+				args << QDir::toNativeSeparators(doc->pdfOptions().fileName);
 				System(pdfViewer, args);
 			}
 		}

Modified: branches/ScribusOIF/scribus/scribusdoc.cpp
URL: http://scribus.info/websvn/diff.php?repname=Scribus&rev=16237&path=/branches/ScribusOIF/scribus/scribusdoc.cpp
==============================================================================
--- branches/ScribusOIF/scribus/scribusdoc.cpp (original)
+++ branches/ScribusOIF/scribus/scribusdoc.cpp Mon Jan 10 00:03:44 2011
@@ -11459,7 +11459,7 @@
 }
 
 
-void ScribusDoc::AdjustItemSize(PageItem *currItem, bool includeGroup)
+void ScribusDoc::AdjustItemSize(PageItem *currItem, bool includeGroup, bool moveInGroup)
 {
 	bool siz = currItem->Sizing;
 	currItem->Sizing = false;
@@ -11488,7 +11488,7 @@
 			currItem->moveImageInFrame(0, (currItem->height() - tp.y())/currItem->imageYScale());
 		SizeItem(tp.x(), tp.y(), currItem, true, false);
 		currItem->PoLine = Clip.copy();
-		if (currItem->isGroup() && includeGroup)
+		if (currItem->isGroup() && includeGroup && moveInGroup)
 		{
 			for (int em = 0; em < currItem->groupItemList.count(); ++em)
 			{
@@ -11684,7 +11684,7 @@
 			bb->PoLine.map(ma2);
 			bb->setRotation(0.0);
 			bb->ClipEdited = true;
-			AdjustItemSize(bb);
+			AdjustItemSize(bb, true, false);
 			QTransform ma3;
 			ma3.translate(gx, gy);
 			ma3.scale(scx, scy);
@@ -11698,7 +11698,7 @@
 				QTransform ma;
 				ma.rotate(-bb->rotation());
 				bb->PoLine.map(ma);
-				AdjustItemSize(bb);
+				AdjustItemSize(bb, true, false);
 			}
 		}
 		if (scaleText)

Modified: branches/ScribusOIF/scribus/scribusdoc.h
URL: http://scribus.info/websvn/diff.php?repname=Scribus&rev=16237&path=/branches/ScribusOIF/scribus/scribusdoc.h
==============================================================================
--- branches/ScribusOIF/scribus/scribusdoc.h (original)
+++ branches/ScribusOIF/scribus/scribusdoc.h Mon Jan 10 00:03:44 2011
@@ -1009,7 +1009,7 @@
 	bool SizeItem(double newX, double newY, PageItem *pi, bool fromMP = false, bool DoUpdateClip = true, bool redraw = true);
 	bool MoveSizeItem(FPoint newX, FPoint newY, int ite, bool fromMP = false, bool constrainRotation=false);
 	bool MoveSizeItem(FPoint newX, FPoint newY, PageItem* currItem, bool fromMP = false, bool constrainRotation = false);
-	void AdjustItemSize(PageItem *currItem, bool includeGroup = false);
+	void AdjustItemSize(PageItem *currItem, bool includeGroup = false, bool moveInGroup = true);
 	void moveGroup(double x, double y, bool fromMP = false, Selection* customSelection = 0);
 	void rotateGroup(double angle, Selection* customSelection = 0);
 	void rotateGroup(double angle, FPoint RCenter, Selection* customSelection = 0);

Modified: branches/ScribusOIF/scribus/ui/newfile.cpp
URL: http://scribus.info/websvn/diff.php?repname=Scribus&rev=16237&path=/branches/ScribusOIF/scribus/ui/newfile.cpp
==============================================================================
--- branches/ScribusOIF/scribus/ui/newfile.cpp (original)
+++ branches/ScribusOIF/scribus/ui/newfile.cpp Mon Jan 10 00:03:44 2011
@@ -367,6 +367,7 @@
 	fileDialog = new QFileDialog(openDocFrame, tr("Open"), docDir, formats);
 	fileDialog->setFileMode(QFileDialog::ExistingFile);
 	fileDialog->setAcceptMode(QFileDialog::AcceptOpen);
+	fileDialog->setOption(QFileDialog::DontUseNativeDialog);
 #if QT_VERSION >= 0x040600
 	fileDialog->setNameFilterDetailsVisible(false);
 #else




More information about the scribus-commit mailing list