Xojo Conferences
MBSSep2018MunichDE
XDCMay2019MiamiUSA

[MBS] Language support? (MBS Xojo Plugin Mailinglist archive)

Back to the thread list
Previous thread: [MBS] 4.0dr3
Next thread: [MBS] get Global Coordinates (LocalToGlobal)


Re: [MBS] MIDI Destinations and External Devices   -   Ron Benditt
  [MBS] Language support?   -   Juergen Schreck
   Re: [MBS] Language support?   -   Christian Schmitz
    Re: [MBS] Language support?   -   Brian Rathbone
     Re: [MBS] Language support?   -   Christian Schmitz
      Re: [MBS] Language support?   -   Brian Rathbone
       Re: [MBS] Language support?   -   Juergen Schreck
        Re: [MBS] Language support?   -   Christian Schmitz

[MBS] Language support?
Date: 14.01.04 17:29 (Wed, 14 Jan 2004 10:29:50 -0600)
From: Juergen Schreck
Hi,

Is there something in the MBSPlugin that would allow me to detect what
language a user is using on a given platform.

I suppose for Mac, one could check the system.countrycodeMBS .

How is it done on windows?

TIA,
Juergen

Re: [MBS] Language support?
Date: 14.01.04 19:46 (Wed, 14 Jan 2004 19:46:07 +0100)
From: Christian Schmitz
Juergen Schreck <<email address removed>> wrote:

> Hi,
>
> Is there something in the MBSPlugin that would allow me to detect what
> language a user is using on a given platform.
>
> I suppose for Mac, one could check the system.countrycodeMBS .
>
> How is it done on windows?

Simply: I don't know this.
You can make it user choiceable.
And to check between German and English, it may be enough to check if
the documents folder starts with "Dok" for German.

Mfg
Christian

Re: [MBS] Language support?
Date: 14.01.04 20:53 (Wed, 14 Jan 2004 14:53:23 -0500)
From: Brian Rathbone
I am not sure about on Mac, but here is a quick port of the API call for
Windows...

Dim Buffer As memoryBlock
dim Ret As integer

Declare Function GetLocaleInfo Lib "kernel32" Alias "GetLocaleInfoA"
(Locale As integer, LCType As integer, lpLCData As ptr, cchData As integer)
As integer

buffer = newmemoryBlock(256)
Ret = GetLocaleInfo(&h400, &h1001, buffer, 256)
If Ret > 0 Then
msgbox "English name of language: " + buffer.cstring(0)
Else
msgBox "Check Lasterror " + str(ret)
End If

//Const LOCALE_USER_DEFAULT = &H400
//Const LOCALE_SENGCOUNTRY = &H1002 ' English name of country
//Const LOCALE_SENGLANGUAGE = &H1001 ' English name of language
//Const LOCALE_SNATIVELANGNAME = &H4 ' native name of language
//Const LOCALE_SNATIVECTRYNAME = &H8 ' native name of country

More information here:

http://www.mentalis.org/apilist/GetLocaleInfo.shtml

hth,

Brian

----- Original Message -----
From: "Christian Schmitz" <<email address removed>>
To: <<email address removed>>
Sent: Wednesday, January 14, 2004 1:46 PM
Subject: Re: [MBS] Language support?

> Juergen Schreck <<email address removed>> wrote:
>
> > Hi,
> >
> > Is there something in the MBSPlugin that would allow me to detect what
> > language a user is using on a given platform.
> >
> > I suppose for Mac, one could check the system.countrycodeMBS .
> >
> > How is it done on windows?
>
> Simply: I don't know this.
> You can make it user choiceable.
> And to check between German and English, it may be enough to check if
> the documents folder starts with "Dok" for German.
>
> Mfg
> Christian
>
> --
> Six thousand functions in one REALbasic plug-in. The MBS Plugin.
> <http://www.monkeybreadsoftware.de/realbasic/plugins.html>
> --
> Web8REALbasic mailing list
> <email address removed>
> http://mail.huynh.de/mailman/listinfo/web8realbasic

Re: [MBS] Language support?
Date: 15.01.04 00:02 (Thu, 15 Jan 2004 00:02:52 +0100)
From: Christian Schmitz
Brian Rathbone <<email address removed>> wrote:

> I am not sure about on Mac, but here is a quick port of the API call for
> Windows...
>
> Dim Buffer As memoryBlock
> dim Ret As integer
>
> Declare Function GetLocaleInfo Lib "kernel32" Alias "GetLocaleInfoA"

Didn't I add such a WinLocalizationMBS class around this function?

Mfg
Christian

Re: [MBS] Language support?
Date: 15.01.04 00:15 (Wed, 14 Jan 2004 18:15:00 -0500)
From: Brian Rathbone

> Didn't I add such a WinLocalizationMBS class around this function?

Oops. Indeed you did. I overlooked it in the docs.

dim w as winlocalizationMBS
w = new winlocalizationMBS(false) <-- true for unicode
msgbox w.LanguageNameEnglish

http://www.monkeybreadsoftware.de/realbasic/pluginhelp/currencydateandtimefo
rmat-winlocalizationmbs.shtml

Thanks Christian!

Brian

Re: [MBS] Language support?
Date: 15.01.04 20:41 (Thu, 15 Jan 2004 13:41:46 -0600)
From: Juergen Schreck
Many thanks, Brian! Just what I needed!

So there we go Chris. See? You do have stuff for it in your plugin. I'd
venture to say that I'd have never looked under CurrencyDateAndTimeFormat
for a WinLocalization Class.

I really think you need a full alphabetical index of classes, methods and
properties. Your plugin just has gotten so big (in terms of number of
functions) that I can't see the "Wald" because of all the "Bäume". :-D

Later,
Juergen

On 1/14/04 5:15 PM, "Brian Rathbone" <<email address removed>>
wrote:

>
>> Didn't I add such a WinLocalizationMBS class around this function?
>
> Oops. Indeed you did. I overlooked it in the docs.
>
> dim w as winlocalizationMBS
> w = new winlocalizationMBS(false) <-- true for unicode
> msgbox w.LanguageNameEnglish
>
> http://www.monkeybreadsoftware.de/realbasic/pluginhelp/currencydateandtimefo
> rmat-winlocalizationmbs.shtml
>
>
> Thanks Christian!
>
> Brian
>

-

Re: [MBS] Language support?
Date: 15.01.04 23:04 (Thu, 15 Jan 2004 23:04:30 +0100)
From: Christian Schmitz
Juergen Schreck <<email address removed>> wrote:

> I really think you need a full alphabetical index of classes, methods and
> properties.

Tell me how this list should look like and I change my docu application
to make it.

Mfg
Christian