r21138 by jghali -
scribus-commit
scribus-commit at lists.scribus.net
Wed Mar 30 09:34:20 UTC 2016
Author: jghali
Date: Wed Mar 30 09:34:20 2016
New Revision: 21138
URL: http://scribus.net/websvn/listing.php?repname=Scribus&sc=1&rev=21138
Log:
simplify code now that PageItem_Table has its own implementation of currentTextProps()
Modified:
trunk/Scribus/scribus/ui/propertywidget_advanced.cpp
trunk/Scribus/scribus/ui/propertywidget_optmargins.cpp
trunk/Scribus/scribus/ui/propertywidget_pareffect.cpp
trunk/Scribus/scribus/ui/propertywidget_textcolor.cpp
Modified: trunk/Scribus/scribus/ui/propertywidget_advanced.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=21138&path=/trunk/Scribus/scribus/ui/propertywidget_advanced.cpp
==============================================================================
--- trunk/Scribus/scribus/ui/propertywidget_advanced.cpp (original)
+++ trunk/Scribus/scribus/ui/propertywidget_advanced.cpp Wed Mar 30 09:34:20 2016
@@ -110,10 +110,8 @@
if (m_item->asTextFrame() || m_item->asPathText() || m_item->asTable())
{
ParagraphStyle parStyle = m_item->itemText.defaultStyle();
- if (m_doc->appMode == modeEdit)
+ if (m_doc->appMode == modeEdit || m_doc->appMode == modeEditTable)
m_item->currentTextProps(parStyle);
- else if (m_doc->appMode == modeEditTable)
- m_item->asTable()->activeCell().textFrame()->currentTextProps(parStyle);
updateStyle(parStyle);
}
connectSignals();
Modified: trunk/Scribus/scribus/ui/propertywidget_optmargins.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=21138&path=/trunk/Scribus/scribus/ui/propertywidget_optmargins.cpp
==============================================================================
--- trunk/Scribus/scribus/ui/propertywidget_optmargins.cpp (original)
+++ trunk/Scribus/scribus/ui/propertywidget_optmargins.cpp Wed Mar 30 09:34:20 2016
@@ -85,10 +85,8 @@
if (m_item->asTextFrame() || m_item->asPathText())
{
ParagraphStyle parStyle = m_item->itemText.defaultStyle();
- if (m_doc->appMode == modeEdit)
+ if (m_doc->appMode == modeEdit || m_doc->appMode == modeEditTable)
m_item->currentTextProps(parStyle);
- else if (m_doc->appMode == modeEditTable)
- m_item->asTable()->activeCell().textFrame()->currentTextProps(parStyle);
showOpticalMargins(parStyle);
}
Modified: trunk/Scribus/scribus/ui/propertywidget_pareffect.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=21138&path=/trunk/Scribus/scribus/ui/propertywidget_pareffect.cpp
==============================================================================
--- trunk/Scribus/scribus/ui/propertywidget_pareffect.cpp (original)
+++ trunk/Scribus/scribus/ui/propertywidget_pareffect.cpp Wed Mar 30 09:34:20 2016
@@ -98,10 +98,8 @@
{
configureWidgets();
ParagraphStyle parStyle = m_item->itemText.defaultStyle();
- if (m_doc->appMode == modeEdit)
+ if (m_doc->appMode == modeEdit || m_doc->appMode == modeEditTable)
m_item->currentTextProps(parStyle);
- else if (m_doc->appMode == modeEditTable)
- m_item->asTable()->activeCell().textFrame()->currentTextProps(parStyle);
updateStyle(parStyle);
connectSignals();
}
Modified: trunk/Scribus/scribus/ui/propertywidget_textcolor.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=21138&path=/trunk/Scribus/scribus/ui/propertywidget_textcolor.cpp
==============================================================================
--- trunk/Scribus/scribus/ui/propertywidget_textcolor.cpp (original)
+++ trunk/Scribus/scribus/ui/propertywidget_textcolor.cpp Wed Mar 30 09:34:20 2016
@@ -108,20 +108,18 @@
if (!m_item->isTable() && !m_item->isTextFrame() && !m_item->asPathText())
return;
- PageItem_TextFrame *i2;
+ PageItem_TextFrame *textItem;
if (m_doc->appMode == modeEditTable)
- i2 = m_item->asTable()->activeCell().textFrame();
+ textItem = m_item->asTable()->activeCell().textFrame();
else
- i2 = m_item->asTextFrame();
- if (i2 != 0)
- revertButton->setChecked(i2->reversed());
+ textItem = m_item->asTextFrame();
+ if (textItem != 0)
+ revertButton->setChecked(textItem->reversed());
if (m_item->asTextFrame() || m_item->asPathText() || m_item->asTable())
{
ParagraphStyle parStyle = m_item->itemText.defaultStyle();
- if (m_doc->appMode == modeEdit)
+ if (m_doc->appMode == modeEdit || m_doc->appMode == modeEditTable)
m_item->currentTextProps(parStyle);
- else if (m_doc->appMode == modeEditTable)
- m_item->asTable()->activeCell().textFrame()->currentTextProps(parStyle);
updateStyle(parStyle);
}
connectSignals();
More information about the scribus-commit
mailing list