mirror of
https://github.com/qgis/QGIS.git
synced 2025-10-06 00:07:29 -04:00
move new composer tests to pyqt wrappers (followup 7a8a541 and f413046)
This commit is contained in:
parent
aef26c90f3
commit
4f6c271490
@ -6,12 +6,12 @@ class FixPrintWithImport(FixPrintWithImportOrig):
|
||||
|
||||
def match(self, node):
|
||||
isPrint = super(FixPrintWithImport, self).match(node)
|
||||
if isPrint and
|
||||
len(node.children) == 2 and \
|
||||
isinstance(node.children[0], Leaf) and \
|
||||
isinstance(node.children[1], Node) and node.children[1].type == syms.atom and \
|
||||
isinstance(node.children[1].children[0], Leaf) and node.children[1].children[0].value == '(' and \
|
||||
isinstance(node.children[1].children[-1], Leaf) and node.children[1].children[-1].value == ')':
|
||||
if isPrint and \
|
||||
len(node.children) == 2 and \
|
||||
isinstance(node.children[0], Leaf) and \
|
||||
isinstance(node.children[1], Node) and node.children[1].type == syms.atom and \
|
||||
isinstance(node.children[1].children[0], Leaf) and node.children[1].children[0].value == '(' and \
|
||||
isinstance(node.children[1].children[-1], Leaf) and node.children[1].children[-1].value == ')':
|
||||
return False
|
||||
|
||||
return ok
|
||||
|
@ -14,9 +14,9 @@ __revision__ = '$Format:%H$'
|
||||
|
||||
import qgis
|
||||
|
||||
from PyQt4.QtGui import QColor
|
||||
from PyQt4.QtGui import QPolygonF
|
||||
from PyQt4.QtCore import QPointF
|
||||
from PyQt.QtGui import QColor
|
||||
from PyQt.QtGui import QPolygonF
|
||||
from PyQt.QtCore import QPointF
|
||||
|
||||
from qgis.core import (QgsComposerPolygon,
|
||||
QgsComposerItem,
|
||||
|
@ -14,9 +14,9 @@ __revision__ = '$Format:%H$'
|
||||
|
||||
import qgis
|
||||
|
||||
from PyQt4.QtGui import QColor
|
||||
from PyQt4.QtGui import QPolygonF
|
||||
from PyQt4.QtCore import QPointF
|
||||
from PyQt.QtGui import QColor
|
||||
from PyQt.QtGui import QPolygonF
|
||||
from PyQt.QtCore import QPointF
|
||||
|
||||
from qgis.core import (QgsComposerPolyline,
|
||||
QgsComposerItem,
|
||||
|
Loading…
x
Reference in New Issue
Block a user