Change encoding of OSX::ObjCPtr#bytestr return value to dummy

git-svn-id: https://svn.code.sf.net/p/rubycocoa/svn/trunk/src@2569 f4f36d40-9719-0410-9868-dde021a23eda
Fix test_ocptr_ary_assign fails on ruby-1.8

git-svn-id: https://svn.code.sf.net/p/rubycocoa/svn/trunk/src@2570 f4f36d40-9719-0410-9868-dde021a23eda
Fix missing symbol rb_enc_str_new_cstr on ruby-2.0

rb_enc_str_new_cstr() in include/ruby/encoding.h is provided
by ruby-2.1 or later. use rb_enc_str_new().

git-svn-id: https://svn.code.sf.net/p/rubycocoa/svn/trunk/src@2571 f4f36d40-9719-0410-9868-dde021a23eda
Add argument vaidation to OSX.load_plist()

OSX.load_plist() accepts String, OSX::NSString and OSX::NSData.

  OSX.load_plist(nil) # => ArgumentError
  OSX.load_plist(broken_input) # => RuntimeError

git-svn-id: https://svn.code.sf.net/p/rubycocoa/svn/trunk/src@2572 f4f36d40-9719-0410-9868-dde021a23eda
Allow running tests with `minitest`, standard library of ruby-2.0

test-unit            minitest
---------------------------------------------
assert_true(cond)    assert_equal(true, cond)
assert_false(cond)   assert_equal(false, cond)

git-svn-id: https://svn.code.sf.net/p/rubycocoa/svn/trunk/src@2573 f4f36d40-9719-0410-9868-dde021a23eda
Improve launch process of RubyCocoa applications on ruby-2.x

- use ruby_run_node(node) on ruby-2.x.
- NSString#fileSystemRepresentation returns regular string.

on ruby-2.x, a return value type (char *) from Objective-C becomes Ruby
String with dummy encoding "RUBYCOCOA_UNKNOWN".

NSString#fileSystemRepresentation is used in most of rb_main.rb.
If the method returns regular string, we need not to modify rb_main.rb
of out RubyCocoa apps.
Use st_table for string encoding conversion
Improve launch process of RubyCocoa applications on ruby-2.x

- use ruby_run_node(node) on ruby-2.x.
- NSString#fileSystemRepresentation returns regular string.

on ruby-2.x, a return value type (char *) from Objective-C becomes Ruby
String with dummy encoding "RUBYCOCOA_UNKNOWN".

NSString#fileSystemRepresentation is used in most of rb_main.rb.
If the method returns regular string, we need not to modify rb_main.rb
of out RubyCocoa apps.

git-svn-id: https://svn.code.sf.net/p/rubycocoa/svn/trunk/src@2574 f4f36d40-9719-0410-9868-dde021a23eda
Add st_table and functions for encoding conversion

st_table
- rb2ocEncConv: ruby encoding index -> CFStringEncoding
- oc2rbEncConv: CFStringEncoding -> ruby encoding index

function - lookup conversion table
- strenc_rb2oc()
- strenc_oc2rb()

function - register conversion table
- register_strenc_rb2oc()
- register_strenc_oc2rb()
- register_strenc_pair()

git-svn-id: https://svn.code.sf.net/p/rubycocoa/svn/trunk/src@2575 f4f36d40-9719-0410-9868-dde021a23eda