From lyle at knology.net Fri Feb 2 11:20:53 2007 From: lyle at knology.net (Lyle Johnson) Date: Fri, 2 Feb 2007 10:20:53 -0600 Subject: [fxruby-users] This FXTextField * already release In-Reply-To: <6C0CF58A187DA5479245E0830AF84F4218CD5C@poweredge.attiksystem.ch> References: <5E66212B-C707-4F16-B33F-CA4D7BCEF86D@knology.net> <6C0CF58A187DA5479245E0830AF84F421D1703@poweredge.attiksystem.ch> <6C0CF58A187DA5479245E0830AF84F421D1706@poweredge.attiksystem.ch> <6C0CF58A187DA5479245E0830AF84F4218CD3F@poweredge.attiksystem.ch> <6C0CF58A187DA5479245E0830AF84F4218CD5C@poweredge.attiksystem.ch> Message-ID: <5CAED8FB-AFBF-42B6-BE53-ACA4CFB677C8@knology.net> On Jan 31, 2007, at 10:18 AM, Philippe Lang wrote: > I told you about this stange bug I have rarely, and that crashes my > FXRuby application. It happened a few times again since last time, and > mostly when code is doing something with a modal FXDialogBox, and > especially closing it. > > I made a modification in my code, so we'll see if it changes anything, > but before that, I'd like to know if it sounds "plausible" to you: > > Until now, I was closing my dialogs (from within the dialog itself) > with: > > self.handle(self, FXSEL(SEL_COMMAND, ID_ACCEPT), nil) > > I have tried changing this into: > > close > $app.stopModal > > (where $app is my application global object) > > I do this because I have the impression that some code could still be > executing WHILE the dialog is closing, which could yield to > problems. I > have also the impression that calling "close" and "stopModal" by hand > can help... That's a lot of impressions, I agree! I don't really believe it has anything to do with how you're closing the dialog box. I think the problem will ultimately be traced to a bug in how FXRuby is interacting with Ruby's garbage collector. As you've mentioned, it's difficult to consistently reproduce it, but one thing you can try to test my theory is to simply disable Ruby's GC by adding the line: GC.disable In your main program. If your program no longer exhibits the problem after adding this line, that's a pretty good sign that it's a GC- related issue. Another, less severe, work around would be to only create the dialog box once, and store a reference to it in an instance variable: @dialog_box = FXDialogBox.new(...) and when you want to display it, call execute on it: @dialog_box.execute > Is there anything like a "message queue" in FXRuby? I'm not sure what you mean. FOX works directly with the OS message queue (whether it's on Windows or X11), but there's no directly- accessible version of that. From lyle.johnson at gmail.com Sat Feb 3 09:59:28 2007 From: lyle.johnson at gmail.com (Lyle Johnson) Date: Sat, 3 Feb 2007 08:59:28 -0600 Subject: [fxruby-users] Bus error in IRB when trying: require "fox16" In-Reply-To: <58f84ffbd56b067464623760b3d22f0c@ruby-forum.com> References: <58f84ffbd56b067464623760b3d22f0c@ruby-forum.com> Message-ID: On 2/2/07, Zane wrote: > I have spent a couple of days trying to get the Fox GUI library to > interact with ruby. Now I think I am getting close. Before I go on to > explain my problem here is some information that may be necessary... > Software Versions: > ---------------------- > Ruby 1.8.1 Just curious: Why still running Ruby 1.8.1? > FXRuby 1.6.5 > Fox 1.6.21 > RubyGems 0.9.1 > > Fox and FXRuby, when compiled they say they compiled succesfully, I have > also recompiled FXRuby with RubyGems, all being successful. I then go > into irb and type require 'fox16' and I get this message returned: > > /sw/lib/ruby/site_ruby/1.8/powerpc-darwin/fox16.bundle: [BUG] Bus Error > ruby 1.8.1 (2003-12-25) [powerpc-darwin] > Abort trap OK, that's bad. When I say that's bad, I mean, I don't recall ever seeing ruby outright *crash* when trying to load FXRuby. It's more common to see, for example, a failure to find one of the shared libraries that FXRuby needs, but the error message in that case is more descriptive than a simple "Bus Error". > When I try require 'fox' in irb I get this message: > > LoadError: No such file to load -- fox > from (irb):1:in `require' > from (irb):1 > > But I take it that as long as I can get fox16 working then this won't be > a problem. Yeah, that's OK. The feature name that you should be trying to require is 'fox16'. > I have trawled through website after website trying to find a fix to > this problem or some helpful information... I have have read a heap of > FXRuby documentation and some Ruby Documentation. Thank you for doing all of that research on your own first. Like I said, this is a new one to me, so you aren't going to find anything about it in the FXRuby documentation. > P.S: Here is a copy of what is writen to ruby1.8.crash.log: I scanned the stack trace, and it looks like the FXRuby code was trying to call an internal Ruby function (st_lookup) when it failed. I have a hunch that that interface has changed a bit since Ruby 1.8.1 (which is several years old now). My advice is to upgrade to the most recent version of Ruby (1.8.5), and then recompile FXRuby and try again. You shouldn't need to recompile FOX -- just zap your FXRuby build directory and recompile that part. Good luck, Lyle From lyle at knology.net Mon Feb 5 21:10:53 2007 From: lyle at knology.net (Lyle Johnson) Date: Mon, 5 Feb 2007 20:10:53 -0600 Subject: [fxruby-users] FXRuby1.6.5 ? In-Reply-To: <45C7A318.8050700@yandex.ru> References: <45C7A318.8050700@yandex.ru> Message-ID: <90C167F5-C23F-4672-8A03-69038B9C20C8@knology.net> On Feb 5, 2007, at 3:35 PM, Aleksey wrote: > I have a couple of questions about FXRuby. (Ruby1.8.5, windowsXP) > 1. Problem with kwargs (new in 1.6.5): I gave scribble.rb, > added 'require 'fox16/kwargs' and changed 'super' in 'initialize' to > 'super(app, "Scribble Application",:width=>800,:height=>600)' . > result - segfault Thanks. I have filed a bug report on your behalf. > 2. How can I speak FXRuby about enother file encoding ('cp1251')? > I can not find any FX...Codec as in Fox. And FXTranslator has now > aliases to > 'setTextCodec' and 'getTextCodec' (as in doc: textCodec=, textCodec). > When I use UTF-8 - all ok(for example, menu text on russian is OK > in FXRuby) > But can I do this with 8-bits-encoding? I think you are asking how to convert data from some codec (like CP1251) to UTF-8? I would use the ruby-iconv library for this, I think. > 3. How can I print with GDI windows-printer from FXCanvas? (When I > used Tcl/Tk , > I found packages 'GDI' and 'Printer' for it, because Postscript- > printing on GDI-printers > very-very bad) I don't know. > 4. I'v attached ZIP with slightly improved examples 'scribble.rb' > and 'bounce.rb' > (I'v added small improvements to make it more professional) OK, I will take a look at these. P.S. Please don't send support requests to me personally, that's what the mailing list is for. From lyle at knology.net Tue Feb 6 21:43:35 2007 From: lyle at knology.net (Lyle Johnson) Date: Tue, 6 Feb 2007 20:43:35 -0600 Subject: [fxruby-users] FXRuby1.6.5 ? In-Reply-To: <45C92AA3.3000503@yandex.ru> References: <45C7A318.8050700@yandex.ru> <90C167F5-C23F-4672-8A03-69038B9C20C8@knology.net> <45C92AA3.3000503@yandex.ru> Message-ID: On Feb 6, 2007, at 7:25 PM, Aleksey wrote: > I don't asc how to convert to UTF-8. I have rb-file saved in > 'ISO-8859-5' > and it has strings for FXRuby (for menu or window title) in russian. > FXRuby renders this strings wrong. > FXRuby renders right only if file with this strings in UTF-8. > Is there a way to say FXRuby about another 8-bit encoding (not > Latin-1) > to render it right? Oh, no. The strings that you pass in to FXRuby definitely need to be UTF-8 encoded Unicode. So you will need to convert your strings which are in the Russian codec to UTF-8. > And what FXTranslyator does (without FX...Codec-s)? I don't know. From erne at powernav.com Tue Feb 6 23:09:28 2007 From: erne at powernav.com (Ernest Ellingson) Date: Tue, 06 Feb 2007 23:09:28 -0500 Subject: [fxruby-users] FXRuby1.6.5 ? In-Reply-To: References: <45C7A318.8050700@yandex.ru> <90C167F5-C23F-4672-8A03-69038B9C20C8@knology.net> <45C92AA3.3000503@yandex.ru> Message-ID: <45C950F8.1040308@powernav.com> Hi: This might help you. It's a message from me in Dec. 2001 to the ruby-talk forumn http://blade.nagaokaut.ac.jp/cgi-bin/vframe.rb?key=unicode&cginame=namazu.rb&submit=Search&dbname=ruby-talk&max=50&whence=0 You should be able to convert unicode to utf8 using the code snippet there. REXML incorporates that code into its parsers. Ernie Lyle Johnson wrote: > On Feb 6, 2007, at 7:25 PM, Aleksey wrote: > > >> I don't asc how to convert to UTF-8. I have rb-file saved in >> 'ISO-8859-5' >> and it has strings for FXRuby (for menu or window title) in russian. >> FXRuby renders this strings wrong. >> FXRuby renders right only if file with this strings in UTF-8. >> Is there a way to say FXRuby about another 8-bit encoding (not >> Latin-1) >> to render it right? >> > > Oh, no. The strings that you pass in to FXRuby definitely need to be > UTF-8 encoded Unicode. So you will need to convert your strings which > are in the Russian codec to UTF-8. > > >> And what FXTranslyator does (without FX...Codec-s)? >> > > I don't know. > _______________________________________________ > fxruby-users mailing list > fxruby-users at rubyforge.org > http://rubyforge.org/mailman/listinfo/fxruby-users > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://rubyforge.org/pipermail/fxruby-users/attachments/20070206/fdda75f3/attachment.html From lyle at knology.net Wed Feb 7 08:56:46 2007 From: lyle at knology.net (Lyle Johnson) Date: Wed, 7 Feb 2007 07:56:46 -0600 Subject: [fxruby-users] FXRuby1.6.5 ? In-Reply-To: <45C950F8.1040308@powernav.com> References: <45C7A318.8050700@yandex.ru> <90C167F5-C23F-4672-8A03-69038B9C20C8@knology.net> <45C92AA3.3000503@yandex.ru> <45C950F8.1040308@powernav.com> Message-ID: On Feb 6, 2007, at 10:09 PM, Ernest Ellingson wrote: > This might help you. > It's a message from me in Dec. 2001 to the ruby-talk forumn > > http://blade.nagaokaut.ac.jp/cgi-bin/vframe.rb? > key=unicode&cginame=namazu.rb&submit=Search&dbname=ruby- > talk&max=50&whence=0 > > You should be able to convert unicode to utf8 using the code > snippet there. REXML incorporates that code into its parsers. Thanks, Ernie, but I believe the problem that Aleksey is dealing with is that he has (literal) strings in ISO-8859-5 (Latin/Cyrillic) encoding, and he's wanting to pass those directly into FXRuby (e.g. as the label for a button). However, as best I understand it, FOX expects those strings to be UTF-8 encoded Unicode, so Aleksey needs to do something to convert his ISO-8859-5-encoded strings into UTF-8 encoded Unicode, e.g. require 'iconv' button = FXButton.new(p, Iconv.new("iso-8859-8", "utf-8").iconv (original_russian_text), ...) -- Lyle -------------- next part -------------- An HTML attachment was scrubbed... URL: http://rubyforge.org/pipermail/fxruby-users/attachments/20070207/e15a1a61/attachment.html From erne at powernav.com Wed Feb 7 10:12:03 2007 From: erne at powernav.com (Ernest Ellingson) Date: Wed, 07 Feb 2007 10:12:03 -0500 Subject: [fxruby-users] FXRuby1.6.5 ? In-Reply-To: References: <45C7A318.8050700@yandex.ru> <90C167F5-C23F-4672-8A03-69038B9C20C8@knology.net> <45C92AA3.3000503@yandex.ru> <45C950F8.1040308@powernav.com> Message-ID: <45C9EC43.900@powernav.com> Here's the direct reference to my code. http://blade.nagaokaut.ac.jp/cgi-bin/scat.rb/ruby/ruby-talk/27298 I know this is code for converting a file, but constructing a utf8 string from unicode is straight forward in the code. If his problem is a simple Lyle describes. Then do this look up the character in the character set. http://www.kostis.net/charsets/iso8859.5.htm Find the decimal value for the character. c=[decimal value of character].pack('U') for example the decimal value for CYRILLIC CAPITAL LETTER IO is 161 in iso8859-5 (a one byte representation of the character) In order to get the utf-8 representation you have to convert the one byte representation to a two or more byte representation based on the utf-8 rules. Ruby does this with array.pack c=[161].pack('U") => "\302\241" The result is the octal values for the two bytes required in this case. That's all he has to do. Ernie Lyle Johnson wrote: > > On Feb 6, 2007, at 10:09 PM, Ernest Ellingson wrote: > >> This might help you. >> It's a message from me in Dec. 2001 to the ruby-talk forumn >> >> http://blade.nagaokaut.ac.jp/cgi-bin/vframe.rb?key=unicode&cginame=namazu.rb&submit=Search&dbname=ruby-talk&max=50&whence=0 >> >> You should be able to convert unicode to utf8 using the code snippet >> there. REXML incorporates that code into its parsers. > > Thanks, Ernie, but I believe the problem that Aleksey is dealing with > is that he has (literal) strings in ISO-8859-5 (Latin/Cyrillic) > encoding, and he's wanting to pass those directly into FXRuby (e.g. as > the label for a button). However, as best I understand it, FOX expects > those strings to be UTF-8 encoded Unicode, so Aleksey needs to do > something to convert his ISO-8859-5-encoded strings into UTF-8 encoded > Unicode, e.g. > > require 'iconv' > > button = FXButton.new(p, Iconv.new("iso-8859-8", > "utf-8").iconv(original_russian_text), ...) > > -- Lyle > ------------------------------------------------------------------------ > > _______________________________________________ > fxruby-users mailing list > fxruby-users at rubyforge.org > http://rubyforge.org/mailman/listinfo/fxruby-users -------------- next part -------------- An HTML attachment was scrubbed... URL: http://rubyforge.org/pipermail/fxruby-users/attachments/20070207/8d6feb5e/attachment.html From ggarra at advancedsl.com.ar Wed Feb 7 13:23:56 2007 From: ggarra at advancedsl.com.ar (gga) Date: Wed, 07 Feb 2007 15:23:56 -0300 Subject: [fxruby-users] FXRuby1.6.5 ? In-Reply-To: <45C9EC43.900@powernav.com> References: <45C7A318.8050700@yandex.ru> <"90C167F5-C23F-4672-8A03-69038B9C20C 8"@knology.net> <45C92AA3.3000503@yandex.ru> <"D5C61EC0-DC7A-4AAD-B17C-38D0A3F0 CF8C"@knology.net> <45C950F8.1040308@powernav.com> <"D29FC2B1-D4BD-4F22-9255-4E 1B3F57C4DE"@knology.net> <45C9EC43.900@powernav.com> Message-ID: <45CA193C.6030202@advancedsl.com.ar> >> require 'iconv' >> >> button = FXButton.new(p, Iconv.new("iso-8859-8", >> "utf-8").iconv(original_russian_text), ...) >> Actually, Lyle, is the other way around. Iconv is unintuitively using Iconv.new( to, from ), like: button = FXButton.new(p, Iconv.new("utf-8", "iso-8859-8").iconv(original_russian_text), ...) Using iconv is much faster (and easier) than packing/unpacking data as Ernest suggests. -- Gonzalo Garramu?o ggarra at advancedsl.com.ar AMD4400 - ASUS48N-E GeForce7300GT Kubuntu Edgy From lyle at knology.net Wed Feb 7 13:56:43 2007 From: lyle at knology.net (Lyle Johnson) Date: Wed, 7 Feb 2007 12:56:43 -0600 Subject: [fxruby-users] FXRuby1.6.5 ? In-Reply-To: <45CA193C.6030202@advancedsl.com.ar> References: <45C7A318.8050700@yandex.ru> <"90C167F5-C23F-4672-8A03-69038B9C20C 8"@knology.net> <45C92AA3.3000503@yandex.ru> <"D5C61EC0-DC7A-4AAD-B17C-38D0A3F0 CF8C"@knology.net> <45C950F8.1040308@powernav.com> <"D29FC2B1-D4BD-4F22-9255-4E 1B3F57C4DE"@knology.net> <45C9EC43.900@powernav.com> <45CA193C.6030202@advancedsl.com.ar> Message-ID: On Feb 7, 2007, at 12:23 PM, gga wrote: > Actually, Lyle, is the other way around. Iconv is unintuitively using > Iconv.new( to, from ), like: > > button = FXButton.new(p, Iconv.new("utf-8", > "iso-8859-8").iconv(original_russian_text), ...) Whoops! Thanks for catching that. From lyle at knology.net Sat Feb 10 22:23:04 2007 From: lyle at knology.net (Lyle Johnson) Date: Sat, 10 Feb 2007 21:23:04 -0600 Subject: [fxruby-users] [ANN] FXRuby 1.6.6 Now Available Message-ID: -----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 All, FXRuby version 1.6.6 is now available for download from this page: http://rubyforge.org/frs/?group_id=300&release_id=9602 Note that you should be using FOX 1.6.16 or later due to some important changes made in that release of FOX. For a summary of the changes in this release of FXRuby, please see this page: http://www.fxruby.org/doc/changes.html As usual, the code is provided as a Win32 installer or a binary Gem (both compatible with the latest One-Click Installer for Ruby 1.8.5), as a source gem, and as a source tarball. For instructions on compiling FXRuby from source, please see: http://www.fxruby.org/doc/build.html And as always, the FXRuby home page is here: http://www.fxruby.org Enjoy, Lyle -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.3 (Darwin) iD8DBQFFzowZFXV/hD6oMd0RAqaZAJ4lrL9EGaiLW9PseYLjCfXX/8xInACdFyrX H55GH8Xt0xMVinOW9RdGOe4= =COMo -----END PGP SIGNATURE----- From lyle at knology.net Sun Feb 11 12:24:45 2007 From: lyle at knology.net (Lyle Johnson) Date: Sun, 11 Feb 2007 11:24:45 -0600 Subject: [fxruby-users] [Foxgui-announce] [ANN] FXRuby 1.6.6 Now Available In-Reply-To: <6C0CF58A187DA5479245E0830AF84F421D1813@poweredge.attiksystem.ch> References: <6C0CF58A187DA5479245E0830AF84F421D1813@poweredge.attiksystem.ch> Message-ID: <21B9ED64-7F18-4661-AE01-313BABC4A98F@knology.net> On Feb 11, 2007, at 9:42 AM, Philippe Lang wrote: > Thanks a lot for the new version. It seems to work really great after > some tests. No need to patch FXRuby anymore! Can I safely take away > the > call to "GC.disable" now? I didn't do anything specifically to fix your bug, so I guess that's up to you. The problem with memory-related bugs is that they are difficult to reproduce, and a given bug will sometimes manifest itself in different ways. > I'm curious: Is there any reason why you haven't chosen Fox 1.6.21 for > the Win32 gem release? Is there anything wrong with this latest > version > and FXRuby? No, there's nothing wrong. There are only minor differences between FOX versions 1.6.20 and 1.6.21, and none of those differences will affect the behavior of FXRuby, so there was simply no point in updating the version of FOX used for this build of FXRuby. (See the FOX News page for more information about what changed in version 1.6.21.) From alan.lake at lakeinfoworks.com Sun Feb 11 19:17:14 2007 From: alan.lake at lakeinfoworks.com (Alan Lake) Date: Mon, 12 Feb 2007 02:17:14 +0200 Subject: [fxruby-users] Installation problem Message-ID: <45CFB20A.9000408@lakeinfoworks.com> I downloaded the all-in-one archive and unpacked it. I then did a cd to the libGUIb directory and [root at erie libGUIb]# ruby install.rb parsearg_config install.rb: entering config phase... ---> lib <--- lib install.rb: config done. parsearg_setup install.rb: entering setup phase... ---> lib <--- lib install.rb: setup done. parsearg_install parsearg_install!!! ARGV: install.rb: entering install phase... ---> lib mkdir -p /usr/lib/ruby/site_ruby/1.8/ install libGUIb14.rb /usr/lib/ruby/site_ruby/1.8/ install libGUIb16.rb /usr/lib/ruby/site_ruby/1.8/ <--- lib install.rb: install done. This looked good to me. I then copied the foxGUIb directory to the location I chose: /home/alan/Software and did a cd to that new directory location and tried to execute it: [alan at erie foxGUIb]$ ruby foxGUIb.rb /usr/lib/ruby/site_ruby/1.8/libGUIb16.rb:833: warning: `*' interpreted as argument prefix please install libGUIb!! no such file to load -- fox16 The directory /usr/lib/ruby/site_ruby/1.8/ contains the following: facter gemconfigure.rb KDE libGUIb14.rb Qt rbconfig rubygems.rb facter.rb i386-linux Korundum.rb libGUIb16.rb Qt.rb rubygems ubygems.rb I don't understand what is wrong or what I should do about it. Thanks for any help. From lyle at knology.net Sun Feb 11 21:33:22 2007 From: lyle at knology.net (Lyle Johnson) Date: Sun, 11 Feb 2007 20:33:22 -0600 Subject: [fxruby-users] Installation problem In-Reply-To: <45CFB20A.9000408@lakeinfoworks.com> References: <45CFB20A.9000408@lakeinfoworks.com> Message-ID: <67CB9EF0-515E-44DE-B7FA-FAB8C8BA0B63@knology.net> On Feb 11, 2007, at 6:17 PM, Alan Lake wrote: > > I downloaded the all-in-one archive and unpacked it. I then did a > cd to > the libGUIb directory and > [root at erie libGUIb]# ruby install.rb Please note that although the developer of foxGUIb does read this mailing list pretty regularly, you might also want to post your question to that project's mailing list. Also, as a side note, this line from the various error messages: "no such file to load -- fox16" seems to indicate that FXRuby itself isn't installed. You might want to try installing it first, before installing foxGUIb. Hope this helps, Lyle From bjorn.bergqvist at gmail.com Mon Feb 12 04:11:22 2007 From: bjorn.bergqvist at gmail.com (=?ISO-8859-1?Q?Bj=F6rn_Bergqvist?=) Date: Mon, 12 Feb 2007 10:11:22 +0100 Subject: [fxruby-users] release memory Message-ID: <44936e730702120111w6d0cd1e1y9c0a34269c9f3fd4@mail.gmail.com> Hello, if I have created some objects in a FXGLViewer and want to remove them and free that memory. How do I do? Regards Bj?rn Bergqvist From alan.lake at lakeinfoworks.com Mon Feb 12 16:21:29 2007 From: alan.lake at lakeinfoworks.com (Alan Lake) Date: Mon, 12 Feb 2007 23:21:29 +0200 Subject: [fxruby-users] Installation problem In-Reply-To: <67CB9EF0-515E-44DE-B7FA-FAB8C8BA0B63@knology.net> References: <45CFB20A.9000408@lakeinfoworks.com> <67CB9EF0-515E-44DE-B7FA-FAB8C8BA0B63@knology.net> Message-ID: <45D0DA59.9030802@lakeinfoworks.com> The list that this is posted to is fxruby-users at rubyforge.org. I don't see any other list that I might post this on. I didn't realize that fxruby was a required install in addition to libGUIb and foxGUIb. So I thank you. I still have a problem, though, in that it didn't install correctly, and I can't tell why. I did the following: [root at erie ~]# gem update fxruby --include-dependencies -------------------------------------- Updating installed gems... Need to update 1 gems from http://gems.rubyforge.org . complete Attempting remote update of fxruby Select which gem to install for your platform (x86_64-linux) 1. fxruby 1.6.6 (ruby) > 1 Building native extensions. This could take a while... *** extconf.rb failed *** Could not create Makefile due to some reason, probably lack of necessary libraries and/or headers. Check the mkmf.log file for more details. You may need configuration options. Provided configuration options: --with-opt-dir --without-fxscintilla-lib=${fxscintilla-dir}/lib ERROR: While executing gem ... (RuntimeError) ERROR: Failed to build gem native extension. Gem files will remain installed in /usr/lib64/ruby/gems/1.8/gems/fxruby-1.6.6 for inspection. Results logged to /usr/lib64/ruby/gems/1.8/gems/fxruby-1.6.6/ext/fox16/gem_make.out ------------------ When I did [root at erie ~]# find / -name mkmf.log No result was returned. gem_make.out is empty. The gem files are present. Can you suggest what I can do now? (I'm using the x64 version of Fedora Core 6, if that helps.) Lyle Johnson wrote: > On Feb 11, 2007, at 6:17 PM, Alan Lake wrote: > > >> I downloaded the all-in-one archive and unpacked it. I then did a >> cd to >> the libGUIb directory and >> [root at erie libGUIb]# ruby install.rb >> > > > > Please note that although the developer of foxGUIb does read this > mailing list pretty regularly, you might also want to post your > question to that project's mailing list. > > Also, as a side note, this line from the various error messages: > > "no such file to load -- fox16" > > seems to indicate that FXRuby itself isn't installed. You might want > to try installing it first, before installing foxGUIb. > > Hope this helps, > > Lyle > _______________________________________________ > fxruby-users mailing list > fxruby-users at rubyforge.org > http://rubyforge.org/mailman/listinfo/fxruby-users > > From lyle at knology.net Mon Feb 12 17:37:02 2007 From: lyle at knology.net (Lyle Johnson) Date: Mon, 12 Feb 2007 16:37:02 -0600 Subject: [fxruby-users] Installation problem In-Reply-To: <45D0DA59.9030802@lakeinfoworks.com> References: <45CFB20A.9000408@lakeinfoworks.com> <67CB9EF0-515E-44DE-B7FA-FAB8C8BA0B63@knology.net> <45D0DA59.9030802@lakeinfoworks.com> Message-ID: <21D83F9C-FEBC-4C9B-AF26-54FA598386BA@knology.net> On Feb 12, 2007, at 3:21 PM, Alan Lake wrote: > The list that this is posted to is fxruby-users at rubyforge.org. I > don't > see any other list that I might post this on. Well, since your question was about the "foxGUIb" project, you would want to look to that project's page: http://rubyforge.org/projects/fox-tool/ and click the "Mailing Lists" link for that project: http://rubyforge.org/mail/?group_id=88 > I didn't realize that > fxruby was a required install in addition to libGUIb and foxGUIb. > So I > thank you. I still have a problem, though, in that it didn't install > correctly, and I can't tell why. I did the following: Please see the FXRuby User's Guide for build instructions: http://www.fxruby.org/doc/book.html I'm going to make an educated guess that you don't have FOX installed yet. You can download FOX (version 1.6.x) from the FOX home page: http://www.fox-toolkit.org/ Be sure that you get one of the 1.6 releases. FOX 1.7 is the experimental "development" branch and is not yet supported by FXRuby. From lyle at knology.net Mon Feb 12 11:25:37 2007 From: lyle at knology.net (Lyle Johnson) Date: Mon, 12 Feb 2007 10:25:37 -0600 Subject: [fxruby-users] release memory In-Reply-To: <44936e730702120111w6d0cd1e1y9c0a34269c9f3fd4@mail.gmail.com> References: <44936e730702120111w6d0cd1e1y9c0a34269c9f3fd4@mail.gmail.com> Message-ID: <73CFF7A7-E95B-412F-9254-5E6F594C115D@knology.net> On Feb 12, 2007, at 3:11 AM, Bj?rn Bergqvist wrote: > if I have created some objects in a FXGLViewer and want to remove them > and free that memory. How do I do? I will assume for the moment that all of the objects in the GLViewer's scene are in a GLGroup (as they are in the example program). In that case, just remove the object(s) from the group, e.g. glviewer.scene.remove(obj) and then call update on the glviewer to get it to redraw itself: glviewer.update Hope this helps, Lyle From philippe.lang at attiksystem.ch Fri Feb 16 07:21:50 2007 From: philippe.lang at attiksystem.ch (Philippe Lang) Date: Fri, 16 Feb 2007 13:21:50 +0100 Subject: [fxruby-users] No accelTable for an FXTabItem? Message-ID: <6C0CF58A187DA5479245E0830AF84F4218CD8B@poweredge.attiksystem.ch> Hi, Here is a small test application made up of an FXMainWindow, where you can find an FXTabBook and three items inside. I can add "keyboard accelerators" in the main window. It works just fine. But I'm unable to do the same in the FXTabItem class. If I call "accelTable.addAccel" in the MyTabItem class, the error I get is: ------------------------------ test.rb:17:in `initialize': undefined method `addAccel' for nil:NilClass (NoMeth odError) from test.rb:33:in `new' from test.rb:33:in `initialize' from test.rb:53:in `new' from test.rb:53 ------------------------------ Apparently, accelTable is not initialized in the FXTabItem class. FXTabItem is derived from FXWindow and should have an accelTable attribute, right? Does anyone see the problem then? I'm using the FXRuby 1.6.6 gem under Ruby 1.8.5, under Windows XP. Regards, Philippe Lang ======================================================== require 'fox16' include Fox class MyTabItem < FXTabItem include Responder ID_SAVE = FXTabItem::ID_LAST def initialize(p, text, ic=nil, opts=TAB_TOP_NORMAL, x=0, y=0, width=0, height=0, padLeft=DEFAULT_PAD, padRight=DEFAULT_PAD, padTop=DEFAULT_PAD, padBottom=DEFAULT_PAD) super(p, text, ic, opts, x, y, width, height, padLeft, padRight, padTop, padBottom) FXHorizontalFrame.new(p, FRAME_RAISED|LAYOUT_FILL_X|LAYOUT_FILL_Y) FXMAPFUNC(SEL_COMMAND, MyTabItem::ID_SAVE, 'onSave') # Bug appears if you uncomment the following line: #accelTable.addAccel(fxparseAccel("Ctrl-S"), self, FXSEL(SEL_COMMAND, MyTabItem::ID_SAVE)) end def onSave(sender, selector, data) puts "save in MyTabItem" end end class MyWindow < FXMainWindow include Responder ID_SAVE = FXMainWindow::ID_LAST def initialize(app) super(app, "Window", nil, nil, DECOR_ALL, 0, 0, 200, 100) tabbook = FXTabBook.new(self, nil, 0, LAYOUT_FILL_X|LAYOUT_FILL_Y) tabitem1 = MyTabItem.new(tabbook, "tab 1") tabitem2 = MyTabItem.new(tabbook, "tab 2") tabitem3 = MyTabItem.new(tabbook, "tab 3") FXMAPFUNC(SEL_COMMAND, MyWindow::ID_SAVE, 'onSave') accelTable.addAccel(fxparseAccel("Ctrl-S"), self, FXSEL(SEL_COMMAND, MyWindow::ID_SAVE)) end def onSave(sender, selector, data) puts "save in MyWindow" end def create super show(PLACEMENT_SCREEN) end end if __FILE__ == $0 application = FXApp.new("Fox", "FXRuby Test") MyWindow.new(application) application.create application.run end ======================================================== From jeroen at fox-toolkit.org Fri Feb 16 08:31:03 2007 From: jeroen at fox-toolkit.org (Jeroen van der Zijp) Date: Fri, 16 Feb 2007 07:31:03 -0600 Subject: [fxruby-users] No accelTable for an FXTabItem? In-Reply-To: <6C0CF58A187DA5479245E0830AF84F4218CD8B@poweredge.attiksystem.ch> References: <6C0CF58A187DA5479245E0830AF84F4218CD8B@poweredge.attiksystem.ch> Message-ID: <200702160731.04093.jeroen@fox-toolkit.org> On Friday 16 February 2007 06:21, Philippe Lang wrote: > Hi, > > Here is a small test application made up of an FXMainWindow, where you > can find an FXTabBook and three items inside. > > I can add "keyboard accelerators" in the main window. It works just > fine. > > But I'm unable to do the same in the FXTabItem class. If I call > "accelTable.addAccel" in the MyTabItem class, the error I get is: > > ------------------------------ > test.rb:17:in `initialize': undefined method `addAccel' for nil:NilClass > (NoMeth > odError) > from test.rb:33:in `new' > from test.rb:33:in `initialize' > from test.rb:53:in `new' > from test.rb:53 > ------------------------------ > > Apparently, accelTable is not initialized in the FXTabItem class. > > FXTabItem is derived from FXWindow and should have an accelTable > attribute, right? It has a variable for accel table, but no accel table has been added yet. However, after you add an accel table, you should certainly be able to add accelerator key-combinations to it then! - Jeroen -- +----------------------------------------------------------------------------+ | Copyright (C) 07:20 02/16/2007 Jeroen van der Zijp. All Rights Reserved. | +----------------------------------------------------------------------------+ From philippe.lang at attiksystem.ch Fri Feb 16 08:50:59 2007 From: philippe.lang at attiksystem.ch (Philippe Lang) Date: Fri, 16 Feb 2007 14:50:59 +0100 Subject: [fxruby-users] No accelTable for an FXTabItem? References: <6C0CF58A187DA5479245E0830AF84F4218CD8B@poweredge.attiksystem.ch> <200702160731.04093.jeroen@fox-toolkit.org> Message-ID: <6C0CF58A187DA5479245E0830AF84F4218CD8C@poweredge.attiksystem.ch> Jeroen van der Zijp wrote: >> Apparently, accelTable is not initialized in the FXTabItem class. >> >> FXTabItem is derived from FXWindow and should have an accelTable >> attribute, right? > > It has a variable for accel table, but no accel table has been added > yet. However, after you add an accel table, you should certainly be > able to add accelerator key-combinations to it then! Hi, I've tried initializing the accel table, the error has disappeared, but the tab item does not react to CTRL-S at all. Something to enable maybe? One more question: what happens if three tabs have the same hotkey configured in their respective accel table? Do they all receive the callback, or only the active tab? I'd like to code something similar to the second solution, but I'm not sure how to do that... Regards, Philippe Lang =========================================== require 'fox16' include Fox class MyTabItem < FXTabItem include Responder ID_SAVE = FXTabItem::ID_LAST def initialize(p, text, ic=nil, opts=TAB_TOP_NORMAL, x=0, y=0, width=0, height=0, padLeft=DEFAULT_PAD, padRight=DEFAULT_PAD, padTop=DEFAULT_PAD, padBottom=DEFAULT_PAD) super(p, text, ic, opts, x, y, width, height, padLeft, padRight, padTop, padBottom) FXHorizontalFrame.new(p, FRAME_RAISED|LAYOUT_FILL_X|LAYOUT_FILL_Y) FXMAPFUNC(SEL_COMMAND, MyTabItem::ID_SAVE, 'onSave') accelTable = FXAccelTable.new() accelTable.addAccel(fxparseAccel("Ctrl-S"), self, FXSEL(SEL_COMMAND, MyTabItem::ID_SAVE)) end def onSave(sender, selector, data) puts "save in MyTabItem" end end class MyWindow < FXMainWindow #include Responder #ID_SAVE = FXMainWindow::ID_LAST def initialize(app) super(app, "Window", nil, nil, DECOR_ALL, 0, 0, 200, 100) tabbook = FXTabBook.new(self, nil, 0, LAYOUT_FILL_X|LAYOUT_FILL_Y) tabitem1 = MyTabItem.new(tabbook, "tab 1") tabitem2 = MyTabItem.new(tabbook, "tab 2") tabitem3 = MyTabItem.new(tabbook, "tab 3") #FXMAPFUNC(SEL_COMMAND, MyWindow::ID_SAVE, 'onSave') #accelTable.addAccel(fxparseAccel("Ctrl-S"), self, FXSEL(SEL_COMMAND, MyWindow::ID_SAVE)) end def onSave(sender, selector, data) puts "save in MyWindow" end def create super show(PLACEMENT_SCREEN) end end if __FILE__ == $0 application = FXApp.new("Fox", "FXRuby Test") MyWindow.new(application) application.create application.run End =========================================== From philippe.lang at attiksystem.ch Fri Feb 16 10:07:25 2007 From: philippe.lang at attiksystem.ch (Philippe Lang) Date: Fri, 16 Feb 2007 16:07:25 +0100 Subject: [fxruby-users] No accelTable for an FXTabItem? References: <6C0CF58A187DA5479245E0830AF84F4218CD8B@poweredge.attiksystem.ch><200702160731.04093.jeroen@fox-toolkit.org> <6C0CF58A187DA5479245E0830AF84F4218CD8C@poweredge.attiksystem.ch> Message-ID: <6C0CF58A187DA5479245E0830AF84F4218CD8D@poweredge.attiksystem.ch> fxruby-users-bounces at rubyforge.org wrote: > Jeroen van der Zijp wrote: > >>> Apparently, accelTable is not initialized in the FXTabItem class. >>> >>> FXTabItem is derived from FXWindow and should have an accelTable >>> attribute, right? >> >> It has a variable for accel table, but no accel table has been added >> yet. However, after you add an accel table, you should certainly be >> able to add accelerator key-combinations to it then! > > Hi, > > I've tried initializing the accel table, the error has disappeared, > but the tab item does not react to CTRL-S at all. Something to enable > maybe? > > One more question: what happens if three tabs have the same hotkey > configured in their respective accel table? Do they all receive the > callback, or only the active tab? I'd like to code something similar > to the second solution, but I'm not sure how to do that... Hi again, I have tried something else, still without success: I have overloaded the tab frame as well, and configured its accel table. The only callback that works for me is the one in the "MyWindow" class. =================================================== require 'fox16' include Fox class MyFrame < FXHorizontalFrame include Responder ID_SAVE = FXHorizontalFrame::ID_LAST def initialize(p, opts=0, x=0, y=0, width=0, height=0, padLeft=DEFAULT_SPACING, padRight=DEFAULT_SPACING, padTop=DEFAULT_SPACING, padBottom=DEFAULT_SPACING, hSpacing=DEFAULT_SPACING, vSpacing=DEFAULT_SPACING) super(p, opts, x, y, width, height, padLeft, padRight, padTop, padBottom, hSpacing, vSpacing) FXMAPFUNC(SEL_COMMAND, MyFrame::ID_SAVE, 'onSave') accelTable = FXAccelTable.new() accelTable.addAccel(fxparseAccel("Ctrl-S"), self, FXSEL(SEL_COMMAND, MyFrame::ID_SAVE)) end def onSave(sender, selector, data) puts "save in MyFrame" end end class MyTabItem < FXTabItem include Responder ID_SAVE = FXTabItem::ID_LAST def initialize(p, text, ic=nil, opts=TAB_TOP_NORMAL, x=0, y=0, width=0, height=0, padLeft=DEFAULT_PAD, padRight=DEFAULT_PAD, padTop=DEFAULT_PAD, padBottom=DEFAULT_PAD) super(p, text, ic, opts, x, y, width, height, padLeft, padRight, padTop, padBottom) frame = MyFrame.new(p, FRAME_RAISED|LAYOUT_FILL_X|LAYOUT_FILL_Y) FXMAPFUNC(SEL_COMMAND, MyTabItem::ID_SAVE, 'onSave') accelTable = FXAccelTable.new() accelTable.addAccel(fxparseAccel("Ctrl-S"), self, FXSEL(SEL_COMMAND, MyTabItem::ID_SAVE)) end def onSave(sender, selector, data) puts "save in MyTabItem" end end class MyWindow < FXMainWindow include Responder ID_SAVE = FXMainWindow::ID_LAST def initialize(app) super(app, "Window", nil, nil, DECOR_ALL, 0, 0, 200, 100) @tabbook = FXTabBook.new(self, nil, 0, LAYOUT_FILL_X|LAYOUT_FILL_Y) tabitem1 = MyTabItem.new(@tabbook, "tab 1") tabitem2 = MyTabItem.new(@tabbook, "tab 2") tabitem3 = MyTabItem.new(@tabbook, "tab 3") FXMAPFUNC(SEL_COMMAND, MyWindow::ID_SAVE, 'onSave') accelTable.addAccel(fxparseAccel("Ctrl-S"), self, FXSEL(SEL_COMMAND, MyWindow::ID_SAVE)) end def onSave(sender, selector, data) puts "save in MyWindow" puts @tabbook.current end def create super show(PLACEMENT_SCREEN) end end if __FILE__ == $0 application = FXApp.new("Fox", "FXRuby Test") MyWindow.new(application) application.create application.run end =================================================== From erne at powernav.com Mon Feb 19 11:03:18 2007 From: erne at powernav.com (Ernest Ellingson) Date: Mon, 19 Feb 2007 11:03:18 -0500 Subject: [fxruby-users] Problem using foxGUIb Message-ID: <45D9CA46.10000@powernav.com> I'm at a definite loss here. I downloaded foxGUIb v0.7. I unzipped the files. (Windows XP pro) I ran ruby install.rb in the libGUIb directory. I switched to the foxGUIb directory I tried running foxGUIb_win32.rbw Nothing happened. I tried running ruby foxGUIb.rb I get the following error. please install libGUIb!! no such file to load -- fox16 Here is the text in the installed files C:/ruby/lib/ruby/site_ruby/1.8//libGUIb14.rb C:/ruby/lib/ruby/site_ruby/1.8//libGUIb16.rb I have other fox gui's that run fine with require 'fox16' Anyone have a clue as to what has gone wrong? Ernie From meinrad.recheis at gmail.com Mon Feb 19 14:02:00 2007 From: meinrad.recheis at gmail.com (Meinrad Recheis) Date: Mon, 19 Feb 2007 20:02:00 +0100 Subject: [fxruby-users] Problem using foxGUIb In-Reply-To: <45D9CA46.10000@powernav.com> References: <45D9CA46.10000@powernav.com> Message-ID: <43d756720702191102o86134e0ufc3f8d640c1ad067@mail.gmail.com> On 2/19/07, Ernest Ellingson wrote: > I'm at a definite loss here. I downloaded foxGUIb v0.7. I unzipped the > files. (Windows XP pro) > I ran ruby install.rb in the libGUIb directory. > I switched to the foxGUIb directory > I tried running foxGUIb_win32.rbw > Nothing happened. > > I tried running ruby foxGUIb.rb > I get the following error. > > > please install libGUIb!! > no such file to load -- fox16 > all i can say is that libGUIb16.rb is there, gets called and fails in its very first line trying to require fox16. i got no clue about what is going wrong... what happens when you do require "fox16" in irb? what exception stacktrace do you get when you launch libGUIb16.rb directly? > > Here is the text in the installed files > C:/ruby/lib/ruby/site_ruby/1.8//libGUIb14.rb > C:/ruby/lib/ruby/site_ruby/1.8//libGUIb16.rb > > I have other fox gui's that run fine with require 'fox16' > > Anyone have a clue as to what has gone wrong? > > Ernie > From erne at powernav.com Mon Feb 19 14:43:01 2007 From: erne at powernav.com (Ernest Ellingson) Date: Mon, 19 Feb 2007 14:43:01 -0500 Subject: [fxruby-users] Problem using foxGUIb In-Reply-To: <43d756720702191102o86134e0ufc3f8d640c1ad067@mail.gmail.com> References: <45D9CA46.10000@powernav.com> <43d756720702191102o86134e0ufc3f8d640c1ad067@mail.gmail.com> Message-ID: <45D9FDC5.7080400@powernav.com> Meinrad Recheis wrote: > On 2/19/07, Ernest Ellingson wrote: > >> I'm at a definite loss here. I downloaded foxGUIb v0.7. I unzipped the >> files. (Windows XP pro) >> I ran ruby install.rb in the libGUIb directory. >> I switched to the foxGUIb directory >> I tried running foxGUIb_win32.rbw >> Nothing happened. >> >> I tried running ruby foxGUIb.rb >> I get the following error. >> >> >> please install libGUIb!! >> no such file to load -- fox16 >> >> > all i can say is that libGUIb16.rb is there, gets called and fails in > its very first line trying to require fox16. i got no clue about what > is going wrong... > > what happens when you do > > require "fox16" > > in irb? > what exception stacktrace do you get when you launch libGUIb16.rb directly? > > >> Here is the text in the installed files >> C:/ruby/lib/ruby/site_ruby/1.8//libGUIb14.rb >> C:/ruby/lib/ruby/site_ruby/1.8//libGUIb16.rb >> >> I have other fox gui's that run fine with require 'fox16' >> >> Anyone have a clue as to what has gone wrong? >> >> Ernie >> >> > _______________________________________________ > fxruby-users mailing list > fxruby-users at rubyforge.org > http://rubyforge.org/mailman/listinfo/fxruby-users > Thanks for the response. I figured out what was going wrong and just now have it working. My fxruby was installed as a gem. When I upgraded Ruby to 1.8.5 windows one click installer, It failed to set the Environmental Variable RUBYOPT. with out that environmental variable, you have to require 'rubygems'. I haven't tried the foxGUI in Linux yet. However, I know fxruby was installed there as a gem as well. So the foxGUI.rb script will have to have a require 'rubygems" in it in order for it to function correctly. I like the gui though. It's very handy. I'm giving a presentation on fxruby to the Atlanta Ruby user's group in March. I will be using the gui to explain how the layout manager works. It's also nice to have all the events available for a widget as well. Very nice job. Ernie From alan.lake at lakeinfoworks.com Mon Feb 19 18:23:00 2007 From: alan.lake at lakeinfoworks.com (Alan Lake) Date: Tue, 20 Feb 2007 01:23:00 +0200 Subject: [fxruby-users] Problem using foxGUIb In-Reply-To: <45D9FDC5.7080400@powernav.com> References: <45D9CA46.10000@powernav.com> <43d756720702191102o86134e0ufc3f8d640c1ad067@mail.gmail.com> <45D9FDC5.7080400@powernav.com> Message-ID: <45DA3154.9060500@lakeinfoworks.com> I, too, installed fxruby as a gem on a 64-bit machine running Fedora Core 6. I have not yet been able to run Fox with Ruby and get the same error message. Following Ernie's lead, I modified foxGUIb.rb, adding require "rubygems" just before require "version" It appears that I crashing on the first code in this file begin require FOXGUIB_LIBRARY rescue LoadError puts "please install libGUIb!!" puts $! exit end I don't know enough about this code to know what FOXGUIB_LIBRARY contains, or what it's supposed to contain, but I do know that I have a successful install of the library. Can someone advise me of the next step in resolving this problem? Thanks. Ernest Ellingson wrote: > Meinrad Recheis wrote: > >> On 2/19/07, Ernest Ellingson wrote: >> >> >>> I'm at a definite loss here. I downloaded foxGUIb v0.7. I unzipped the >>> files. (Windows XP pro) >>> I ran ruby install.rb in the libGUIb directory. >>> I switched to the foxGUIb directory >>> I tried running foxGUIb_win32.rbw >>> Nothing happened. >>> >>> I tried running ruby foxGUIb.rb >>> I get the following error. >>> >>> >>> please install libGUIb!! >>> no such file to load -- fox16 >>> >>> >>> >> all i can say is that libGUIb16.rb is there, gets called and fails in >> its very first line trying to require fox16. i got no clue about what >> is going wrong... >> >> what happens when you do >> >> require "fox16" >> >> in irb? >> what exception stacktrace do you get when you launch libGUIb16.rb directly? >> >> >> >>> Here is the text in the installed files >>> C:/ruby/lib/ruby/site_ruby/1.8//libGUIb14.rb >>> C:/ruby/lib/ruby/site_ruby/1.8//libGUIb16.rb >>> >>> I have other fox gui's that run fine with require 'fox16' >>> >>> Anyone have a clue as to what has gone wrong? >>> >>> Ernie >>> >>> >>> >> _______________________________________________ >> fxruby-users mailing list >> fxruby-users at rubyforge.org >> http://rubyforge.org/mailman/listinfo/fxruby-users >> >> > Thanks for the response. I figured out what was going wrong and just > now have > it working. My fxruby was installed as a gem. When I upgraded Ruby to > 1.8.5 > windows one click installer, It failed to set the Environmental Variable > RUBYOPT. > with out that environmental variable, you have to require 'rubygems'. I > haven't tried the > foxGUI in Linux yet. However, I know fxruby was installed there as a > gem as well. So > the foxGUI.rb script will have to have a require 'rubygems" in it in > order for it to function > correctly. > I like the gui though. It's very handy. I'm giving a presentation > on fxruby to the Atlanta > Ruby user's group in March. I will be using the gui to explain how the > layout manager works. > It's also nice to have all the events available for a widget as well. > Very nice job. > > Ernie > _______________________________________________ > fxruby-users mailing list > fxruby-users at rubyforge.org > http://rubyforge.org/mailman/listinfo/fxruby-users > > From erne at powernav.com Tue Feb 20 09:44:50 2007 From: erne at powernav.com (Ernest Ellingson) Date: Tue, 20 Feb 2007 09:44:50 -0500 Subject: [fxruby-users] Problem using foxGUIb In-Reply-To: <45DA3154.9060500@lakeinfoworks.com> References: <45D9CA46.10000@powernav.com> <43d756720702191102o86134e0ufc3f8d640c1ad067@mail.gmail.com> <45D9FDC5.7080400@powernav.com> <45DA3154.9060500@lakeinfoworks.com> Message-ID: <45DB0962.9090609@powernav.com> Alan Lake wrote: > I, too, installed fxruby as a gem on a 64-bit machine running Fedora > Core 6. I have not yet been able to run Fox with Ruby and get the same > error message. Following Ernie's lead, I modified foxGUIb.rb, adding > require "rubygems" > just before > require "version" > It appears that I crashing on the first code in this file > begin > require FOXGUIB_LIBRARY > rescue LoadError > puts "please install libGUIb!!" > puts $! > exit > end > I don't know enough about this code to know what FOXGUIB_LIBRARY > contains, or what it's supposed to contain, but I do know that I have a > successful install of the library. > > Can someone advise me of the next step in resolving this problem? Thanks. > > Ernest Ellingson wrote: > >> Meinrad Recheis wrote: >> >> >>> On 2/19/07, Ernest Ellingson wrote: >>> >>> >>> >>>> I'm at a definite loss here. I downloaded foxGUIb v0.7. I unzipped the >>>> files. (Windows XP pro) >>>> I ran ruby install.rb in the libGUIb directory. >>>> I switched to the foxGUIb directory >>>> I tried running foxGUIb_win32.rbw >>>> Nothing happened. >>>> >>>> I tried running ruby foxGUIb.rb >>>> I get the following error. >>>> >>>> >>>> please install libGUIb!! >>>> no such file to load -- fox16 >>>> >>>> >>>> >>>> >>> all i can say is that libGUIb16.rb is there, gets called and fails in >>> its very first line trying to require fox16. i got no clue about what >>> is going wrong... >>> >>> what happens when you do >>> >>> require "fox16" >>> >>> in irb? >>> what exception stacktrace do you get when you launch libGUIb16.rb directly? >>> >>> >>> >>> >>>> Here is the text in the installed files >>>> C:/ruby/lib/ruby/site_ruby/1.8//libGUIb14.rb >>>> C:/ruby/lib/ruby/site_ruby/1.8//libGUIb16.rb >>>> >>>> I have other fox gui's that run fine with require 'fox16' >>>> >>>> Anyone have a clue as to what has gone wrong? >>>> >>>> Ernie >>>> >>>> >>>> >>>> >>> _______________________________________________ >>> fxruby-users mailing list >>> fxruby-users at rubyforge.org >>> http://rubyforge.org/mailman/listinfo/fxruby-users >>> >>> >>> >> Thanks for the response. I figured out what was going wrong and just >> now have >> it working. My fxruby was installed as a gem. When I upgraded Ruby to >> 1.8.5 >> windows one click installer, It failed to set the Environmental Variable >> RUBYOPT. >> with out that environmental variable, you have to require 'rubygems'. I >> haven't tried the >> foxGUI in Linux yet. However, I know fxruby was installed there as a >> gem as well. So >> the foxGUI.rb script will have to have a require 'rubygems" in it in >> order for it to function >> correctly. >> I like the gui though. It's very handy. I'm giving a presentation >> on fxruby to the Atlanta >> Ruby user's group in March. I will be using the gui to explain how the >> layout manager works. >> It's also nice to have all the events available for a widget as well. >> Very nice job. >> >> Ernie >> _______________________________________________ >> fxruby-users mailing list >> fxruby-users at rubyforge.org >> http://rubyforge.org/mailman/listinfo/fxruby-users >> >> >> > _______________________________________________ > fxruby-users mailing list > fxruby-users at rubyforge.org > http://rubyforge.org/mailman/listinfo/fxruby-users > Have you installed the Fox Gui itself? Are you able to run any of the examples in the examples directory of the fox gem? Ernie From alan.lake at lakeinfoworks.com Tue Feb 20 12:24:10 2007 From: alan.lake at lakeinfoworks.com (Alan Lake) Date: Tue, 20 Feb 2007 19:24:10 +0200 Subject: [fxruby-users] Problem using foxGUIb In-Reply-To: <45DB0962.9090609@powernav.com> References: <45D9CA46.10000@powernav.com> <43d756720702191102o86134e0ufc3f8d640c1ad067@mail.gmail.com> <45D9FDC5.7080400@powernav.com> <45DA3154.9060500@lakeinfoworks.com> <45DB0962.9090609@powernav.com> Message-ID: <45DB2EBA.5050001@lakeinfoworks.com> Have you installed the Fox Gui itself? Yes Are you able to run any of the examples in the examples directory of the fox gem? I just tried hello.rb, figuring that if that wouldn't run, then nothing else would. /usr/lib64/ruby/gems/1.8/gems/fxruby-1.6.6/examples/hello.rb:3:in `require': no such file to load -- fox16 (LoadError) from /usr/lib64/ruby/gems/1.8/gems/fxruby-1.6.6/examples/hello.rb:3 However, I have /usr/lib64/ruby/gems/1.8/gems/fxruby-1.6.6/lib/fox16 /usr/lib64/ruby/gems/1.8/gems/fxruby-1.6.6/ext/fox16 I also have a syntax problem with my .bash_profile export of RUBYOPT. I wish to set both "w" and "rubygems". I seem to be able to set either, but not both. Can you give me the correct syntax, please? Ernest Ellingson wrote: > Alan Lake wrote: > >> I, too, installed fxruby as a gem on a 64-bit machine running Fedora >> Core 6. I have not yet been able to run Fox with Ruby and get the same >> error message. Following Ernie's lead, I modified foxGUIb.rb, adding >> require "rubygems" >> just before >> require "version" >> It appears that I crashing on the first code in this file >> begin >> require FOXGUIB_LIBRARY >> rescue LoadError >> puts "please install libGUIb!!" >> puts $! >> exit >> end >> I don't know enough about this code to know what FOXGUIB_LIBRARY >> contains, or what it's supposed to contain, but I do know that I have a >> successful install of the library. >> >> Can someone advise me of the next step in resolving this problem? Thanks. >> >> Ernest Ellingson wrote: >> >> >>> Meinrad Recheis wrote: >>> >>> >>> >>>> On 2/19/07, Ernest Ellingson wrote: >>>> >>>> >>>> >>>> >>>>> I'm at a definite loss here. I downloaded foxGUIb v0.7. I unzipped the >>>>> files. (Windows XP pro) >>>>> I ran ruby install.rb in the libGUIb directory. >>>>> I switched to the foxGUIb directory >>>>> I tried running foxGUIb_win32.rbw >>>>> Nothing happened. >>>>> >>>>> I tried running ruby foxGUIb.rb >>>>> I get the following error. >>>>> >>>>> >>>>> please install libGUIb!! >>>>> no such file to load -- fox16 >>>>> >>>>> >>>>> >>>>> >>>>> >>>> all i can say is that libGUIb16.rb is there, gets called and fails in >>>> its very first line trying to require fox16. i got no clue about what >>>> is going wrong... >>>> >>>> what happens when you do >>>> >>>> require "fox16" >>>> >>>> in irb? >>>> what exception stacktrace do you get when you launch libGUIb16.rb directly? >>>> >>>> >>>> >>>> >>>> >>>>> Here is the text in the installed files >>>>> C:/ruby/lib/ruby/site_ruby/1.8//libGUIb14.rb >>>>> C:/ruby/lib/ruby/site_ruby/1.8//libGUIb16.rb >>>>> >>>>> I have other fox gui's that run fine with require 'fox16' >>>>> >>>>> Anyone have a clue as to what has gone wrong? >>>>> >>>>> Ernie >>>>> >>>>> >>>>> >>>>> >>>>> >>>> _______________________________________________ >>>> fxruby-users mailing list >>>> fxruby-users at rubyforge.org >>>> http://rubyforge.org/mailman/listinfo/fxruby-users >>>> >>>> >>>> >>>> >>> Thanks for the response. I figured out what was going wrong and just >>> now have >>> it working. My fxruby was installed as a gem. When I upgraded Ruby to >>> 1.8.5 >>> windows one click installer, It failed to set the Environmental Variable >>> RUBYOPT. >>> with out that environmental variable, you have to require 'rubygems'. I >>> haven't tried the >>> foxGUI in Linux yet. However, I know fxruby was installed there as a >>> gem as well. So >>> the foxGUI.rb script will have to have a require 'rubygems" in it in >>> order for it to function >>> correctly. >>> I like the gui though. It's very handy. I'm giving a presentation >>> on fxruby to the Atlanta >>> Ruby user's group in March. I will be using the gui to explain how the >>> layout manager works. >>> It's also nice to have all the events available for a widget as well. >>> Very nice job. >>> >>> Ernie >>> _______________________________________________ >>> fxruby-users mailing list >>> fxruby-users at rubyforge.org >>> http://rubyforge.org/mailman/listinfo/fxruby-users >>> >>> >>> >>> >> _______________________________________________ >> fxruby-users mailing list >> fxruby-users at rubyforge.org >> http://rubyforge.org/mailman/listinfo/fxruby-users >> >> > Have you installed the Fox Gui itself? Are you able to run any of the > examples in the > examples directory of the fox gem? > > Ernie > _______________________________________________ > fxruby-users mailing list > fxruby-users at rubyforge.org > http://rubyforge.org/mailman/listinfo/fxruby-users > > From erne at powernav.com Tue Feb 20 13:06:18 2007 From: erne at powernav.com (Ernest Ellingson) Date: Tue, 20 Feb 2007 13:06:18 -0500 Subject: [fxruby-users] Problem using foxGUIb In-Reply-To: <45DB2EBA.5050001@lakeinfoworks.com> References: <45D9CA46.10000@powernav.com> <43d756720702191102o86134e0ufc3f8d640c1ad067@mail.gmail.com> <45D9FDC5.7080400@powernav.com> <45DA3154.9060500@lakeinfoworks.com> <45DB0962.9090609@powernav.com> <45DB2EBA.5050001@lakeinfoworks.com> Message-ID: <45DB389A.6060903@powernav.com> Alan Lake wrote: > Have you installed the Fox Gui itself? Yes > Are you able to run any of the examples in the examples directory of the fox gem? I just tried hello.rb, figuring that if that wouldn't run, then nothing else would. > > /usr/lib64/ruby/gems/1.8/gems/fxruby-1.6.6/examples/hello.rb:3:in > `require': no such file to load -- fox16 (LoadError) > from /usr/lib64/ruby/gems/1.8/gems/fxruby-1.6.6/examples/hello.rb:3 > However, I have > /usr/lib64/ruby/gems/1.8/gems/fxruby-1.6.6/lib/fox16 > /usr/lib64/ruby/gems/1.8/gems/fxruby-1.6.6/ext/fox16 > > I also have a syntax problem with my .bash_profile export of RUBYOPT. I > wish to set both "w" and "rubygems". I seem to be able to set either, > but not both. Can you give me the correct syntax, please? > > Ernest Ellingson wrote: > >> Alan Lake wrote: >> >> >>> I, too, installed fxruby as a gem on a 64-bit machine running Fedora >>> Core 6. I have not yet been able to run Fox with Ruby and get the same >>> error message. Following Ernie's lead, I modified foxGUIb.rb, adding >>> require "rubygems" >>> just before >>> require "version" >>> It appears that I crashing on the first code in this file >>> begin >>> require FOXGUIB_LIBRARY >>> rescue LoadError >>> puts "please install libGUIb!!" >>> puts $! >>> exit >>> end >>> I don't know enough about this code to know what FOXGUIB_LIBRARY >>> contains, or what it's supposed to contain, but I do know that I have a >>> successful install of the library. >>> >>> Can someone advise me of the next step in resolving this problem? Thanks. >>> >>> Ernest Ellingson wrote: >>> >>> >>> >>>> Meinrad Recheis wrote: >>>> >>>> >>>> >>>> >>>>> On 2/19/07, Ernest Ellingson wrote: >>>>> >>>>> >>>>> >>>>> >>>>> >>>>>> I'm at a definite loss here. I downloaded foxGUIb v0.7. I unzipped the >>>>>> files. (Windows XP pro) >>>>>> I ran ruby install.rb in the libGUIb directory. >>>>>> I switched to the foxGUIb directory >>>>>> I tried running foxGUIb_win32.rbw >>>>>> Nothing happened. >>>>>> >>>>>> I tried running ruby foxGUIb.rb >>>>>> I get the following error. >>>>>> >>>>>> >>>>>> please install libGUIb!! >>>>>> no such file to load -- fox16 >>>>>> >>>>>> >>>>>> >>>>>> >>>>>> >>>>>> >>>>> all i can say is that libGUIb16.rb is there, gets called and fails in >>>>> its very first line trying to require fox16. i got no clue about what >>>>> is going wrong... >>>>> >>>>> what happens when you do >>>>> >>>>> require "fox16" >>>>> >>>>> in irb? >>>>> what exception stacktrace do you get when you launch libGUIb16.rb directly? >>>>> >>>>> >>>>> >>>>> >>>>> >>>>> >>>>>> Here is the text in the installed files >>>>>> C:/ruby/lib/ruby/site_ruby/1.8//libGUIb14.rb >>>>>> C:/ruby/lib/ruby/site_ruby/1.8//libGUIb16.rb >>>>>> >>>>>> I have other fox gui's that run fine with require 'fox16' >>>>>> >>>>>> Anyone have a clue as to what has gone wrong? >>>>>> >>>>>> Ernie >>>>>> >>>>>> >>>>>> >>>>>> >>>>>> >>>>>> >>>>> _______________________________________________ >>>>> fxruby-users mailing list >>>>> fxruby-users at rubyforge.org >>>>> http://rubyforge.org/mailman/listinfo/fxruby-users >>>>> >>>>> >>>>> >>>>> >>>>> >>>> Thanks for the response. I figured out what was going wrong and just >>>> now have >>>> it working. My fxruby was installed as a gem. When I upgraded Ruby to >>>> 1.8.5 >>>> windows one click installer, It failed to set the Environmental Variable >>>> RUBYOPT. >>>> with out that environmental variable, you have to require 'rubygems'. I >>>> haven't tried the >>>> foxGUI in Linux yet. However, I know fxruby was installed there as a >>>> gem as well. So >>>> the foxGUI.rb script will have to have a require 'rubygems" in it in >>>> order for it to function >>>> correctly. >>>> I like the gui though. It's very handy. I'm giving a presentation >>>> on fxruby to the Atlanta >>>> Ruby user's group in March. I will be using the gui to explain how the >>>> layout manager works. >>>> It's also nice to have all the events available for a widget as well. >>>> Very nice job. >>>> >>>> Ernie >>>> _______________________________________________ >>>> fxruby-users mailing list >>>> fxruby-users at rubyforge.org >>>> http://rubyforge.org/mailman/listinfo/fxruby-users >>>> >>>> >>>> >>>> >>>> >>> _______________________________________________ >>> fxruby-users mailing list >>> fxruby-users at rubyforge.org >>> http://rubyforge.org/mailman/listinfo/fxruby-users >>> >>> >>> >> Have you installed the Fox Gui itself? Are you able to run any of the >> examples in the >> examples directory of the fox gem? >> >> Ernie >> _______________________________________________ >> fxruby-users mailing list >> fxruby-users at rubyforge.org >> http://rubyforge.org/mailman/listinfo/fxruby-users >> >> >> > _______________________________________________ > fxruby-users mailing list > fxruby-users at rubyforge.org > http://rubyforge.org/mailman/listinfo/fxruby-users > Just to clear up some confusion. I believed I had installed fxruby as a gem on my linux (ubuntu) box, I did not. I downloaded the tarball and compiled fxruby on that machine. Thus no need to require rubygems when running foxGUIb.rb. It runs fine on the linux box with no alterations. I'm not sure what is installed on a linux box when you install the fxruby gem. Although looking at the size of the gem file, there must be a precompiled version of Fox included in that gem. As for your problem. Try putting in a require 'rubygems' in the example files. Does that allow you to run foxGUIb? Since I don't have the linux gem installed, I can't help you much other than to suggest making sure the ruby application knows where required files are located. Usually if libraries are installed in Ruby the ruby knows about all the locations of those libraries. When you require 'rubygems', rubygems is in one of those locations. rubygems will know where to find fox16. Ernie From erne at powernav.com Tue Feb 20 13:09:40 2007 From: erne at powernav.com (Ernest Ellingson) Date: Tue, 20 Feb 2007 13:09:40 -0500 Subject: [fxruby-users] fonts in Linux Message-ID: <45DB3964.7010204@powernav.com> The fonts that Fox uses in Linux look terrible. I saw a post somewhere perhaps here about compiling Fox with some declaration about fonts. However (He slaps his head in disgust) I deleted the email with that post. I've looked through the archives of this mailing list but haven't been able to find a reference to that post. Is there a way to get better fonts in Fox under linux? If so, what is the Fox compile syntax to do that? Ernie From lyle.johnson at gmail.com Tue Feb 20 14:13:15 2007 From: lyle.johnson at gmail.com (Lyle Johnson) Date: Tue, 20 Feb 2007 13:13:15 -0600 Subject: [fxruby-users] Problem using foxGUIb In-Reply-To: <45DB2EBA.5050001@lakeinfoworks.com> References: <45D9CA46.10000@powernav.com> <43d756720702191102o86134e0ufc3f8d640c1ad067@mail.gmail.com> <45D9FDC5.7080400@powernav.com> <45DA3154.9060500@lakeinfoworks.com> <45DB0962.9090609@powernav.com> <45DB2EBA.5050001@lakeinfoworks.com> Message-ID: On 2/20/07, Alan Lake wrote: > I also have a syntax problem with my .bash_profile export of RUBYOPT. I > wish to set both "w" and "rubygems". I seem to be able to set either, > but not both. Can you give me the correct syntax, please? This should work: export RUBYOPT="-w -rubygems" and if the -rubygems thing isn't set, then yeah, it's not going to see a gem-based installation of FXRuby (or any of your other gems, for that matter). From lyle.johnson at gmail.com Tue Feb 20 14:21:23 2007 From: lyle.johnson at gmail.com (Lyle Johnson) Date: Tue, 20 Feb 2007 13:21:23 -0600 Subject: [fxruby-users] Problem using foxGUIb In-Reply-To: <45DB389A.6060903@powernav.com> References: <45D9CA46.10000@powernav.com> <43d756720702191102o86134e0ufc3f8d640c1ad067@mail.gmail.com> <45D9FDC5.7080400@powernav.com> <45DA3154.9060500@lakeinfoworks.com> <45DB0962.9090609@powernav.com> <45DB2EBA.5050001@lakeinfoworks.com> <45DB389A.6060903@powernav.com> Message-ID: On 2/20/07, Ernest Ellingson wrote: > I'm not sure what is installed on a linux box when you install the > fxruby gem. When you install the fxruby gem on Linux (or any other non-Windows platform), it will first compile the FXRuby extension source code, and this may take several minutes. Then it will install that code to your /usr/lib/ruby/1.8/gems/whatever directory as usual. > Although looking at the size of the gem file, there must be a precompiled version > of Fox included in that gem. No. We only provide precompiled versions of FOX and FXRuby in the FXRuby gem for Windows. So there are two gems: the "binary" gem for Win32, which is a pretty quick install (because everything's already compiled), and the "source" gem for any other platform, which compiles FXRuby as it installs. From lyle.johnson at gmail.com Tue Feb 20 14:34:08 2007 From: lyle.johnson at gmail.com (Lyle Johnson) Date: Tue, 20 Feb 2007 13:34:08 -0600 Subject: [fxruby-users] fonts in Linux In-Reply-To: <45DB3964.7010204@powernav.com> References: <45DB3964.7010204@powernav.com> Message-ID: On 2/20/07, Ernest Ellingson wrote: > Is there a way to get better fonts in Fox under linux? If so, > what is the Fox compile syntax to do that? I know that part of the solution is to configure FOX with the setting "--with-xft=yes". For more, you might want to check out this thread: http://article.gmane.org/gmane.comp.lib.fox-toolkit.user/9783 Hope this helps, Lyle From alan.lake at lakeinfoworks.com Wed Feb 21 18:10:43 2007 From: alan.lake at lakeinfoworks.com (Alan Lake) Date: Thu, 22 Feb 2007 01:10:43 +0200 Subject: [fxruby-users] foxGUIb on FC6 x86_64 won't run In-Reply-To: <45DB389A.6060903@powernav.com> References: <45D9CA46.10000@powernav.com> <43d756720702191102o86134e0ufc3f8d640c1ad067@mail.gmail.com> <45D9FDC5.7080400@powernav.com> <45DA3154.9060500@lakeinfoworks.com> <45DB0962.9090609@powernav.com> <45DB2EBA.5050001@lakeinfoworks.com> <45DB389A.6060903@powernav.com> Message-ID: <45DCD173.1060409@lakeinfoworks.com> I began adding comments with my problem to Ernie Ellingson's post, Problem using foxGUIb, because my problem is very similar to his. The difference is that I'm running Fedora Core 6 (x86_64) and he's running Ubuntu. However, I'm totally confused because of the mix up that I caused. I'd like to start this new thread to separate our posts. I hope that this statement of how I installed the separate packages may yield a clue of why I can't run the fox GUI: fox-1.6.21 -- This installed correctly make clean export LDFLAGS="-L/usr/lib64 -L/usr/X11R6/lib64 -L/lib64" ./configure --enable-release make make install make docs fxruby-1.6.6.gem foxGUIb-0.7.1 ruby install.rb -- This installed correctly I copied the foxGUIb directory to ~/Software/ In .bash_profile, I have export RUBYOPT="w" I have tried to add "rubygems" to the above statement, but I can't guess the correct syntax. First test: (I'm repeating the tests as I write this) cd ~/Software/foxGUIb;ruby foxGUIb.rb This yielded: /usr/lib/ruby/site_ruby/1.8/libGUIb16.rb:833: warning: `*' interpreted as argument prefix please install libGUIb!! no such file to load -- fox16 Second test: I modified ~/Software/foxGUIb/foxGUIb.rb to include require "rubygems" but this made no difference Third test: It seems that the line "please install libGUIb!!" is generated by the following code in foxGUIb.rb: begin require FOXGUIB_LIBRARY rescue LoadError puts "please install libGUIb!!" puts $! exit end I added the following line at the beginning of this program: puts "FOXGUIB_LIBRARY = #{FOXGUIB_LIBRARY}" My test gave: FOXGUIB_LIBRARY = libGUIb16 prior to the messages above I have these files: /usr/lib/ruby/site_ruby/1.8/libGUIb16.rb /usr/lib64/ruby/gems/1.8/gems/fxruby-1.6.6/lib/fox16 /usr/lib64/ruby/gems/1.8/gems/fxruby-1.6.6/ext/fox16 I created symbolic links to the lib64 directories from /usr/lib/ruby..., but that didn't help, so I removed the links. Can you suggest what I might try next? From erne at powernav.com Wed Feb 21 19:36:13 2007 From: erne at powernav.com (Ernest Ellingson) Date: Wed, 21 Feb 2007 19:36:13 -0500 Subject: [fxruby-users] foxGUIb possible bug Message-ID: <45DCE57D.1030606@powernav.com> Hi: I've been experimenting with foxGUIb for a while. Everything I have tried as a layout has worked, except the matrix. The layout appears correct in the Main Window layout. However, after generating the code, I get a single row of widgets. I'm trying to layou a simple 2 x 2 matrix. Each cell of the matrix has a button. The layout in foxGUIb looks like this but but but but However, running the code, yields this layout. but but but but Ernie From lyle.johnson at gmail.com Wed Feb 21 21:13:54 2007 From: lyle.johnson at gmail.com (Lyle Johnson) Date: Wed, 21 Feb 2007 20:13:54 -0600 Subject: [fxruby-users] foxGUIb on FC6 x86_64 won't run In-Reply-To: <45DCD173.1060409@lakeinfoworks.com> References: <45D9CA46.10000@powernav.com> <43d756720702191102o86134e0ufc3f8d640c1ad067@mail.gmail.com> <45D9FDC5.7080400@powernav.com> <45DA3154.9060500@lakeinfoworks.com> <45DB0962.9090609@powernav.com> <45DB2EBA.5050001@lakeinfoworks.com> <45DB389A.6060903@powernav.com> <45DCD173.1060409@lakeinfoworks.com> Message-ID: On 2/21/07, Alan Lake wrote: > I hope that this statement of how I installed the separate packages may > yield a clue of why I can't run the fox GUI: > > fox-1.6.21 -- This installed correctly > make clean > export LDFLAGS="-L/usr/lib64 -L/usr/X11R6/lib64 -L/lib64" > ./configure --enable-release > make > make install > make docs OK. > fxruby-1.6.6.gem > foxGUIb-0.7.1 > ruby install.rb -- This installed correctly Just to be clear: How do you know that this installed correctly? Can you run any of the FXRuby examples? > In .bash_profile, I have > export RUBYOPT="w" > I have tried to add "rubygems" to the above statement, but I can't > guess the correct syntax. Did you try my previous suggestion? export RUBYOPT="-w -rubygems" I want to hold off on any more comments until we confirm that FXRuby is installed and working...