You can get to the source editor a number of ways. 1) From the menubar click windows | source editor. 2) Double click on the component you wish to work with in the source editor. 3) Press alt+s on the current working component (signified by 8 black squares around it's border). 4) Right click on the component you wish to work on, and select source editor. ![]() The source editor should be very easy to navigate. On the left is a combo box full of available components (the current one showing) the second is full of members for the current active component. The right combobox also has a "key character" it displays in the left most position in the member definition. The signifigance is: If a '-' shows then that means the prototype is for that of a signal, upon selection it will take you to the display described in Signals & Slots. If a '*' is shows it means it is a regular member that can has source code behind it (ie upon selection it's contents will be displayed in the editor below the combo box) If a '+' means that it means it is a normal member that is defined elsewhere. Thus the function is read only (this can be changed by going to file | member | modify member, and unchecking the defined else where box. If nothing shows it is a normal function with no source behind it, and will most likely not be in the final source that is dumped. If a '^' appears there, then it means the item is READONLY and there is no way for you to edit that object (by editing source, deletion, or modification) But this doesn't mean an object is readonly, you can still edit the other members, as well as adding new ones. ![]() You will also find the classwide header on this dialog. In there you can define, include, or declare any globals settings you want for just this class this could be done in this editor but may be more satisfactory to put it into the class itself if you only need it in one place. There is an additional feature to the source editor, when you run your program it will test for errors/warnings during compilation. If something occurs then The Source Editor will change, to accomodate a new list at the bottom of the dialog, in it is a list of messages the compiler gave you, simply click on any of the items in the list, and it will take you to the object, member, and line that the error occured on, if the compiler gave it such info for the message. Header Editor: The contents of this editor will go into main.h which all objects (including the main.cpp) will include. Anything put into here is a global declaration. The editor will try to figure out including pertaining to Qt, it will fill this file out with these includes when you try to run the program, of if you close and open the globals editor. Main Editor: Everthing in this area will be appended to the main() function in a seperate file (main.cpp). It may be a seldom used dialog as most things to start Qt into the event loop are done by QtEZ, it may still be usefull on occation to put something in here. Raw Source: You can put source code into here that may not belong in the GUI objects, came from another project, or are even just C functions. Contents of this are put into the main.cpp just before the main() function. This means if just the Main Editor above calls the contents it isn't necesary to prototype however if you are going to use this for other features then be sure to put valid declarations and prototypes into the Header Editor (as described above). Signature/Comments: The contents of this do NOT make it to the source code dumping, instead this is just used so you can put your name and documentation for a .qtz inside the same file. It also allows you to tell people where to contact you, or how to get updates. |