r21814 by jghali - fix properties and text palettes not being displayed in screen rect in some situations
scribus-commit
scribus-commit at lists.scribus.net
Tue Mar 7 21:02:55 UTC 2017
Author: jghali
Date: Tue Mar 7 21:02:55 2017
New Revision: 21814
URL: http://scribus.net/websvn/listing.php?repname=Scribus&sc=1&rev=21814
Log:
fix properties and text palettes not being displayed in screen rect in some situations
Modified:
trunk/Scribus/scribus/ui/propertiespalette.cpp
trunk/Scribus/scribus/ui/textpalette.cpp
Modified: trunk/Scribus/scribus/ui/propertiespalette.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=21814&path=/trunk/Scribus/scribus/ui/propertiespalette.cpp
==============================================================================
--- trunk/Scribus/scribus/ui/propertiespalette.cpp (original)
+++ trunk/Scribus/scribus/ui/propertiespalette.cpp Tue Mar 7 21:02:55 2017
@@ -146,11 +146,16 @@
void PropertiesPalette::setMainWindow(ScribusMainWindow* mw)
{
- m_ScMW=mw;
- QPoint p1 = mapToGlobal(pos());
+ m_ScMW = mw;
+
+ // For some reason, the mapToGlobal() / mapFromGlobal() roundtrip
+ // performed below does not give always good results, causing PP to
+ // not display in some situations. Moreover the reparenting is useless
+ // as PP is already created with ScribusMainWindow as parent.
+ /*QPoint p1 = mapToGlobal(pos());
QPoint p2 = m_ScMW->mapFromGlobal(p1);
setParent(m_ScMW);
- move(p2);
+ move(p2);*/
this->xyzPal->setMainWindow(mw);
this->shadowPal->setMainWindow(mw);
Modified: trunk/Scribus/scribus/ui/textpalette.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=21814&path=/trunk/Scribus/scribus/ui/textpalette.cpp
==============================================================================
--- trunk/Scribus/scribus/ui/textpalette.cpp (original)
+++ trunk/Scribus/scribus/ui/textpalette.cpp Tue Mar 7 21:02:55 2017
@@ -72,11 +72,16 @@
void TextPalette::setMainWindow(ScribusMainWindow* mw)
{
- m_ScMW=mw;
- QPoint p1 = mapToGlobal(pos());
+ m_ScMW = mw;
+
+ // For some reason, the mapToGlobal() / mapFromGlobal() roundtrip
+ // performed below does not give always good results, causing TP to
+ // not display in some situations. Moreover the reparenting is useless
+ // as TP is already created with ScribusMainWindow as parent.
+ /*QPoint p1 = mapToGlobal(pos());
QPoint p2 = m_ScMW->mapFromGlobal(p1);
setParent(m_ScMW);
- move(p2);
+ move(p2);*/
this->textPal->setMainWindow(mw);
More information about the scribus-commit
mailing list