You are not logged in.

Dear visitor, welcome to Jabaco - Community. If this is your first visit here, please read the Help. It explains in detail how this page works. To use all features of this page, you should consider registering. Please use the registration form, to register here or read more information about the registration process. If you are already registered, please login here.

Theera

Beginner

  • "Theera" is male
  • "Theera" started this thread

Posts: 21

Date of registration: Feb 27th 2014

Location: Supanburi ,Thailand

Occupation: Agric Chemical Seller

Hobbies: learning programming and English

  • Send private message

1

Sunday, March 2nd 2014, 2:05am

How to set my language in order to read?

Hi all,
I 've start coding a simple code,I know myself,it's one of the best programs which released in the world. It's so like VB6.0 . However I 've problem which attached as below.
Theera has attached the following image:
  • HowtoSetMyLangauge.png
P.S. I'm not good at English and programming,Please understand me.
Best Regards,

Theera

jbExplorer

Trainee

Posts: 111

Date of registration: Mar 18th 2013

  • Send private message

2

Sunday, March 2nd 2014, 12:40pm

What text do you want to appear, in the Message Box?

Theera

Beginner

  • "Theera" is male
  • "Theera" started this thread

Posts: 21

Date of registration: Feb 27th 2014

Location: Supanburi ,Thailand

Occupation: Agric Chemical Seller

Hobbies: learning programming and English

  • Send private message

3

Monday, March 3rd 2014, 2:35am

My text is appeared at the part of IDE's coding page.
P.S. I'm not good at English and programming,Please understand me.
Best Regards,

Theera

jbExplorer

Trainee

Posts: 111

Date of registration: Mar 18th 2013

  • Send private message

4

Monday, March 3rd 2014, 5:24pm

Theera, sorry I don't understand the question. What text do you want, in the Message box? Do you have a project sample, we can look at?

Theera

Beginner

  • "Theera" is male
  • "Theera" started this thread

Posts: 21

Date of registration: Feb 27th 2014

Location: Supanburi ,Thailand

Occupation: Agric Chemical Seller

Hobbies: learning programming and English

  • Send private message

5

Wednesday, March 5th 2014, 3:43am

My coding I need to show Thai langauge in order that any Thai developers can read my sourcecode.
P.S. I'm not good at English and programming,Please understand me.
Best Regards,

Theera

jbExplorer

Trainee

Posts: 111

Date of registration: Mar 18th 2013

  • Send private message

6

Wednesday, March 5th 2014, 2:42pm

My coding I need to show Thai langauge in order that any Thai developers can read my sourcecode.
So you need to be able to display Unicode characters, like the ones here

http://jrgraphix.net/r/Unicode/0E00-0E7F


Can't give you a definite answer yet, but will research it. Off the top of my head, I think you would want to convert the Thai characters from the Unicode values to decimal, and concatenate the ChrW( nChar ) of each character, into a string.

But actually, I tried that, and it doesn't seem to work right. Here's what I tried:

Go to Google translate, and get a Thai phrase

http://translate.google.com/#en/th/Good%20morning


, returning

สวัสดี


Convert the Unicode values to decimal values, using

http://www.branah.com/unicode-converter


(make sure you click Add spaces)

So

สวัสดี


becomes

U+0e2a U+0e27 U+0e31 U+0e2a U+0e14 U+0e35


in Unicode, which becomes

3626 3623 3633 3626 3604 3637


in decimal.

When you concatenate all of the characters into a string


sUnicodeMessage = ChrW( 3626 ) & ChrW( 3623 ) & ChrW( 3633 ) & ChrW( 3626 ) & ChrW( 3604 ) & ChrW( 3637 )

MsgBox sUnicodeMessage


But it doesn't work, it doesn't display the Thai Good morning message. So I'm clearly doing something wrong. I'm not sure if Jabaco has more direct language support. Read this, maybe this will help:

Translate Jabaco into your native language




Gotta get back to work, but will take a closer look, later in the day.

Theera

Beginner

  • "Theera" is male
  • "Theera" started this thread

Posts: 21

Date of registration: Feb 27th 2014

Location: Supanburi ,Thailand

Occupation: Agric Chemical Seller

Hobbies: learning programming and English

  • Send private message

7

Friday, March 7th 2014, 1:51am

"Translate Jabaco into yout native langauge" it helps me to change only userinterface,but can't helps this problem. However,I have translated some my native language(still not finished).
Theera has attached the following image:
  • ThaiLangEdition.png
