[Eric] Extras - Wizards -> Main
Carles Pina i Estany
carles at pina.cat
Mon Jan 15 17:30:19 GMT 2007
Hello,
(this is the last mail with my comments and wishes, I don't have more
comments/wishes about Eric :-) -by the moment!)
Note: I am still using version 3.9.1, if this is already implemented in
Eric4 sorry for the noise.
User case of my idea:
-User creates a new project
-User makes a new formulary
Now users wants to have a "new application", I mean, to execute this
formulary.
Usually I do something similar to:
from PyQt4 import QtCore,QtGui
from Ui_main import *
class MainWindow(QtGui.QMainWindow):
def __init__(self):
QtGui.QMainWindow.__init__(self)
self.ui = Ui_Principal()
self.ui.setupUi(self)
if __name__=="__main__":
app=QtGui.QApplication(sys.argv)
window=MainWindow()
window.show()
sys.exit(app.exec_())
I think that would be very goodthat user is able to do Extras - Wizards
- Main Window, then that Eric asks to user "in which file do you
have the formulary?" user selects the file and then form is compiled
and that code (or little better, i found it in some program that I
did) is written. Notice that from Ui_main is the file that user
would select, Ui_Principal is the name of form and has to be taken from
.ui file, etc.
The same concept (I can provide the code, but I am sure that you
Detlev has this code) to create a class importing from a formulary.
Even is so similar that could be in same options and checking if .ui
file is a Dialog or MainWindow, or something like this.
In my opinion, this would do Eric so much better.
PD: and optionally, could create this code:
@QtCore.pyqtSignature("")
def on_casquet_clicked(self):
##Type your button code here
if .ui has some buttons, already.
Thanks for the attention!
--
Carles Pina i Estany GPG id: 0x8CBDAE64
http://pinux.info Manresa - Barcelona
More information about the Eric
mailing list