r23193 by jghali - Rename setCurrentItem() argument for a few properties widgets
scribus-commit
scribus-commit at lists.scribus.net
Mon Sep 9 14:32:03 UTC 2019
Author: jghali
Date: Mon Sep 9 14:32:02 2019
New Revision: 23193
URL: http://scribus.net/websvn/listing.php?repname=Scribus&sc=1&rev=23193
Log:
Rename setCurrentItem() argument for a few properties widgets
Modified:
trunk/Scribus/scribus/ui/propertiespalette.h
trunk/Scribus/scribus/ui/propertiespalette_group.h
trunk/Scribus/scribus/ui/propertiespalette_image.h
trunk/Scribus/scribus/ui/propertiespalette_line.h
trunk/Scribus/scribus/ui/propertiespalette_shadow.cpp
trunk/Scribus/scribus/ui/propertiespalette_shadow.h
trunk/Scribus/scribus/ui/propertiespalette_shape.h
trunk/Scribus/scribus/ui/propertiespalette_text.cpp
trunk/Scribus/scribus/ui/propertiespalette_text.h
trunk/Scribus/scribus/ui/propertiespalette_xyz.cpp
trunk/Scribus/scribus/ui/propertiespalette_xyz.h
trunk/Scribus/scribus/ui/propertywidget_advanced.h
trunk/Scribus/scribus/ui/propertywidget_textcolor.h
trunk/Scribus/scribus/ui/textpalette.cpp
trunk/Scribus/scribus/ui/textpalette.h
Modified: trunk/Scribus/scribus/ui/propertiespalette.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23193&path=/trunk/Scribus/scribus/ui/propertiespalette.h
==============================================================================
--- trunk/Scribus/scribus/ui/propertiespalette.h (original)
+++ trunk/Scribus/scribus/ui/propertiespalette.h Mon Sep 9 14:32:02 2019
@@ -88,7 +88,7 @@
void setDoc(ScribusDoc *d);
void AppModeChanged();
- void setCurrentItem(PageItem *i);
+ void setCurrentItem(PageItem *item);
void unsetDoc();
void unsetItem();
Modified: trunk/Scribus/scribus/ui/propertiespalette_group.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23193&path=/trunk/Scribus/scribus/ui/propertiespalette_group.h
==============================================================================
--- trunk/Scribus/scribus/ui/propertiespalette_group.h (original)
+++ trunk/Scribus/scribus/ui/propertiespalette_group.h Mon Sep 9 14:32:02 2019
@@ -53,7 +53,7 @@
void setMainWindow(ScribusMainWindow *mw);
void setDoc(ScribusDoc *d);
- void setCurrentItem(PageItem *i);
+ void setCurrentItem(PageItem *item);
void unsetDoc();
void unsetItem();
Modified: trunk/Scribus/scribus/ui/propertiespalette_image.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23193&path=/trunk/Scribus/scribus/ui/propertiespalette_image.h
==============================================================================
--- trunk/Scribus/scribus/ui/propertiespalette_image.h (original)
+++ trunk/Scribus/scribus/ui/propertiespalette_image.h Mon Sep 9 14:32:02 2019
@@ -61,7 +61,7 @@
void setMainWindow(ScribusMainWindow *mw);
void setDoc(ScribusDoc *d);
- void setCurrentItem(PageItem *i);
+ void setCurrentItem(PageItem *item);
void unsetDoc();
void unsetItem();
Modified: trunk/Scribus/scribus/ui/propertiespalette_line.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23193&path=/trunk/Scribus/scribus/ui/propertiespalette_line.h
==============================================================================
--- trunk/Scribus/scribus/ui/propertiespalette_line.h (original)
+++ trunk/Scribus/scribus/ui/propertiespalette_line.h Mon Sep 9 14:32:02 2019
@@ -55,7 +55,7 @@
void setMainWindow(ScribusMainWindow *mw);
void setDoc(ScribusDoc *d);
- void setCurrentItem(PageItem *i);
+ void setCurrentItem(PageItem *item);
void unsetDoc();
void unsetItem();
Modified: trunk/Scribus/scribus/ui/propertiespalette_shadow.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23193&path=/trunk/Scribus/scribus/ui/propertiespalette_shadow.cpp
==============================================================================
--- trunk/Scribus/scribus/ui/propertiespalette_shadow.cpp (original)
+++ trunk/Scribus/scribus/ui/propertiespalette_shadow.cpp Mon Sep 9 14:32:02 2019
@@ -185,24 +185,24 @@
return currentItem;
}
-void PropertiesPalette_Shadow::setCurrentItem(PageItem *i)
+void PropertiesPalette_Shadow::setCurrentItem(PageItem *item)
{
if (!m_ScMW || m_ScMW->scriptIsRunning())
return;
if (!m_doc)
- setDoc(i->doc());
- m_haveItem = false;
- m_item = i;
- hasSoftShadow->setBoolValue(i->hasSoftShadow());
- softShadowXOffset->setDoubleValue(i->softShadowXOffset() * m_unitRatio);
- softShadowYOffset->setDoubleValue(i->softShadowYOffset() * m_unitRatio);
- softShadowBlurRadius->setDoubleValue(i->softShadowBlurRadius() * m_unitRatio);
- softShadowColor->setStringValue(i->softShadowColor());
- softShadowShade->setIntValue(i->softShadowShade());
- softShadowOpacity->setDoubleValue(qRound(100 - (i->softShadowOpacity() * 100)));
- softShadowBlendMode->setIntValue(i->softShadowBlendMode());
- softShadowErase->setBoolValue(i->softShadowErasedByObject());
- softShadowObjTrans->setBoolValue(i->softShadowHasObjectTransparency());
+ setDoc(item->doc());
+ m_haveItem = false;
+ m_item = item;
+ hasSoftShadow->setBoolValue(item->hasSoftShadow());
+ softShadowXOffset->setDoubleValue(item->softShadowXOffset() * m_unitRatio);
+ softShadowYOffset->setDoubleValue(item->softShadowYOffset() * m_unitRatio);
+ softShadowBlurRadius->setDoubleValue(item->softShadowBlurRadius() * m_unitRatio);
+ softShadowColor->setStringValue(item->softShadowColor());
+ softShadowShade->setIntValue(item->softShadowShade());
+ softShadowOpacity->setDoubleValue(qRound(100 - (item->softShadowOpacity() * 100)));
+ softShadowBlendMode->setIntValue(item->softShadowBlendMode());
+ softShadowErase->setBoolValue(item->softShadowErasedByObject());
+ softShadowObjTrans->setBoolValue(item->softShadowHasObjectTransparency());
m_haveItem = true;
updateSpinBoxConstants();
}
Modified: trunk/Scribus/scribus/ui/propertiespalette_shadow.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23193&path=/trunk/Scribus/scribus/ui/propertiespalette_shadow.h
==============================================================================
--- trunk/Scribus/scribus/ui/propertiespalette_shadow.h (original)
+++ trunk/Scribus/scribus/ui/propertiespalette_shadow.h Mon Sep 9 14:32:02 2019
@@ -36,7 +36,7 @@
void setMainWindow(ScribusMainWindow *mw);
void setDoc(ScribusDoc *d);
- void setCurrentItem(PageItem *i);
+ void setCurrentItem(PageItem *item);
void unsetDoc();
void unsetItem();
Modified: trunk/Scribus/scribus/ui/propertiespalette_shape.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23193&path=/trunk/Scribus/scribus/ui/propertiespalette_shape.h
==============================================================================
--- trunk/Scribus/scribus/ui/propertiespalette_shape.h (original)
+++ trunk/Scribus/scribus/ui/propertiespalette_shape.h Mon Sep 9 14:32:02 2019
@@ -63,7 +63,7 @@
void setMainWindow(ScribusMainWindow *mw);
void setDoc(ScribusDoc *d);
- void setCurrentItem(PageItem *i);
+ void setCurrentItem(PageItem *item);
void unsetDoc();
void unsetItem();
Modified: trunk/Scribus/scribus/ui/propertiespalette_text.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23193&path=/trunk/Scribus/scribus/ui/propertiespalette_text.cpp
==============================================================================
--- trunk/Scribus/scribus/ui/propertiespalette_text.cpp (original)
+++ trunk/Scribus/scribus/ui/propertiespalette_text.cpp Mon Sep 9 14:32:02 2019
@@ -311,7 +311,7 @@
}
}
-void PropertiesPalette_Text::setCurrentItem(PageItem *i)
+void PropertiesPalette_Text::setCurrentItem(PageItem *item)
{
if (!m_ScMW || m_ScMW->scriptIsRunning())
return;
@@ -323,10 +323,10 @@
// return;
if (!m_doc)
- setDoc(i->doc());
-
- m_haveItem = false;
- m_item = i;
+ setDoc(item->doc());
+
+ m_haveItem = false;
+ m_item = item;
showFirstLinePolicy(m_item->firstLineOffset());
Modified: trunk/Scribus/scribus/ui/propertiespalette_text.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23193&path=/trunk/Scribus/scribus/ui/propertiespalette_text.h
==============================================================================
--- trunk/Scribus/scribus/ui/propertiespalette_text.h (original)
+++ trunk/Scribus/scribus/ui/propertiespalette_text.h Mon Sep 9 14:32:02 2019
@@ -67,7 +67,7 @@
void setMainWindow(ScribusMainWindow *mw);
void setDoc(ScribusDoc *d);
- void setCurrentItem(PageItem *i);
+ void setCurrentItem(PageItem *item);
void unsetDoc();
void unsetItem();
Modified: trunk/Scribus/scribus/ui/propertiespalette_xyz.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23193&path=/trunk/Scribus/scribus/ui/propertiespalette_xyz.cpp
==============================================================================
--- trunk/Scribus/scribus/ui/propertiespalette_xyz.cpp (original)
+++ trunk/Scribus/scribus/ui/propertiespalette_xyz.cpp Mon Sep 9 14:32:02 2019
@@ -274,7 +274,7 @@
return currentItem;
}
-void PropertiesPalette_XYZ::setCurrentItem(PageItem *i)
+void PropertiesPalette_XYZ::setCurrentItem(PageItem *item)
{
if (!m_ScMW || m_ScMW->scriptIsRunning())
return;
@@ -286,12 +286,12 @@
// return;
if (!m_doc)
- setDoc(i->doc());
+ setDoc(item->doc());
disconnect(nameEdit, SIGNAL(Leaved()), this, SLOT(handleNewName()));
m_haveItem = false;
- m_item = i;
+ m_item = item;
nameEdit->setText(m_item->itemName());
levelLabel->setText( QString::number(m_item->level()) );
@@ -319,15 +319,15 @@
// showXY(selX, selY);
// showWH(selW, selH);
- bool checkableFlip = (i->isImageFrame() || i->isTextFrame() || i->isLatexFrame() || i->isOSGFrame() || i->isSymbol() || i->isGroup() || i->isSpiral());
+ bool checkableFlip = (item->isImageFrame() || item->isTextFrame() || item->isLatexFrame() || item->isOSGFrame() || item->isSymbol() || item->isGroup() || item->isSpiral());
flipH->setCheckable(checkableFlip);
flipV->setCheckable(checkableFlip);
- noPrint->setChecked(!i->printEnabled());
- showFlippedH(i->imageFlippedH());
- showFlippedV(i->imageFlippedV());
- double rr = i->rotation();
- if (i->rotation() > 0)
+ noPrint->setChecked(!item->printEnabled());
+ showFlippedH(item->imageFlippedH());
+ showFlippedV(item->imageFlippedV());
+ double rr = item->rotation();
+ if (item->rotation() > 0)
rr = 360 - rr;
m_oldRotation = fabs(rr);
rotationSpin->setValue(fabs(rr));
@@ -348,7 +348,7 @@
xposSpin->setEnabled(!setter);
yposSpin->setEnabled(!setter);
bool haveSameParent = m_doc->m_Selection->objectsHaveSameParent();
- levelGroup->setEnabled(haveSameParent && !i->locked());
+ levelGroup->setEnabled(haveSameParent && !item->locked());
if ((m_item->isGroup()) && (!m_item->isSingleSel))
{
setEnabled(true);
@@ -382,10 +382,10 @@
}
showXY(selX, selY);
showWH(selW, selH);
- showLocked(i->locked());
- showSizeLocked(i->sizeLocked());
- double rrR = i->imageRotation();
- if (i->imageRotation() > 0)
+ showLocked(item->locked());
+ showSizeLocked(item->sizeLocked());
+ double rrR = item->imageRotation();
+ if (item->imageRotation() > 0)
rrR = 360 - rrR;
noResize->setEnabled(!m_item->isArc());
Modified: trunk/Scribus/scribus/ui/propertiespalette_xyz.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23193&path=/trunk/Scribus/scribus/ui/propertiespalette_xyz.h
==============================================================================
--- trunk/Scribus/scribus/ui/propertiespalette_xyz.h (original)
+++ trunk/Scribus/scribus/ui/propertiespalette_xyz.h Mon Sep 9 14:32:02 2019
@@ -49,7 +49,7 @@
void setMainWindow(ScribusMainWindow *mw);
void setDoc(ScribusDoc *d);
- void setCurrentItem(PageItem *i);
+ void setCurrentItem(PageItem *item);
void unsetDoc();
void unsetItem();
Modified: trunk/Scribus/scribus/ui/propertywidget_advanced.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23193&path=/trunk/Scribus/scribus/ui/propertywidget_advanced.h
==============================================================================
--- trunk/Scribus/scribus/ui/propertywidget_advanced.h (original)
+++ trunk/Scribus/scribus/ui/propertywidget_advanced.h Mon Sep 9 14:32:02 2019
@@ -36,7 +36,7 @@
ScribusMainWindow* m_ScMW;
void configureWidgets();
- void setCurrentItem(PageItem *i);
+ void setCurrentItem(PageItem *item);
virtual void changeEvent(QEvent *e);
Modified: trunk/Scribus/scribus/ui/propertywidget_textcolor.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23193&path=/trunk/Scribus/scribus/ui/propertywidget_textcolor.h
==============================================================================
--- trunk/Scribus/scribus/ui/propertywidget_textcolor.h (original)
+++ trunk/Scribus/scribus/ui/propertywidget_textcolor.h Mon Sep 9 14:32:02 2019
@@ -24,7 +24,7 @@
~PropertyWidget_TextColor() {};
void updateColorList();
- void setCurrentItem(PageItem *i);
+ void setCurrentItem(PageItem *item);
protected:
PageItem * m_item;
Modified: trunk/Scribus/scribus/ui/textpalette.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23193&path=/trunk/Scribus/scribus/ui/textpalette.cpp
==============================================================================
--- trunk/Scribus/scribus/ui/textpalette.cpp (original)
+++ trunk/Scribus/scribus/ui/textpalette.cpp Mon Sep 9 14:32:02 2019
@@ -193,7 +193,7 @@
}
}
-void TextPalette::setCurrentItem(PageItem *i)
+void TextPalette::setCurrentItem(PageItem *item)
{
if (!m_ScMW || m_ScMW->scriptIsRunning())
return;
@@ -201,20 +201,20 @@
//maybe we do if the item has been changed by scripter.. but that should probably
//set some status if so.
//FIXME: This won't work until when a canvas deselect happens, m_item must be nullptr.
- //if (m_item == i)
+ //if (m_item == item)
// return;
- if (!i)
+ if (!item)
{
unsetItem();
return;
}
if (!m_doc)
- setDoc(i->doc());
-
- m_haveItem = false;
- m_item = i;
+ setDoc(item->doc());
+
+ m_haveItem = false;
+ m_item = item;
if ((m_item->isGroup()) && (!m_item->isSingleSel))
textPal->setEnabled(false);
Modified: trunk/Scribus/scribus/ui/textpalette.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23193&path=/trunk/Scribus/scribus/ui/textpalette.h
==============================================================================
--- trunk/Scribus/scribus/ui/textpalette.h (original)
+++ trunk/Scribus/scribus/ui/textpalette.h Mon Sep 9 14:32:02 2019
@@ -58,7 +58,7 @@
void setDoc(ScribusDoc *d);
void AppModeChanged();
- void setCurrentItem(PageItem *i);
+ void setCurrentItem(PageItem *item);
void unsetDoc();
void unsetItem();
More information about the scribus-commit
mailing list