autogen c version of text from js