r17635 by jghali - fix quite a few build warnings

scribus-commit scribus-commit at lists.scribus.net
Mon Jun 25 19:42:39 UTC 2012


Author: jghali
Date: Mon Jun 25 19:42:39 2012
New Revision: 17635

URL: http://scribus.net/websvn/listing.php?repname=Scribus&sc=1&rev=17635
Log:
fix quite a few build warnings

Modified:
    trunk/Scribus/scribus/canvas.cpp
    trunk/Scribus/scribus/canvasgesture_resize.cpp
    trunk/Scribus/scribus/canvasmode.cpp
    trunk/Scribus/scribus/canvasmode_create.cpp
    trunk/Scribus/scribus/canvasmode_drawcalligraphic.cpp
    trunk/Scribus/scribus/pageitem_textframe.cpp
    trunk/Scribus/scribus/pdflib_core.cpp
    trunk/Scribus/scribus/plugins/fileloader/scribus150format/scribus150format.cpp
    trunk/Scribus/scribus/plugins/import/pdf/importpdf.cpp
    trunk/Scribus/scribus/plugins/import/sml/importsml.cpp
    trunk/Scribus/scribus/plugins/import/svg/svgplugin.cpp
    trunk/Scribus/scribus/scpageoutput.cpp
    trunk/Scribus/scribus/scpainterex_ps2.cpp
    trunk/Scribus/scribus/ui/cmykfw.cpp
    trunk/Scribus/scribus/ui/multiprogressdialog.cpp

Modified: trunk/Scribus/scribus/canvas.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=17635&path=/trunk/Scribus/scribus/canvas.cpp
==============================================================================
--- trunk/Scribus/scribus/canvas.cpp (original)
+++ trunk/Scribus/scribus/canvas.cpp Mon Jun 25 19:42:39 2012
@@ -1273,7 +1273,7 @@
 			double gx, gy, gw, gh;
 			m_doc->m_Selection->setGroupRect();
 			m_doc->m_Selection->getGroupRect(&gx, &gy, &gw, &gh);
-			QPoint out = contentsToViewport(QPoint(0, 0));
+			//QPoint out = contentsToViewport(QPoint(0, 0));
 			pp->translate(gx, gy);
 			pp->drawRect(QRectF(0.0, 0.0, gw, gh));
 		}
@@ -2488,8 +2488,3 @@
 	m_view->horizRuler->setItem(item);
 	m_view->horizRuler->update();
 }
-
-
-
-
-

Modified: trunk/Scribus/scribus/canvasgesture_resize.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=17635&path=/trunk/Scribus/scribus/canvasgesture_resize.cpp
==============================================================================
--- trunk/Scribus/scribus/canvasgesture_resize.cpp (original)
+++ trunk/Scribus/scribus/canvasgesture_resize.cpp Mon Jun 25 19:42:39 2012
@@ -342,12 +342,8 @@
 				}
 			}
 		}
-		double oldX = currItem->xPos();
-		double oldY = currItem->yPos();
 		QTransform mm = currItem->getTransform();
 		QPointF itPos = mm.map(QPointF(0, 0));
-		oldX = itPos.x();
-		oldY = itPos.y();
 		double m_scaleX, m_scaleY;
 		getScaleFromMatrix(mm, m_scaleX, m_scaleY);
 		double dx = (itPos.x() - newBounds.x()) / m_scaleX;

