Hello guys!
now I'm developing application using qml and pyqt4
backend is pyqt4, frontend is qml
In some component, I used QtDesktop 0.1
When I run it using qmlviewer, it works.
but After I package it using pyinstaller-2.0(with "--windowed"), it doesn't
work.
please help me.
code:
testqmlRes.py:
import os
import sys
from PyQt4.QtGui import *
from PyQt4.QtDeclarative import *
from PyQt4.QtCore import *
from PyQt4.QtNetwork import *
import test_qml_res
class MainWidget(QDeclarativeView):
def __init__(self, parent=None, _platform=None):
super(MainWidget,self).__init__(parent)
self.setSource(QUrl("qrc:/qml/TestRect.qml"))
self.setResizeMode(QDeclarativeView.SizeRootObjectToView)
if __name__ == '__main__':
app = QApplication(sys.argv)
dlg = MainWidget()
dlg.show()
app.exec_()
pass
TestRect.qml:
import QtQuick 1.1
import QtDesktop 0.1
Rectangle {
width: childrenRect.width
height: childrenRect.height
Row{
Rectangle{
color:"yellow"
width:200
height:200
}
Image{
source:"images/logo_loading.gif"
}
TextArea {
anchors.fill:parent
id: area
frame: frameCheckbox.checked
text: "Hello world"
KeyNavigation.tab: button1
}
}
}
test_qml_res.qrc: (it was converted by pyrcc4")
<RCC>
<qresource prefix="/qml">
<file>TestRect.qml</file>
<file>images/logo_loading.gif</file>
</qresource>
</RCC>
--
You received this message because you are subscribed to the Google Groups
"PyInstaller" group.
To view this discussion on the web visit
https://groups.google.com/d/msg/pyinstaller/-/C_zquffEh-YJ.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/pyinstaller?hl=en.