<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Create an UTF-8 API_TextType element in Archicad C++ API</title>
    <link>https://community.graphisoft.com/t5/Archicad-C-API/Create-an-UTF-8-API-TextType-element/m-p/221497#M4157</link>
    <description>&lt;DIV class="actalk-migrated-content"&gt;Hi!&lt;BR /&gt;&lt;BR /&gt;I've recently been struggling with utf-8 encoding in Archicad :&lt;BR /&gt;I am trying to create a Text Element in the scene, but my text is UTF8. I tried converting the text, playing around with GS::UniString and the CH family of functions, but so far nothing worked.&lt;BR /&gt;&lt;BR /&gt;I even wonder if it is actually possible, as the API_ElementMemo-&amp;gt;textContent is just a pointer to char * ? I am not experienced at all with encoding issues, so any help is welcome !&lt;BR /&gt;&lt;BR /&gt;Thanks !&lt;/DIV&gt;</description>
    <pubDate>Tue, 06 Dec 2022 12:29:44 GMT</pubDate>
    <dc:creator>Anonymous</dc:creator>
    <dc:date>2022-12-06T12:29:44Z</dc:date>
    <item>
      <title>Create an UTF-8 API_TextType element</title>
      <link>https://community.graphisoft.com/t5/Archicad-C-API/Create-an-UTF-8-API-TextType-element/m-p/221497#M4157</link>
      <description>&lt;DIV class="actalk-migrated-content"&gt;Hi!&lt;BR /&gt;&lt;BR /&gt;I've recently been struggling with utf-8 encoding in Archicad :&lt;BR /&gt;I am trying to create a Text Element in the scene, but my text is UTF8. I tried converting the text, playing around with GS::UniString and the CH family of functions, but so far nothing worked.&lt;BR /&gt;&lt;BR /&gt;I even wonder if it is actually possible, as the API_ElementMemo-&amp;gt;textContent is just a pointer to char * ? I am not experienced at all with encoding issues, so any help is welcome !&lt;BR /&gt;&lt;BR /&gt;Thanks !&lt;/DIV&gt;</description>
      <pubDate>Tue, 06 Dec 2022 12:29:44 GMT</pubDate>
      <guid>https://community.graphisoft.com/t5/Archicad-C-API/Create-an-UTF-8-API-TextType-element/m-p/221497#M4157</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2022-12-06T12:29:44Z</dc:date>
    </item>
    <item>
      <title>Re: Create an UTF-8 API_TextType element</title>
      <link>https://community.graphisoft.com/t5/Archicad-C-API/Create-an-UTF-8-API-TextType-element/m-p/221498#M4158</link>
      <description>Alright, it was easy once I got a little less ArchiCAD specific in my searches, I feel ashamed !&lt;BR /&gt;
&lt;BR /&gt;
It is as simple as declaring your strings as &lt;PRE&gt;std::string str = u8"Whatever you want to input àéï" ;&lt;/PRE&gt;, and work done, the u8 before your string does all the work, no need for a GS::Unistring or anything else.&lt;BR /&gt;
&lt;BR /&gt;
Hope it will help someone !</description>
      <pubDate>Wed, 11 Jul 2018 09:13:10 GMT</pubDate>
      <guid>https://community.graphisoft.com/t5/Archicad-C-API/Create-an-UTF-8-API-TextType-element/m-p/221498#M4158</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2018-07-11T09:13:10Z</dc:date>
    </item>
  </channel>
</rss>

