Page 1 of 4

New FTDN September/Septiembre 2015 (FWH 15.09)

PostPosted: Sat Sep 26, 2015 8:24 am
by Antonio Linares
September 2015
==============
* Unicode support extended to all controls. Existing applications
turn into multi-lingual unicode application by inserting one line
of code in the Main function

FW_SetUnicode( .t. )

This being a major revision, we request the users to provide
feedback to help improvements.

* It is the ulitmate aim that a single application can simultaneously
have different ANSI and Unicode windows at the sametime and also
one window/dialog to contain some Ansi and some Unicode controls.
But for now it is desirable to have the entire application either as
Ansi or as Unicode. However even in a Unicode application, every effort
has been makde to maintain full backward compatibility of Ansi text
opetaions including accented characters. Any feedback on this aspect
will be highly appreciated and promptly responded.

* Fix: Edit.prg: fixed excess release of font when font clause is used.

* Enhancement: Unicode support for common messageboxesm MsgInfo(),
MsgAlert(), MsgStop(), MsgYesNo(), MsgNoYes(), MsgRetryCancel(),
MsgAbout(), MsgRun, MsgWait(). MsgText and Title can be any
combination of UTF8/ANSI. Buttons are shown in the default
language installed.

* MsgGet() supports unicode display and edit if FW_SetUnicode()
is set to TRUE.

* MemoEdit() supports unicode display and multilingual edit
if FW_SetUnicode() is set to TRUE

* Enhancement: TEdit control supports multiline mode.
- Supports multi-lingual edit from keyboard / paste.
- Supports password clause

* Enhancement: GetTextWidth(). Optionally text height can be
retrieved in the 4th parameter if passed by reference.

* New: functions CompareString( nLocaleID, cUtfStr1, cUtfStr2 ) and
CompareStringEx( cLocaleName, cUtfStr1, cUtfStr2 ) adopting Win API
for comparing UTF8 stings,

* New: DATA ncLocalID of TXBrwColumn: If provided UTF8 data in
a column in an arry can be sorted like other columns

* Enhancement: XBrowse: Reasonable functionality for Unicode Incremental
Seeks, etc.

August 2015 (Revd Build)
=======================

1) Fix: Wrong printing and display of accented characters in some cases
is fixed.

2) Clipborad: Method SetText() fully supports Unicode text also.
New Method GetUnicodeText() copies unicode or ansi text from the clipborad

3) XBrowse supports Pasting of unicode text into cells.

Re: New FTDN September/Septiembre 2015 (FWH 15.09)

PostPosted: Sat Sep 26, 2015 11:41 am
by ShumingWang
Up!
Shuming Wang

Re: New FTDN September/Septiembre 2015 (FWH 15.09)

PostPosted: Sun Sep 27, 2015 4:15 am
by richard-service
Hi Antonio,
Could you please offer a sample EXE for test?

Re: New FTDN September/Septiembre 2015 (FWH 15.09)

PostPosted: Sun Sep 27, 2015 7:01 am
by Antonio Linares
Richard,

Please provide me a PRG that you want to be built using unicode and I will send you the EXE :-)

Re: New FTDN September/Septiembre 2015 (FWH 15.09)

PostPosted: Mon Sep 28, 2015 4:09 am
by dutch
Dear Antonio,

I've still got problem when compile in "samples\testuni2.prg" as picture. I choose UTF-8 and save already.
What is the problem?
Image
image uploading

Re: New FTDN September/Septiembre 2015 (FWH 15.09)

PostPosted: Mon Sep 28, 2015 6:56 am
by Antonio Linares

Re: New FTDN September/Septiembre 2015 (FWH 15.09)

PostPosted: Mon Sep 28, 2015 1:31 pm
by richard-service
Antonio,

I already sent to you sample ANSI PRG to your EMail.
Please check it.
Thanks a lot.

Re: New FTDN September/Septiembre 2015 (FWH 15.09)

PostPosted: Mon Sep 28, 2015 9:14 pm
by cnavarro

Re: New FTDN September/Septiembre 2015 (FWH 15.09)

PostPosted: Tue Sep 29, 2015 12:05 am
by Antonio Linares
Richard,

Here you have the EXE for testchinese-u8.prg:

