20345-21580

20178-20644 subjects 20588-22393

Win32 Functionality
20345 [tub4jxr@ho m] Does anyone know of a robust distribution of WIN32 functions such as
20350 [aleksei.guze] What functions You nedd ( what windows services) ? I will append them to
20384 [sol123@ms .c] ...
+ 20395 [tub4jxr@ho m] Thank you for the post.  I look forward to the code.
+ 20400 [alwagner@tc ] in the RAA there is something called Ruby/Python (I think) that interfaces

Digest::MD5 usage...
20352 [sean-ruby-ta] require 'digest/md5'
20358 [neumann@s- i] Digest is new in Ruby 1.7.

File.new() strangeness...
20354 [sean-ruby-ta] f =3D File.new('testing', 0600, File::CREAT|File::TRUNC|File::WRONLY|File::=
20355 [sean-ruby-ta] Ah! Figured it out.  Dave, I have some errata for 'ya.  Page 308=20
20370 [Dave@Pr gm t] Sorry to have inconvenienced you.

Vector graphics
20356 [aleksei.guze] Is there an open crossplatform vector-based graphics file format
+ 20364 [kero@d4 50 u] Tk Canvasses can dump their content in EPS.
+ 20369 [mikkelj-anti] Not that I'm aware of. But I'd like to point your attention to the XML based
| 20394 [aleksei.guze] # Not that I'm aware of. But I'd like to point your attention
| 20405 [kero@d4 50 u] Only PS dump, no rendering/playing.
+ 20398 [jgraham@si n] I do not know if you are interested in Flash format or not but there are

attribute setting method white space, bug?
20360 [zarkon_z@ho ] I am using ruby 1.6.4 (2001-06-04) [i386-cygwin] , it's for windows
+ 20372 [Dave@Pr gm t] Well, say you had a method called move_piece. Would be be OK to add
+ 20375 [neumann@s- i] The method name is "durationInMinutes=", this is found in anObject.methods, or

Summary: Features of Ruby or Why I like Ruby
20362 [neumann@s- i] I've put up some points for a presentation, why I like Ruby.

Freezing state in the Ruby interpreter (RCR?)
20366 [jjthrash@po ] Unlike Java and Smalltalk, Ruby doesn't have any file/class bindings.
20380 [neumann@s- i] Maybe it's doable if we have a hook function that gets called whenever a "class"
20391 [pit@ca it in] If you don't mind exactly which classes to reload, maybe it is

Does RubyTK work on Mac?
20371 [andy@to ls e] If not, what do you Mac fans use?
+ 20393 [alunapr@ap l] My biggest problem right now. It looks like you can install  GTK, and I
+ 21580 [msnomer@sp m] AFAIK, TK isn't available for OS X. I hope someone does a port, or that

The word "dynamicity"
20381 [hal9000@hy e] Question for the community -- mainly the
+ 20382 [sean-ruby-ta] I don't think it's a word, but it sure does look and sound neat! =20
+ 20383 [Dave@Pr gm t] You're absolutely right - it's in the Compact OED it's a synonym of
| 20388 [schneiker@ju] And perhaps, "Ruby's dynamical nature, ...."?
+ 20387 [james@ja es ] How about 'dynamism'?
+ 20465 [pdcawley@it ] But you can say 'Dynamism', which is a perfectly valid word and

Exemplars, Prototypes, ?
20386 [charleshixsn] I think that the word should be exemplar, but a google search of

Object Persistence in PostgreSQL
20390 [gabriel@de o] Any advice or existing publicly available work done for ruby object
+ 20404 [sean-ruby-ta] There isn't one for postgres (that I'm aware of)... not yet at
+ 20418 [neumann@s- i] For Ruby/DBI (www.ruby-projects.org/dbi) I've written a simple storage system, that

Ruby vs Python / Perl for Win32 Administration
20396 [tub4jxr@ho m] I'm a sysadmin for several NT, Solaris, and Linux boxes.  I currently
20403 [neumann@s- i] Use WIN32OLE for this.
20451 [mikkelj-anti] I hate to say this, but WIN32OLE is not sufficiently reliable - you may be
20473 [neumann@s- i] Do you mean that the Ruby library WIN32OLE is not reliable or in general

returning from Tk.mainloop
20397 [cpine99@ho m] When I have a tk window open and I close it with the close (X) button up in
20406 [kero@d4 50 u] You "exit" Ruby! What do you expect?

rwiki/drb problem
20399 [hdstich@hd t] drb gives me the following error message when I try to start

What is Method#unbind used for?
20401 [ned@bi e- om] I see that Method supports an instance method called unbind.
20402 [decoux@mo lo] See

Neck and neck in the Perl/Python poll
20407 [Dave@Pr gm t] Perl               37.34% (90)

