Registered Member
|
Anyone knows a tutorial of how to make forms in javascript. I wanted to make a configuration form for my script but don't know how to use the *. ui files.
Thanks in advance.
Ignacio Serantes, proud to be a member of KDE forums since 2008-Nov.
|
Registered Member
|
I've just started looking into this as well, so someone else may know better than me .. but here's an example of what I found using a ui file I created in designer
If you want to hand code it you can do something like:
There's a bunch of info here Also I've been reading though other people's scripts to see what they've done. |
Registered Member
|
Thank you so much. Without a designer construct forms is very hard.
Update: I try your code and kills my Amarok.
Last edited by Ignacio Serantes on Fri Mar 27, 2009 2:14 pm, edited 1 time in total.
Ignacio Serantes, proud to be a member of KDE forums since 2008-Nov.
|
Registered Member
|
Hi, wondering if someone can help me.
Say, in the quoted example below, settings.ui represents a simple window with one QPushButton() object in the middle named "pushButton". (created using Qt Designer). If I add the line
to my script then the gui pops onto the screen and I can see the window and push button as expected. Now I wish to bind a function to the clicked signal of the push button so I can assign it some functionality. I can do this as follows:
My question is, how can I do this using the objects NAME (ie. pushButton) rather than the number 0 (first child object of configWindow?). As when building complex interfaces this obviously quickly gets out of hand and names become the most sensible way to do it. Sadly the following code fails miserably (Type Error - not an object).
The answer is somewhere on this page http://doc.trolltech.com/4.4/script-calculator.html but I cant figure it out. Can someone help me out? Thanks. Chris
|
Registered users: Bing [Bot], gfielding, Google [Bot], markhm, Sogou [Bot], Yahoo [Bot]