This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/qtreactor/qt4base.py b/qtreactor/qt4base.py | |
index 076599e..88af08c 100644 | |
--- a/qtreactor/qt4base.py | |
+++ b/qtreactor/qt4base.py | |
@@ -273,7 +273,8 @@ class QtReactor(posixbase.PosixReactorBase): | |
else: | |
self._blockApp = QtCore.QEventLoop() | |
self.runReturn() | |
- self._blockApp.exec_() | |
+ #self._blockApp.exec_() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform"> | |
<xsl:output method="html"/> | |
<xsl:template match="/"> | |
<xsl:apply-templates/> | |
</xsl:template> | |
<xsl:template match="ELECTION/MUNICIPALITY/CONSTITUENCY_MUNICIPALITY/ELECTORAL"> | |
<p><xsl:value-of select="@NAME"/></p> | |
</xsl:template> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform"> | |
<xsl:output method="html"/> | |
<xsl:template match="/ELECTION/MUNICIPALITY/CONSTITUENCY_MUNICIPALITY/ELECTORAL"> | |
<p><xsl:value-of select="@NAME"/></p> | |
</xsl:template> | |
<!-- Suppress unmatched input --> | |
<xsl:template match="text()"/> | |
</xsl:stylesheet> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from functools import partial | |
from sys import argv, exit | |
from PyQt5.QtCore import (Qt, QAbstractTableModel, QModelIndex, pyqtProperty, | |
pyqtSignal, QVariant) | |
from PyQt5.QtWidgets import (QApplication, QFrame, QStyledItemDelegate, QTableView, | |
QFormLayout, QSlider) | |
class MyAbstractItem(object): |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from functools import partial | |
from PyQt5.QtCore import pyqtProperty, Qt, QVariant | |
from PyQt5.QtWidgets import QFormLayout, QSlider, QStyledItemDelegate, QFrame | |
class MineralLevelsEditor(QFrame): | |
def __init__(self, parent=None): | |
super(MineralLevelsEditor, self).__init__(parent) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from PyQt5.QtCore import QFile, QIODevice, Qt | |
from PyQt5.QtWidgets import QStyledItemDelegate, QComboBox | |
# noinspection PyUnresolvedReferences | |
from orexplore.gui.ui import rock_types_rc # noqa | |
class RockTypeDelegate(QStyledItemDelegate): | |
def __init__(self, parent=None): |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
transitions: [ | |
Transition { | |
RotationAnimation { | |
// Animate all rotation changes. | |
duration: 1000 | |
easing.type: Easing.InOutQuad | |
direction: { | |
// Take the shortest direction. | |
if (from < to) | |
if (Math.abs(from - to) < 180) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from time import sleep | |
import zmq | |
context = zmq.Context() | |
socket = context.socket(zmq.PUB) | |
socket.bind("tcp://*:9001") | |
while True: | |
socket.send_json(('vidar', {'foo': 'bar'})) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def save(self, destination=None): | |
"""Save the project to a destination. | |
Args: | |
destination (Archive or str): An archive open for writing or an archive | |
file name. | |
""" | |
if isinstance(destination, Archive): | |
destination.saveFile('project.json', dumps({ | |
'name': self.name |
OlderNewer