Chinese

Chinese

Postby MarcoBoschi » Tue Jun 16, 2015 11:47 am

Hi,
I have to print somethink like this: English and Chinese text togheter

Image
How can I do that?

I usually use a program written in CAVO2.5 and libreries ReportPro 2.10
But all my programs are written in fivewin/xHarbour.
Any hints?

Marco
User avatar
MarcoBoschi
 
Posts: 1015
Joined: Thu Nov 17, 2005 11:08 am
Location: Padova - Italy

Re: Chinese

Postby Antonio Linares » Tue Jun 16, 2015 12:06 pm

Marco,

Please review FWH\samples\unicode.prg
regards, saludos

Antonio Linares
www.fivetechsoft.com
User avatar
Antonio Linares
Site Admin
 
Posts: 41315
Joined: Thu Oct 06, 2005 5:47 pm
Location: Spain

Re: Chinese

Postby MarcoBoschi » Tue Jun 16, 2015 12:42 pm

Antonio,
I have ad old version and I obtain this
Image
User avatar
MarcoBoschi
 
Posts: 1015
Joined: Thu Nov 17, 2005 11:08 am
Location: Padova - Italy

Re: Chinese

Postby nageswaragunupudi » Tue Jun 16, 2015 1:08 pm

For me it worked with Menus, Says on Window and WBrowse.
Regards

G. N. Rao.
Hyderabad, India
User avatar
nageswaragunupudi
 
Posts: 10248
Joined: Sun Nov 19, 2006 5:22 am
Location: India

Re: Chinese

Postby ShumingWang » Wed Jun 17, 2015 3:41 am

Your windows should install Chinese fonts .Print English letters and Chinese word can be mixed together .

Shuming Wang
来自广东省广州市
Come from Guangzhou City,Guangdong Province
http://www.xtech2.top
Mobile:(86)13802729058
Email:100200651@qq.com
QQ:100200651
Weixin: qq100200651
ShumingWang
 
Posts: 460
Joined: Sun Oct 30, 2005 6:37 am
Location: Guangzhou(Canton),China

Re: Chinese

Postby MarcoBoschi » Wed Jun 17, 2015 9:32 am

S.W.,
this is a screenshot uf unicode.exe in my windows 7 pc.

Image

I noticed that if unicode.exe lost focus and then takes it back Chinese characters are substituted with ????

What do you think by adding a button that prints... will work ?
And what about to store the content of oGet into a dbf field?

Many thanks

Marco
User avatar
MarcoBoschi
 
Posts: 1015
Joined: Thu Nov 17, 2005 11:08 am
Location: Padova - Italy

Re: Chinese

Postby ShumingWang » Wed Jun 17, 2015 10:15 am

Oh!I use Chinese GBK ,or GB2312 Code,Chinese words same as other strings,PRG without any setting ,Windows control panel should choose Chinese language.
In the past ,FWH not supported Unicode. I have not upgraded FWH into new version.

Shuming Wang
http://www.xtech2.top
Mobile:(86)13802729058
Email:100200651@qq.com
QQ:100200651
Weixin: qq100200651
ShumingWang
 
Posts: 460
Joined: Sun Oct 30, 2005 6:37 am
Location: Guangzhou(Canton),China

Re: Chinese

Postby Antonio Linares » Wed Jun 17, 2015 12:05 pm

Marco,

With FWH 15.05 build 4 looks like this on Windows 10:

Image
regards, saludos

Antonio Linares
www.fivetechsoft.com
User avatar
Antonio Linares
Site Admin
 
Posts: 41315
Joined: Thu Oct 06, 2005 5:47 pm
Location: Spain

Re: Chinese

Postby MarcoBoschi » Wed Jun 17, 2015 2:26 pm

Antonio,
there is a colleague who modify this program in such a way that it works in the Chinese language?
I can not understand Whether it is possible

Many Thanks
Marco

Code: Select all  Expand view

#include "fivewin.ch"


FUNCTION MAIN()

LOCAL oDlg
LOCAL oSay  , cSay := "Chinese Text "
LOCAL oGet1 , cGet1 := SPACE( 20 )
LOCAL oGet2 , cGet2 := SPACE( 20 )
LOCAL oBut1 , oBut2