P.S. I'm not good at English and programming,Please understand me.
Best Regards,

Theera

jbExplorer

Trainee

Posts: 111

Date of registration: Mar 18th 2013

  • Send private message

8

Friday, March 7th 2014, 1:44pm

"Translate Jabaco into yout native langauge" it helps me to change only userinterface,but can't helps this problem. However,I have translated some my native language(still not finished).
Yes, I understand. So, what you're trying to do, is be able to display a Messagebox, with Thai characters.

Ok, gotta catch up on a couple of projects at the office, but will look further into it.

jbExplorer

Trainee

Posts: 111

Date of registration: Mar 18th 2013

  • Send private message

9

Saturday, March 8th 2014, 12:54am

Theera,

I'm having problem making this work. I tried using the Locale class, but as soon as the Import statement


Import #java#util#Locale


is input and the project compiled, there is an error:

ERROR JABACO (9-1)
Hashkey failed!

Unfortunately, nothing with the Locale Import will compile, at least not on my Windows 8 PC.

theuserbl has already worked out the Jabaco details:

happy holidays


Maybe it will compile, on your PC.

jbExplorer

Trainee

Posts: 111

Date of registration: Mar 18th 2013

  • Send private message

10

Thursday, March 13th 2014, 8:34pm

Theera,


If you look at

happy holidays

, you'll see that theuserbl was able to copy and paste the actual contents of "Happy holidays", in various languages.

But I haven't the foggiest idea, of how theuserbl was able to directly copy the unicode characters, into the IDE. When I copy them, they just appear as question marks.

Anyway, this is what I've got so far. It compiles, but doesn't display any Thai characters:



Import java#util#Locale

Public Sub btnTestUnicodeMsgBox_Click()
Dim lclLocale As Locale
Dim sUnicodeMessage As String = ""

lclLocale = New Locale( "th", "TH" )
Locale.setDefault( lclLocale )

'// Copying the content directly into the IDE doesn't work.
sUnicodeMessage = "??????"

'// This doesn't work, either.
sUnicodeMessage = ChrW( 3626 ) & ChrW( 3623 ) & ChrW( 3633 ) & ChrW( 3626 ) & ChrW( 3604 ) & ChrW( 3637 )


MsgBox( sUnicodeMessage )



End Sub

Theera

Beginner

  • "Theera" is male
  • "Theera" started this thread

Posts: 21

Date of registration: Feb 27th 2014

Location: Supanburi ,Thailand

Occupation: Agric Chemical Seller

Hobbies: learning programming and English

  • Send private message

11

Friday, March 14th 2014, 3:01am

