Fix crash if location text is so long (typo in code), thanks David666 to

report it


git-svn-id: svn+ssh://svn.tuxfamily.org/svnroot/qet/qet/trunk@5231 bfdf4180-ca20-0410-9c96-a3a8aa849046
This commit is contained in:
scorpio810
2018-02-07 00:20:50 +00:00
parent b4c2fd2372
commit ea8ee983df

View File

@@ -696,7 +696,7 @@ bool Element::fromXml(QDomElement &e, QHash<int, Terminal *> &table_id_adr, bool
location_text->setTextFrom(DynamicElementTextItem::ElementInfo);
location_text->setInfoName("location");
location_text->setFontSize(6);
if(comment_text->toPlainText().count() > 17)
if(location_text->toPlainText().count() > 17)
location_text->setTextWidth(80);
location_text->setPos(deti->x(), deti->y()+20); //+20 is arbitrary, location_text must be below deti and comment
addDynamicTextItem(location_text);