https://bitbucket.org/fivetech/fivewin-contributions/downloads/testchinese-u8.zip

Please try it and let me know how it goes for you, thanks

Re: New FTDN September/Septiembre 2015 (FWH 15.09)

PostPosted: Tue Sep 29, 2015 5:29 am
by ShumingWang
Runs OK!
TKS!
Shuming Wang

Re: New FTDN September/Septiembre 2015 (FWH 15.09)

PostPosted: Tue Sep 29, 2015 6:43 am
by richard-service
Dear Antonio,

Run it OK.
I just sent to you V2, please compile it to EXE.

This version include Code and Resource Dialog.
UTF-8 PRG and UTF-8 RC

Re: New FTDN September/Septiembre 2015 (FWH 15.09)

PostPosted: Tue Sep 29, 2015 7:51 am
by Antonio Linares
Richard,

I get these errors. Please fix them and send it again, thanks

Compiling 'testchinese-u8.prg' and generating preprocessed output to 'testchinese-u8.ppo'...
5 errors

No code generated.
testchinese-u8.prg(233) Error E0030 Syntax error "syntax error at 'OREPORT'"
testchinese-u8.prg(235) Error E0030 Syntax error "syntax error at 'TITLE'"
testchinese-u8.prg(236) Error E0030 Syntax error "syntax error at 'TITLE'"
testchinese-u8.prg(238) Error E0030 Syntax error "syntax error at 'END'"
testchinese-u8.prg(249) Warning W0001 Ambiguous reference 'NI'
testchinese-u8.prg(250) Warning W0001 Ambiguous reference 'NI'
testchinese-u8.prg(251) Warning W0001 Ambiguous reference 'NI'
testchinese-u8.prg(251) Warning W0001 Ambiguous reference 'NI'
testchinese-u8.prg(255) Error E0030 Syntax error "syntax error at 'REPORT'"

Re: New FTDN September/Septiembre 2015 (FWH 15.09)

PostPosted: Wed Sep 30, 2015 5:50 am
by richard-service
Antonio,

I make this sample, PRG and RC Save UTF-8 style.

http://www.fivetech.com.tw/downloads/TestChinese-u8-V3.rar

Code: Select all  Expand view

// Add this to your resources RC file

#ifdef __FLAT__
   1 24 "./WinXP/WindowsXP.Manifest"
#endif

new      BITMAP "./bitmaps/32x32/new.bmp"
quit     BITMAP "./bitmaps/32x32/quit.bmp"

TEST DIALOG 20, 41, 356, 86
STYLE DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU
CAPTION "測試  Unicode 繁體中文(Traditional Chinese)-例如堃,叙"
FONT 12, "細明體"
{
 EDITTEXT 201, 68, 7, 170, 12
 EDITTEXT 202, 68, 22, 99, 12
 CONTROL "存檔", 301, "BUTTON", BS_USERBUTTON | WS_TABSTOP, 302, 8, 46, 18
 CONTROL "取消", 302, "BUTTON", BS_USERBUTTON | WS_TABSTOP, 302, 29, 46, 18
 CONTROL "列印", 303, "BUTTON", BS_USERBUTTON | WS_TABSTOP, 302, 50, 46, 18
 LTEXT "中文地址", 101, 5, 7, 60, 12
 LTEXT "中文姓名", 102, 5, 22, 60, 12
}
 

Re: New FTDN September/Septiembre 2015 (FWH 15.09)

PostPosted: Wed Sep 30, 2015 7:49 am
by Antonio Linares
Richard,

When I try to build your examples using bcc7 I get this error:

Error testchinese-u8.RC 1 2: Bad character in source input

And if I try to build it using VS2013 then I get:

testchinese-u8.RC(4) : error RC2135 : file not found: 1
testchinese-u8.RC(8) : error RC2135 : file not found: quit
testchinese-u8.RC(10) : error RC2135 : file not found: TEST

There is something wrong with the RC file. Not sure if it is caused for using unicode into it

Re: New FTDN September/Septiembre 2015 (FWH 15.09)

PostPosted: Wed Sep 30, 2015 8:32 am
by Antonio Linares
It seems as cgrc.exe has to be used instead of brc32.exe:

http://blog.spreendigital.de/2008/10/14/unicode-in-resource-files/