r17408 by fschmid - Fixed crash when creating PathText items.
scribus-commit
scribus-commit at lists.scribus.net
Sat Mar 31 20:57:30 UTC 2012
Author: fschmid
Date: Sat Mar 31 20:57:30 2012
New Revision: 17408
URL: http://scribus.net/websvn/listing.php?repname=Scribus&sc=1&rev=17408
Log:
Fixed crash when creating PathText items.
Modified:
trunk/Scribus/scribus/pageitem_pathtext.cpp
trunk/Scribus/scribus/text/storytext.cpp
trunk/Scribus/scribus/text/storytext.h
Modified: trunk/Scribus/scribus/pageitem_pathtext.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=17408&path=/trunk/Scribus/scribus/pageitem_pathtext.cpp
==============================================================================
--- trunk/Scribus/scribus/pageitem_pathtext.cpp (original)
+++ trunk/Scribus/scribus/pageitem_pathtext.cpp Sat Mar 31 20:57:30 2012
@@ -174,6 +174,7 @@
totalTextLen += itemText.charStyle(0).fontSize() * itemText.charStyle(0).tracking() / 10000.0;
}
itemRenderText.clear();
+ itemRenderText.setDoc(m_Doc);
itemRenderText.setDefaultStyle(itemText.defaultStyle());
for (a = firstChar; a < itemText.length(); ++a)
{
Modified: trunk/Scribus/scribus/text/storytext.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=17408&path=/trunk/Scribus/scribus/text/storytext.cpp
==============================================================================
--- trunk/Scribus/scribus/text/storytext.cpp (original)
+++ trunk/Scribus/scribus/text/storytext.cpp Sat Mar 31 20:57:30 2012
@@ -110,6 +110,11 @@
d->len = 0;
delete d;
}
+}
+
+void StoryText::setDoc(ScribusDoc *docin)
+{
+ doc = docin;
}
StoryText StoryText::copy() const
Modified: trunk/Scribus/scribus/text/storytext.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=17408&path=/trunk/Scribus/scribus/text/storytext.h
==============================================================================
--- trunk/Scribus/scribus/text/storytext.h (original)
+++ trunk/Scribus/scribus/text/storytext.h Sat Mar 31 20:57:30 2012
@@ -90,11 +90,12 @@
Q_OBJECT
public:
- StoryText(ScribusDoc * doc);
+ StoryText(ScribusDoc *doc);
StoryText();
StoryText(const StoryText & other);
StoryText& operator= (const StoryText & other);
virtual ~StoryText();
+ void setDoc(ScribusDoc *docin);
static const Xml_string saxxDefaultElem;
static void desaxeRules(const Xml_string& prefixPattern, desaxe::Digester& ruleset, Xml_string elemtag = saxxDefaultElem);
More information about the scribus-commit
mailing list