CalendarCtrl - Weekdays names - Month names

Hi there!
I’ve been using wxRuby for some days, and already done some quite neat
apps, but (there is always a but) even though I thought WeekDays names
and month names where governed by the OS (and local localization), my
calendar shows up with english names.
I haven’t been able to find a method or attr on the calendarctrl to
override this.
So, is it possible to use custom names (Mon-Tue-Wed-Thu-Fri-Sat-Sun) ->
(Lu-Ma-Mi-Ju-Vi-Sa-Do) as well as month names for use in foreign apps?
Best regards
Carlos Troncoso Phillips

Hi

Carlos Troncoso Phillips wrote:

I’ve been using wxRuby for some days, and already done some quite neat
apps, but (there is always a but) even though I thought WeekDays names
and month names where governed by the OS (and local localization), my
calendar shows up with english names.
I haven’t been able to find a method or attr on the calendarctrl to
override this.
So, is it possible to use custom names (Mon-Tue-Wed-Thu-Fri-Sat-Sun) ->
(Lu-Ma-Mi-Ju-Vi-Sa-Do) as well as month names for use in foreign apps?

My native locale is en_GB, but when I added this to the top of the
calendar sample:

Wx::Locale.new(Wx::LANGUAGE_FRENCH)

the calendar control correctly displays the weekdays as “Lun Mar Mer
Jeu…” and with the french month names. This is on OS X.

I had a look at the wxWidgets code that handles this, and it should be
using the same locale-sensitive system calls as Ruby itself. Could you
say a) what operating system you’re using and b) whether a ruby call
like

Time.now.strftime("%A")

returns the correct local name?

You could try adding a call like the above
Wx::Locale.new(Wx::LANGUAGE_XXX) for the correct language to see if that
sets what you want.

alex