codebrowser icon indicating copy to clipboard operation
codebrowser copied to clipboard

ERROR:not support utf8, can't see chinese char

Open samuelyao314 opened this issue 7 years ago • 3 comments

source, adlist.h

/*

  • 双端链表结构 */ typedef struct list {

    // 表头节点 listNode *head;

    // 表尾节点 listNode *tail;

    // 节点值复制函数 void _(_dup)(void *ptr);

    // 节点值释放函数 void (*free)(void *ptr);

    // 节点值对比函数 int (*match)(void *ptr, void *key);

    // 链表所包含的节点数量 unsigned long len;

} list;

output, adlist.h.html

/* 66 * 鍙岀閾捐〃缁撴瀯 67 _/ 68 typedef struct list { 69
70 // 琛ㄥご鑺傜偣 71 listNode *head; 72
73 // 琛ㄥ熬鑺傜偣 74 listNode *tail; 75
76 // 鑺傜偣鍊煎鍒跺嚱鏁� 77 void *(_dup)(void _ptr); 78
79 // 鑺傜偣鍊奸噴鏀惧嚱鏁� 80 void (_free)(void _ptr); 81
82 // 鑺傜偣鍊煎姣斿嚱鏁� 83 int (_match)(void *ptr, void *key); 84
85 // 閾捐〃鎵€鍖呭惈鐨勮妭鐐规暟閲� 86 unsigned long len; 87
88 } list;

samuelyao314 avatar Oct 30 '16 03:10 samuelyao314

There is no encoding specified in the generator. Technicaly, the source code also does not specify the encoding.

We could add a type to specify the encoding.

The alternative is to configure the web sterver to add a specific header: Content-Type: text/html; charset=utf-8

ogoffart avatar Nov 11 '16 08:11 ogoffart

I personally changed code to add Content-Type, but would be nice to have ability to specify this as generator & indexmaker command line argument

PiotrZSL avatar Nov 19 '16 11:11 PiotrZSL

Is anyone writing code in something else than utf8?

guruz avatar Aug 09 '17 11:08 guruz