diff options
| author | Adrien Tétar | 2015-10-09 21:42:45 +0200 |
|---|---|---|
| committer | Adrien Tétar | 2015-10-09 21:42:45 +0200 |
| commit | adbf6b44e679c4b55200ded0f97d01402b58feeb (patch) | |
| tree | 81100877ba3b86d24a63b65c09d1ab42b75c3516 | |
| parent | 2c5b4b82ca816532c8366db762c9bcec8849623d (diff) | |
| download | trufont-adbf6b44e679c4b55200ded0f97d01402b58feeb.tar.bz2 | |
fontView: put InspectorWindow on the side
| -rw-r--r-- | Lib/defconQt/fontView.py | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/Lib/defconQt/fontView.py b/Lib/defconQt/fontView.py index 00434ff..dab393f 100644 --- a/Lib/defconQt/fontView.py +++ b/Lib/defconQt/fontView.py @@ -195,6 +195,14 @@ class InspectorWindow(QWidget): mainLayout.addWidget(transformGroup) self.setLayout(mainLayout) + def showEvent(self, event): + super(InspectorWindow, self).showEvent(event) + screenRect = QApplication.desktop().screenGeometry() + widgetRect = self.frameGeometry() + x = screenRect.width() - (widgetRect.width() + 20) + y = screenRect.center().y() - widgetRect.height() / 2 + self.move(x, y) + def hSymmetry(self): xMin, yMin, xMax, yMax = self._glyph.controlPointBounds for contour in self._glyph: |