Windows socket problem?
20409 [chadfowler@y] I'm not usually a user of the Ruby Windows port, but
20410 [chadfowler@y] I suppose I should have mentioned that the same code
20412 [chadfowler@y] Please excuse my spam, but I now see this same problem

Changes in ruby implementation ? Do we need it ?
20411 [domingo@da -] I'm looking for a way to have more than one instance of one
+ 20423 [decoux@mo lo] Well, you can perhaps take a look at RubyInterpreter
+ 20464 [olivier@vi e] I was also looking in that direction and fell to the same conclusion!

Interactive objectspace script...
20413 [sean-ruby-ta] Hey.  I've included a script that lets you traverse part (most?)
20414 [sean-ruby-ta] Whoops!  I had the perms on so that you could only get access to=20

Cygwin DLL conflict (was: New Windows InstallShield version of Ruby)
20415 [kevinbsmith@] I guess my suggestion was only if you didn't believe or

handling errors without exiting
20420 [mmilanesi@bc] First of all, I'm a newbie in OOP programming and ruby so please excuse me
20422 [sean-ruby-ta] me
20425 [mmilanesi@bc] require 'net/http'
+ 20426 [sean-ruby-ta] 1,}/ =3D~ line}
+ 20429 [ r2d2@um .s ] As the program is now, it will jump out of the loop to the exception
  20431 [mmilanesi@bc] it worked. thank you, I was really stumped!

kanji size
20432 [arachis@gm .] puts "{K}".size            # --->  2
20433 [decoux@mo lo] Well, you're probably working with 1.6.* or 1.7.* but with ruby_m17n
20435 [matz@ru y- a] You were right.  But Dave Thomas persuaded me that they should behave
20438 [arachis@gm .] Er... sorry for being a bit dumb... I'm still not an advanced ruby user ;)
20446 [matz@ru y- a] The "latest" ruby at the "ruby_m17n" branch.  So for you -1.6.4 user-
20463 [arachis@gm .] Ok, got that. Thank you.

huge variations in execution times on Win32
20439 [bdelmee@ad a] I just installed the latest distro prepared by Andrew, and

YACC & lex and Ruby
20441 [thucdat@ho m] ...
20494 [markus.lado@] probably you mean Ruby + racc
+ 20497 [thucdat@ho m] ...
+ 20498 [geniusj@bl e] This might be slightly off topic, but the conversation has sparked an inter=
  + 20499 [waisun.chia@] Yes, it's YAAB (yet another animal book)! ;-)
  + 20527 [markus.lado@] info bison

Cygwin DLL - What does it do?
20456 [tub4jxr@ho m] My apologies for this question, but what does the CYGWIN dll do on the
+ 20458 [aleksei.guze] Not UNIX emulation. It implements some functions from POSIX standards.
+ 20459 [eban@os ri .] eban

attained the impossible
20457 [joe@vp p. et] I did it.  I convinced my bride of 5 years (coming up) to spend our
20460 [Dave@Pr gm t] Your wife is a brave woman. Looking forward to meeting you both.
20467 [andy@to ls e] Remarkable.  Is she a programmer too or just a good sport?

recursive lambda forms
20462 [theschof@cs ] It occurs to me that being able to create recursive lambda forms
+ 20469 [jweirich@on ] This isn't exactly what you want, but it reminds me of a "problem"
| 20493 [pit@ca it in] the Y combinator was fun, indeed.
| 20495 [jweirich@on ] I don't know if I would call either of them *readable*. :-)
+ 20496 [theschof@cs ] That certainly works, and serves to show why a truly anonymous
| 20507 [pit@ca it in] I hoped to find a way to write something like
+ 20556 [john.carter@] One could perhaps take the route similar to that of Manfred von Thun's Joy

News on Rajah?
20468 [tammo.freese] Some time ago, there was a post on a ruby-java bridge called "Rajah".

Various FXRuby weirdnesses
20470 [jjthrash@po ] In programming with Fox and Ruby recently, I've come across a couple
+ 20472 [alwagner@ua ] Yes, I too have lots of segfaults when running FXRuby.  I don't
| 20514 [jjthrash@po ] Well, this makes me wonder how I need to restructure my code.  The
| 20515 [alwagner@ua ] Sorry, what I undertook was not a very intelligent operation. My
+ 20633 [ljohnson@re ] Jimmy,

RE: cygwin and win32 interaction (RE:  Re: Bug i n require?)
20471 [cbroult@sa i] ...
20482 [bdelmee@ad a] (replying to my message)

