similar to: rspec runner setting $KCODE considered harmful?

Displaying 20 results from an estimated 2000 matches similar to: "rspec runner setting $KCODE considered harmful?"

2006 Feb 15
1
where to set $KCODE
My application uses only UTF-8. Which is the canonical place to do something global like setting $KCODE? -- fxn
2007 Nov 13
1
win32-api idea - wide method first based on $KCODE
All, Currently, the Win32::API.new method will search for the function name, then the ''A'' (ANSI) name, and finally the ''W'' (Wide) name. The code looks something like this: fProc = GetProcAddress(hLibrary, TEXT(RSTRING(v_proc)->ptr)); if(!fProc){ VALUE v_ascii = rb_str_new3(v_proc); v_ascii = rb_str_cat(v_ascii, "A", 1); fProc =
2005 Mar 16
1
Re: Unicode support
How about this: we expose the known conversions of wxMBConv to wxruby global methods. Then we create a $WXSTRING_TO_RUBY and $RUBY_TO_WXSTRING globals that has a reference to those procs. In the ruby-string to wxString typemap, we use ruby to invoke $WXSTRING_TO_RUBY and $RUBY_TO_WXSTRING. That way, if people want a different method, they can write one (even a pure-ruby one) that changes the
2006 Jan 05
1
unicode hacks - fixes for webrick and Safari
Hello! First, thank you Julian for the useful plugin ''unicode_hacks'' < http://julik.textdriven.com/svn/tools/rails_plugins/unicode_hacks/>. I have found some problems running my app in development on Webrick and looking at it with Safari (MacOS X 10.4.3, Safari 2.0.2). Some files are sent with different sizes (e.g. default css example, or controls.js ), and it
2008 Jun 18
2
[ win32utils-Bugs-20722 ] Windows::Error.get_last_error only returns the first character (PATCH)
Bugs item #20722, was opened at 2008-06-18 15:16 You can respond by visiting: http://rubyforge.org/tracker/?func=detail&atid=411&aid=20722&group_id=85 Category: windows-pr Group: Code Status: Open Resolution: None Priority: 3 Submitted By: John Whitley (whitley) Assigned to: Nobody (None) Summary: Windows::Error.get_last_error only returns the first character (PATCH) Initial
2008 May 06
1
Problem with ActionWebService and UTF-8 encoding
Hello, I have a Rails App which serve a Soap Web Service with ActionWebService. I accept 2 string parameters that must contain xml. The data sent are in UTF-8, but the non-ascii char (é, à ...) in the message are crippled at the end. I tested the app, database, html, ... all accept utf-8, a direct http post works well, but going through the web service broke the content. I tried to manually set
2011 Sep 14
1
Hitting 500 status code on invalid UTF-8 byte sequence in params
Hello Core, Background: with Redmine-1.2 on Rails-2.3.11 we''re experiencing a "500 Internal Server Error" every time a mail with invalid UTF-8 byte sequence is hitting the MailHandler (the exception comes from the DB complaining about invalid string in the INSERT statement.) Since we do care about internal errors we''ve installed exception_notification plugin and this
2009 Jun 17
12
FasterCVS and Rails
Hello all, I''m trying to import some csv data (that has latin characters) using faster csv but I keep getting a MalformedCSVError: "Unclosed quoted field on line 1." "/ruby/lib/ruby/gems/1.8/gems/fastercsv-1.2.3/lib/faster_csv.rb:1592:in `shift''" I''ve tested the same code outside of the Rails application an it works fine. Can anyone help me? Here is
2006 Jan 10
1
Validating Umlauts
Hi there, I''m building a rails application for German and English speakers. However, I''m having some problems validating German-specific characters (????). I have a tag-model which validates format of :name, :with => /^\w+$/. This throws an exception if german characters are used. My tables are all utf-8 and my environment.rb has the lines $KCODE = ''u''
2010 Mar 18
1
capitalize and utf8 international symbols
Hi there, Being a relatively happy Rails user I suddenly noticed that string#capitalize and friends do not play well with international characters well. Sample console session: $ ./script/console Loading development environment (Rails 2.2.3) >> $KCODE => "UTF8" >> "яблоко".capitalize => "яблоко" Where "Яблоко" was expected (Russian word
2007 Mar 28
2
iconv does not work with french characters
Hello, I am trying to convert french characters into latin ones using inconv but I face some problems. Here is what I am doing in ruby console: >> $KCODE = ''u'' => "u" >> @x = ''x éèçà x'' => "x éèçà x" >> Iconv.new(''US-ASCII//TRANSLIT'', ''utf-8'').iconv @x => "x ???? x"
2008 Oct 14
6
Disabling XML character escaping for to_xml
Currently, it appears to_xml will automatically escape any entities into their corresponding &XXX representation. There''s a piece in the documentation that says "If $KCODE is set to u and encoding set to UTF8, then escaping will NOT be performed." Unfortunately, this doesn''t appear to be the case. Even after following the docs and ensuring that default_charset is
2007 Apr 29
1
Chinese full-text support! Still fail-_-
Hi all, I want to use ferrent in my website but when i input chinese words, i have the same symptom like Chengcai. In order to fix it, i have reviewed all the topics about chinese support in our forum and tried all the way your guys suggested but still made any progress. i downloaded the latest version of ferret from svn. Thanks and regards. captain Chengcai He wrote: > Hello everyone!
2005 Aug 28
7
Unicode support in FXRuby 1.6
All, As some of you know, Jeroen has added support for Unicode strings in the unstable development version of FOX (version 1.5). I''m trying to plan ahead to decide how best to support this for FXRuby 1.6, but I don''t really know anything about Ruby''s support for Unicode or i18n in general. If you''re familiar with this topic (how/if Ruby deals with Unicode
2012 Feb 28
4
JIRA anyone?
I''m trying to evaluate what use I can make of JIRA with Rails/Ruby and am getting frustrated. The jira4r gem will install but the soap4r gem won''t load. literally: ''irb -r soap4r'' returns :cannot load such file... I also set this up in a Gemfile and tried to run this from the rails console:
2006 Jul 18
10
searching with chinese chars
Hi all, maybe not a Ferret question, but I assume here might have came across that already. I wrote a simple CGI app that adds docs into a Ferret index. The idea is testing asian languages input and searching. The script that does the input seems to be OK. As David mentioned in a question I made a little while ago, Ferret''s index is agnostic, in the sense that you can store anything in
2009 May 03
13
Ruby or Rails bug?
In irb all works fine: # irb irb(main):001:0> require ''rubygems'' => true irb(main):002:0> require ''raspell'' => true irb(main):003:0> speller = Aspell.new("ru_RU") => #<Aspell:0x7f8692c9d158> irb(main):004:0> speller.suggestion_mode = Aspell::NORMAL => "normal" irb(main):005:0>
2007 Apr 05
7
Re: how to use Chinese Characters in wxRuby?
yes,I'm using wxruby2 When I change "samples/text/unicode.rb" 's content: require 'wx' into begin require 'wx' rescue LoadError => no_wx_err begin require 'rubygems' require 'wx' rescue LoadError raise no_wx_err end end and run unicode.rb in this way: ruby -Ku unicode.rb I got the error message like this: unicode.rb:119:
2006 May 26
13
win32-dir, unicode
Hi, I''ve got a preliminary version of the pure Ruby version of win32-dir in CVS. However, I was hoping to work out the Unicode issue. Run this: from = "C:\\test" to = "?????" Dir.mkdir(from) unless File.exists?(from) Dir.create_junction(to, from) It works, but my explorer (and dos) window shows the name garbled. I don''t think it''s a font
2007 Jul 20
8
Wx::StaticText
Salut alex. J''ai une question a propos de wx::statictext(wxruby2) est-il possible de mettre les accents pour la langue française?, car pour l''instant je ne peut pas mettre l''accentuation alors que ça marche bien avec "wxruby". merci Sebastien _______________________________________________ wxruby-users mailing list wxruby-users@rubyforge.org