IF !FILE( "TESTCHINA.DBF" )
   DBCREATE( "TESTCHINA" , { { "CINESE1", "C", 20, 0 } , { "CINESE2", "C", 20, 0 }} )
ENDIF

USE testchina

GO BOTTOM

cGet1 := field->cinese1
cGet2 := field->cinese2


DEFINE DIALOG oDlg

@ 1 ,  1 SAY oSay PROMPT cSay OF oDlg
@ 2 ,  1 GET oGet1 VAR cGet1 OF oDlg
@ 3 ,  1 GET oGet2 VAR cGet2 OF oDlg
@ 3 ,  1 BUTTON oBut2 PROMPT "WRITE" ACTION write_dbf( cGet1 , cGet2 )
@ 3 , 10 BUTTON oBut1 PROMPT "PRINT" ACTION MsgInfo( "Print get content" )

ACTIVATE DIALOG oDlg
CLOSE DATABASE

RETURN NIL
FUNCTION WRITE_DBF( cGet1 , cGet2 )

APPEND BLANK
REPLACE field->cinese1  WITH cGet1
REPLACE field->cinese2  WITH cGet2


RETURN NIL
 
User avatar
MarcoBoschi
 
Posts: 1015
Joined: Thu Nov 17, 2005 11:08 am
Location: Padova - Italy

Re: Chinese

Postby Antonio Linares » Wed Jun 17, 2015 3:02 pm

Marco,

There are several FWH users from China on these forums that surely will be able to help you.

I am sorry I have no more expertise on this area
regards, saludos

Antonio Linares
www.fivetechsoft.com
User avatar
Antonio Linares
Site Admin
 
Posts: 41315
Joined: Thu Oct 06, 2005 5:47 pm
Location: Spain

Re: Chinese

Postby MarcoBoschi » Wed Jun 17, 2015 6:10 pm

Antonio,
Thankyou
Marco
User avatar
MarcoBoschi
 
Posts: 1015
Joined: Thu Nov 17, 2005 11:08 am
Location: Padova - Italy

Re: Chinese

Postby richard-service » Thu Jun 18, 2015 4:49 am

MarcoBoschi wrote:Hi,
I have to print somethink like this: English and Chinese text togheter

Image
How can I do that?

I usually use a program written in CAVO2.5 and libreries ReportPro 2.10
But all my programs are written in fivewin/xHarbour.
Any hints?

Marco


FWH not support full Unicode function, not input Chinese word.
so suggestion
if you just display chinese and english
install chinese font and set code for chinese font( from dbf and chinese inside )
if you input chinese word and english
install chinese OS and modify TGet.prg( support chinese two bytes and control key functions )
Best Regards,

Richard

Harbour 3.2.0dev (r2402101027) => Borland C++ v7.7 32bit
MySQL v5.7 /ADS v10
Harbour 3.2.0dev (r2011030937) => Borland C++ v7.4 64bit
User avatar
richard-service
 
Posts: 765
Joined: Tue Oct 16, 2007 8:57 am
Location: New Taipei City, Taiwan

Re: Chinese

Postby MarcoBoschi » Thu Jun 18, 2015 8:06 am

Richard,
many thanks
I've just wrote you by mail
Marco
User avatar
MarcoBoschi
 
Posts: 1015
Joined: Thu Nov 17, 2005 11:08 am
Location: Padova - Italy

Re: Chinese

Postby richard-service » Thu Jun 18, 2015 8:10 am

MarcoBoschi wrote:Richard,
many thanks
I've just wrote you by mail
Marco

ok. I got it.
Best Regards,

Richard

Harbour 3.2.0dev (r2402101027) => Borland C++ v7.7 32bit
MySQL v5.7 /ADS v10
Harbour 3.2.0dev (r2011030937) => Borland C++ v7.4 64bit
User avatar
richard-service
 
Posts: 765
Joined: Tue Oct 16, 2007 8:57 am
Location: New Taipei City, Taiwan


Return to FiveWin for Harbour/xHarbour

Who is online

Users browsing this forum: Google [Bot] and 81 guests