hml tag removal
20474 [w3gat@be ls ] Does anyone have a Ruby routine to strip the html tags off a document and
+ 20487 [jose@ox ge o] That must work
| 20492 [charleshixsn] but consider
+ 20504 [decoux@mo lo] Yes it's in perl and this is why you'll not use it :-)
  + 20522 [ned@bi e- om] Numbers 2<1
  | 20523 [decoux@mo lo] Try to check the document that I've given in [ruby-talk:20504] with the
  | 20533 [in6x059@pu l] I am impressed. I wouldn't have thought that it is legal HTML to
  + 20534 [in6x059@pu l] using a regexp: Until minutes ago I didn't know the above is valid
    20536 [decoux@mo lo] See my regexp given in [ruby-talk:20477]. This regexp just try to extract

Virtual Machine references?
20491 [ptkwt@sh ll ] Some of the threads here recently which touch on the issue of virtual
+ 20503 [Pierre-Charl] There is a course on OO VM Design and Implementation, with slides and
+ 20510 [hipster@xs a] Take a look at the Wizard Book, Structure and Interpretation of

Question: How to use TCPSocketServer and threads on  Win32
20508 [mulperi@ik .] here is what I'm trying to do, unfortunately this block on
20509 [decoux@mo lo] You have an example of TCPserver in the documentation of ruby
20567 [mulperi@ik .] Unfortunately this example does not show how to connect to
20568 [decoux@mo lo] pigeon% cat b.rb
20570 [mulperi@ik .] Thanks! I was pretty close with my own tryings 8-).

a more interesting ruby example fib.rb
20512 [fritz.heinri] What about using this as ruby-Fibonacci-Example? It highlights rubys
20597 [john.carter@] That is just so pretty.

Question to the Tk/whatever GUI gurus: displaying trees
20513 [armin@ap ro ] this is only partly related to Ruby. I'm writing a Ruby prg. that needs
20517 [Dave@Pr gm t] Could you pipe your data to a subprocess running 'dot'?
20518 [armin@ap ro ] Yes!
20529 [Dave@Pr gm t] ...
20535 [armin@ap ro ] Exactly what I had dreamed to find. Thanks a lot to Dave.

A plea for CPAN in Ruby
20516 [avdi@my ro t] I know it's bad manners to ask for some non-trivial feature without offering
20520 [gabriel@de o] Hrm.  I think my preference would be to code them as needed in Ruby.  I'd
+ 20546 [neumann@s- i] This is one possible solution. Perhaps I'll extract some parts of GD::Graph to
+ 20560 [jweirich@on ] I'm wondering if a "MostWanted" page should be setup in the Ruby Wiki
  20563 [Dave@Pr gm t] Cry havoc!

string replacement in C interface ?
20519 [Vincent.Pica] I am writing a new ruby module in C and I can't find the equivalent of
20526 [decoux@mo lo] You can call rb_funcall(), if you want to call String#replace. Something

Problem with float numbers
20524 [bombadil@wa ] I have found a rare problem with float numbers. It only raises when I use
+ 20525 [matz@ru y- a] I think it's caused by locale. Gtk calls setlocale() inside.
| + 20531 [erik@ba fo s] I think you are correct
| | 20537 [matz@ru y- a] I don't know.  Maybe a bug in Ruby.  I hope not.
| | 20566 [decoux@mo lo] It came from here (flo_to_s). rb_f_puts is called will a Float and
| | 20599 [matz@ru y- a] Thank you.  I just removed the dependency on assumption that decimal
| + 20544 [eban@os ri .] % setenv LC_NUMERIC C
| + 20557 [davinci@es o] Yes. But what about the other problem?
|   20562 [matz@ru y- a] Probably strtod() returns 3.0 (actually 3,0 in this case) for "3.45"
|   20569 [bombadil@wa ] Any solution for this? I don't understand why it fails with locale. I
|   20574 [pixel@ma dr ] setlocale(LC_NUMERIC, "C")
+ 20530 [erik@ba fo s] 5.2

Ruby, DBI, design
20528 [steved-clr@d] Can anyone point me to example Ruby code that uses an SQL database.
+ 20532 [erik@ba fo s] I've only used the ruby-dbi-layer as a test but I found it very nice and
+ 20538 [alwagner@ua ] A field is an instance of Column.
| 20645 [toddg@li ux ] And how have you implemented JOINs?
| + 20649 [alwagner@tc ] For who?   An SQL savy programmer?  Or an end user who doesn't understand the
| | 20654 [toddg@li ux ] This was not a rhetorical question.  I am only interested in how you had
| + 20670 [neumann@s- i] It's like PStore with multiple keys - no joins. It marshalls Ruby objects and
+ 20542 [ r2d2@um .s ] [steved-clr@daviesfam.org]

(1) ASCII Code, (2) ()-operator
20539 [fschaef@ce .] 1) how do I compare an integer against let's say '\n' or ' '
+ 20540 [Pierre-Charl] 'a'[0] is the same as ?a. Use " "[0], "\t"[0]...
| 20543 [Dave@Pr gm t] You can generate character constants for any characters: page down
+ 20541 [decoux@mo lo] pigeon% ruby
+ 20548 [matz@ru y- a] ?\s for space

