Skip to content

Commit

Permalink
Merge pull request #55 from spyder-ide/feature/import-qtsvg
Browse files Browse the repository at this point in the history
PR: Add explicit imports to QtSvg module
  • Loading branch information
ccordoba12 authored Aug 20, 2016
2 parents 16e444d + b748df4 commit a4cc859
Showing 1 changed file with 14 additions and 10 deletions.
24 changes: 14 additions & 10 deletions qtpy/QtSvg.py
Original file line number Diff line number Diff line change
@@ -1,21 +1,25 @@
# -*- coding: utf-8 -*-
#
# -----------------------------------------------------------------------------
# Copyright © 2009- The Spyder Development Team
#
# Licensed under the terms of the MIT License
# (see LICENSE.txt for details)
# -----------------------------------------------------------------------------
"""Provides QtSvg classes and functions."""

"""
Provides QtSvg classes and functions.
"""

from qtpy import PYQT5, PYQT4, PYSIDE, PythonQtError

# Local imports
from qtpy import PYQT4, PYQT5, PYSIDE, PythonQtError

if PYQT5:
from PyQt5.QtSvg import *
from PyQt5.QtSvg import (QGraphicsSvgItem, QSvgGenerator, QSvgRenderer,
QSvgWidget)
elif PYQT4:
from PyQt4.QtSvg import *
from PyQt4.QtSvg import (QGraphicsSvgItem, QSvgGenerator, QSvgRenderer,
QSvgWidget)
elif PYSIDE:
from PySide.QtSvg import *
from PySide.QtSvg import (QGraphicsSvgItem, QSvgGenerator, QSvgRenderer,
QSvgWidget)
else:
raise PythonQtError('No Qt bindings could be found')

del PYQT4, PYQT5, PYSIDE

0 comments on commit a4cc859

Please sign in to comment.