r24615 by jghali - Code style fixes
scribus-commit
scribus-commit at lists.scribus.net
Wed Apr 7 22:44:23 UTC 2021
Author: jghali
Date: Wed Apr 7 22:44:23 2021
New Revision: 24615
URL: http://scribus.net/websvn/listing.php?repname=Scribus&sc=1&rev=24615
Log:
Code style fixes
Modified:
trunk/Scribus/scribus/ui/nodeeditpalette.cpp
trunk/Scribus/scribus/ui/nodeeditpalette.h
Modified: trunk/Scribus/scribus/ui/nodeeditpalette.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=24615&path=/trunk/Scribus/scribus/ui/nodeeditpalette.cpp
==============================================================================
--- trunk/Scribus/scribus/ui/nodeeditpalette.cpp (original)
+++ trunk/Scribus/scribus/ui/nodeeditpalette.cpp Wed Apr 7 22:44:23 2021
@@ -24,7 +24,7 @@
QSize iconSize = QSize(22, 22);
QSize buttonSize = QSize(24,24);
m_doc = nullptr;
- unitRatio = 1.0;
+ m_unitRatio = 1.0;
vboxLayout = new QVBoxLayout(this);
vboxLayout->setSpacing(6);
vboxLayout->setContentsMargins(9, 9, 9, 9);
@@ -613,7 +613,7 @@
{
PageItem *currItem = m_doc->m_Selection->itemAt(0);
FPoint zp;
- FPoint np(XSpin->value()/m_doc->unitRatio(), YSpin->value()/m_doc->unitRatio());
+ FPoint np(XSpin->value() / m_doc->unitRatio(), YSpin->value() / m_doc->unitRatio());
if (AbsMode->isChecked())
{
if (absToCanvas->isChecked())
@@ -971,15 +971,15 @@
// position in the item's coordinate space (which is rotated and translated,
// but the translation does not matter for the delta)
QTransform m = QTransform().rotate(-currItem->rotation());
- QPointF delta = m.map(QPointF(xPos, yPos)) - m.map(QPointF(currItem->xPos(), currItem->yPos()));
+ QPointF delta = m.map(QPointF(m_xPos, m_yPos)) - m.map(QPointF(currItem->xPos(), currItem->yPos()));
// During operation the image offsets and possibly other values are changed.
// To not remember everything we move the clip path to the original position
// relative to the current position (in the item's coordinate space).
// adjustItemSize will then take care of moving the position and changing
// image offsets, etc.
- currItem->PoLine = itemPath.copy();
+ currItem->PoLine = m_itemPath.copy();
currItem->PoLine.translate(delta.x(), delta.y());
- currItem->ContourLine = itemContourPath.copy();
+ currItem->ContourLine = m_itemContourPath.copy();
m_doc->adjustItemSize(currItem);
if (currItem->itemType() == PageItem::PathText)
currItem->updatePolyClip();
@@ -1006,18 +1006,18 @@
// See comment in NodePalette::CancelEdit
QTransform m = QTransform().rotate(-currItem->rotation());
- QPointF delta = m.map(QPointF(xPos, yPos)) - m.map(QPointF(currItem->xPos(), currItem->yPos()));
+ QPointF delta = m.map(QPointF(m_xPos, m_yPos)) - m.map(QPointF(currItem->xPos(), currItem->yPos()));
if (EditCont->isChecked())
{
- currItem->ContourLine = itemContourPath.copy();
+ currItem->ContourLine = m_itemContourPath.copy();
currItem->ContourLine.translate(delta.x(), delta.y());
}
else
{
// See comment in NodePalette::CancelEdit
- currItem->PoLine = itemPath;
+ currItem->PoLine = m_itemPath;
currItem->PoLine.translate(delta.x(), delta.y());
- currItem->ContourLine = itemContourPath;
+ currItem->ContourLine = m_itemContourPath;
m_doc->adjustItemSize(currItem);
}
if (currItem->itemType() == PageItem::PathText)
@@ -1044,10 +1044,10 @@
void NodePalette::setDefaults(PageItem* currItem)
{
- xPos = currItem->xPos();
- yPos = currItem->yPos();
- itemPath = currItem->PoLine.copy();
- itemContourPath = currItem->ContourLine.copy();
+ m_xPos = currItem->xPos();
+ m_yPos = currItem->yPos();
+ m_itemPath = currItem->PoLine.copy();
+ m_itemContourPath = currItem->ContourLine.copy();
}
void NodePalette::iconSetChange()
@@ -1133,7 +1133,7 @@
{
if (m_doc == nullptr)
return;
- unitRatio = m_doc->unitRatio();
+ m_unitRatio = m_doc->unitRatio();
bool sigBlocked1 = XSpin->blockSignals(true);
bool sigBlocked2 = YSpin->blockSignals(true);
Modified: trunk/Scribus/scribus/ui/nodeeditpalette.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=24615&path=/trunk/Scribus/scribus/ui/nodeeditpalette.h
==============================================================================
--- trunk/Scribus/scribus/ui/nodeeditpalette.h (original)
+++ trunk/Scribus/scribus/ui/nodeeditpalette.h Wed Apr 7 22:44:23 2021
@@ -148,11 +148,11 @@
ScribusDoc *m_doc { nullptr };
ScribusView *m_view { nullptr };
- double unitRatio { 1.0 };
- double xPos { 0.0 };
- double yPos { 0.0 };
- FPointArray itemPath;
- FPointArray itemContourPath;
+ double m_unitRatio { 1.0 };
+ double m_xPos { 0.0 };
+ double m_yPos { 0.0 };
+ FPointArray m_itemPath;
+ FPointArray m_itemContourPath;
signals:
void DocChanged();
More information about the scribus-commit
mailing list