您的位置->>条码打印机->>在线支持                                  

编号:4026 留言者名称:小林 标题:急!
214(PPLB)用 B_Prn_Text_TrueType()函数打印汉字时两汉字之间的距离总是很大,应如何调节那些参数呢?
地区:广东    留言时间: 2004-7-25 18:21:05
专家解答:
B_Prn_Text_TrueType()
B_Prn_Text_TrueType_W()
    ===============================================================================
        PURPOSE  Create a "True Type Font" text object.

         SYNTAX  int B_Prn_Text_TrueType(int x, int y, int FSize, LPCTSTR FType,
                                      int Fspin, int FWeight, int FItalic, int FUnline,
                                      int FStrikeOut, LPCTSTR id_name, LPCTSTR data,
                                      int mem_mode);
 int B_Prn_Text_TrueType_W(int x,int y,int FHeight,int FWidth,LPCTSTR FType,
                                    int Fspin,int FWeight,int FItalic,int FUnline,
                                    int FStrikeOut,LPCTSTR id_name,LPCTSTR data);
      
      PARAMETER  int      x;              X coordinates.
                 int      y;              Y coordinates.
                 int      FSize;          TrueType font size,unit is (dot).
FSize = (dpi * point) / 72.
 int      FHeight;        Font Height, unit is (dot).
FHeight = (dpi * point) / 72.
                 int      FWidth;         Font Width, unit is (dot).
FWidth = (dpi * point) / 72.
                 LPCTSTR  FType;          TrueType font type name.
                 int      Fspin;          TrueType font to rotate.
                                           1 -> 0, 2 -> 90, 3 -> 180, 4 -> 270
                 int      FWeight;        TrueType font thickness bellow:
                                           0 and NULL and 400 -> standard,
                                           100 -> special thin,200 -> very thin,
                                           300 -> thin        ,500 -> middle,
                                           600 -> half thick  ,700 -> thick,
                                           800 -> special thick,900 ->blackbody.
                 int      FItalic;        TrueType font italic.
                                           0 -> FALSE, 1 -> TRUE.
                 int      FUnline;        TrueType font underline.
                                           0 -> FALSE, 1 -> TRUE.
                 int      FStrikeOut;     TrueType font StrikeOut.
                                           0 -> FALSE, 1 -> TRUE.
                 LPCTSTR  id_name;        To give a id name to store in printer after
                                           calling text by Load_Pcx().
                 LPCTSTR  data;           A text string.

条码小知识:
当UPC 作为十二位进行解码时,定义如下:
· 第一位 = 数字标识 (已经由UCC(统一代码委员会)所建立).
· 第2-6位 = 生产厂家的标识号(包括第一位)
· 第7-11 = 唯一的厂家产品代码
· 第12位 = 校验位(used for error detection)