From carcass.dev at gmail.com Thu Aug 2 06:51:16 2007 From: carcass.dev at gmail.com (dev carcass) Date: Thu, 2 Aug 2007 19:51:16 +0900 Subject: [Wxruby-users] RAD tool for OS X? Message-ID: Hello everybody, I've been getting very impressed with the features of wxRuby. I was wondering... IS THERE ANY GRAPHIC ENVIRONMENT DEVELOPMENT TOOL FOR RUBY? Something like Boa Constructor for PYTHON or Glade? I was forgetting... I'm thinking for MACINTOSH OS X but! deploying for Windows and Mac. I Know I can use wxGlade and use the XML saved file to handle the events in Ruby, but Is there anything "more native" for Ruby for OS X. I've tried wxGlade but...don't feeel very comfortable with it. Boa Constructor for Python is very impressive, although not very stable yet, but promissing. Thanks in advance. From alex at pressure.to Thu Aug 2 08:05:00 2007 From: alex at pressure.to (Alex Fenton) Date: Thu, 02 Aug 2007 13:05:00 +0100 Subject: [Wxruby-users] RAD tool for OS X? In-Reply-To: References: Message-ID: <46B1C86C.1010706@pressure.to> dev carcass wrote: > IS THERE ANY GRAPHIC ENVIRONMENT DEVELOPMENT TOOL FOR RUBY? > If you're looking something that will allow you to both edit ruby code and visually design layouts rigth alongside each other, the only wxWidgets designer that claims to support Ruby directly is VisualWx http://visualwx.altervista.org/download2.php I haven't tried it and there isn't much info on the site, so I'd be interested to learn about how it is. > I was forgetting... I'm thinking for MACINTOSH OS X but! deploying for > Windows and Mac. > It sounds like it uses wxPython, so perhaps could run on OS X. The screenshots are all from Windows. > I Know I can use wxGlade and use the XML saved file to handle the > events in Ruby, but Is there anything "more native" for Ruby for OS X. There's certainly nothing as nice as XCode's Interface Builder for OS X. If you're willing to stick with the XRC route and writing the GUI action your normal editor, you might find you like one of the other GUI builders better than wxGlade. People speak very well of DialogBlocks, although again I haven't tried it personally. alex From bureaux.sebastien at neuf.fr Sun Aug 5 13:00:53 2007 From: bureaux.sebastien at neuf.fr (Sebastien) Date: Sun, 05 Aug 2007 19:00:53 +0200 Subject: [Wxruby-users] accent Message-ID: <000501c7d782$2f169d40$0201a8c0@SN111194970311> Salut alex, est-ce qu'il est possible d'avoir la liste de tous les accents qu'il est possible de repr?senter avec wxruby2, comme "?" par exemple. merci Sebastien -------------- next part -------------- An HTML attachment was scrubbed... URL: http://rubyforge.org/pipermail/wxruby-users/attachments/20070805/5373608c/attachment.html From roys at mindspring.com Sun Aug 5 15:01:46 2007 From: roys at mindspring.com (Roy Sutton) Date: Sun, 05 Aug 2007 15:01:46 -0400 Subject: [Wxruby-users] accent In-Reply-To: <000501c7d782$2f169d40$0201a8c0@SN111194970311> References: <000501c7d782$2f169d40$0201a8c0@SN111194970311> Message-ID: <46B61E9A.8070703@mindspring.com> Sebastien wrote: > Salut alex, est-ce qu'il est possible d'avoir la liste de tous les > accents qu'il est possible de repr?senter avec wxruby2, > comme "?" par exemple. > merci > Sebastien > Hello Sebastien, I have seen several of your postings on this list but haven't been able to reply because I don't speak French very well. I'm afraid I can't contribute much and I'm also afraid that I haven't been able to get much from the answers you do get in French. I wonder if other users who might be looking for answers in the archives will miss them because they are in French. Is it possible, perhaps, to also post a translation with the questions and answers? Roy From bureaux.sebastien at neuf.fr Sun Aug 5 16:24:34 2007 From: bureaux.sebastien at neuf.fr (Sebastien) Date: Sun, 05 Aug 2007 22:24:34 +0200 Subject: [Wxruby-users] accent Message-ID: <000501c7d79e$a37be980$0201a8c0@SN111194970311> Salut roy, en fait tu voudrais que je traduise mes questions en anglais, d'apr?s ce que j'ai compris? Hello roy, in fact you would want that I translate my questions into English, as I understood? Sebastien -------------- next part -------------- An HTML attachment was scrubbed... URL: http://rubyforge.org/pipermail/wxruby-users/attachments/20070805/a443b723/attachment.html From roys at mindspring.com Sun Aug 5 18:01:04 2007 From: roys at mindspring.com (Roy Sutton) Date: Sun, 05 Aug 2007 18:01:04 -0400 Subject: [Wxruby-users] accent In-Reply-To: <000501c7d79e$a37be980$0201a8c0@SN111194970311> References: <000501c7d79e$a37be980$0201a8c0@SN111194970311> Message-ID: <46B648A0.8000908@mindspring.com> Sebastien wrote: > Salut roy, en fait tu voudrais que je traduise mes questions en > anglais, d'apr?s ce que j'ai compris? > > Hello roy, in fact you would want that I translate my questions into > English, as I understood? > Sebastien > Yes, Sebastien, that's perfect! Oui Sebastien. C'est parfait! Roy From fabio.petrucci at gmail.com Mon Aug 6 03:56:28 2007 From: fabio.petrucci at gmail.com (Fabio Petrucci) Date: Mon, 6 Aug 2007 09:56:28 +0200 Subject: [Wxruby-users] base64 image Message-ID: Hi all, is there any way to load a base64 converted image using classes such as Image or Bitmap? Thank you, fabio. -------------- next part -------------- An HTML attachment was scrubbed... URL: http://rubyforge.org/pipermail/wxruby-users/attachments/20070806/729a0081/attachment.html From alex at pressure.to Mon Aug 6 05:15:38 2007 From: alex at pressure.to (Alex Fenton) Date: Mon, 06 Aug 2007 10:15:38 +0100 Subject: [Wxruby-users] accent In-Reply-To: <000501c7d782$2f169d40$0201a8c0@SN111194970311> References: <000501c7d782$2f169d40$0201a8c0@SN111194970311> Message-ID: <46B6E6BA.3050103@pressure.to> Salut Sebastien wrote: > est-ce qu'il est possible d'avoir la liste de tous les accents qu'il > est possible de repr?senter avec wxruby2, > comme "?" par exemple. [Sebastien asked whether it was possible to get a list of all the accents which could be displayed in wxruby2] Parce que wxruby2 utilise UTF8, les accents qu'il peut represent sont limit?s seulement par la sp?cification Unicode [1], qui englobe milliers des caract?res. On doit avoir une fonte qu'inclut le caract?re pour que wxruby2 puisse l'afficher, mais on peut compte sur les accents des langues europ?ennes dans presque tous cas. [Because wxruby2 uses UTF-8, it's only limited by the Unicode specification, which includes many thousands of characters. wxruby2 relies on the user having an appropriate font installed to display a character, but you can count on almost all computers having at least accents for european languages] alex [1] http://unicode.org/ From alex at pressure.to Mon Aug 6 05:31:54 2007 From: alex at pressure.to (Alex Fenton) Date: Mon, 06 Aug 2007 10:31:54 +0100 Subject: [Wxruby-users] accent In-Reply-To: <46B61E9A.8070703@mindspring.com> References: <000501c7d782$2f169d40$0201a8c0@SN111194970311> <46B61E9A.8070703@mindspring.com> Message-ID: <46B6EA8A.9060700@pressure.to> Roy Sutton wrote: > Hello Sebastien, > > I have seen several of your postings on this list but haven't been able > to reply because I don't speak French very well. I'm afraid I can't > contribute much and I'm also afraid that I haven't been able to get much > from the answers you do get in French. I wonder if other users who > might be looking for answers in the archives will miss them because they > are in French. Is it possible, perhaps, to also post a translation with > the questions and answers? Thanks Roy - that is a good idea. My french is not all that either but if I'm responding I'll post a summary of the question and answer in English for other users. Also happy to go back and translate any of the recent queries: - how to ensure a taskbaricon is removed properly on application exit (summary - call taskbaricon.remove_icon before app exit) - how to display accented characters in Wx::StaticText (use UTF8 for the ruby file) - how to convert a bmp to an xpm file (use Wx::Image) - how to install wxruby2 somewhere other than standard dirs - how to not display a "close" button in a Frame's top bar (use style Wx::DEFAULT_FRAME_STYLE ^ Wx::CLOSE_BOX) [Sebastien - comme Roy, je voudrais que ceux qui ne parlent pas francais puissent suivre les conversations et trouver les r?ponses dans les archives. Je suis content de traduire une sommaire de vos questions en anglais] alex From alex at pressure.to Mon Aug 6 05:43:18 2007 From: alex at pressure.to (Alex Fenton) Date: Mon, 06 Aug 2007 10:43:18 +0100 Subject: [Wxruby-users] base64 image In-Reply-To: References: Message-ID: <46B6ED36.4080003@pressure.to> Hi Fabio Fabio Petrucci wrote: > is there any way to load a base64 converted image using classes such > as Image or Bitmap? I would use Ruby's base64 module (in the standard library) to decode the image to data, then save it to a temporary file to open using Wx::Image or Bitmap. WxWidgets has constructors for Image and Bitmap that are support creating images from a blob of xpm data, or from a stream, but these aren't in wxRuby. I can probably add them if anyone thinks they would be useful. alex From fabio.petrucci at gmail.com Mon Aug 6 06:35:44 2007 From: fabio.petrucci at gmail.com (Fabio Petrucci) Date: Mon, 6 Aug 2007 12:35:44 +0200 Subject: [Wxruby-users] base64 image In-Reply-To: <46B6ED36.4080003@pressure.to> References: <46B6ED36.4080003@pressure.to> Message-ID: Hi Alex, follow is my need: using fxruby binding library i've got all my application's icons to be embedded inside an .rb file, here is an example: icon_mgr.rb class IconMgr def self.acrobatPng(app) icon = < wrote: > > Hi Fabio > > Fabio Petrucci wrote: > > is there any way to load a base64 converted image using classes such > > as Image or Bitmap? > I would use Ruby's base64 module (in the standard library) to decode the > image to data, then save it to a temporary file to open using Wx::Image > or Bitmap. > > WxWidgets has constructors for Image and Bitmap that are support > creating images from a blob of xpm data, or from a stream, but these > aren't in wxRuby. I can probably add them if anyone thinks they would be > useful. > > alex > > > _______________________________________________ > wxruby-users mailing list > wxruby-users at rubyforge.org > http://rubyforge.org/mailman/listinfo/wxruby-users > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://rubyforge.org/pipermail/wxruby-users/attachments/20070806/d60caade/attachment.html From alex at pressure.to Mon Aug 6 07:45:47 2007 From: alex at pressure.to (Alex Fenton) Date: Mon, 06 Aug 2007 12:45:47 +0100 Subject: [Wxruby-users] base64 image In-Reply-To: References: <46B6ED36.4080003@pressure.to> Message-ID: <46B709EB.9050000@pressure.to> Fabio Petrucci wrote: > Hi Alex, > follow is my need: > using fxruby binding library i've got all my application's icons to be > embedded inside an .rb file, here is an example: probably the best solution for now is something like: require 'tempfile' # convert +img_str+, a base64 encoded PNG, into a Wx::Bitmap def img_from_str(img_str) tf = Tempfile.new('an_image') tf.binmode # probably needed on Windows tf.write( img_str.unpack('m') ) tf.close Wx::Bitmap.new(tf.path, Wx::BITMAP_TYPE_PNG) end I will look into whether there is something more convenient we can add from the wxWidgets API. If there are more than an a couple of images to deal with this way, it might be easier to keep the image files separate and use RUBYSCRIPT2EXE_APPEXE constant (which contains the directory where the .exe is saved) to find them. Wx::ArtProvider might help - see recent thread with Sebastien on this list. cheers alex From bureaux.sebastien at neuf.fr Sat Aug 11 16:08:26 2007 From: bureaux.sebastien at neuf.fr (Sebastien) Date: Sat, 11 Aug 2007 22:08:26 +0200 Subject: [Wxruby-users] TextCtrl.new Message-ID: <000501c7dc53$60f82560$0201a8c0@SN111194970311> Salut alex, j'utilise ce bout de code pour faire appara?tre mon texte dans ma fen?tre: @dou = TextCtrl.new(@s, -1, "", Point.new(10, 70), Size.new(410, 210), TE_RICH | TE_MULTILINE) @dou << "je vais ? l'?cole" le probl?me c'est que l'encodage ne marche pas.Je ne peut pas mettre l'accentuation.J'ai essayer pas mal de solution diff?rente mais rien ? faire. Quand je veut encoder ?a ne marche pas mais par contre si je fait ceci: @dou = TextCtrl.new(@s, -1, "je vais ? l'?cole", Point.new(10, 70), Size.new(410, 210), TE_RICH | TE_MULTILINE) ?a marche tr?s bien. Pourquoi? Quel est le probl?me? C'est pareil quand je veut lire des fichiers.txt, j'ai le m?me probl?me. J'ai essayer de tourner mes bouts de codes diff?rement, mais je ne trouve pas!!! merci -------------------------------------------------------- Hello alex, I use this end of code to create my text in my window: @dou = TextCtrl.new(@s, -1, "", Point.new(10, 70), Size.new(410, 210), TE_RICH | TE_MULTILINE) @dou << "je vais ? l'?cole" The problem it is because the encoding does not walk(work). I cannot put the accentuation. I have to try quite a lot of different solution but nothing to make. When I want to encode that do not walk(work) but on the other hand if I makes this: @dou = TextCtrl.new(@s, -1, "je vais ? l'?cole", Point.new(10, 70), Size.new(410, 210), TE_RICH | TE_MULTILINE) That walks(works) very well. Why? What is the problem? It is the similar when I wants to read fichiers.txt, I have the same problem. I have to try to turn(shoot) my ends of codes diff?rement, but I do not find!!! Thank you Sebastien -------------- next part -------------- An HTML attachment was scrubbed... URL: http://rubyforge.org/pipermail/wxruby-users/attachments/20070811/c23abdba/attachment-0001.html From alex at pressure.to Sat Aug 11 16:24:06 2007 From: alex at pressure.to (Alex Fenton) Date: Sat, 11 Aug 2007 21:24:06 +0100 Subject: [Wxruby-users] TextCtrl.new In-Reply-To: <000501c7dc53$60f82560$0201a8c0@SN111194970311> References: <000501c7dc53$60f82560$0201a8c0@SN111194970311> Message-ID: <46BE1AE6.4090002@pressure.to> Salut Sebastien wrote: > j'utilise ce bout de code pour faire appara?tre mon texte dans ma fen?tre: > > @dou = TextCtrl.new(@s, -1, "", Point.new(10, 70), Size.new(410, 210), > TE_RICH | TE_MULTILINE) > @dou << "je vais ? l'?cole" > > le probl?me c'est que l'encodage ne marche pas.Je ne peut pas mettre > l'accentuation.J'ai essayer pas mal de solution diff?rente mais rien ? > faire. [Does writing accented text into a TextCtrl work if you use the write_text method, instead of << or append_text? There is a known bug at the moment with UTF8 characters and TextCtrl#append_text] Marche-t-il si vous vous servez de write_text, comme ?i-dessus? @dou.write_text("je vais ? l'?cole") Il y a un probl?me connu avec 'TextCtrl#append_text' et l'accentuation: http://rubyforge.org/tracker/index.php?func=detail&aid=8068&group_id=35&atid=218 Aussi, c'est tres gentil de vous de poser votre question en anglais. Je suis content de traduire si ?a vous convient plus. alex From bureaux.sebastien at neuf.fr Sat Aug 11 16:50:54 2007 From: bureaux.sebastien at neuf.fr (Sebastien) Date: Sat, 11 Aug 2007 22:50:54 +0200 Subject: [Wxruby-users] TextCtrl.new Message-ID: <000501c7dc59$4f8e62c0$0201a8c0@SN111194970311> J'ai essayer et ?a marche. c'est sympa car cela faisait un moment que je cherchai. Tu peut traduire si tu veut. je traduit car fabbio m'avait demand? si je pouvait pos? mes questions en fran?ais et en anglais, donc c'est pour ?a que je met les 2. c'est comme tu veut. merci. Sebastien -------------- next part -------------- An HTML attachment was scrubbed... URL: http://rubyforge.org/pipermail/wxruby-users/attachments/20070811/dd02b8a4/attachment.html From lancecarlson at gmail.com Sun Aug 12 21:49:13 2007 From: lancecarlson at gmail.com (lancecarlson at gmail.com) Date: Mon, 13 Aug 2007 01:49:13 +0000 Subject: [Wxruby-users] Anvil: an application framework Message-ID: <388732552-1186969832-cardhu_decombobulator_blackberry.rim.net-61544281-@bxe124.bisx.prod.on.blackberry> Hi everyone! I have been working on idea for an application framework in ruby the wraps around the wx ruby gem. The goal is to make a framework that is as easy as rails create applications using concise and dry ruby code. We are in need of some experienced help! If you are interested checkout the project on ruby forge. Anvil.rubyforge.com and the irc channel is #rubyanvil on irc . My buck on irc is d2dchat. I look forward to all the input everyone could provide! -Lance Carlson Sent via BlackBerry from T-Mobile From bureaux.sebastien at neuf.fr Mon Aug 13 18:22:14 2007 From: bureaux.sebastien at neuf.fr (Sebastien) Date: Tue, 14 Aug 2007 00:22:14 +0200 Subject: [Wxruby-users] unicode Message-ID: <000501c7ddf8$67061bf0$0201a8c0@SN111194970311> Salut alex, j'ai essayer d'encoder quelques fichiers pour faire des test. Il y a des sigles comme "?" que je ne peut pas encoder. le probl?me c'est que quand j'ouvre un fichier.txt par exemple et qu'il contient ce sigle, le contenu du fichier ne s'affiche pas. Compter-vous ins?rer ces sigles par la suite que l'on puissent les encod?s? Est il possible d'avoir la liste des sigles manquant dans wxruby-1.9.0? Est-ce qu'il y a une solution en attendant pour lire tous les fichiers ou faut il attendre que vous fassiez le n?cessaire? wxruby-1.9.0 contient combien de norme d'encodage diff?rent? comme par exemple(windows-1252) merci Sebastien -------------- next part -------------- An HTML attachment was scrubbed... URL: http://rubyforge.org/pipermail/wxruby-users/attachments/20070814/d985c4ea/attachment.html From alex at pressure.to Tue Aug 14 05:27:56 2007 From: alex at pressure.to (Alex Fenton) Date: Tue, 14 Aug 2007 10:27:56 +0100 Subject: [Wxruby-users] unicode In-Reply-To: <000501c7ddf8$67061bf0$0201a8c0@SN111194970311> References: <000501c7ddf8$67061bf0$0201a8c0@SN111194970311> Message-ID: <46C1759C.9040505@pressure.to> Sebastien wrote: > j'ai essayer d'encoder quelques fichiers pour faire des test. Il y a > des sigles comme "?" que je ne peut pas encoder. le probl?me c'est que > quand j'ouvre un fichier.txt par exemple et qu'il contient ce sigle, > le contenu du fichier ne s'affiche pas. [A file containing the euro currency symbol ? isn't displaying correctly] > Est il possible d'avoir la liste des sigles manquant dans wxruby-1.9.0? > Est-ce qu'il y a une solution en attendant pour lire tous les fichiers > ou faut il attendre que vous fassiez le n?cessaire? > wxruby-1.9.0 contient combien de norme d'encodage diff?rent? comme par > exemple(windows-1252) [What symbols are missing in wxruby 1.9? What different encoding systems are suppported?] wxruby 1.9.0 ne soutient que UTF-8. Ainsi, si ton affiche ne conforme pas ? cette norme d'encodage, on ne pourra pas l'afficher. Donc, on doit enregistrer l'affiche qui contient le sigle en UTF-8 comme on enregistre le script.rb. Alternativement, on peut convertir d'une norme ? une autre avec 'iconv' - voyez 'samples/text/unicode.rb'. Parce-que UTF-8 est une forme d'unicode, aucune des sigles y manquent. On peut utilise n'importe quelle sigles, pourvu que l'utilisateur ait install? une fonte convenable. [wxruby 1.9 only supports UTF8. A file which isn't saved as UTF8 therefore can't be displayed. A text file must be saved with this encoding the same as a script file, or you can convert from one encoding to another in ruby using 'iconv' - see the 'samples/text/unicode.rb' sample] [Because UTF-8 is a form of unicode, there aren't any missing symbols or characters - you can use any characters provided that the user has a suitable font installed] alex From bureaux.sebastien at neuf.fr Tue Aug 14 07:02:01 2007 From: bureaux.sebastien at neuf.fr (Sebastien) Date: Tue, 14 Aug 2007 13:02:01 +0200 Subject: [Wxruby-users] unicode Message-ID: <000501c7de62$8a97bd70$0201a8c0@SN111194970311> Salut alex, je me suis rendu compte de mon erreur. ?a y est j'ai reussi ? encoder le sigle"?". De combien de caract?res est compos? utf-8? Qu'est-ce qu'une fonte? Par contre on n'a pas besoin d'encoder les chiffres? merci Sebastien -------------- next part -------------- An HTML attachment was scrubbed... URL: http://rubyforge.org/pipermail/wxruby-users/attachments/20070814/083d69b7/attachment.html From alex at pressure.to Wed Aug 15 07:38:51 2007 From: alex at pressure.to (Alex Fenton) Date: Wed, 15 Aug 2007 12:38:51 +0100 Subject: [Wxruby-users] unicode In-Reply-To: <000501c7de62$8a97bd70$0201a8c0@SN111194970311> References: <000501c7de62$8a97bd70$0201a8c0@SN111194970311> Message-ID: <46C2E5CB.403@pressure.to> Sebastien wrote: > De combien de caract?res est compos? utf-8? [How many characters are there in UTF-8?] Selon ce page [1], autour de 100,000 caract?res [According to this page from the unicode website, about 100,000 ] > Qu'est-ce qu'une fonte? Je ne trouvais pas autre mot dans ma dictionnaire. Exemples bien connus incluent 'Arial', 'Times New Roman', 'Courier'. > Par contre on n'a pas besoin d'encoder les chiffres? [Does one need to encode numbers?] Je ne comprends pas ta question - des chiffres sont caract?res comme les autres. Par dessin, en UTF-8, les chiffres 0-9 et les lettres latins non-accentu?s ont les meme valeurs qu'en ASCII. [I'm not sure I understand the question - numbers are characters like any other. By design, in UTF-8, the numbers 0-9 and unacccented latin letters have the same value is in ASCII ] Je vous suggere de trouver une introduction aux principes d'unicode et UTF-8. alex [1] http://www.unicode.org/standard/principles.html From glenn at tangelosoftware.net Mon Aug 20 21:51:59 2007 From: glenn at tangelosoftware.net (Glenn Davy) Date: Tue, 21 Aug 2007 11:51:59 +1000 Subject: [Wxruby-users] installing on X86_64 - unable to build Message-ID: <200708211151.59740.glenn@tangelosoftware.net> hi wxrubiers firstly - im right in understanding there is no gem for x86_64? failing that i've been trying to compile, but am failing because ld cant find lwx_gtk2u_aui-2.8 im on ubuntu (gutsy) and have wx-windows2.8 headers installed as well as libwxbase2.8dev and libwxgtk2.8-dev can anyone help? thanks glenn From alex at pressure.to Tue Aug 21 05:22:37 2007 From: alex at pressure.to (Alex Fenton) Date: Tue, 21 Aug 2007 10:22:37 +0100 Subject: [Wxruby-users] installing on X86_64 - unable to build In-Reply-To: <200708211151.59740.glenn@tangelosoftware.net> References: <200708211151.59740.glenn@tangelosoftware.net> Message-ID: <46CAAEDD.8020302@pressure.to> Hi Glenn Glenn Davy wrote: > firstly - im right in understanding there is no gem for x86_64? > No, not at the moment - we'd like to offer them but none of the dev team has a suitable machine. > failing that i've been trying to compile, but am failing because ld cant find > lwx_gtk2u_aui-2.8 > This is the Wx Advanced User Interface library. It's part of the core wxwidgets distro but I guess ubuntu/debian doesn't include it in libwxbase2.8. > im on ubuntu (gutsy) and have wx-windows2.8 headers installed as well as > libwxbase2.8dev and libwxgtk2.8-dev > Are there any likely-looking packages eg libwxaui2.8 offered for gutsy? If not you may need to compile your own wxWidgets 2.8.4. This almost always goes smoothly, although there are a lot of compile-time options. Recommended options for use with wxRuby are here: http://wxruby.rubyforge.org/wiki/wiki.pl?HowToBuildWxWidgets cheers alex From bplummer at zapeng.com Tue Aug 21 07:04:58 2007 From: bplummer at zapeng.com (Bill Plummer) Date: Tue, 21 Aug 2007 07:04:58 -0400 Subject: [Wxruby-users] installing on X86_64 - unable to build In-Reply-To: <46CAAEDD.8020302@pressure.to> References: <200708211151.59740.glenn@tangelosoftware.net> <46CAAEDD.8020302@pressure.to> Message-ID: <1187694299.5607.13.camel@bplummer-laptop> Hi Glenn, I'm curious, are you developing for Ubuntu x86_64 or is that your base operating system. I currently use Ubuntu 7.04 x86_64 as my base OS and then use VMWare Workstation 6.0 to run my virtual development computer. My target development OS is MS XP Professional. So, I have a new XP Pro VM for each project and save the VM for later bug fixes and additions without concern that my development system will change over time and become incompatible with my "old" project. This may not help you at all, but this has worked well for me because VMWare allows me to develop on any OS, 32 or 64 bit versions, for my target client. I think this setup would be an answer to Alex's problem of not having a development machine running a particular OS. But I may be over simplifying the issue. Bill On Tue, 2007-08-21 at 10:22 +0100, Alex Fenton wrote: > Hi Glenn > > Glenn Davy wrote: > > firstly - im right in understanding there is no gem for x86_64? > > > No, not at the moment - we'd like to offer them but none of the dev team > has a suitable machine. > > failing that i've been trying to compile, but am failing because ld cant find > > lwx_gtk2u_aui-2.8 > > > This is the Wx Advanced User Interface library. It's part of the core > wxwidgets distro but I guess ubuntu/debian doesn't include it in > libwxbase2.8. > > im on ubuntu (gutsy) and have wx-windows2.8 headers installed as well as > > libwxbase2.8dev and libwxgtk2.8-dev > > > Are there any likely-looking packages eg libwxaui2.8 offered for gutsy? > > If not you may need to compile your own wxWidgets 2.8.4. This almost > always goes smoothly, although there are a lot of compile-time options. > Recommended options for use with wxRuby are here: > > http://wxruby.rubyforge.org/wiki/wiki.pl?HowToBuildWxWidgets > > cheers > alex > > > _______________________________________________ > wxruby-users mailing list > wxruby-users at rubyforge.org > http://rubyforge.org/mailman/listinfo/wxruby-users From glenn at tangelosoftware.net Tue Aug 21 08:46:08 2007 From: glenn at tangelosoftware.net (Glenn Davy) Date: Tue, 21 Aug 2007 22:46:08 +1000 Subject: [Wxruby-users] installing on X86_64 - unable to build In-Reply-To: <1187694299.5607.13.camel@bplummer-laptop> References: <200708211151.59740.glenn@tangelosoftware.net> <46CAAEDD.8020302@pressure.to> <1187694299.5607.13.camel@bplummer-laptop> Message-ID: <200708212246.08658.glenn@tangelosoftware.net> On Tue, 21 Aug 2007 09:04:58 pm Bill Plummer wrote: > Hi Glenn, Hi Bill > > I'm curious, are you developing for Ubuntu x86_64 or is that your base > operating system. I currently use Ubuntu 7.04 x86_64 as my base OS and > then use VMWare Workstation 6.0 to run my virtual development computer. > My target development OS is MS XP Professional. So, I have a new XP Pro > VM for each project and save the VM for later bug fixes and additions > without concern that my development system will change over time and > become incompatible with my "old" project. yeah originally was intended as a 64Xen Dom0, and everything i used was going to be DomU's, but it hasnt worked out that way, so what i am using is running on bare metal. > > This may not help you at all, but this has worked well for me because > VMWare allows me to develop on any OS, 32 or 64 bit versions, for my > target client well it would give me a way to play with wxruby, true enough. btw Im using virtual box on this machine for when i need to virtualise, im liking it more than vmware. but, i get your gist. > . > > I think this setup would be an answer to Alex's problem of not having a > development machine running a particular OS. But I may be over > simplifying the issue. > > Bill > > On Tue, 2007-08-21 at 10:22 +0100, Alex Fenton wrote: > > Hi Glenn > > > > Glenn Davy wrote: > > > firstly - im right in understanding there is no gem for x86_64? > > > > No, not at the moment - we'd like to offer them but none of the dev team > > has a suitable machine. > > > > > failing that i've been trying to compile, but am failing because ld > > > cant find lwx_gtk2u_aui-2.8 > > > > This is the Wx Advanced User Interface library. It's part of the core > > wxwidgets distro but I guess ubuntu/debian doesn't include it in > > libwxbase2.8. > > > > > im on ubuntu (gutsy) and have wx-windows2.8 headers installed as well > > > as libwxbase2.8dev and libwxgtk2.8-dev > > > > Are there any likely-looking packages eg libwxaui2.8 offered for gutsy? > > > > If not you may need to compile your own wxWidgets 2.8.4. This almost > > always goes smoothly, although there are a lot of compile-time options. > > Recommended options for use with wxRuby are here: > > > > http://wxruby.rubyforge.org/wiki/wiki.pl?HowToBuildWxWidgets > > > > cheers > > alex > > > > > > _______________________________________________ > > wxruby-users mailing list > > wxruby-users at rubyforge.org > > http://rubyforge.org/mailman/listinfo/wxruby-users > > _______________________________________________ > wxruby-users mailing list > wxruby-users at rubyforge.org > http://rubyforge.org/mailman/listinfo/wxruby-users From glenn at tangelosoftware.net Tue Aug 21 08:53:28 2007 From: glenn at tangelosoftware.net (Glenn Davy) Date: Tue, 21 Aug 2007 22:53:28 +1000 Subject: [Wxruby-users] installing on X86_64 - unable to build In-Reply-To: <46CAAEDD.8020302@pressure.to> References: <200708211151.59740.glenn@tangelosoftware.net> <46CAAEDD.8020302@pressure.to> Message-ID: <200708212253.28680.glenn@tangelosoftware.net> On Tue, 21 Aug 2007 07:22:37 pm Alex Fenton wrote: > Hi Glenn > > Glenn Davy wrote: > > firstly - im right in understanding there is no gem for x86_64? > > No, not at the moment - we'd like to offer them but none of the dev team > has a suitable machine. ok - i've got a couple of suitable machines here. I dont (yet) know how to make gems, and my C is neglible. Im happy to learn to make gems, but suspect i'll never make a C programmer. Having said that, is there something i can do to help, by either a) compling binaries, or b) giving ssh access to one of your developers. anyhow, if i can be of use here, contact me off list. > > > failing that i've been trying to compile, but am failing because ld cant > > find lwx_gtk2u_aui-2.8 > > This is the Wx Advanced User Interface library. It's part of the core > wxwidgets distro but I guess ubuntu/debian doesn't include it in > libwxbase2.8. bumma > > > im on ubuntu (gutsy) and have wx-windows2.8 headers installed as well as > > libwxbase2.8dev and libwxgtk2.8-dev > > Are there any likely-looking packages eg libwxaui2.8 offered for gutsy? well, not that i can find > > If not you may need to compile your own wxWidgets 2.8.4. This almost > always goes smoothly, although there are a lot of compile-time options. > Recommended options for use with wxRuby are here: > > http://wxruby.rubyforge.org/wiki/wiki.pl?HowToBuildWxWidgets ok - will give this a go. will this interfere with any packaged ubuntu wx widgets? thanks glenn > > cheers > alex > > > _______________________________________________ > wxruby-users mailing list > wxruby-users at rubyforge.org > http://rubyforge.org/mailman/listinfo/wxruby-users From alex at pressure.to Tue Aug 21 10:01:39 2007 From: alex at pressure.to (Alex Fenton) Date: Tue, 21 Aug 2007 15:01:39 +0100 Subject: [Wxruby-users] installing on X86_64 - unable to build In-Reply-To: <200708212253.28680.glenn@tangelosoftware.net> References: <200708211151.59740.glenn@tangelosoftware.net> <46CAAEDD.8020302@pressure.to> <200708212253.28680.glenn@tangelosoftware.net> Message-ID: <46CAF043.2040600@pressure.to> Glenn Davy wrote: >>> firstly - im right in understanding there is no gem for x86_64? >>> >> No, not at the moment - we'd like to offer them but none of the dev team >> has a suitable machine. >> > > ok - i've got a couple of suitable machines here. I dont (yet) know how to > make gems, and my C is neglible. Im happy to learn to make gems, but suspect > i'll never make a C programmer. No knowledge of C is required - the packaging's all handled by the Rakefile: rake # build the library strip -x lib/wxruby2.so # optional, but reduces gem size rake gem # bundle a binary gem > Having said that, is there something i can do > to help, by either a) compling binaries, or b) giving ssh access to one of > your developers. anyhow, if i can be of use here, contact me off list. > That's kind of you, thanks. I'll drop you a line later. >>> im on ubuntu (gutsy) and have wx-windows2.8 headers installed as well as >>> libwxbase2.8dev and libwxgtk2.8-dev >>> >> Are there any likely-looking packages eg libwxaui2.8 offered for gutsy? >> > > well, not that i can find > Shame. I don't know why they haven't included this as I think AUI is (since 2.8) part of the default build of Wx. >> http://wxruby.rubyforge.org/wiki/wiki.pl?HowToBuildWxWidgets >> > > ok - will give this a go. will this interfere with any packaged ubuntu wx > widgets? > That I don't know - I use Ubuntu but haven't tried their Wx packages. Do you have other packages installed which depend on wx2.8? Also, what does 'which wx-config' return on your system at the moment? By default, a standard wx build installs in /usr/local, so I expect you might be able to have multiple versions cohabiting. alex From glenn at tangelosoftware.net Tue Aug 21 09:30:33 2007 From: glenn at tangelosoftware.net (Glenn Davy) Date: Tue, 21 Aug 2007 23:30:33 +1000 Subject: [Wxruby-users] installing on X86_64 - unable to build In-Reply-To: <46CAAEDD.8020302@pressure.to> References: <200708211151.59740.glenn@tangelosoftware.net> <46CAAEDD.8020302@pressure.to> Message-ID: <200708212330.33519.glenn@tangelosoftware.net> On Tue, 21 Aug 2007 07:22:37 pm Alex Fenton wrote: > Hi Glenn Hi again alex > > http://wxruby.rubyforge.org/wiki/wiki.pl?HowToBuildWxWidgets on this topic... that article suggests it might be best to build from your distros own source version of wx widgets. are you ( or anyone else able to tell me, once i install libwxbase*dev and libwxgtk*-dev, yes the headers are in /usr/include/wx... but does this also install the source files? and if so where to i find them so i can do a make? if not, what package installs the ubuntu 'source' version of libwxBla?, or should i just get the wxX11 source off the web site? I notice the debian binaries of wxwidgets are available there (which i'll install in preference to whats shipped with ubuntu, just to see what gives), but no equivalent for the source. any hints relished. glenn > > cheers > alex > > > _______________________________________________ > wxruby-users mailing list > wxruby-users at rubyforge.org > http://rubyforge.org/mailman/listinfo/wxruby-users From alex at pressure.to Wed Aug 22 05:00:02 2007 From: alex at pressure.to (Alex Fenton) Date: Wed, 22 Aug 2007 10:00:02 +0100 Subject: [Wxruby-users] installing on X86_64 - unable to build In-Reply-To: <200708212330.33519.glenn@tangelosoftware.net> References: <200708211151.59740.glenn@tangelosoftware.net> <46CAAEDD.8020302@pressure.to> <200708212330.33519.glenn@tangelosoftware.net> Message-ID: <46CBFB12.9030405@pressure.to> Glenn Davy wrote: >> http://wxruby.rubyforge.org/wiki/wiki.pl?HowToBuildWxWidgets >> > > on this topic... > that article suggests it might be best to build from your distros own source > version of wx widgets. I don't that wxruby page is intended to suggest that - or did you mean a different article? Anyway, I've realised it's got unclear with edits, so I'll tidy up that page. The question there is just about some of the support libraries (eg libpng, libtiff, libjpeg) of which there are bundled versions included with WxWidgets. The recommendation for distributors is to force the use of the Wx versions, whereas those building for their own use only may want to allow Wx to link to their system versions. if they exist. > are you ( or anyone else able to tell me, once i > install libwxbase*dev and libwxgtk*-dev, yes the headers are > in /usr/include/wx... but does this also install the source files? and if so > where to i find them so i can do a make? if not, what package installs the > ubuntu 'source' version of libwxBla?, I don't know the answer to either of these questions, sorry, or even if there is a source package. > or should i just get the wxX11 source > off the web site? > No, don't use wxX11 - wxWidgets on X11 is very limited compared to GTK. I would simply download the wxGTK source from wxWidgets and build that, if you don't have any distro packages that depend on the Ubuntu wx packages. alex From kazaam at oleco.net Wed Aug 22 13:39:17 2007 From: kazaam at oleco.net (kazaam) Date: Wed, 22 Aug 2007 19:39:17 +0200 Subject: [Wxruby-users] Can't change button-size? Message-ID: <20070822193917.ca03cfb0.kazaam@oleco.net> Hi, I tried my first steps with wxruby today and I have a problem. I read the doc and wanted to add a button but no matter what I do the button has always the size of the whole frame also if I told him another size like in this example in which I gave him this size button = Button.new(self, -1, "Push me",Point.new(10,10),Size.new(50,10)) but it always has the size of the whole frame?: #!/usr/bin/env ruby $Verbose=true require 'rubygems' require 'wx' include Wx class MyFrame < Frame def initialize super(nil, -1, "Threepwood",Point.new(400,250),Size.new(600,200),DEFAULT_FRAME_STYLE) button = Button.new(self, -1, "Push me",Point.new(10,10),Size.new(50,10)) evt_button(button.get_id()) {|event| on_button(event)} show() end def message(text, title) m = Wx::MessageDialog.new(self, text, title, Wx::OK | Wx::ICON_INFORMATION) m.show_modal() end def on_button(event) message("event recieved!!", "Button event") end end class MinimalApp < App def on_init MyFrame.new end end MinimalApp.new.main_loop #eof Can someone help me with this? greets -- kazaam From alex at pressure.to Wed Aug 22 17:51:49 2007 From: alex at pressure.to (Alex Fenton) Date: Wed, 22 Aug 2007 22:51:49 +0100 Subject: [Wxruby-users] Can't change button-size? In-Reply-To: <20070822193917.ca03cfb0.kazaam@oleco.net> References: <20070822193917.ca03cfb0.kazaam@oleco.net> Message-ID: <46CCAFF5.1070803@pressure.to> kazaam wrote: > Hi, > I tried my first steps with wxruby today and I have a problem. I read the doc and wanted to add a button but no matter what I do the button has always the size of the whole frame also if I told him another size like in this example in which I gave him this size button = Button.new(self, -1, "Push me",Point.new(10,10),Size.new(50,10)) but it always has the size of the whole frame? In initialize, try: panel = Panel.new(self) button = Button.new(panel, ...) I think, if a Frame has only one child widget, the child widget is sized to fit the whole available space in the frame cheers alex From kazaam at oleco.net Thu Aug 23 03:57:37 2007 From: kazaam at oleco.net (kazaam) Date: Thu, 23 Aug 2007 09:57:37 +0200 Subject: [Wxruby-users] Can't change button-size? In-Reply-To: <46CCAFF5.1070803@pressure.to> References: <20070822193917.ca03cfb0.kazaam@oleco.net> <46CCAFF5.1070803@pressure.to> Message-ID: <20070823095737.d0b59061.kazaam@oleco.net> hey thanks that solved my problem :) On Wed, 22 Aug 2007 22:51:49 +0100 Alex Fenton wrote: > kazaam wrote: > > Hi, > > I tried my first steps with wxruby today and I have a problem. I read the doc and wanted to add a button but no matter what I do the button has always the size of the whole frame also if I told him another size like in this example in which I gave him this size button = Button.new(self, -1, "Push me",Point.new(10,10),Size.new(50,10)) but it always has the size of the whole frame? > In initialize, try: > > panel = Panel.new(self) > button = Button.new(panel, ...) > > I think, if a Frame has only one child widget, the child widget is sized > to fit the whole available space in the frame > > cheers > alex > _______________________________________________ > wxruby-users mailing list > wxruby-users at rubyforge.org > http://rubyforge.org/mailman/listinfo/wxruby-users -- kazaam From kazaam at oleco.net Thu Aug 23 05:40:07 2007 From: kazaam at oleco.net (kazaam) Date: Thu, 23 Aug 2007 11:40:07 +0200 Subject: [Wxruby-users] TaskBarIcon gives Typerror Message-ID: <20070823114007.b29c5f10.kazaam@oleco.net> Hi, I'm working with wxruby since 2 days but next to this Wiki: http://wxruby.rubyforge.org/wiki/wiki.pl and this Doc: http://wxruby.rubyforge.org/doc/ I couldn't find something usefull for it. Also del.icio.us has no intresting links. Do you know any good website or book about wxruby? My problem at the moment is, I wanna test the TaskBarIcon on Gnome and so I did: #!/usr/bin/env ruby $Verbose=true require 'rubygems' require 'wx' include Wx class MinimalApp < App def on_init mytask = TaskBarIcon.new mytask.set_icon('shutdown.svg','thats my tooltip') end end MinimalApp.new.main_loop #eof the doc tells about set_icon: Boolean set_icon(Icon icon, String tooltip) Sets the icon, and optional tooltip text. shutdown.svg is an Icon and next to it comes a string, so it should be right or? But executed I'm always getting this error: ./task.rb:15:in `set_icon': in method 'SetIcon', argument 2 of type 'wxIcon const &' (TypeError) from ./task.rb:15:in `on_init' from ./task.rb:21:in `main_loop' from ./task.rb:21 Someone knows why this happens? greets -- kazaam From mario at ruby-im.net Thu Aug 23 05:46:10 2007 From: mario at ruby-im.net (Mario Steele) Date: Thu, 23 Aug 2007 04:46:10 -0500 Subject: [Wxruby-users] TaskBarIcon gives Typerror In-Reply-To: <20070823114007.b29c5f10.kazaam@oleco.net> References: <20070823114007.b29c5f10.kazaam@oleco.net> Message-ID: <46CD5762.8010802@ruby-im.net> Hello Kazaam, Afraid that there isn't much documentation towards wxRuby, aside from the wiki and doc on those links you have provided already. The problem with what is going on with your file, is that you first need to create/load an icon, before you can pass it to TaskBarIcon#set_icon(). To do this, there is one of two ways, you create the icon via Wx::Icon.load(filename) or Wx::Icon.new(filename). WxRuby can only handle certian file formats, and I don't know if SVG is one of those or not. You will need to check and see if SVG is enabled. The Second method, is you can indirectly load a Bitmap first, then create an Icon for the next part. Example being: bitmap = Wx::Bitmap.load("mybitmap.ext") icon = Wx::Icon.new(bitmap) This is not a comprehensive example of how this works, but gives you the ground work in which to make what you want done, to get there. Have fun, and always feel free to ask for help from here, someone is bound to answer. ;-) Mario Steele kazaam wrote: > Hi, > I'm working with wxruby since 2 days but next to this Wiki: http://wxruby.rubyforge.org/wiki/wiki.pl and this Doc: http://wxruby.rubyforge.org/doc/ I couldn't find something usefull for it. Also del.icio.us has no intresting links. Do you know any good website or book about wxruby? > > My problem at the moment is, I wanna test the TaskBarIcon on Gnome and so I did: > > #!/usr/bin/env ruby > > $Verbose=true > > require 'rubygems' > require 'wx' > > include Wx > > > class MinimalApp < App > > def on_init > mytask = TaskBarIcon.new > mytask.set_icon('shutdown.svg','thats my tooltip') > end > > end > > > MinimalApp.new.main_loop > > #eof > > the doc tells about set_icon: > Boolean set_icon(Icon icon, String tooltip) > Sets the icon, and optional tooltip text. > > shutdown.svg is an Icon and next to it comes a string, so it should be right or? But executed I'm always getting this error: > > ./task.rb:15:in `set_icon': in method 'SetIcon', argument 2 of type 'wxIcon const &' (TypeError) > from ./task.rb:15:in `on_init' > from ./task.rb:21:in `main_loop' > from ./task.rb:21 > > Someone knows why this happens? > > greets > > > From kazaam at oleco.net Thu Aug 23 05:59:15 2007 From: kazaam at oleco.net (kazaam) Date: Thu, 23 Aug 2007 11:59:15 +0200 Subject: [Wxruby-users] TaskBarIcon gives Typerror In-Reply-To: <46CD5762.8010802@ruby-im.net> References: <20070823114007.b29c5f10.kazaam@oleco.net> <46CD5762.8010802@ruby-im.net> Message-ID: <20070823115915.c4c5b9a4.kazaam@oleco.net> Hi Mario thanks alot for your help! :) It works nice, also with *.svg files: #!/usr/bin/env ruby $Verbose=true require 'rubygems' require 'wx' include Wx class MinimalApp < App def on_init mytask = TaskBarIcon.new mytask.set_icon(Icon.new('shutdown.svg'),'test tooltip') end end MinimalApp.new.main_loop -- kazaam From alex at pressure.to Thu Aug 23 06:14:49 2007 From: alex at pressure.to (Alex Fenton) Date: Thu, 23 Aug 2007 11:14:49 +0100 Subject: [Wxruby-users] TaskBarIcon gives Typerror In-Reply-To: <20070823114007.b29c5f10.kazaam@oleco.net> References: <20070823114007.b29c5f10.kazaam@oleco.net> Message-ID: <46CD5E19.5010901@pressure.to> kazaam wrote: > the doc tells about set_icon: > Boolean set_icon(Icon icon, String tooltip) > Mario's already given you a good answer, but just as a general hint in reading the wxRuby docs: - in the argument list, the grey capitalised first part of each argument (eg "Icon") is the ruby class of the object that's expected. So if it's "Icon", it wants a Wx::Icon, if it's "String" it wants a ruby String. > shutdown.svg is an Icon and next to it comes a string, so it should be right or? But executed I'm always getting this error: > Wow, cool, I never knew that wxRuby handled SVG icons. I expect this is GTK only though.. > ./task.rb:15:in `set_icon': in method 'SetIcon', argument 2 of type 'wxIcon const &' (TypeError) it's a bit confusing - "argument 2" here means the first argument to ruby - this is a SWIG idiocy that it reports errors from a C++ perspective... Though the class reference docs are pretty comprehensive, I know they're not always that helpful getting an overall idea of how to use a class. There is an excellent book on wxWidgets programming which used to be available as a free PDF. Although the examples are in C++, it's got lots and lots of ideas and detailed discussion of how the wxRuby classes work. Alex From kazaam at oleco.net Thu Aug 23 06:26:44 2007 From: kazaam at oleco.net (kazaam) Date: Thu, 23 Aug 2007 12:26:44 +0200 Subject: [Wxruby-users] TaskBarIcon gives Typerror In-Reply-To: <20070823115915.c4c5b9a4.kazaam@oleco.net> References: <20070823114007.b29c5f10.kazaam@oleco.net> <46CD5762.8010802@ruby-im.net> <20070823115915.c4c5b9a4.kazaam@oleco.net> Message-ID: <20070823122644.2b1c7cd9.kazaam@oleco.net> Another question: someone knows any apps already written with wxruby? I'd like to read them to learn from them. The doc is definitivly not enough for me.. Right now I'm trying a popup-menu when clicking on the taskbaricon but the doc tells: It is recommended to override create_popup_icon callback instead of calling this method from event handler, because some ports (e.g. Cocoa) may not implement PopupMenu and mouse click events at all. Alright "override create_popup_icon callback" sounds like chinese to me :))) It would really help reading some example-codes or -programs but I can't find any with google. Can someone point me to any code? greets -- kazaam From kazaam at oleco.net Thu Aug 23 06:30:49 2007 From: kazaam at oleco.net (kazaam) Date: Thu, 23 Aug 2007 12:30:49 +0200 Subject: [Wxruby-users] TaskBarIcon gives Typerror In-Reply-To: <46CD5E19.5010901@pressure.to> References: <20070823114007.b29c5f10.kazaam@oleco.net> <46CD5E19.5010901@pressure.to> Message-ID: <20070823123049.13845fbb.kazaam@oleco.net> k thanks, I will look for this pdf-file on wxwidgets although my c++ is nearly enough for an "hello-world", I'll give it a try. greets On Thu, 23 Aug 2007 11:14:49 +0100 Alex Fenton wrote: > kazaam wrote: > > the doc tells about set_icon: > > Boolean set_icon(Icon icon, String tooltip) > > > Mario's already given you a good answer, but just as a general hint in > reading the wxRuby docs: - in the argument list, the grey capitalised > first part of each argument (eg "Icon") is the ruby class of the object > that's expected. So if it's "Icon", it wants a Wx::Icon, if it's > "String" it wants a ruby String. > > shutdown.svg is an Icon and next to it comes a string, so it should be right or? But executed I'm always getting this error: > > > Wow, cool, I never knew that wxRuby handled SVG icons. I expect this is > GTK only though.. > > ./task.rb:15:in `set_icon': in method 'SetIcon', argument 2 of type 'wxIcon const &' (TypeError) > it's a bit confusing - "argument 2" here means the first argument to > ruby - this is a SWIG idiocy that it reports errors from a C++ > perspective... > > Though the class reference docs are pretty comprehensive, I know they're > not always that helpful getting an overall idea of how to use a class. > There is an excellent book on wxWidgets programming which used to be > available as a free PDF. Although the examples are in C++, it's got lots > and lots of ideas and detailed discussion of how the wxRuby classes work. > > Alex > > > _______________________________________________ > wxruby-users mailing list > wxruby-users at rubyforge.org > http://rubyforge.org/mailman/listinfo/wxruby-users -- kazaam From alex at pressure.to Thu Aug 23 06:32:25 2007 From: alex at pressure.to (Alex Fenton) Date: Thu, 23 Aug 2007 11:32:25 +0100 Subject: [Wxruby-users] TaskBarIcon gives Typerror In-Reply-To: <20070823122644.2b1c7cd9.kazaam@oleco.net> References: <20070823114007.b29c5f10.kazaam@oleco.net> <46CD5762.8010802@ruby-im.net> <20070823115915.c4c5b9a4.kazaam@oleco.net> <20070823122644.2b1c7cd9.kazaam@oleco.net> Message-ID: <46CD6239.70502@pressure.to> kazaam wrote: > Another question: someone knows any apps already written with wxruby? I'd like to read them to learn from them. The doc is definitivly not enough for me.. Right now I'm trying a popup-menu when clicking on the taskbaricon but the doc tells: > It is recommended to override create_popup_icon callback instead of calling this method from event handler, because some ports (e.g. Cocoa) may not implement PopupMenu and mouse click events at all. > Alright "override create_popup_icon callback" sounds like chinese to me :))) The best place to start is probably the wxruby samples. If you installed from a gem, these will be in your gems directory. There's illustrations of how to use almost all the GUI classes in there (although the code is sometimes a bit ugly) - when I want to remember how to use Wx:XXX I often just search for that class's name in those files. I know there is an illustration of how to create a popup menu with a TaskBarIcon in there (in samples/bigdemo.rb) There are a couple of bigger applications written using wxRuby - see here: http://wxruby.rubyforge.org/wiki/wiki.pl?OnlineCodeExamples or search rubyforge for 'wxruby' to turn up some other projects at various stages of development alex From kazaam at oleco.net Thu Aug 23 06:45:17 2007 From: kazaam at oleco.net (kazaam) Date: Thu, 23 Aug 2007 12:45:17 +0200 Subject: [Wxruby-users] TaskBarIcon gives Typerror In-Reply-To: <46CD6239.70502@pressure.to> References: <20070823114007.b29c5f10.kazaam@oleco.net> <46CD5762.8010802@ruby-im.net> <20070823115915.c4c5b9a4.kazaam@oleco.net> <20070823122644.2b1c7cd9.kazaam@oleco.net> <46CD6239.70502@pressure.to> Message-ID: <20070823124517.61c225e8.kazaam@oleco.net> And again thanks :) I found the samples and will start reading them now. greets On Thu, 23 Aug 2007 11:32:25 +0100 Alex Fenton wrote: > kazaam wrote: > > Another question: someone knows any apps already written with wxruby? I'd like to read them to learn from them. The doc is definitivly not enough for me.. Right now I'm trying a popup-menu when clicking on the taskbaricon but the doc tells: > > It is recommended to override create_popup_icon callback instead of calling this method from event handler, because some ports (e.g. Cocoa) may not implement PopupMenu and mouse click events at all. > > Alright "override create_popup_icon callback" sounds like chinese to me :))) > The best place to start is probably the wxruby samples. If you installed > from a gem, these will be in your gems directory. There's illustrations > of how to use almost all the GUI classes in there (although the code is > sometimes a bit ugly) - when I want to remember how to use Wx:XXX I > often just search for that class's name in those files. I know there is > an illustration of how to create a popup menu with a TaskBarIcon in > there (in samples/bigdemo.rb) > > There are a couple of bigger applications written using wxRuby - see here: > http://wxruby.rubyforge.org/wiki/wiki.pl?OnlineCodeExamples > > or search rubyforge for 'wxruby' to turn up some other projects at > various stages of development > > alex > > _______________________________________________ > wxruby-users mailing list > wxruby-users at rubyforge.org > http://rubyforge.org/mailman/listinfo/wxruby-users -- kazaam From fabio.petrucci at gmail.com Fri Aug 24 02:47:23 2007 From: fabio.petrucci at gmail.com (Fabio Petrucci) Date: Fri, 24 Aug 2007 08:47:23 +0200 Subject: [Wxruby-users] Choice append Message-ID: Ciao Alex, Is it possible to enable the overloaded method 'ControlWithItems#append' to be able to provide user data? to do this: ch = Wx::Choice.new() ch.append("pluto", 10) ch.append("pippo", 20) ch.append("paperino", 30) instead of this (the way i've found to get the same result): ch = Wx::Choice.new() id = ch.append("pluto") ch.set_item_data(id, 10) id = ch.append("pippo") ch.set_item_data(id, 20) id = ch.append("paperino") ch.set_item_data(id, 30) thank you. fabio. -------------- next part -------------- An HTML attachment was scrubbed... URL: http://rubyforge.org/pipermail/wxruby-users/attachments/20070824/c265c817/attachment.html From alex at pressure.to Fri Aug 24 04:47:01 2007 From: alex at pressure.to (Alex Fenton) Date: Fri, 24 Aug 2007 09:47:01 +0100 Subject: [Wxruby-users] Choice append In-Reply-To: References: Message-ID: <46CE9B05.2000609@pressure.to> Hi Fabio Fabio Petrucci wrote: > Is it possible to enable the overloaded method > 'ControlWithItems#append' to be able to provide user data? Yes, there's supposed to be versions of insert/append that allow you to set the client data at the same time, but for some reason they were disabled. I've committed a patch to enable those for the next release. Thanks for the report alex From alex at pressure.to Fri Aug 24 13:22:54 2007 From: alex at pressure.to (Alex Fenton) Date: Fri, 24 Aug 2007 18:22:54 +0100 Subject: [Wxruby-users] wxSugar 0.1.16 Message-ID: <46CF13EE.7090204@pressure.to> Hi all Just uploaded wxSugar 0.1.16 to rubyforge. This is a minor bugfix release to catch up with developments in the core wxRuby2 library. It's a recommended, though not urgent upgrade. Changes - Fixed a problem with keyword parameters for Wx::Gauge - Enabled keyword parameters for Wx::HyperlinkCtrl - Fixed an error with TreeCtrl#traverse when used with recent wxRuby2 releases cheers alex From alex at pressure.to Fri Aug 24 18:42:14 2007 From: alex at pressure.to (Alex Fenton) Date: Fri, 24 Aug 2007 23:42:14 +0100 Subject: [Wxruby-users] SURVEY: wxRuby API style Message-ID: <46CF5EC6.6020308@pressure.to> Hi As we're getting closer to a stable release of wxRuby, I'd like to get your views on the API style. There's a survey here: http://rubyforge.org/survey/survey.php?group_id=35&survey_id=66 I'd like to know if you'd like to see two wxSugar syntax features become part of core, standard wxRuby version 2.0. These are: 1) Allow ruby-style accessors as well as C++ style getters/setters. This means you can write frame.title = 'my frame' # as well as frame.set_title('my frame') or frame.title # as well as frame.get_title 2) Allow keyword constructors for window classes. This means you can write frame = Wx::Frame.new(parent, :title => 'foo', :style => Wx::DEFAULT_FRAME_STYLE) as well as frame = Wx::Frame.new(parent, -1, 'foo', Wx::DEFAULT_POSITION, Wx::DEFAULT_SIZE, Wx::DEFAULT_FRAME_STYLE) In both cases, these would be based on the current wxSugar implementation, which is 100% backwards compatible - no existing code would need to be changed. Please feel free to comment on this thread here also thanks alex From jacekwiktor at gmail.com Mon Aug 27 13:11:17 2007 From: jacekwiktor at gmail.com (Jacek Nowak) Date: Mon, 27 Aug 2007 19:11:17 +0200 Subject: [wxruby-users] Problem with ListCtrl#get_item Message-ID: <570d9b010708271011m220eea0cra1d3566577287686@mail.gmail.com> Hello, I have a problem with getting items from ListCtrl. Although my ListCtrl is in LC_REPORT mode, it has columns set up, every cell is set with set_item and everything displays fine, this code: x = myList.get_item(row,col).get_text() always returns an empty string. For example: myList.set_item(0,0,"Hello") x = myList.get_item(0,0).get_text() now x equals "" ! I don't know whether it is a bug in wxRuby or I'm doing something wrong. I have tried: x = myList.get_item_text(row) and it works but it always returns the element from the first column in a given row and I have no idea how to get elements from other columns. Thanks in advance for your help! -- Jacek Nowak jacekwiktor at gmail.com From teki321 at gmail.com Mon Aug 27 20:03:39 2007 From: teki321 at gmail.com (Bela Babik) Date: Tue, 28 Aug 2007 10:03:39 +1000 Subject: [wxruby-users] Problem with ListCtrl#get_item In-Reply-To: <570d9b010708271011m220eea0cra1d3566577287686@mail.gmail.com> References: <570d9b010708271011m220eea0cra1d3566577287686@mail.gmail.com> Message-ID: I can reproduce it. It seems to be a wxListItem related problem. The list controls function gives back a copy of the string: wxString GetItemText(long item ) const; But wxListItem gives back a string reference, this can be the cause of the problem: const wxString& GetText() const; Workaround: if you need to access the data later, use a virtual list. -- teki On 8/28/07, Jacek Nowak wrote: > Hello, > > I have a problem with getting items from ListCtrl. > > Although my ListCtrl is in LC_REPORT mode, it has columns set up, > every cell is set with set_item and everything displays fine, this > code: > > x = myList.get_item(row,col).get_text() > > always returns an empty string. > > For example: > > myList.set_item(0,0,"Hello") > x = myList.get_item(0,0).get_text() > > now x equals "" ! > > I don't know whether it is a bug in wxRuby or I'm doing something wrong. > > I have tried: > > x = myList.get_item_text(row) > > and it works but it always returns the element from the first column > in a given row and I have no idea how to get elements from other > columns. > > Thanks in advance for your help! > > -- > Jacek Nowak > jacekwiktor at gmail.com > _______________________________________________ > wxruby-users mailing list > wxruby-users at rubyforge.org > http://rubyforge.org/mailman/listinfo/wxruby-users > From alex at pressure.to Tue Aug 28 07:55:44 2007 From: alex at pressure.to (Alex Fenton) Date: Tue, 28 Aug 2007 12:55:44 +0100 Subject: [wxruby-users] Problem with ListCtrl#get_item In-Reply-To: <570d9b010708271011m220eea0cra1d3566577287686@mail.gmail.com> References: <570d9b010708271011m220eea0cra1d3566577287686@mail.gmail.com> Message-ID: <46D40D40.8050300@pressure.to> Hi Jacek Jacek Nowak wrote: > I have a problem with getting items from ListCtrl. > > Although my ListCtrl is in LC_REPORT mode, it has columns set up, > every cell is set with set_item and everything displays fine, this > code: > > x = myList.get_item(row,col).get_text() > > always returns an empty string. > Thanks for the report - looks like a bug to me on Windows, at least. There seems to be a few oddities with the behaviour of ListCtrl at the moment (eg setting set_text_colour and then set_text doesn't seem to work), so I'll have a look into this on the debug build shortly. alex From alex at pressure.to Tue Aug 28 18:07:37 2007 From: alex at pressure.to (Alex Fenton) Date: Tue, 28 Aug 2007 23:07:37 +0100 Subject: [wxruby-users] Problem with ListCtrl#get_item In-Reply-To: <570d9b010708271011m220eea0cra1d3566577287686@mail.gmail.com> References: <570d9b010708271011m220eea0cra1d3566577287686@mail.gmail.com> Message-ID: <46D49CA9.9080308@pressure.to> Jacek Nowak wrote: > Although my ListCtrl is in LC_REPORT mode, it has columns set up, > every cell is set with set_item and everything displays fine, this > code: > > x = myList.get_item(row,col).get_text() > > always returns an empty string. > Just to follow up: I pinned down the bug and have just applied a patch to SVN to fix it for the next 1.9.1 release. This hopefully won't be too far off as we're hoping to get bugfix builds out quite frequently in the run up to 2.0. As this wiki page says, the API to get a cell's contents 'is somewhat rough for a newcomer': http://www.wxwidgets.org/wiki/index.php/WxListCtrl#Get_the_string_contents_of_a_.22cell.22_in_a_LC_REPORT_wxListCtrl thanks again for the report alex From alex at pressure.to Wed Aug 29 18:21:14 2007 From: alex at pressure.to (Alex Fenton) Date: Wed, 29 Aug 2007 23:21:14 +0100 Subject: [wxruby-users] [Wxruby-users] Last chance: SURVEY: wxRuby API style In-Reply-To: <46CF5EC6.6020308@pressure.to> References: <46CF5EC6.6020308@pressure.to> Message-ID: <46D5F15A.90007@pressure.to> Hi Just a reminder to vote soon on the API style survey here: http://rubyforge.org/survey/survey.php?group_id=35&survey_id=66 we'll be closing voting at the beginning of next week and announcing the results, so please do get your vote in and let us know what direction you'd like wxRuby to go... thanks alex Alex Fenton wrote: > As we're getting closer to a stable release of wxRuby, I'd like to get > your views on the API style. There's a survey here: > > http://rubyforge.org/survey/survey.php?group_id=35&survey_id=66 > > I'd like to know if you'd like to see two wxSugar syntax features become > part of core, standard wxRuby version 2.0. These are: > > 1) Allow ruby-style accessors as well as C++ style getters/setters. This > means you can write > > frame.title = 'my frame' > # as well as > frame.set_title('my frame') > > or > frame.title > # as well as > frame.get_title > > 2) Allow keyword constructors for window classes. This means you can write > > frame = Wx::Frame.new(parent, :title => 'foo', :style => > Wx::DEFAULT_FRAME_STYLE) > as well as > frame = Wx::Frame.new(parent, -1, 'foo', Wx::DEFAULT_POSITION, > Wx::DEFAULT_SIZE, Wx::DEFAULT_FRAME_STYLE) > > In both cases, these would be based on the current wxSugar > implementation, which is 100% backwards compatible - no existing code > would need to be changed. > > Please feel free to comment on this thread here also > > thanks > alex > > _______________________________________________ > wxruby-users mailing list > wxruby-users at rubyforge.org > http://rubyforge.org/mailman/listinfo/wxruby-users > From lancecarlson at gmail.com Wed Aug 29 19:13:27 2007 From: lancecarlson at gmail.com (Lance Carlson) Date: Wed, 29 Aug 2007 19:13:27 -0400 Subject: [wxruby-users] [Wxruby-users] Last chance: SURVEY: wxRuby API style In-Reply-To: <46D5F15A.90007@pressure.to> References: <46CF5EC6.6020308@pressure.to> <46D5F15A.90007@pressure.to> Message-ID: <49f64a900708291613m2a8255c6p5966d76d37e7409a@mail.gmail.com> Already voted :) On 8/29/07, Alex Fenton wrote: > Hi > > Just a reminder to vote soon on the API style survey here: > > http://rubyforge.org/survey/survey.php?group_id=35&survey_id=66 > > we'll be closing voting at the beginning of next week and announcing the > results, so please do get your vote in and let us know what direction > you'd like wxRuby to go... > > thanks > alex > > Alex Fenton wrote: > > As we're getting closer to a stable release of wxRuby, I'd like to get > > your views on the API style. There's a survey here: > > > > http://rubyforge.org/survey/survey.php?group_id=35&survey_id=66 > > > > I'd like to know if you'd like to see two wxSugar syntax features become > > part of core, standard wxRuby version 2.0. These are: > > > > 1) Allow ruby-style accessors as well as C++ style getters/setters. This > > means you can write > > > > frame.title = 'my frame' > > # as well as > > frame.set_title('my frame') > > > > or > > frame.title > > # as well as > > frame.get_title > > > > 2) Allow keyword constructors for window classes. This means you can write > > > > frame = Wx::Frame.new(parent, :title => 'foo', :style => > > Wx::DEFAULT_FRAME_STYLE) > > as well as > > frame = Wx::Frame.new(parent, -1, 'foo', Wx::DEFAULT_POSITION, > > Wx::DEFAULT_SIZE, Wx::DEFAULT_FRAME_STYLE) > > > > In both cases, these would be based on the current wxSugar > > implementation, which is 100% backwards compatible - no existing code > > would need to be changed. > > > > Please feel free to comment on this thread here also > > > > thanks > > alex > > > > _______________________________________________ > > wxruby-users mailing list > > wxruby-users at rubyforge.org > > http://rubyforge.org/mailman/listinfo/wxruby-users > > > > _______________________________________________ > wxruby-users mailing list > wxruby-users at rubyforge.org > http://rubyforge.org/mailman/listinfo/wxruby-users > From lancecarlson at gmail.com Thu Aug 30 16:51:16 2007 From: lancecarlson at gmail.com (Lance Carlson) Date: Thu, 30 Aug 2007 16:51:16 -0400 Subject: [wxruby-users] Fwd: Anvil: an application framework In-Reply-To: <49f64a900708291504j544f0b4y3798f9f78df5f4ec@mail.gmail.com> References: <388732552-1186969832-cardhu_decombobulator_blackberry.rim.net-61544281-@bxe124.bisx.prod.on.blackberry> <46D54CC0.8030905@pressure.to> <49f64a900708291504j544f0b4y3798f9f78df5f4ec@mail.gmail.com> Message-ID: <49f64a900708301351y2514d6bdpcb704c711aa90462@mail.gmail.com> just forwarding this conversation to the list as it should be published! :) Hi mate Lance Carlson wrote: > It is going well, (although I could use some help) Looks like you're really making progress. I'm pretty maxed out with core wxRuby development, but don't hesitate to ask for help on the dev list. There's a lot of indicators of increasing interest in wxRuby over the past 12 months, so once you're ready, I'd say a good-looking offer on the ruby mailing list might well draw in some developers. > I've got MVC setup, > though I'm not sure exactly if the way I've done the MVC is the best > way to do it. I've also been extending all of the wxruby classes to > make them more ruby-esk and also created a :render option inside all > of the methods so you can do the rails equivalent of partials. I don't know a huge amount about MVC and have only used rails for toy applications (though I used to be web dev, before rails existed...). So I probably can't help much here. > The > problem I think though is that views in application development are > not used so much and I think more and more people are using GUIs to > take care of interfaces.. is this a correct assumption or should I > continue to extend wx ruby to include this new syntax? I kind of like where that it is going, though it's quite a paradigm jump from core wxRuby ... but ... > If there is a need for a purely coded way to create views than I will > continue my extension of wx::ruby for views with an :xml => option > available, but otherwise I will just use wx's XML exclusively. I think you're right that it's increasing popular to use IDEs to design GUI interfaces. From that, I would say there's a really big win in making Wx's XRC interface much more ruby-ish. All that find_element_by_id etc is clumsy. If there was a nice "DSLish" way to load an XRC file, and attach event handlers and behaviours to the elements initially designed in an IDE and stored in XRC, that would be very interesting. > Once > this interface decision is decided (I could use some input from > everyone on this list) (btw, this isn't on the list) > I will continue to build out hamr using the > anvil framework and include examples on what I did to create the > application. Totally agree that's the best way to develop the framework - through trying to build an app. That's where almost everything that's now part of wxSugar came from - ideas initially developed in relation to Weft QDA. > I can see a lot of the things I'm doing helping out the > wx::ruby community a great deal and almost feel like parts of the > framework should be integrated into wx::sugar or wx::ruby. Thoughts? > Yes, additions to wxSugar would be very welcome. The normal way is to submit diff patches on the wxruby-development list. all the best alex ---------- Forwarded message ---------- From: Lance Carlson Date: Aug 29, 2007 6:04 PM Subject: Re: Anvil: an application framework To: Alex Fenton It is going well, (although I could use some help) I've got MVC setup, though I'm not sure exactly if the way I've done the MVC is the best way to do it. I've also been extending all of the wxruby classes to make them more ruby-esk and also created a :render option inside all of the methods so you can do the rails equivalent of partials. The problem I think though is that views in application development are not used so much and I think more and more people are using GUIs to take care of interfaces.. is this a correct assumption or should I continue to extend wx ruby to include this new syntax? (an example of the syntax can be found on my blog here: http://grasprubyonrails.com/2007/8/16/mvc-support-and-view-rendering-in-anvil). If there is a need for a purely coded way to create views than I will continue my extension of wx::ruby for views with an :xml => option available, but otherwise I will just use wx's XML exclusively. Once this interface decision is decided (I could use some input from everyone on this list) I will continue to build out hamr using the anvil framework and include examples on what I did to create the application. On agenda after that will be an anvil generator that will automatically create the files necessary to get going with an anvil application. I can see a lot of the things I'm doing helping out the wx::ruby community a great deal and almost feel like parts of the framework should be integrated into wx::sugar or wx::ruby. Thoughts? Suggestions? Criticisms? On 8/29/07, Alex Fenton wrote: > Hi Lance > > How's it going? Be interested to hear at some point more about your > ideas for Anvil. > > Just to let you know that I moved the Anvil info on the wxRuby wiki from > the front page to here: > http://wxruby.rubyforge.org/wiki/wiki.pl?OnlineCodeExamples > > This is simply because at obviously Anvil is right now at a very early > stage in development with no releases or documentation. As it matures > and gains acceptance I'd be happy to feature it more prominently. > > best wishes > alex > > lancecarlson at gmail.com wrote: > > Hi everyone! I have been working on idea for an application framework in ruby the wraps around the wx ruby gem. The goal is to make a framework that is as easy as rails create applications using concise and dry ruby code. We are in need of some experienced help! If you are interested checkout the project on ruby forge. Anvil.rubyforge.com and the irc channel is #rubyanvil on irc . My buck on irc is d2dchat. I look forward to all the input everyone could provide! > > > > -Lance Carlson > > Sent via BlackBerry from T-Mobile > > > > _______________________________________________ > > wxruby-users mailing list > > wxruby-users at rubyforge.org > > http://rubyforge.org/mailman/listinfo/wxruby-users > > > > From lancecarlson at gmail.com Thu Aug 30 16:56:20 2007 From: lancecarlson at gmail.com (Lance Carlson) Date: Thu, 30 Aug 2007 16:56:20 -0400 Subject: [wxruby-users] Anvil: an application framework In-Reply-To: <49f64a900708301351y2514d6bdpcb704c711aa90462@mail.gmail.com> References: <388732552-1186969832-cardhu_decombobulator_blackberry.rim.net-61544281-@bxe124.bisx.prod.on.blackberry> <46D54CC0.8030905@pressure.to> <49f64a900708291504j544f0b4y3798f9f78df5f4ec@mail.gmail.com> <49f64a900708301351y2514d6bdpcb704c711aa90462@mail.gmail.com> Message-ID: <49f64a900708301356w2c1e04abpe3dc7d28b6f01726@mail.gmail.com> Hey Alex Me: > > The > > problem I think though is that views in application development are > > not used so much and I think more and more people are using GUIs to > > take care of interfaces.. is this a correct assumption or should I > > continue to extend wx ruby to include this new syntax? Alex: > I kind of like where that it is going, though it's quite a paradigm jump > from core wxRuby ... but ... Me: > > If there is a need for a purely coded way to create views than I will > > continue my extension of wx::ruby for views with an :xml => option > > available, but otherwise I will just use wx's XML exclusively. Alex: > I think you're right that it's increasing popular to use IDEs to design > GUI interfaces. From that, I would say there's a really big win in > making Wx's XRC interface much more ruby-ish. All that > find_element_by_id etc is clumsy. If there was a nice "DSLish" way to > load an XRC file, and attach event handlers and behaviours to the > elements initially designed in an IDE and stored in XRC, that would be > very interesting. So does that mean that you think I should continue building out my DSL or I should shift my focus on creating the framework to wrap our Wx's XRC XML? On 8/30/07, Lance Carlson wrote: > just forwarding this conversation to the list as it should be published! :) > > Hi mate > > Lance Carlson wrote: > > It is going well, (although I could use some help) > Looks like you're really making progress. I'm pretty maxed out with core > wxRuby development, but don't hesitate to ask for help on the dev list. > > There's a lot of indicators of increasing interest in wxRuby over the > past 12 months, so once you're ready, I'd say a good-looking offer on > the ruby mailing list might well draw in some developers. > > > I've got MVC setup, > > though I'm not sure exactly if the way I've done the MVC is the best > > way to do it. I've also been extending all of the wxruby classes to > > make them more ruby-esk and also created a :render option inside all > > of the methods so you can do the rails equivalent of partials. > I don't know a huge amount about MVC and have only used rails for toy > applications (though I used to be web dev, before rails existed...). So > I probably can't help much here. > > > The > > problem I think though is that views in application development are > > not used so much and I think more and more people are using GUIs to > > take care of interfaces.. is this a correct assumption or should I > > continue to extend wx ruby to include this new syntax? > I kind of like where that it is going, though it's quite a paradigm jump > from core wxRuby ... but ... > > If there is a need for a purely coded way to create views than I will > > continue my extension of wx::ruby for views with an :xml => option > > available, but otherwise I will just use wx's XML exclusively. > I think you're right that it's increasing popular to use IDEs to design > GUI interfaces. From that, I would say there's a really big win in > making Wx's XRC interface much more ruby-ish. All that > find_element_by_id etc is clumsy. If there was a nice "DSLish" way to > load an XRC file, and attach event handlers and behaviours to the > elements initially designed in an IDE and stored in XRC, that would be > very interesting. > > Once > > this interface decision is decided (I could use some input from > > everyone on this list) > (btw, this isn't on the list) > > I will continue to build out hamr using the > > anvil framework and include examples on what I did to create the > > application. > Totally agree that's the best way to develop the framework - through > trying to build an app. That's where almost everything that's now part > of wxSugar came from - ideas initially developed in relation to Weft QDA. > > I can see a lot of the things I'm doing helping out the > > wx::ruby community a great deal and almost feel like parts of the > > framework should be integrated into wx::sugar or wx::ruby. Thoughts? > > > Yes, additions to wxSugar would be very welcome. The normal way is to > submit diff patches on the wxruby-development list. > > all the best > alex > > ---------- Forwarded message ---------- > From: Lance Carlson > Date: Aug 29, 2007 6:04 PM > Subject: Re: Anvil: an application framework > To: Alex Fenton > > > It is going well, (although I could use some help) I've got MVC setup, > though I'm not sure exactly if the way I've done the MVC is the best > way to do it. I've also been extending all of the wxruby classes to > make them more ruby-esk and also created a :render option inside all > of the methods so you can do the rails equivalent of partials. The > problem I think though is that views in application development are > not used so much and I think more and more people are using GUIs to > take care of interfaces.. is this a correct assumption or should I > continue to extend wx ruby to include this new syntax? (an example of > the syntax can be found on my blog here: > http://grasprubyonrails.com/2007/8/16/mvc-support-and-view-rendering-in-anvil). > If there is a need for a purely coded way to create views than I will > continue my extension of wx::ruby for views with an :xml => option > available, but otherwise I will just use wx's XML exclusively. Once > this interface decision is decided (I could use some input from > everyone on this list) I will continue to build out hamr using the > anvil framework and include examples on what I did to create the > application. On agenda after that will be an anvil generator that will > automatically create the files necessary to get going with an anvil > application. I can see a lot of the things I'm doing helping out the > wx::ruby community a great deal and almost feel like parts of the > framework should be integrated into wx::sugar or wx::ruby. Thoughts? > Suggestions? Criticisms? > > On 8/29/07, Alex Fenton wrote: > > Hi Lance > > > > How's it going? Be interested to hear at some point more about your > > ideas for Anvil. > > > > Just to let you know that I moved the Anvil info on the wxRuby wiki from > > the front page to here: > > http://wxruby.rubyforge.org/wiki/wiki.pl?OnlineCodeExamples > > > > This is simply because at obviously Anvil is right now at a very early > > stage in development with no releases or documentation. As it matures > > and gains acceptance I'd be happy to feature it more prominently. > > > > best wishes > > alex > > > > lancecarlson at gmail.com wrote: > > > Hi everyone! I have been working on idea for an application framework in ruby the wraps around the wx ruby gem. The goal is to make a framework that is as easy as rails create applications using concise and dry ruby code. We are in need of some experienced help! If you are interested checkout the project on ruby forge. Anvil.rubyforge.com and the irc channel is #rubyanvil on irc . My buck on irc is d2dchat. I look forward to all the input everyone could provide! > > > > > > -Lance Carlson > > > Sent via BlackBerry from T-Mobile > > > > > > _______________________________________________ > > > wxruby-users mailing list > > > wxruby-users at rubyforge.org > > > http://rubyforge.org/mailman/listinfo/wxruby-users > > > > > > > > From alex at pressure.to Thu Aug 30 17:30:14 2007 From: alex at pressure.to (Alex Fenton) Date: Thu, 30 Aug 2007 22:30:14 +0100 Subject: [wxruby-users] Anvil: an application framework In-Reply-To: <49f64a900708301356w2c1e04abpe3dc7d28b6f01726@mail.gmail.com> References: <388732552-1186969832-cardhu_decombobulator_blackberry.rim.net-61544281-@bxe124.bisx.prod.on.blackberry> <46D54CC0.8030905@pressure.to> <49f64a900708291504j544f0b4y3798f9f78df5f4ec@mail.gmail.com> <49f64a900708301351y2514d6bdpcb704c711aa90462@mail.gmail.com> <49f64a900708301356w2c1e04abpe3dc7d28b6f01726@mail.gmail.com> Message-ID: <46D736E6.2010608@pressure.to> Lance Carlson wrote: >> I think you're right that it's increasing popular to use IDEs to design >> GUI interfaces. From that, I would say there's a really big win in >> making Wx's XRC interface much more ruby-ish. All that >> find_element_by_id etc is clumsy. If there was a nice "DSLish" way to >> load an XRC file, and attach event handlers and behaviours to the >> elements initially designed in an IDE and stored in XRC, that would be >> very interesting. >> > > So does that mean that you think I should continue building out my DSL > or I should shift my focus on creating the framework to wrap our Wx's > XRC XML? I think you should work on whatever you see as the biggest blocks to slick, easy application development in wxRuby at the moment. Others here who use wxRuby might well have views, and the dev team welcomes patches to improve the API. But improving wxRuby's XML/XRC API is something that's not being worked on at the moment; 'is there a good IDE / RAD solution for ruby GUI?' is a frequently asked question on comp.lang.ruby; and all the current wxRuby visual IDEs depend on XRC. So I think you could have some impact there. I haven't used them, but others have stated that some of the GUI builders for wxWidgets are excellent - eg DialogBlocks. best alex PS - I don't mind at all here - but as a general rule it's probably netiquette to ask before reposting an off-list discussion From lancecarlson at gmail.com Thu Aug 30 17:39:38 2007 From: lancecarlson at gmail.com (Lance Carlson) Date: Thu, 30 Aug 2007 17:39:38 -0400 Subject: [wxruby-users] Anvil: an application framework In-Reply-To: <46D736E6.2010608@pressure.to> References: <388732552-1186969832-cardhu_decombobulator_blackberry.rim.net-61544281-@bxe124.bisx.prod.on.blackberry> <46D54CC0.8030905@pressure.to> <49f64a900708291504j544f0b4y3798f9f78df5f4ec@mail.gmail.com> <49f64a900708301351y2514d6bdpcb704c711aa90462@mail.gmail.com> <49f64a900708301356w2c1e04abpe3dc7d28b6f01726@mail.gmail.com> <46D736E6.2010608@pressure.to> Message-ID: <49f64a900708301439m6e998fc8ra078df07d9569cf3@mail.gmail.com> I think that wxGlade, a python based widget editor is pretty good. It doesn't generate ruby code, but it does generate XRC which is parsable by wx::ruby I assume. i will take a look into wx::ruby's XML/XRC API and implement changes I think should be made to it in Anvil and will let you decide if you want to push off that functionality into Wx::Ruby. As for my netiquette, I wasn't thinking and I'm sorry :). I assumed our discussion was pretty important for the list. Even announcements of making changes to the wx::ruby wiki should be public IMO and I think your reasons for doing so are justified thus person memos are unnecessary. In the future however, if you email me directly I will remember to ask before I post! -regards, -Lance On 8/30/07, Alex Fenton wrote: > Lance Carlson wrote: > >> I think you're right that it's increasing popular to use IDEs to design > >> GUI interfaces. From that, I would say there's a really big win in > >> making Wx's XRC interface much more ruby-ish. All that > >> find_element_by_id etc is clumsy. If there was a nice "DSLish" way to > >> load an XRC file, and attach event handlers and behaviours to the > >> elements initially designed in an IDE and stored in XRC, that would be > >> very interesting. > >> > > > > So does that mean that you think I should continue building out my DSL > > or I should shift my focus on creating the framework to wrap our Wx's > > XRC XML? > I think you should work on whatever you see as the biggest blocks to > slick, easy application development in wxRuby at the moment. Others here > who use wxRuby might well have views, and the dev team welcomes patches > to improve the API. > > But improving wxRuby's XML/XRC API is something that's not being worked > on at the moment; 'is there a good IDE / RAD solution for ruby GUI?' is > a frequently asked question on comp.lang.ruby; and all the current > wxRuby visual IDEs depend on XRC. So I think you could have some impact > there. > > I haven't used them, but others have stated that some of the GUI > builders for wxWidgets are excellent - eg DialogBlocks. > > best > alex > > PS - I don't mind at all here - but as a general rule it's probably > netiquette to ask before reposting an off-list discussion > _______________________________________________ > wxruby-users mailing list > wxruby-users at rubyforge.org > http://rubyforge.org/mailman/listinfo/wxruby-users >