OpenTP1 Version 7 TP1/Client User's Guide TP1/Client/W, TP1/Client/P

[Contents][Index][Back][Next]

Appendix A.3 Code conversion examples

The result of converting some characters is different depending on the value specified for the flags argument of the dc_clt_code_convert or dc_clt_codeconv_exec function. This section shows the differences.

Organization of this subsection
(1) If DCCLT_CNV_SPCHAN is specified
(2) If DCCLT_CNV_TAB is specified
(3) If DCCLT_CNV_CNTL is specified

(1) If DCCLT_CNV_SPCHAN is specified

If DCCLT_CNV_SPCHAN is specified for the flags argument of the dc_clt_code_convert or dc_clt_codeconv_exec function, a zenkaku space is converted to two hankaku spaces. The following table shows the character code correspondence when DCCLT_CNV_SPCHAN is specified.

Figure A-1 Character code correspondence when DCCLT_CNV_SPCHAN is specified

[Figure]

(2) If DCCLT_CNV_TAB is specified

If DCCLT_CNV_TAB is specified for the flags argument of the dc_clt_code_convert or dc_clt_codeconv_exec function, a tab code is converted to the corresponding hankaku code. If a tab code is adjacent to a zenkaku code, shift codes are inserted. The following table shows the character code correspondence when DCCLT_CNV_TAB is specified.

Figure A-2 Character code correspondence when DCCLT_CNV_TAB is specified

[Figure]

(3) If DCCLT_CNV_CNTL is specified

If DCCLT_CNV_CNTL is specified for the flags argument of the dc_clt_code_convert or dc_clt_codeconv_exec function, a control code is converted to a hankaku code. If a control code is adjacent to a zenkaku code, shift codes are inserted. The following table shows the character code correspondence when DCCLT_CNV_CNTL is specified.

Figure A-3 Character code correspondence when DCCLT_CNV_CNTL is specified

[Figure]