Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

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

Open
samuelyao314 opened this issue Oct 30, 2016 · 3 comments
Open

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

samuelyao314 opened this issue Oct 30, 2016 · 3 comments
Assignees

Comments

@samuelyao314
Copy link

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 samuelyao314 changed the title ERROR:can't see utf8 commit ERROR:not support utf8, can't see chinese char Oct 30, 2016
@ogoffart
Copy link
Contributor

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

@PiotrZSL
Copy link

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

@guruz guruz self-assigned this Aug 9, 2017
@guruz
Copy link
Contributor

guruz commented Aug 9, 2017

Is anyone writing code in something else than utf8?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants