<?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 Re: drwIndex, send to front/back in Archicad C++ API</title>
    <link>https://community.graphisoft.com/t5/Archicad-C-API/drwIndex-send-to-front-back/m-p/57000#M8014</link>
    <description>I do not know exactly is it a bug of 7 version, but I remember, that when I used it early and I needed set a some fixed drwIndex, I used a loop too using APITool_BringForward and APITool_SendBackward functions commands of ACAPI_Element_Tool function. If you need just send from/back you can use the function.&lt;BR /&gt;
&lt;BR /&gt;
PS: And I think, that the drawing index is limited to the 1-14 range.</description>
    <pubDate>Tue, 05 Apr 2005 09:06:16 GMT</pubDate>
    <dc:creator>Oleg</dc:creator>
    <dc:date>2005-04-05T09:06:16Z</dc:date>
    <item>
      <title>drwIndex, send to front/back</title>
      <link>https://community.graphisoft.com/t5/Archicad-C-API/drwIndex-send-to-front-back/m-p/56997#M8011</link>
      <description>&lt;DIV class="actalk-migrated-content"&gt;Hello,&lt;BR /&gt;&lt;BR /&gt;I want to programmatically send elements to front/back and am finding strange things with element.header.drwIndex.&lt;BR /&gt;&lt;BR /&gt;According to the docs:&lt;BR /&gt;drwIndex &lt;BR /&gt;The index of the element in drawing order. It is important for bring to front/send to back type operations. Elements with higher drwIndex are drawn last.&lt;BR /&gt;&lt;BR /&gt;Is there some trick to using this? Or some bug in version 7 of ArchiCAD?&lt;BR /&gt;I've made a simple SendToFront function and in my tests if I set this value to anything higher than 14 (decimal) it gets set back to 1.&lt;BR /&gt;&lt;BR /&gt;Any insight would be much appreciated.&lt;BR /&gt;&lt;BR /&gt;Thanks,&lt;BR /&gt;Adam&lt;/DIV&gt;</description>
      <pubDate>Mon, 07 Aug 2023 10:10:55 GMT</pubDate>
      <guid>https://community.graphisoft.com/t5/Archicad-C-API/drwIndex-send-to-front-back/m-p/56997#M8011</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2023-08-07T10:10:55Z</dc:date>
    </item>
    <item>
      <title>Re: drwIndex, send to front/back</title>
      <link>https://community.graphisoft.com/t5/Archicad-C-API/drwIndex-send-to-front-back/m-p/56998#M8012</link>
      <description>After a bit of playing I got around this problem like this:&lt;BR /&gt;
&lt;BR /&gt;
while(true)&lt;BR /&gt;
{&lt;BR /&gt;
   tempElement = element&lt;BR /&gt;
   tempElement.header.drwIndex++;&lt;BR /&gt;
   ACAPI_Element_Create(tempElement)&lt;BR /&gt;
   if(tempElement.header.drwIndex &amp;lt;= element.header.drwIndex)&lt;BR /&gt;
   {&lt;BR /&gt;
     ACAPI_Delete... tempElement&lt;BR /&gt;
     break;&lt;BR /&gt;
   }&lt;BR /&gt;
   ACAPI_Delete... element&lt;BR /&gt;
   element = tempElement&lt;BR /&gt;
}&lt;BR /&gt;
&lt;BR /&gt;
This seems a bit dodgy but it works - I'm still wondering if there is a better way to do this???</description>
      <pubDate>Tue, 05 Apr 2005 06:08:10 GMT</pubDate>
      <guid>https://community.graphisoft.com/t5/Archicad-C-API/drwIndex-send-to-front-back/m-p/56998#M8012</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2005-04-05T06:08:10Z</dc:date>
    </item>
    <item>
      <title>Re: drwIndex, send to front/back</title>
      <link>https://community.graphisoft.com/t5/Archicad-C-API/drwIndex-send-to-front-back/m-p/56999#M8013</link>
      <description>I remember from the manuals that there are only about 15 depth layers in total. That might explain why it suddenly jumps forward at 14 or so...&lt;BR /&gt;
