# RubyCocoa 0.12.0

**URL:** <https://www.ruby-forum.com/t/rubycocoa-0-12-0/112050>\
**Category:** Ruby\
**Created:** [August 14, 2007, 6:07pm UTC](https://www.ruby-forum.com/t/rubycocoa-0-12-0/112050 "2007-08-14T18:07:32Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Laurent\_S](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/l/65b543/32.png) [@Laurent\_S](https://www.ruby-forum.com/u/Laurent_S)\
**Post date:** [August 14, 2007, 6:07pm UTC](https://www.ruby-forum.com/t/rubycocoa-0-12-0/112050/1 "2007-08-14T18:07:32Z")

</div>

Hi,

I am honored to announce the immediate release of RubyCocoa 0.12.0.

RubyCocoa is a Mac OS X framework that allows Cocoa programming in the  
object-oriented scripting language Ruby. In other words, it is a  
bridge that let you access Objective-C objects from Ruby, and  
vice-versa.

You can learn more about RubyCocoa on our new website:

[http://rubycocoa.sf.net](http://rubycocoa.sf.net)

This release fixes lots of important bugs, and also bring a few  
interesting new features. All users are encouraged to upgrade.

Following are the release notes. Enjoy!

The RubyCocoa Team

Changes:

- Introduced support for using Ruby threads with RubyCocoa. The Ruby  
interpreter must be patched in order to activate the support. The  
binary release ships an already-patched libruby, but if you build from  
the sources, please read misc/README\_THREADING. If you installed Ruby  
from MacPorts, it should be already pre-patched.
- Now automatically registering informal protocol methods defined in  
Ruby to the ObjC runtime.
- When messaging Objective-C from Ruby, we now auto-define the Ruby  
methods on the proxy class (by generating Libffi closures), to make  
#method\_missing called only once per method.
- Better generic Ruby → ObjC boolean conversion, now trying to  
respect the Ruby semantics. Ruby’s true and false are converted as  
true and false, all integers (including 0) are converted as true and  
nil as false.
- When ObjC tries to message a private Ruby method, raises an exception.
- Implemented foo? → isFoo method name conversion.
- Added the docs for the ruby-like setters that are supported by the  
bridge. So for instance NSView will have documentation for  
#setNeedsDisplay() and #needsDisplay=().
- Fixed a PPC bug where floating types were not properly handled by  
variadic arguments.
- Fixed a PPC regression when converting small integers (less than 4  
bytes) from a metadata-driven Ruby method (ex: an informal protocol  
method).
- ObjcPtr.new initialize ObjcPtr.encoding as “uchar” by default and  
clear allocated memory.
- ObjcPtr#allocate\_as\_int{8,16,32} set ObjcPtr.encoding" as “char”,  
“short”, and “int”, respectively.
- OSX.objc\_method: Add acceptable types: BOOL, longlong, ulonglong and  
cstr.
- standalonify: Fixed a bug that occurs when the app bundle already  
contains the RubyCocoa.framework.
- rb\_nibtool: When writing a plist for a given Ruby source code, make  
sure the outlets and actions are ordered in the same order they have  
been defined in the given code.
- rb\_nibtool: Support passing ‘-’ as the source code path, which will  
read on stdin.
- rb\_nibtool: Write the property list as XML.
- rb\_nibtool: If the RubyNode library is present in the system, uses  
it to collect the necessary IB metadata, by parsing the given Ruby  
source code file. If not, uses the old behavior that requires the  
given Ruby source code file and collect the metadata via code  
evaluation.
- Work around possible warnings when defining module functions from  
bridge support, in case a function has already been defined.
- Templates: Modified method definition by appropriate syntax, because  
it was written by obsoleted syntax.
- Templates: Removed the .pch files in CoreData projects.
- Templates: Modified the main.m files to `#import \<Cocoa/Cocoa.h\>',  
to give a hint to the Xcode indexer.
- Samples: New CocoaRepl example.
- Samples: Removed references to the 10.4u SDK and use instead the  
current SDK.
- Fixed --build-universal for systems higher than 10.4.
- Improved ObjcPtr#regard\_as to accept an ObjC runtime encoding string.
- Added the class method ActiveRecordProxy.on\_get() which can be used  
to define filters to be applied when a specified key is requested in  
rbValueForKey. So the filter will be run before returning the data.
- Fixed some bugs when importing NSProxy-based classes.
- Define #dup and #clone for C structures boxed types.
- Proxy classes are now automagically defined when a  
ActiveRecord::Base subclass is defined.  
ActiveRecord::Base#to\_activerecord\_proxy now caches the proxy class  
name.
- Fixed NULL to C strings and opaque types conversion.

---

<div class="post-metadata">

**Author:** ![Laurent\_S](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/l/65b543/32.png) [@Laurent\_S](https://www.ruby-forum.com/u/Laurent_S)\
**Post date:** [August 14, 2007, 6:41pm UTC](https://www.ruby-forum.com/t/rubycocoa-0-12-0/112050/2 "2007-08-14T18:41:37Z")

</div>

On 8/14/07, unbewust [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid) wrote:

> The latest release is 0.11.1p1.  
> Thanks, I just forgot to update the website, now it’s done 🙂

Please tell us if you find something wrong again,

Laurent

---

<div class="post-metadata">

**Author:** ![Laurent\_S](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/l/65b543/32.png) [@Laurent\_S](https://www.ruby-forum.com/u/Laurent_S)\
**Post date:** [August 14, 2007, 6:21pm UTC](https://www.ruby-forum.com/t/rubycocoa-0-12-0/112050/3 "2007-08-14T18:21:34Z")

</div>

On 14 août, 18:04, “Laurent S.” [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid)  
wrote:

> Hi,
> 
> I am honored to announce the immediate release of RubyCocoa 0.12.0.

Great news thanks a lot !

however this new release didn’t propagate enough :

The latest release is 0.11.1p1.

best,

Yvon
