Subject: Re: JIS <-> BIG5(GB)

From: [email-masked]
Date: Thu, 19 Mar 1992 11:15:53 +001

RE: JIS <->BIG5 (GB)
 00000001
 HI,
 00000002
 I AM GUANGFAN XU. I WROTE TOBIG5/TOGB (FOR PC) MAINLY BASED ON B2G BY
 00000003
 FUNG LEE & RICKY YEUNG. I THINK THEY GAVE PERMISSION TO PORT B2G TO
 00000004
 OTHER PLATFORM, WHICH I DID FOR MSDOS. SINCE I AM NOT A PROGRAMMER BY
 00000005
 PROFESSION, MY APPROACH WAS VERY PRIMITIVE. BY THE TIME I WROTE TOGB/
 00000006
 TOBIG, I HAD NO ACCESS TO UNIX SYSTEM MYSELF. THEREFOR I HAD TO BUILD
 00000007
 UP THE TRANSLATION TABLE OUT OF THE TAR FILE OF B2G. I WAS SORT OF
 00000008
 INTERESTED IN READING HKNEWS (IN BIG5) THEN, BUT GOT TIRED OF USING
 00000009
 HKREADNEWS/SHOWNEWS. I WANTED TO READ HKNEWS ON BYX. I USED PASCAL TO
 00000010
 BUILD THE TABLES (DOUBLE ENTRY ARRAY, LIKE TABLE(X,Y) ). THE ELEMENT OF
 00000011
 THE ARRAY IS DEFINED AS TWO-BYTE-STRING. SINCE I DON'T KNOW C, I HAD TO
 00000012
 USE PASCAL TO CREATE THE TRANSLATION SCHEME.
 00000013
 1) CHECK IF X BELONG TO BIG5 FIRST BYTE RANGE THEN CHECK IF Y BELONGS
 TO00000014
 BIG5 SECOND BYTE RANGE THEN OUTPUT TABLE(X,Y);
 00000015
    ELSE OUTPUT ORIGINAL X;
 00000016
 ELSE ASSIGN Y TO X
 00000017
 NEXT LOOP;
 00000018
 2) AFTER I HAD TOGB RUNNING, I SORTED THE TABLE BY SIZE OF THE
 ELEMENTS;00000019
 THE SORTED ELEMENTS WERE USED TO CONSTRUCT TABLE FOR TOBIG5;
 00000020
 TO DEBUG ERRORS IN TRANSLATION TABLES, I RELY ON HKREADNEWS TO READ
 BIG500000021
 CODE. I USED BYX TO BUILD THE ARRAY SECTION BY SECTION IN BIG5 ORDER.
 00000022
 IF ANYONE WANTS TO BUILD JIS <-> BIG5 (GB), I SUGGEST FOLLOWING
 PRIMITIV00000023
 APPROACH :))
 00000024
 IF YOU HAVE HANDY TOOLS FOR BIG5(GB) THAN JIS;
 00000025
 1) GET HARD COPY OF JIS SECTION BY SECTION
 00000026
 2) CREATE A BIG5(GB) FILE ON BIG5(GB) EDITOR THAT MAPS TO JIS SECTION
 00000027
 BY SECTION;
 00000028
 BUILD THE TRANSLATION SCHEME ACCORDING TO THE CHARACTERISTIC OF JIS
 00000029
 SO THAT YOU CAN DETECT JIS CODES FROM NON-JIS CODE;
 00000030
 THEN USE THE ARRAY (MATRIX) TO DO THE TRANSLATION;
 00000031
 IF YOU JNOW BETTER JIS THAN BIG5(GB), DO IT ANOTHER WAY AROUND;
 00000032
 GET A HARDCOPY OF BIG5(GB) SECTION BY SECTION;
 00000033
 AND DO THE MAPPING OF BIG5(GB) ON JIS EDITOR;
 00000034
 FOR GB<->BIG5, THERE IS NO NEED FOR GRAMMATIC DETECTION. TO DO JIS<->
 00000035
 BIG5(GB), YOU HAVE TO BUILD A FAIR GOOD SCHEME TO TRANSLATE NON-HANZI
 00000036
 JIS CODES TO UNDERSTABLY HANZI BIG5(GB). OF COUSE, YOU LEAVE THE
 JAPANES00000037
 LETTERS AS THEY ARE IN GB. I AM NOT SURE ABOUT BIG5.
 00000038
 I HOPE THIS CAN HELP.
 00000039

 00000040
 GUANGFAN XU, DENMARK
 00000041

 00000042
 P.S. DUE TO A HARDDISK CRASH LAST YEAR, I LOST MY TRANSLATION TABLES
 AND00000043
 RUN-TIME PROGRAMS. I HAVE A BACKUP COPY SOMEWHERE IN MY 500+ UNLABELED
 00000044
 DISKETTES. BUT IT TAKES A LOT OF TIME FOR ME TO LOCATE THE RIGHT ONE.
 00000045
 SO I CAN BE EXPECTED TO HAND OUT THE SOURCE CODE PROMPTLY UPON REQUEST.
 00000046
 AFTER ALL, THERE ARE SO MANY PROF. ON THE NETTERS. THEY CAN CREATE SOME
 00000047
 THING BETTER THAN MINE FOR SURE. :))
 00000048