Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Menu
Open sidebar
Benjamin Jakimow
EO Time Series Viewer
Commits
bb3533ab
Commit
bb3533ab
authored
Sep 10, 2013
by
Luke Campagnola
Browse files
Workaround for pyside bug:
https://bugs.launchpad.net/pyqtgraph/+bug/1223173
parent
88158946
Changes
1
Hide whitespace changes
Inline
Side-by-side
pyqtgraph/Vector.py
View file @
bb3533ab
...
...
@@ -5,7 +5,7 @@ Copyright 2010 Luke Campagnola
Distributed under MIT/X11 license. See license.txt for more infomation.
"""
from
.Qt
import
QtGui
,
QtCore
from
.Qt
import
QtGui
,
QtCore
,
USE_PYSIDE
import
numpy
as
np
class
Vector
(
QtGui
.
QVector3D
):
...
...
@@ -33,7 +33,13 @@ class Vector(QtGui.QVector3D):
def
__len__
(
self
):
return
3
def
__add__
(
self
,
b
):
# workaround for pyside bug. see https://bugs.launchpad.net/pyqtgraph/+bug/1223173
if
USE_PYSIDE
and
isinstance
(
b
,
QtGui
.
QVector3D
):
b
=
Vector
(
b
)
return
QtGui
.
QVector3D
.
__add__
(
self
,
b
)
#def __reduce__(self):
#return (Point, (self.x(), self.y()))
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment