title: How to render Unicode character in TCL/TK using X11 System
body: <p>I am trying to render a unicode character to draw a scissor mark (✂) in TCL/TK</p>
  
  <p>I am using X11 API "void XwcDrawString(Display *display, Drawable d, XFontSet font_set, GC gc, int x, int y, wchar_t *string, int num_wchars)"</p>
  
  <pre><code>/* This is my code */
  
  setlocale(LC_ALL, "");
  
  wchar_t scr = 0x2702;
  char *fontname;
  fontname = (char *)malloc(strlen("ISO10646-1") + 3);
  if (fontname) sprintf(fontname, "%s,*", "ISO10646-1");
  else fontname = ",*";
  
  char **missing_charset_list_return;
  int missing_charset_count_return;
  char *def_string_return;
  XFontSet font_set = XCreateFontSet(ths-&gt;display, fontname, &amp;missing_charset_list_return, &amp;missing_charset_count_return,  &amp;def_string_return);
  
  XwcDrawString(ths-&gt;display, ths-&gt;drawable, font_set, ths-&gt;gc, x, y, &amp;scr, 1);
  </code></pre>
  
  <p>I expect scissor marks to get drawn here but instead some garbage text is printed. </p>
  
  <p>I suspect I am setting wrong font name in API XwcDrawString (not sure though).
  So, anybody could tell me what is wrong with this code or any other way to render unicode character.</p>