Sadez Report post Posted October 11, 2004 I added support for gui widgets and made a label widget. It has been implemented like it was said in a an thread in the old forums. TODO: - More widgets: Image, button, checkbox, vertical scroll bar at least. - XML format for easily creating windows. - Server windows. With the XML format it will be possible to create windows sending the XML data. This could be useful for an npc to display quest information for example. Share this post Link to post Share on other sites
frak Report post Posted October 11, 2004 thatll be great for the python binding! Share this post Link to post Share on other sites
Cicero Report post Posted October 11, 2004 Careful with XML defined windows . . . didn't M$ recently patent that? Share this post Link to post Share on other sites
Wytter Report post Posted October 11, 2004 Careful with XML defined windows . . . didn't M$ recently patent that? Hmm, I know that they've patented file formats for Office that uses xml - but do you have a link for that information? I've actually been working on using xml to create GTK2-windows for a while (just for generic configuration tool usage), and well - if that's true I'd have to find a server in Asia to host the source once it's more mature... Software patents are evil... Share this post Link to post Share on other sites
Cicero Report post Posted October 11, 2004 Actually, I think it was an XML based installer or something. I wouldn't worry about it, I was just joking around. I'm surprised they haven't tried to patent XML. Share this post Link to post Share on other sites
Wytter Report post Posted October 11, 2004 Ah good... Would hate to see that work go down the drain... :-) When it comes to software patents I have a hard time figuring out the difference between what's a joke and what isn't - I mean, patenting the double-click? Share this post Link to post Share on other sites
Entropy Report post Posted October 12, 2004 The over text Widget should be on a dark gray background (as it was before), otherwise it's hard to read. Share this post Link to post Share on other sites
Sadez Report post Posted October 13, 2004 Added checkbox and image widgets. Share this post Link to post Share on other sites
Sadez Report post Posted October 21, 2004 Button, progressbar and vertical scrollbar are done. Thats the basic set of widgets I had planned, they still need some polishing but I'll wait until I do the XML format for the windows. Share this post Link to post Share on other sites
Sadez Report post Posted October 26, 2004 Added support for XML windows. Here is an example: win = AddXMLWindow("test.xml"); <window name="window1" pos_x="100" pos_y="100" size_x="100" size_y="300" flags="821"> <label pos_x="0" pos_y="20" text="se se se" r="1.0" g="0.0" b="0.0" size="0.7"/> <image pos_x="0" pos_y="40" len_x="40" len_y="40"/> <checkbox pos_x="50" pos_y="100" len_x="20" len_y="20" r="1.0" g="0.0" b="0.0" checked="1" /> <button pos_x="10" pos_y="120" text="si si si"/> <progressbar pos_x="5" pos_y="140" len_x="200" len_y="20" progress="50" /> <vscrollbar pos_x="50" pos_y="70" len_x="20" len_y="200" pos="0" pos_inc="4" /> </window> Share this post Link to post Share on other sites
Entropy Report post Posted October 26, 2004 Stupid question: How do you get the feedback from a xml window? I mean, the callbacks and such. Share this post Link to post Share on other sites
Sadez Report post Posted October 27, 2004 (edited) You need to assign an id to the widget: <button id="666" pos_x="10" pos_y="120" text="si si si"/> Then you create the window and set the callback function win = AddXMLWindow("test.xml"); widget_set_OnClick(win,666,clika); the callback looks like this (it just increases the position by 10 each click): int clika(widget_list *w){ w->pos_x+=10; return 0; } Edited October 27, 2004 by Sadez Share this post Link to post Share on other sites