&lt;BR /&gt;
Each element gets a default level, but for the elements you need it you can override it (with limitations, such as the total amount of available levels).</description>
      <pubDate>Tue, 05 Apr 2005 07:54:12 GMT</pubDate>
      <guid>https://community.graphisoft.com/t5/Archicad-C-API/drwIndex-send-to-front-back/m-p/56999#M8013</guid>
      <dc:creator>stefan</dc:creator>
      <dc:date>2005-04-05T07:54:12Z</dc:date>
    </item>
    <item>
      <title>Re: drwIndex, send to front/back</title>
      <link>https://community.graphisoft.com/t5/Archicad-C-API/drwIndex-send-to-front-back/m-p/57000#M8014</link>
      <description>I do not know exactly is it a bug of 7 version, but I remember, that when I used it early and I needed set a some fixed drwIndex, I used a loop too using APITool_BringForward and APITool_SendBackward functions commands of ACAPI_Element_Tool function. If you need just send from/back you can use the function.&lt;BR /&gt;
&lt;BR /&gt;
PS: And I think, that the drawing index is limited to the 1-14 range.</description>
      <pubDate>Tue, 05 Apr 2005 09:06:16 GMT</pubDate>
      <guid>https://community.graphisoft.com/t5/Archicad-C-API/drwIndex-send-to-front-back/m-p/57000#M8014</guid>
      <dc:creator>Oleg</dc:creator>
      <dc:date>2005-04-05T09:06:16Z</dc:date>
    </item>
    <item>
      <title>Re: drwIndex, send to front/back</title>
      <link>https://community.graphisoft.com/t5/Archicad-C-API/drwIndex-send-to-front-back/m-p/57001#M8015</link>
      <description>&lt;BLOCKQUOTE&gt;adambutler wrote:&lt;BR /&gt;I want to programmatically send elements to front/back and am finding strange things with element.header.drwIndex.&lt;BR /&gt;
&lt;BR /&gt;
According to the docs:&lt;BR /&gt;
drwIndex &lt;BR /&gt;
The index of the element in drawing order. It is important for bring to front/send to back type operations. Elements with higher drwIndex are drawn last.&lt;/BLOCKQUOTE&gt;

It appears that this value is read-only in the element header. Any changes you make are ignored. The only way to change it is through &lt;I&gt;&lt;/I&gt;&lt;S&gt;&lt;I&gt;&lt;I&gt;&lt;/I&gt;&lt;/I&gt;&lt;/S&gt;ACAPI_Element_Tool&lt;E&gt;&lt;/E&gt; with &lt;I&gt;&lt;/I&gt;&lt;S&gt;&lt;I&gt;&lt;I&gt;&lt;/I&gt;&lt;/I&gt;&lt;/S&gt;APITool_BringForward&lt;E&gt;&lt;/E&gt;, &lt;I&gt;&lt;/I&gt;&lt;S&gt;&lt;I&gt;&lt;I&gt;&lt;/I&gt;&lt;/I&gt;&lt;/S&gt;APITool_SendBackward&lt;E&gt;&lt;/E&gt;, &lt;I&gt;&lt;/I&gt;&lt;S&gt;&lt;I&gt;&lt;I&gt;&lt;/I&gt;&lt;/I&gt;&lt;/S&gt;APITool_SendToBack&lt;E&gt;&lt;/E&gt;, or &lt;I&gt;&lt;/I&gt;&lt;S&gt;&lt;I&gt;&lt;I&gt;&lt;/I&gt;&lt;/I&gt;&lt;/S&gt;APITool_ResetOrder&lt;E&gt;&lt;/E&gt;.</description>
      <pubDate>Tue, 05 Apr 2005 22:21:19 GMT</pubDate>
      <guid>https://community.graphisoft.com/t5/Archicad-C-API/drwIndex-send-to-front-back/m-p/57001#M8015</guid>
      <dc:creator>Ralph Wessel</dc:creator>
      <dc:date>2005-04-05T22:21:19Z</dc:date>
    </item>
    <item>
      <title>Re: drwIndex, send to front/back</title>
      <link>https://community.graphisoft.com/t5/Archicad-C-API/drwIndex-send-to-front-back/m-p/57002#M8016</link>
      <description>Thanks, I should have done more searching through the docs. APITool_SendToFront is working nicely.</description>
      <pubDate>Wed, 06 Apr 2005 02:25:09 GMT</pubDate>
      <guid>https://community.graphisoft.com/t5/Archicad-C-API/drwIndex-send-to-front-back/m-p/57002#M8016</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2005-04-06T02:25:09Z</dc:date>
    </item>
  </channel>
</rss>