Modified: trunk/Scribus/scribus/canvasmode.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=17635&path=/trunk/Scribus/scribus/canvasmode.cpp
==============================================================================
--- trunk/Scribus/scribus/canvasmode.cpp (original)
+++ trunk/Scribus/scribus/canvasmode.cpp Mon Jun 25 19:42:39 2012
@@ -789,7 +789,6 @@
 
 bool CanvasMode::commonMouseMove(QMouseEvent *m)
 {
-	const FPoint mousePointDoc = m_canvas->globalToCanvas(m->globalPos());
 	if ((m_canvas->m_viewMode.m_MouseButtonPressed && (m->buttons() & Qt::RightButton) && (m->modifiers() & Qt::ControlModifier)) || ((!(m->modifiers() & Qt::ControlModifier)) && (m->buttons() & Qt::MidButton)))
 	{
 		if (!m_panGesture)

Modified: trunk/Scribus/scribus/canvasmode_create.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=17635&path=/trunk/Scribus/scribus/canvasmode_create.cpp
==============================================================================
--- trunk/Scribus/scribus/canvasmode_create.cpp (original)
+++ trunk/Scribus/scribus/canvasmode_create.cpp Mon Jun 25 19:42:39 2012
@@ -392,7 +392,6 @@
 
 void CreateMode::mouseReleaseEvent(QMouseEvent *m)
 {
-	const FPoint mousePointDoc = m_canvas->globalToCanvas(m->globalPos());
 	modifiers = m->modifiers();
 
 	PageItem *currItem;

Modified: trunk/Scribus/scribus/canvasmode_drawcalligraphic.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=17635&path=/trunk/Scribus/scribus/canvasmode_drawcalligraphic.cpp
==============================================================================
--- trunk/Scribus/scribus/canvasmode_drawcalligraphic.cpp (original)
+++ trunk/Scribus/scribus/canvasmode_drawcalligraphic.cpp Mon Jun 25 19:42:39 2012
@@ -188,8 +188,6 @@
 	const FPoint mousePointDoc = m_canvas->globalToCanvas(m->globalPos());
 	double Rxp = 0;
 	double Ryp = 0;
-	double Rxpd = 0;
-	double Rypd = 0;
 	FPoint npf, npf2;
 	QRect tx;
 	QTransform pm;
@@ -203,10 +201,8 @@
 	Myp = mousePointDoc.y(); //qRound(m->y()/m_canvas->scale() + 0*m_doc->minCanvasCoordinate.y());
 	QRect mpo(m->x()-m_doc->guidesPrefs().grabRadius, m->y()-m_doc->guidesPrefs().grabRadius, m_doc->guidesPrefs().grabRadius*2, m_doc->guidesPrefs().grabRadius*2);
 	Rxp = m_doc->ApplyGridF(FPoint(Mxp, Myp)).x();
-	Rxpd = Mxp - Rxp;
 	Mxp = qRound(Rxp);
 	Ryp = m_doc->ApplyGridF(FPoint(Mxp, Myp)).y();
-	Rypd = Myp - Ryp;
 	Myp = qRound(Ryp);
 	SeRx = Mxp;
 	SeRy = Myp;
@@ -235,9 +231,6 @@
 
 void CalligraphicMode::mouseReleaseEvent(QMouseEvent *m)
 {
-	const FPoint mousePointDoc = m_canvas->globalToCanvas(m->globalPos());
-	
-
 	PageItem *currItem;
 	m_MouseButtonPressed = false;
 	m_canvas->resetRenderMode();

Modified: trunk/Scribus/scribus/pageitem_textframe.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=17635&path=/trunk/Scribus/scribus/pageitem_textframe.cpp
==============================================================================
--- trunk/Scribus/scribus/pageitem_textframe.cpp (original)
+++ trunk/Scribus/scribus/pageitem_textframe.cpp Mon Jun 25 19:42:39 2012
@@ -1291,7 +1291,7 @@
 	QPoint pt1, pt2;
 	QRect pt;
 	double chs, chsd = 0;
-	double oldCurY, EndX, OFs, wide, kernVal;
+	double EndX, OFs, wide, kernVal;
 	QString chstr;
 	ScText *hl;
 	ParagraphStyle style;
@@ -1603,7 +1603,7 @@
 				itemText.item(a)->setEffects(itemText.item(a)->effects() & ~ScStyle_StartOfLine);
 			}
 			hl->glyph.yadvance = 0;
-			oldCurY = layoutGlyphs(*hl, chstr, hl->glyph);
+			layoutGlyphs(*hl, chstr, hl->glyph);
 			// find out width, ascent and descent of char
 			if ((hl->ch == SpecialChars::OBJECT) && (hl->hasObject(m_Doc)))
 			{
@@ -2847,8 +2847,7 @@
 		return;
 	QTransform pf2;
 	QPoint pt1, pt2;
-	double wide, lineCorr;
-	QChar chstr0;
+	double wide;
 	QString cachedStroke = "";
 	QString cachedFill = "";
 	double cachedFillShade = -1;
@@ -2860,7 +2859,7 @@
 	QColor cachedFillQ;
 	QColor cachedStrokeQ;
 	//	QValueList<ParagraphStyle::TabRecord> tTabValues;
-	double desc, asce, tabDist;
+	double desc, asce;
 	//	tTabValues.clear();
 	p->save(); //SA1
 	//	QRect e2;
@@ -2884,10 +2883,6 @@
 			p->fillPath();
 		}
 	}
-	if ((lineColor() != CommonStrings::None) || (!patternStrokeVal.isEmpty()) || (GrTypeStroke > 0))
-		lineCorr = m_lineWidth / 2.0;
-	else
-		lineCorr = 0;
 	if ((isAnnotation()) && (annotation().Type() == 2) && (!Pfile.isEmpty()) && (PictureIsAvailable) && (PicArt) && (annotation().UseIcons()))
 	{
 		p->save();//SA2
@@ -2948,14 +2943,12 @@
 			pf2.translate(0, Height);
 			pf2.scale(1, -1);
 		}
-		uint tabCc = 0;
 		assert( firstInFrame() >= 0 );
 		assert( lastInFrame() < itemText.length() );
 		LineSpec ls;
 		for (uint ll=0; ll < itemText.lines(); ++ll)
 		{
 			ls = itemText.line(ll);
-			tabDist = ls.x;
 			double CurX = ls.x;
 
 			// Draw text selection rectangles
@@ -3039,11 +3032,8 @@
 			{
 				hl = itemText.item(a);
 				const CharStyle& charStyle(itemText.charStyle(a));
-				double chs = charStyle.fontSize() * hl->glyph.scaleV;
 				bool selected = itemText.selected(a);
-				if (charStyle.effects() & ScStyle_StartOfLine)
-					tabCc = 0;
-				chstr0 = hl->ch;
+
 				actFill = charStyle.fillColor();
 				actFillShade = charStyle.fillShade();
 				if (actFill != CommonStrings::None)
@@ -3062,14 +3052,6 @@
 				}
 				else
 					p->setFillMode(ScPainter::None);
-				if (charStyle.effects() & ScStyle_DropCap)
-				{
-					const ParagraphStyle& style(itemText.paragraphStyle(a));
-					double spacing = calculateLineSpacing (style, this);
-					chs = qRound(10 * ((spacing * (style.dropCapLines()-1) + (charStyle.font().ascent(style.charStyle().fontSize() / 10.0))) / charStyle.font().realCharHeight(chstr0, 10)));
-				}
-				if (chstr0 == SpecialChars::TAB)
-					tabCc++;
 
 				if (!m_Doc->RePos)
 				{
@@ -3113,7 +3095,6 @@
 					else*/
 					CurX += hl->glyph.wide();
 				}
-				tabDist = CurX;
 			}
 		}
 	//	else {
@@ -4123,7 +4104,6 @@
 		p->drawLine(FPoint(0, TExtra + lineCorr), FPoint(Width, TExtra + lineCorr));
 	if (BExtra + lineCorr!=0.0)
 		p->drawLine(FPoint(0, Height - BExtra - lineCorr), FPoint(Width, Height - BExtra - lineCorr));
-	double oldColRightX = Extra + lineCorr;
 	while(curCol < Cols)
 	{
 		colLeft=(colWidth + ColGap) * curCol + Extra + lineCorr;
@@ -4131,7 +4111,6 @@
 			p->drawLine(FPoint(colLeft, 0), FPoint(colLeft, 0+Height));
 		if (colLeft + colWidth != Width)
 			p->drawLine(FPoint(colLeft+colWidth, 0), FPoint(colLeft+colWidth, 0+Height));
-		oldColRightX=colLeft+colWidth;
 		++curCol;
 	}
 	

Modified: trunk/Scribus/scribus/pdflib_core.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=17635&path=/trunk/Scribus/scribus/pdflib_core.cpp
==============================================================================
--- trunk/Scribus/scribus/pdflib_core.cpp (original)
+++ trunk/Scribus/scribus/pdflib_core.cpp Mon Jun 25 19:42:39 2012
@@ -4832,7 +4832,6 @@
 	int tabCc = 0;
 	int savedOwnPage = ite->OwnPage;
 	double tabDist = ite->textToFrameDistLeft();
-	double colLeft = 0.0;
 	QString tmp(""), tmp2("");
 	QList<ParagraphStyle::TabRecord> tTabValues;
 	ite->OwnPage = PNr;
@@ -4848,7 +4847,6 @@
 		for (uint ll=0; ll < ite->itemText.lines(); ++ll)
 		{
 			LineSpec ls = ite->itemText.line(ll);
-			colLeft = ls.colLeft;
 			tabDist = ls.x;
 			double CurX = ls.x;
 			for (int d = ls.firstItem; d <= ls.lastItem; ++d)
@@ -5175,11 +5173,7 @@
 		{
 			//		double Ulen = style.font().charWidth(chstr, style.fontSize()) * (hl->glyph.scaleH);
 			double Ulen = hl->glyph.xadvance;
-			double Upos, Uwid, kern;
-			if (style.effects() & ScStyle_StartOfLine)
-				kern = 0;
-			else
-				kern = style.fontSize() * style.tracking() / 10000.0;
+			double Upos, Uwid;
 			if ((style.underlineOffset() != -1) || (style.underlineWidth() != -1))
 			{
 				if (style.underlineOffset() != -1)
@@ -5468,11 +5462,7 @@
 		{
 			//		double Ulen = style.font().charWidth(chstr, style.fontSize()) * (hl->glyph.scaleH);
 			double Ulen = hl->glyph.xadvance;
-			double Upos, Uwid, kern;
-			if (hl->effects() & ScStyle_StartOfLine)
-				kern = 0;
-			else
-				kern = style.fontSize() * style.tracking() / 10000.0;
+			double Upos, Uwid;
 			if ((style.strikethruOffset() != -1) || (style.strikethruWidth() != -1))
 			{
 				if (style.strikethruOffset() != -1)

Modified: trunk/Scribus/scribus/plugins/fileloader/scribus150format/scribus150format.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=17635&path=/trunk/Scribus/scribus/plugins/fileloader/scribus150format/scribus150format.cpp
==============================================================================
--- trunk/Scribus/scribus/plugins/fileloader/scribus150format/scribus150format.cpp (original)
+++ trunk/Scribus/scribus/plugins/fileloader/scribus150format/scribus150format.cpp Mon Jun 25 19:42:39 2012
@@ -201,8 +201,6 @@
 	QStack< QList<PageItem*> > groupStackP;
 	QStack<int> groupStack2;
 
-	ScColor lf = ScColor();
-
 	itemRemap.clear();
 	itemNext.clear();
 	itemCount = 0;
@@ -683,7 +681,6 @@
 		return false;
 	}
 	QString fileDir = QFileInfo(fileName).absolutePath();
-	ScColor lf = ScColor();
 	
 	if (m_mwProgressBar!=0)
 	{
@@ -1189,7 +1186,6 @@
 	QString fileDir = QFileInfo(fileName).absolutePath();
 	int firstPage = 0;
 	int layerToSetActive = 0;
-	ScColor lf = ScColor();
 	
 	if (m_mwProgressBar!=0)
 	{

Modified: trunk/Scribus/scribus/plugins/import/pdf/importpdf.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=17635&path=/trunk/Scribus/scribus/plugins/import/pdf/importpdf.cpp
==============================================================================
--- trunk/Scribus/scribus/plugins/import/pdf/importpdf.cpp (original)
+++ trunk/Scribus/scribus/plugins/import/pdf/importpdf.cpp Mon Jun 25 19:42:39 2012
@@ -94,7 +94,7 @@
 	interactive = (flags & LoadSavePlugin::lfInteractive);
 	importerFlags = flags;
 	cancel = false;
-	double x, y, b, h;
+	double b, h;
 	bool ret = false;
 	QFileInfo fi = QFileInfo(fName);
 	if ( !ScCore->usingGUI() )
@@ -123,8 +123,6 @@
 	else
 		progressDialog = NULL;
 /* Set default Page to size defined in Preferences */
-	x = 0.0;
-	y = 0.0;
 	b = 0.0;
 	h = 0.0;
 	if (progressDialog)

Modified: trunk/Scribus/scribus/plugins/import/sml/importsml.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=17635&path=/trunk/Scribus/scribus/plugins/import/sml/importsml.cpp
==============================================================================
--- trunk/Scribus/scribus/plugins/import/sml/importsml.cpp (original)
+++ trunk/Scribus/scribus/plugins/import/sml/importsml.cpp Mon Jun 25 19:42:39 2012
@@ -128,7 +128,7 @@
 	interactive = (flags & LoadSavePlugin::lfInteractive);
 	importerFlags = flags;
 	cancel = false;
-	double x, y, b, h;
+	double b, h;
 	bool ret = false;
 	QFileInfo fi = QFileInfo(fName);
 	if ( !ScCore->usingGUI() )
@@ -157,8 +157,6 @@
 	else
 		progressDialog = NULL;
 /* Set default Page to size defined in Preferences */
-	x = 0.0;
-	y = 0.0;
 	b = 0.0;
 	h = 0.0;
 	if (progressDialog)

Modified: trunk/Scribus/scribus/plugins/import/svg/svgplugin.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=17635&path=/trunk/Scribus/scribus/plugins/import/svg/svgplugin.cpp
==============================================================================
--- trunk/Scribus/scribus/plugins/import/svg/svgplugin.cpp (original)
+++ trunk/Scribus/scribus/plugins/import/svg/svgplugin.cpp Mon Jun 25 19:42:39 2012
@@ -634,7 +634,7 @@
 		}
 	case PageItem::TextFrame:
 		{
-			QTransform mm = gc->matrix;
+			//QTransform mm = gc->matrix;
 			item->setLineWidth(item->lineWidth() * (coeff1 + coeff2) / 2.0);
 		}
 		break;

Modified: trunk/Scribus/scribus/scpageoutput.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=17635&path=/trunk/Scribus/scribus/scpageoutput.cpp
==============================================================================
--- trunk/Scribus/scribus/scpageoutput.cpp (original)
+++ trunk/Scribus/scribus/scpageoutput.cpp Mon Jun 25 19:42:39 2012
@@ -1067,7 +1067,7 @@
 
 void ScPageOutput::drawItem_PathText( PageItem_PathText* item, ScPainterExBase* painter, const QRect& clip )
 {
-	QString chstr, chstr2, chstr3;
+	QString chstr;
 	ScText *hl;
 	FPoint point = FPoint(0, 0);
 	FPoint tangent = FPoint(0, 0);
@@ -1582,7 +1582,6 @@
 	FPoint ColBound;
 	QRegion cm;
 	int a;
-	QString chstr, chstr2, chstr3;
 	ScText *hl;
 	double desc, asce;
 	
@@ -1624,7 +1623,6 @@
 			painter->translate(0, item->height());
 			painter->scale(1, -1);
 		}
-		uint tabCc = 0;
 
 		//automatic line spacing factor (calculated once)
 		double autoLS = static_cast<double>(m_doc->typographicPrefs().autoLineSpacing) / 100.0;
@@ -1637,10 +1635,7 @@
 			{
 				hl = item->itemText.item(a);
 				const CharStyle& charStyle  = item->itemText.charStyle(a);
-				double chs = charStyle.fontSize() * hl->glyph.scaleV;
-				if (charStyle.effects() & ScStyle_StartOfLine)
-					tabCc = 0;
-				chstr = hl->ch;
+
 				if (charStyle.fillColor() != CommonStrings::None)
 				{
 					ScColorShade tmp(m_doc->PageColors[charStyle.fillColor()], (int) hl->fillShade());
@@ -1651,21 +1646,7 @@
 					ScColorShade tmp(m_doc->PageColors[charStyle.strokeColor()], (int) hl->strokeShade());
 					painter->setPen(tmp, 1, Qt::SolidLine, Qt::FlatCap, Qt::MiterJoin);
 				}
-				if (charStyle.effects() & ScStyle_DropCap)
-				{
-					const ParagraphStyle& style(item->itemText.paragraphStyle(a));
-					if (style.lineSpacingMode() == ParagraphStyle::BaselineGridLineSpacing)
-						chs = qRound(10 * ((m_doc->guidesPrefs().valueBaselineGrid * (style.dropCapLines()-1) + (charStyle.font().ascent(style.charStyle().fontSize() / 10.0))) / charStyle.font().realCharHeight(chstr[0], 10)));
-					else if (style.lineSpacingMode() == ParagraphStyle::FixedLineSpacing)
-						chs = qRound(10 * ((style.lineSpacing() * (style.dropCapLines()-1)+(charStyle.font().ascent(style.charStyle().fontSize() / 10.0))) / charStyle.font().realCharHeight(chstr[0], 10)));
-					else
-					{
-						double currasce = charStyle.font().height(style.charStyle().fontSize() / 10.0) * autoLS;
-						chs = qRound(10 * ((currasce * (style.dropCapLines() - 1)+(charStyle.font().ascent(style.charStyle().fontSize() / 10.0))) / charStyle.font().realCharHeight(chstr[0], 10)));
-					}
-				}
-				if (chstr[0] == SpecialChars::TAB)
-					tabCc++;
+
 				//if (!m_doc->RePos)
 				{
 					//double xcoZli = CurX + hl->glyph.xoffset;

Modified: trunk/Scribus/scribus/scpainterex_ps2.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=17635&path=/trunk/Scribus/scribus/scpainterex_ps2.cpp
==============================================================================
--- trunk/Scribus/scribus/scpainterex_ps2.cpp (original)
+++ trunk/Scribus/scribus/scpainterex_ps2.cpp Mon Jun 25 19:42:39 2012
@@ -976,7 +976,6 @@
 	int r2, g2, b2;
 	double cosa, sina;
 	double ramp1, ramp2;
-	double scale1, scale2;
 	double length, scale;
 	double x1, y1, x2, y2, dx, dy;
 	int clipBoxWidth, clipBoxHeight, maxDim;
@@ -994,9 +993,6 @@
 	clipBoxHeight = rect.height();
 	maxDim = qRound(sqrt( (double) (clipBoxWidth * clipBoxWidth + clipBoxHeight * clipBoxHeight) )) * 2;
 	if ( maxDim <= 0 ) return;
-	
-	scale1 = sqrt( m_matrix.m11() * m_matrix.m11() + m_matrix.m12() * m_matrix.m12() );
-	scale2 = sqrt( m_matrix.m21() * m_matrix.m21() + m_matrix.m22() * m_matrix.m22() );
 
 	x1 = m_matrix.dx() + gradient.origin().x() * m_matrix.m11();
 	y1 = m_matrix.dy() + gradient.origin().y() * m_matrix.m22();
@@ -1080,7 +1076,6 @@
 	int c2, m2, j2, n2;
 	double cosa, sina;
 	double ramp1, ramp2;
-	double scale1, scale2;
 	double length, scale;
 	double x1, y1, x2, y2, dx, dy;
 	int clipBoxWidth, clipBoxHeight, maxDim;
@@ -1098,9 +1093,6 @@
 	clipBoxHeight = rect.height();
 	maxDim = qRound(sqrt( (double) (clipBoxWidth * clipBoxWidth + clipBoxHeight * clipBoxHeight) )) * 2;
 	if ( maxDim <= 0 ) return;
-	
-	scale1 = sqrt( m_matrix.m11() * m_matrix.m11() + m_matrix.m12() * m_matrix.m12() );
-	scale2 = sqrt( m_matrix.m21() * m_matrix.m21() + m_matrix.m22() * m_matrix.m22() );
 
 	x1 = m_matrix.dx() + gradient.origin().x() * m_matrix.m11();
 	y1 = m_matrix.dy() + gradient.origin().y() * m_matrix.m22();
@@ -1198,7 +1190,6 @@
 	int r1, g1, b1;
 	int r2, g2, b2;
 	double ramp1, ramp2;
-	double scale1, scale2;
 	int clipBoxWidth, clipBoxHeight, maxDim;
 	QList<VColorStopEx*> colorStops = gradient.colorStops();
 	VColorStopEx stop1( *colorStops[gradient.Stops() - 1] );
@@ -1210,9 +1201,6 @@
 	clipBoxHeight = rect.height();
 	maxDim = qRound(sqrt( (double) (clipBoxWidth * clipBoxWidth + clipBoxHeight * clipBoxHeight) )) * 2;
 	if ( maxDim <= 0 ) return;
-
-	scale1 = sqrt( m_matrix.m11() * m_matrix.m11() + m_matrix.m21() * m_matrix.m21() );
-	scale2 = sqrt( m_matrix.m12() * m_matrix.m12() + m_matrix.m22() * m_matrix.m22() );
 
 	FPoint pc( gradient.origin().x(), gradient.origin().y() );
 	FPoint pcz( gradient.origin().x(), gradient.origin().y() );
@@ -1285,7 +1273,6 @@
 	int c1, m1, y1, k1;
 	int c2, m2, y2, k2;
 	double ramp1, ramp2;
-	double scale1, scale2;
 	int clipBoxWidth, clipBoxHeight, maxDim;
 	QList<VColorStopEx*> colorStops = gradient.colorStops();
 	VColorStopEx stop1( *colorStops[gradient.Stops() - 1] );
@@ -1297,9 +1284,6 @@
 	clipBoxHeight = rect.height();
 	maxDim = qRound(sqrt( (double) (clipBoxWidth * clipBoxWidth + clipBoxHeight * clipBoxHeight) )) * 2;
 	if ( maxDim <= 0 ) return;
-
-	scale1 = sqrt( m_matrix.m11() * m_matrix.m11() + m_matrix.m21() * m_matrix.m21() );
-	scale2 = sqrt( m_matrix.m12() * m_matrix.m12() + m_matrix.m22() * m_matrix.m22() );
 
 	FPoint pc( gradient.origin().x(), gradient.origin().y() );
 	FPoint pcz( gradient.origin().x(), gradient.origin().y() );

Modified: trunk/Scribus/scribus/ui/cmykfw.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=17635&path=/trunk/Scribus/scribus/ui/cmykfw.cpp
==============================================================================
--- trunk/Scribus/scribus/ui/cmykfw.cpp (original)
+++ trunk/Scribus/scribus/ui/cmykfw.cpp Mon Jun 25 19:42:39 2012
@@ -85,11 +85,7 @@
 	cyd = cmyk.y / 2.55;
 	ckd = cmyk.k / 2.55;
 	RGBColor rgb;
-	double crd, cgd, cbd;
 	ScColorEngine::getRGBValues(orig, m_doc, rgb);
-	crd = rgb.r / 2.55;
-	cgd = rgb.g / 2.55;
-	cbd = rgb.b / 2.55;
 	resize( 498, 306 );
 	setWindowTitle( tr( "Edit Color" ) );
 	setWindowIcon(QIcon(loadIcon("AppIcon.png")));

Modified: trunk/Scribus/scribus/ui/multiprogressdialog.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=17635&path=/trunk/Scribus/scribus/ui/multiprogressdialog.cpp
==============================================================================
--- trunk/Scribus/scribus/ui/multiprogressdialog.cpp (original)
+++ trunk/Scribus/scribus/ui/multiprogressdialog.cpp Mon Jun 25 19:42:39 2012
@@ -90,11 +90,8 @@
 {
 	int progress = 0;
 	if (progressBars.contains(barName))
-	{
 		progress = progressBars[barName]->value();
-		return true;
-	}
-	return false;
+	return progress;
 }
 
 bool MultiProgressDialog::setLabel(const QString &barName, const QString & newLabel)




More information about the scribus-commit mailing list