Skip to content

Commit bad3df5

Browse files
committed
Rollback retina fix, earlier fix is not longer required see tpaviot#426
1 parent 6105131 commit bad3df5

File tree

3 files changed

+0
-31
lines changed

3 files changed

+0
-31
lines changed

.travis.yml

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -71,10 +71,6 @@ before_install:
7171
- conda info -a
7272
# download/install OCE from DLR-SC channel
7373
- conda config --add channels https://conda.anaconda.org/dlr-sc
74-
# on osx, need for pyobjc-core, available at erik's repository
75-
- if [ "$TRAVIS_OS_NAME" == "linux" ]; then
76-
conda config --add channels https://conda.anaconda.org/erik;
77-
fi;
7874
- conda config --add channels https://conda.anaconda.org/conda-forge
7975
- conda config --add channels https://conda.anaconda.org/tpaviot
8076
- conda config --add channels https://conda.anaconda.org/oce

ci/conda/meta.yaml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,6 @@ requirements:
3333
- oce ==0.18.1
3434
- python
3535
- freetype ==2.7
36-
- pyobjc-core [osx and py27]
3736

3837
test:
3938
requires:

src/Display/qtDisplay.py

Lines changed: 0 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -99,29 +99,6 @@ def resizeEvent(self, event):
9999
self._display.OnResize()
100100

101101

102-
def handle_retina(_nsview_pointer):
103-
""" OSX only. hack to detect and handle Retina display
104-
"""
105-
screen = QtGui.QGuiApplication.instance().primaryScreen()
106-
pixelDensity = screen.physicalDotsPerInch()
107-
108-
if pixelDensity >= 147:
109-
log.info("Retina display detected")
110-
try:
111-
import objc
112-
except ImportError:
113-
log.critical("pyobjc is not installed... try pip installing it \npip install pyobjc")
114-
else:
115-
nsview = objc.objc_object(c_void_p=_nsview_pointer)
116-
nsview.setWantsBestResolutionOpenGLSurface_(True)
117-
scaleFactor = nsview.backingScaleFactor()
118-
rec1 = screen.geometry()
119-
nsview.setBounds_(((rec1.x(),
120-
rec1.y()),
121-
(rec1.width() * scaleFactor,
122-
rec1.height() * scaleFactor)))
123-
124-
125102
class qtViewer3d(qtBaseViewer):
126103

127104
# emit signal when selection is changed
@@ -158,9 +135,6 @@ def qApp(self, value):
158135
self._qApp = value
159136

160137
def InitDriver(self):
161-
if sys.platform == "darwin":
162-
handle_retina(self.GetHandle())
163-
164138
self._display = OCCViewer.Viewer3d(self.GetHandle())
165139
self._display.Create()
166140
# background gradient

0 commit comments

Comments
 (0)