CGI in Ruby with Apache and Exec
20547 [p_hilton@ex ] I am a newbie to the Ruby programming language. I have have found it
+ 20549 [ned@bi e- om] Does your script work from the command line? Have you told Apache how to run
+ 20550 [eli.green@co] It has been my experience that Apache rarely throws a 500 Server Internal
+ 20552 [bdelmee@ad a] Assuming ruby is on your path (typically C:\Ruby\bin), and that
| 21081 [p_hilton@ex ] Thanks to all the guys who replied to my queries regarding Exec and
+ 21082 [stephen.hill] Phil,

Multiple args to constructor
20553 [fschaef@ce .] now, how can I process multiple arguments by the constructor.
+ 20554 [cbroult@sa i] ...
+ 20555 [ned@bi e- om] Assuming you have only one way you want to call new(), just define an
+ 20564 [thegrandbrie] what about
  20572 [neumann@s- i] def initialize ( *args )
  20657 [thegrandbrie] oops... thx.

Re: A plea for CPAN in Ruby - NO Please!
20558 [john.carter@] Hmm, that was my cry at first, but it is fading...

2nd RFD: comp.software.patterns
20559 [panu@fc .n t] 2nd RFD: comp.software.patterns

Equivalent of Perl Format
20561 [zak_mail@ya ] In my project I need to print report to dot-matrix printer

multi-lingual inline comments using rd...
20565 [sean-ruby-ta] How does the RD format handle multi-lingual documentation?
20601 [sean-ruby-ta] Let me take another shot at asking this.  In the interest of
20603 [matz@ru y- a] net/smtp.rb etc. used the last scheme.  They put Japanese document in

To those who want abstract classes in Ruby
20571 [   ml@sp .d ] There are people who miss a feature like abstract/virtual
+ 20573 [nat.pryce@b1] There is very little need for this in Ruby, and it can be a drawback.
| 20575 [   ml@sp .d ] Also las ich bei Nat Pryce [mailto:nat.pryce@b13media.com]
| 20576 [nat.pryce@b1] Yes, thinking in Ruby is closer to thinking in Smalltalk than thinking in
+ 20577 [jweirich@on ] I did something similar at one point.  I didn't bother with the
  20578 [   ml@sp .d ] Also las ich bei Nat Pryce [mailto:nat.pryce@b13media.com]
  20593 [nat.pryce@b1] That's a good analogy.

hml tag removal
20579 [w3gat@be ls ] Thanks everyone.  The suggestions worked just fine.  I appreciate the help.

Relative path
20580 [Milan.Gardia] what is the shortest & quickest way of finding a relative path between path1
+ 20581 [aaron.barnet] i havnt impressed myself with the elegance of this solution, but it works.
| + 20582 [decoux@mo lo] perhaps you can replace it with
| + 20583 [renaud.heber] def rel_path(a, b)
|   + 20584 [decoux@mo lo] Use File::expand_path to remove these cases
|   + 20586 [rtarpine@ho ] def rel_path(a, b)
|     20610 [decoux@mo lo] When you call #split without a value for the parameter limit, ruby remove
+ 20666 [zak_mail@ya ] Assalamu'alaikum wr. wb.
  20667 [decoux@mo lo] path1 = "/temp/foo\t/temp/foo"

Weird things with eval
20585 [pbrannan@at ] class Module
20591 [dblack@ca dl] The part I don't get, as a general matter, is why #send gets to bypass
+ 20615 [decoux@mo lo] Well, you don't give the same example
| 20617 [dblack@ca dl] I wasn't trying to :-)
| 20619 [decoux@mo lo] OK, sorry
+ 20624 [pbrannan@at ] Both dRb and ROMP use __send__ to pass messages from a socket to an
| 20625 [dblack@ca dl] It's good to know about though, since it seems to mean that access
| 20627 [pbrannan@at ] Is there any reason why send() could not be changed to obey the access
| 20631 [matz@ru y- a] Always remember that access rules in Ruby are just fool proof.  So
| 20632 [dblack@ca dl] Isn't this more like a front door, though? :-)  I don't know -- maybe
| 20662 [matz@ru y- a] Maybe because Ruby is a mansion, a backdoor is bigger than you expect.
+ 20626 [pbrannan@at ] I see, this seems to be the case.
  20628 [Dave@Pr gm t] Because a bare method definition makes 'bar' a private method of

Calling ruby methods from C++
20587 [jglueck@vo .] I have been integrating Ruby into my game engine, and it works quite nicely, I can export my game objects to ruby classes which are then instantiated in scripts
threads.html
top