My problem is not about how to coding for translation,but it 's about Jabaco directly. Why doesn't it display Thai characters in IDE of Jabaco. (Msgbox isn't concerned about this) Please consider my sourcecode attached at the Private Function ThaiMonth(imonth As String) As String.

P.S. The ThaiCalendar.jba file is attributed to read-only for any changed protection
Theera has attached the following file:
P.S. I'm not good at English and programming,Please understand me.
Best Regards,

Theera

This post has been edited 2 times, last edit by "Theera" (Mar 14th 2014, 3:10am)


jbExplorer

Trainee

Posts: 111

Date of registration: Mar 18th 2013

  • Send private message

12

Friday, March 14th 2014, 1:26pm

Yes, I understand, Theera. I'm having a similar problem, displaying characters in the ide, and can't figure out how theuserbl did it. I thought we could work around the problem, by inputting the Thai characters with their unicode values. But that didn't work, either.

Anyway, let's await some responses, and reflect on it, for a few days. There might be something obvious, that we're just not seeing. That happens to me, all the time.

My problem is not about how to coding for translation,but it 's about Jabaco directly. Why doesn't it display Thai characters in IDE of Jabaco. (Msgbox isn't concerned about this) Please consider my sourcecode attached at the Private Function ThaiMonth(imonth As String) As String.

P.S. The ThaiCalendar.jba file is attributed to read-only for any changed protection

theuserbl

Intermediate

Posts: 436

Date of registration: Dec 20th 2008

  • Send private message

13

Sunday, March 16th 2014, 10:12pm

I'm having a similar problem, displaying characters in the ide, and can't figure out how theuserbl did it.

I haven't done it.
I have only written the "happy holidays"-code in the forum with the help of the google-translater, in the hope, that it will work in Jabaco.

The reason, why the menu of Jabaco supports unicode and the textarea of Jabaco not, is which components they are.

Jabaco 1.5.2 is written in VisualBasic 6 with some external DLLs, which are written in VisualC++.
The Menu of Jabaco with some buttons and so on, are using the Codejock-components (http://www.codejock.com/), which seems to support Unicode. They also supports themed controls. Controls, which comes with Visual Basic 6, on the other side, have an Windows 2000 look.
The textarea in Jabaco is based on Scintilla (http://www.scintilla.org/). On the Sintilla side stands, that Unicode is supported, if it is in the sourcecode of the own program activated. So it seems, that Manuel have not activated it for Jabaco. It is also for me currently not clear, how an unicode-file created in Scintilla will be saved. Currently in the Jabaco-editor every character have the size of one byte. With Unicode that will not be possible.

In Java-class files, UTF-8 is used for strings. That means, that standard-ASCII characters are one byte long. Others are two byte long and some are three bytes long. If your sourcecode is not UTF-8, strings will be converted from the Java-compiler to UTF-8.

Microsofts .NET on the other hand, using UTF-16 internally. So every character is at minimum two bytes long.

Greatings
theuserbl

theuserbl

Intermediate

Posts: 436

Date of registration: Dec 20th 2008

  • Send private message

14

Monday, March 17th 2014, 11:38am

"Translate Jabaco into yout native langauge" it helps me to change only userinterface,but can't helps this problem. However,I have translated some my native language(still not finished).
If you have all translated, please upload it, so that it can be uploaded to svn, so that other users in thailand, could using the language-filke, too.

My problem is not about how to coding for translation,but it 's about Jabaco directly. Why doesn't it display Thai characters in IDE of Jabaco. (Msgbox isn't concerned about this) Please consider my sourcecode attached at the Private Function ThaiMonth(imonth As String) As String.

P.S. The ThaiCalendar.jba file is attributed to read-only for any changed protection
I have looked at your program. That should be working. But it don't. :-(
Seems, that there is also a bug in the JabacoFramework. I will look later at it.

Greatings
theuserbl

jbExplorer

Trainee

Posts: 111

Date of registration: Mar 18th 2013

  • Send private message

15

Monday, March 17th 2014, 12:30pm

I'm having a similar problem, displaying characters in the ide, and can't figure out how theuserbl did it.

I haven't done it.
I have only written the "happy holidays"-code in the forum with the help of the google-translater, in the hope, that it will work in Jabaco.

The reason, why the menu of Jabaco supports unicode and the textarea of Jabaco not, is which components they are.

Jabaco 1.5.2 is written in VisualBasic 6 with some external DLLs, which are written in VisualC++.
The Menu of Jabaco with some buttons and so on, are using the Codejock-components (http://www.codejock.com/), which seems to support Unicode. They also supports themed controls. Controls, which comes with Visual Basic 6, on the other side, have an Windows 2000 look.
The textarea in Jabaco is based on Scintilla (http://www.scintilla.org/). On the Sintilla side stands, that Unicode is supported, if it is in the sourcecode of the own program activated. So it seems, that Manuel have not activated it for Jabaco. It is also for me currently not clear, how an unicode-file created in Scintilla will be saved. Currently in the Jabaco-editor every character have the size of one byte. With Unicode that will not be possible.

In Java-class files, UTF-8 is used for strings. That means, that standard-ASCII characters are one byte long. Others are two byte long and some are three bytes long. If your sourcecode is not UTF-8, strings will be converted from the Java-compiler to UTF-8.

Microsofts .NET on the other hand, using UTF-16 internally. So every character is at minimum two bytes long.

Greatings
theuserbl


Hi theuserbl,

Understood about the unicode issues of course. But I'm still confused, as to how your source is actually displaying unicode characters. Google translator was the first thing I tried also, but when I copy a Thai message to code in the Jabaco ide, it shows up as question marks.

In other words, my confusion is not in the components displaying foreign strings. But rather, how did you coax the source code, inside the Jabaco IDE, to display foreign characters?

You said 'if your sourcecode is not utf-8', etc. Are you able to choose the format that Jabaco saves source?


So, my messagebox should display the contents of sUnicodeMessage, but the Jabaco ide does not allow me to copy the actual Thai content to Jabaco.

sUnicodeMessage = "??????"


, whereas you are able to use Thai characters directly:

MsgBox "สุขสันต์วันหยุด"


Maybe this is a Windows clipboard issue, and my pasting is auto-converting to CF_TEXT or CF_OEMTEXT.


By the way, thanks much for explaining about the source code behind Jabaco. I had no idea this was done in VB. It makes Manuel's accomplishment, even more amazing.

theuserbl

Intermediate

Posts: 436

Date of registration: Dec 20th 2008

  • Send private message

16

Tuesday, March 18th 2014, 12:45pm

But I'm still confused, as to how your source is actually displaying unicode characters.
It doesn't. I have only written the source in the webbrowser as comment. I have also seen, that all characters of thai are replaced with "?". But I thought at this time, that I haven't the right font installed and thai-people, who have the font installed, could see it.
Since this thread I know, that the font is installed on my computer, too. But Jabaco have not on all parts support of it:
The Jabaco menu support Unicode (look at the screenhsot of Theera)
The Jabaco designer support unicode, too.
The Jabaco 1.5.2 editor-area (based on Scintilla) doesn't support unicode.
And I now know (because I have looked, to what .class files Jabaco 1.5.2 compiles the program in Lesson5_ThaiCalendar.zip) that the current Jabaco-compiler don't support unicode, too.

And in the framework, the current ChrW() don't support unicode. That is the reason why your mentioned program don't work.
And I am currently trying to bring it to work. But it needs still some time.

When I have fixed the framework-bug, your program

Jabaco Source

1
2
sUnicodeMessage = ChrW( 3626 ) & ChrW( 3623 ) & ChrW( 3633 ) & ChrW( 3626 ) & ChrW( 3604 ) & ChrW( 3637 )
MsgBox sUnicodeMessage
will be running correct.

Greatings
theuserbl

jbExplorer

Trainee

Posts: 111

Date of registration: Mar 18th 2013

  • Send private message

17

Tuesday, March 18th 2014, 3:52pm

But I'm still confused, as to how your source is actually displaying unicode characters.
It doesn't. I have only written the source in the webbrowser as comment. I have also seen, that all characters of thai are replaced with "?". But I thought at this time, that I haven't the right font installed and thai-people, who have the font installed, could see it.
Since this thread I know, that the font is installed on my computer, too. But Jabaco have not on all parts support of it:
The Jabaco menu support Unicode (look at the screenhsot of Theera)
The Jabaco designer support unicode, too.
The Jabaco 1.5.2 editor-area (based on Scintilla) doesn't support unicode.
And I now know (because I have looked, to what .class files Jabaco 1.5.2 compiles the program in Lesson5_ThaiCalendar.zip) that the current Jabaco-compiler don't support unicode, too.

And in the framework, the current ChrW() don't support unicode. That is the reason why your mentioned program don't work.
And I am currently trying to bring it to work. But it needs still some time.

When I have fixed the framework-bug, your program

Jabaco Source

1
2
sUnicodeMessage = ChrW( 3626 ) & ChrW( 3623 ) & ChrW( 3633 ) & ChrW( 3626 ) & ChrW( 3604 ) & ChrW( 3637 )
MsgBox sUnicodeMessage
will be running correct.

Greatings
theuserbl

Got it, thanks for the clarification, theuserbl.

Abidjunior

Beginner

Posts: 1

Date of registration: Mar 18th 2014

  • Send private message

18

Tuesday, March 18th 2014, 8:00pm

Other languages

:) Hi,

I am new to jabaco and am trying to write a programme where i have to display characters from arabic and urdu languages. But when i try to populate any control after processing string inputs of other language in this case urdu the out put is "?" A question mark. Any help please.

jbExplorer

Trainee

Posts: 111

Date of registration: Mar 18th 2013

  • Send private message

19

Tuesday, March 18th 2014, 9:09pm

:) Hi,

I am new to jabaco and am trying to write a programme where i have to display characters from arabic and urdu languages. But when i try to populate any control after processing string inputs of other language in this case urdu the out put is "?" A question mark. Any help please.

:) Hi,

I am new to jabaco and am trying to write a programme where i have to display characters from arabic and urdu languages. But when i try to populate any control after processing string inputs of other language in this case urdu the out put is "?" A question mark. Any help please.


Hi Abidjunior,

We need to wait for an update to the framework.

theuserbl

Intermediate

Posts: 436

Date of registration: Dec 20th 2008

  • Send private message

20

Wednesday, March 19th 2014, 12:33am

Done.
Updated Framework at:
[ http://www.jabaco.org/wiki/Latest_JabacoFramework_Binary ]

Unzip the last zip-file in your Jabaco-directory and restart Jabaco.

Thats it. Then ChrW and AscW will be working correct.

The problems with the editor and compiler, that they don't support unicode, I can't change.

Greatings
theuserbl

Rate this thread
WoltLab Burning Board