<?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: Label for hatch in GDL</title>
    <link>https://community.graphisoft.com/t5/GDL/Label-for-hatch/m-p/373323#M899</link>
    <description>&lt;P&gt;Haha, this is ChatGPT response when I told it was wrong. it's very polite:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;"It's possible that the property code you used is incorrect or not applicable for the specific element you are trying to retrieve the value from.&lt;/P&gt;
&lt;P&gt;However, as you have discovered, the General Libpart Parameters provide a better solution to get the information you need about the fill and its properties. These parameters are specifically designed for use in GDL scripts and provide a wide range of information about the fill, including line type, fill type, building material name and index, and the pens of the fill and its background.&lt;/P&gt;
&lt;P&gt;So, using these parameters would be a better approach to get the information you need about the fill and its properties."&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Thu, 16 Mar 2023 08:44:37 GMT</pubDate>
    <dc:creator>Ernest Atanasiu</dc:creator>
    <dc:date>2023-03-16T08:44:37Z</dc:date>
    <item>
      <title>Label for hatch</title>
      <link>https://community.graphisoft.com/t5/GDL/Label-for-hatch/m-p/373120#M896</link>
      <description>&lt;P&gt;I would to create a label that shows the contour pen, &amp;nbsp;pen of the background fill and pen of the fill pattern.&lt;/P&gt;&lt;P&gt;I cannot extract those information with the default Autotext. I noticed that when when I'm creating custom label with Autotext, the information for Autotext has this kind of code :&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;&lt;FONT size="2"&gt;paragraph "AC_PRG_12" &amp;nbsp; &amp;nbsp; &amp;nbsp;1, &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;0, &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;0, &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;0, &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;1&lt;/FONT&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;&amp;nbsp; &amp;nbsp; pen &amp;nbsp; &amp;nbsp; penAttribute_1&lt;/FONT&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;&amp;nbsp; &amp;nbsp; set style "AC_STYLE_1"&lt;/FONT&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &lt;FONT color="#FF0000"&gt;&amp;nbsp; "&amp;lt;PROPERTY-B9179DB7-97BC-4985-94DC-06C201F79EF4&amp;gt;"&lt;/FONT&gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;endparagraph&lt;/FONT&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;paragraph "AC_PRG_13" &amp;nbsp; &amp;nbsp; &amp;nbsp;1, &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;0, &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;0, &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;0, &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;1&lt;/FONT&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &lt;FONT color="#FF0000"&gt;"&amp;lt;PROPERTY-BE376478-6966-4892-BEC7-4CB72ABF4003&amp;gt;"&lt;/FONT&gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;endparagraph&lt;/FONT&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;paragraph "AC_PRG_14" &amp;nbsp; &amp;nbsp; &amp;nbsp;1, &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;0, &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;0, &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;0, &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;1&lt;/FONT&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;&lt;FONT color="#FF0000"&gt; "&amp;lt;PROPERTY-8E19BE5F-D487-4BEC-9281-B34CA2355292&amp;gt;"&lt;/FONT&gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;endparagraph&lt;/FONT&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;textblock "AC_TEXTBLOCK_6" 21.71378406315, &amp;nbsp; &amp;nbsp; &amp;nbsp;1, &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;0, &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;1, &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;1, &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;1,&amp;nbsp;&lt;/FONT&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; "AC_PRG_12", "AC_PRG_13", "AC_PRG_14"&lt;/FONT&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;richtext2 12.27684530913, 13.27296877469, "AC_TEXTBLOCK_6"&lt;/FONT&gt;&lt;/PRE&gt;&lt;DIV&gt;Is there a property code that would give me back f.e the background fill? If not what would be the easiest way to get those information for the hatch?&amp;nbsp;&lt;/DIV&gt;&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV&gt;Cheers!&lt;/DIV&gt;&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;</description>
      <pubDate>Tue, 14 Mar 2023 08:52:32 GMT</pubDate>
      <guid>https://community.graphisoft.com/t5/GDL/Label-for-hatch/m-p/373120#M896</guid>
      <dc:creator>mus-a</dc:creator>
      <dc:date>2023-03-14T08:52:32Z</dc:date>
    </item>
    <item>
      <title>Re: Label for hatch</title>
      <link>https://community.graphisoft.com/t5/GDL/Label-for-hatch/m-p/373262#M897</link>
      <description>&lt;P&gt;Have you tried chatGPT? I don't know GDL, I can't correct it if it's wrong but it's worth a try.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;"Yes, in ARCHICAD GDL development, you can use property codes to extract information about the attributes of an object, such as the contour pen, pen of the background fill, and pen of the fill pattern. However, not all properties are available for all objects.&lt;/P&gt;
&lt;P&gt;To get the pen of the background fill, you can use the property code "&amp;lt;PROPERTY-B5F6E5A6-5B10-47A6-9B6D-2116C2DC1C89&amp;gt;" in your label's Autotext code. This property code extracts the pen attribute of the background fill. Here's an example of how you could use it:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;DIV class="bg-black MB-4 rounded-md"&gt;
&lt;DIV class="flex items-center relative text-gray-200 bg-gray-800 px-4 py-2 text-xs font-sans"&gt;&lt;SPAN class=""&gt;python&lt;/SPAN&gt;&lt;BUTTON class="flex ml-auto gap-2"&gt;Copy code&lt;/BUTTON&gt;&lt;/DIV&gt;
&lt;DIV class="p-4 overflow-y-auto"&gt;&lt;CODE class="!whitespace-pre hljs language-python"&gt;paragraph &lt;SPAN class="hljs-string"&gt;"AC_PRG_12"&lt;/SPAN&gt; &lt;SPAN class="hljs-number"&gt;1&lt;/SPAN&gt;, &lt;SPAN class="hljs-number"&gt;0&lt;/SPAN&gt;, &lt;SPAN class="hljs-number"&gt;0&lt;/SPAN&gt;, &lt;SPAN class="hljs-number"&gt;0&lt;/SPAN&gt;, &lt;SPAN class="hljs-number"&gt;1&lt;/SPAN&gt;
    &lt;SPAN class="hljs-built_in"&gt;set&lt;/SPAN&gt; style &lt;SPAN class="hljs-string"&gt;"AC_STYLE_1"&lt;/SPAN&gt;
    &lt;SPAN class="hljs-string"&gt;"&amp;lt;PROPERTY-B5F6E5A6-5B10-47A6-9B6D-2116C2DC1C89&amp;gt;"&lt;/SPAN&gt;
endparagraph
&lt;/CODE&gt;&lt;/DIV&gt;
&lt;/DIV&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&amp;nbsp;&lt;/PRE&gt;
&lt;P&gt;To get the pen of the fill pattern, you can use the property code "&amp;lt;PROPERTY-C66309EA-7B06-46AE-9F8F-33E1567AC107&amp;gt;" in your label's Autotext code. This property code extracts the pen attribute of the fill pattern. Here's an example of how you could use it:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;DIV class="bg-black MB-4 rounded-md"&gt;
&lt;DIV class="flex items-center relative text-gray-200 bg-gray-800 px-4 py-2 text-xs font-sans"&gt;&lt;SPAN class=""&gt;python&lt;/SPAN&gt;&lt;BUTTON class="flex ml-auto gap-2"&gt;Copy code&lt;/BUTTON&gt;&lt;/DIV&gt;
&lt;DIV class="p-4 overflow-y-auto"&gt;&lt;CODE class="!whitespace-pre hljs language-python"&gt;paragraph &lt;SPAN class="hljs-string"&gt;"AC_PRG_12"&lt;/SPAN&gt; &lt;SPAN class="hljs-number"&gt;1&lt;/SPAN&gt;, &lt;SPAN class="hljs-number"&gt;0&lt;/SPAN&gt;, &lt;SPAN class="hljs-number"&gt;0&lt;/SPAN&gt;, &lt;SPAN class="hljs-number"&gt;0&lt;/SPAN&gt;, &lt;SPAN class="hljs-number"&gt;1&lt;/SPAN&gt;
    &lt;SPAN class="hljs-built_in"&gt;set&lt;/SPAN&gt; style &lt;SPAN class="hljs-string"&gt;"AC_STYLE_1"&lt;/SPAN&gt;
    &lt;SPAN class="hljs-string"&gt;"&amp;lt;PROPERTY-C66309EA-7B06-46AE-9F8F-33E1567AC107&amp;gt;"&lt;/SPAN&gt;
endparagraph
&lt;/CODE&gt;&lt;/DIV&gt;
&lt;/DIV&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&amp;nbsp;&lt;/PRE&gt;
&lt;P&gt;For the contour pen, you can use the "Pen" command in GDL to explicitly define the pen attribute of the object. Here's an example of how you could use it:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;DIV class="bg-black MB-4 rounded-md"&gt;
&lt;DIV class="flex items-center relative text-gray-200 bg-gray-800 px-4 py-2 text-xs font-sans"&gt;&lt;SPAN class=""&gt;python&lt;/SPAN&gt;&lt;BUTTON class="flex ml-auto gap-2"&gt;Copy code&lt;/BUTTON&gt;&lt;/DIV&gt;
&lt;DIV class="p-4 overflow-y-auto"&gt;&lt;CODE class="!whitespace-pre hljs language-python"&gt;Pen(contour_pen)

paragraph &lt;SPAN class="hljs-string"&gt;"AC_PRG_12"&lt;/SPAN&gt; &lt;SPAN class="hljs-number"&gt;1&lt;/SPAN&gt;, &lt;SPAN class="hljs-number"&gt;0&lt;/SPAN&gt;, &lt;SPAN class="hljs-number"&gt;0&lt;/SPAN&gt;, &lt;SPAN class="hljs-number"&gt;0&lt;/SPAN&gt;, &lt;SPAN class="hljs-number"&gt;1&lt;/SPAN&gt;
    &lt;SPAN class="hljs-built_in"&gt;set&lt;/SPAN&gt; style &lt;SPAN class="hljs-string"&gt;"AC_STYLE_1"&lt;/SPAN&gt;
    &lt;SPAN class="hljs-string"&gt;"Contour pen: "&lt;/SPAN&gt; contour_pen
endparagraph
&lt;/CODE&gt;&lt;/DIV&gt;
&lt;/DIV&gt;
&lt;P&gt;&lt;LI-WRAPPER&gt;&lt;/LI-WRAPPER&gt;&lt;/P&gt;
&lt;PRE&gt;&amp;nbsp;&lt;/PRE&gt;
&lt;P&gt;Note that you would need to define the variable "contour_pen" in your GDL script to hold the value of the contour pen attribute."&lt;/P&gt;</description>
      <pubDate>Wed, 15 Mar 2023 18:48:19 GMT</pubDate>
      <guid>https://community.graphisoft.com/t5/GDL/Label-for-hatch/m-p/373262#M897</guid>
      <dc:creator>Ernest Atanasiu</dc:creator>
      <dc:date>2023-03-15T18:48:19Z</dc:date>
    </item>
    <item>
      <title>Re: Label for hatch</title>
      <link>https://community.graphisoft.com/t5/GDL/Label-for-hatch/m-p/373316#M898</link>
      <description>&lt;P&gt;Thanks for your reply! I didn't try chatGPT, but that's a great idea!&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Update:I tried it now those property codes, but it gives back "#".I wonder why it doesn't work, while the others like the name of the fill works perfectly. Maybe chatGPT gave the wrong property code?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Meanwhile with big help of my coworker, we found this solution - to use General Libpart Parameters and it works like a charm. So for those who looks for something similar in the future, here they are:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;DIV&gt;FILL_LINETYPE line type of the fill&lt;/DIV&gt;&lt;DIV&gt;FILL_FILL fill type of the fill&lt;/DIV&gt;&lt;DIV&gt;FILL_BMAT_NAME building material name of the fill&lt;/DIV&gt;&lt;DIV&gt;FILL_BMAT building material index of the fill&lt;/DIV&gt;&lt;DIV&gt;Compatibility: introduced in ARCHICAD 21.&lt;/DIV&gt;&lt;DIV&gt;FILL_FILL_PEN pen of the fill pattern of the fill&lt;/DIV&gt;&lt;DIV&gt;FILL_PEN pen of the fill&lt;/DIV&gt;&lt;DIV&gt;FILL_FBGD_PEN pen of the background of the fill&lt;/DIV&gt;&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;</description>
      <pubDate>Thu, 16 Mar 2023 08:12:01 GMT</pubDate>
      <guid>https://community.graphisoft.com/t5/GDL/Label-for-hatch/m-p/373316#M898</guid>
      <dc:creator>mus-a</dc:creator>
      <dc:date>2023-03-16T08:12:01Z</dc:date>
    </item>
    <item>
      <title>Re: Label for hatch</title>
      <link>https://community.graphisoft.com/t5/GDL/Label-for-hatch/m-p/373323#M899</link>
      <description>&lt;P&gt;Haha, this is ChatGPT response when I told it was wrong. it's very polite:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;"It's possible that the property code you used is incorrect or not applicable for the specific element you are trying to retrieve the value from.&lt;/P&gt;
&lt;P&gt;However, as you have discovered, the General Libpart Parameters provide a better solution to get the information you need about the fill and its properties. These parameters are specifically designed for use in GDL scripts and provide a wide range of information about the fill, including line type, fill type, building material name and index, and the pens of the fill and its background.&lt;/P&gt;
&lt;P&gt;So, using these parameters would be a better approach to get the information you need about the fill and its properties."&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 16 Mar 2023 08:44:37 GMT</pubDate>
      <guid>https://community.graphisoft.com/t5/GDL/Label-for-hatch/m-p/373323#M899</guid>
      <dc:creator>Ernest Atanasiu</dc:creator>
      <dc:date>2023-03-16T08:44:37Z</dc:date>
    </item>
    <item>
      <title>Re: Label for hatch</title>
      <link>https://community.graphisoft.com/t5/GDL/Label-for-hatch/m-p/373332#M900</link>
      <description>&lt;P&gt;haha &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt; i also asked ChatGPT to generate list of lib part parameters for a fill. Also not correct &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;"Certainly! Here is a list of common libpart parameters for fill in ArchiCAD GDL:&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;FILL_TYPE: Type of fill used in the object (e.g. Solid, Pattern, Gradient, Image).&lt;/LI&gt;&lt;LI&gt;FILL_ANGLE: Angle of the fill pattern or gradient.&lt;/LI&gt;&lt;LI&gt;FILL_SPACING: Spacing of the fill pattern or gradient.&lt;/LI&gt;&lt;LI&gt;FILL_COLOR: Color of the fill.&lt;/LI&gt;&lt;LI&gt;FILL_BACKGROUND_COLOR: Background color of the fill.&lt;/LI&gt;&lt;LI&gt;FILL_FOREGROUND_COLOR: Foreground color of the fill.&lt;/LI&gt;&lt;LI&gt;FILL_PATTERN: Name of the fill pattern used.&lt;/LI&gt;&lt;LI&gt;FILL_GRADIENT: Name of the gradient used.&lt;/LI&gt;&lt;LI&gt;FILL_IMAGE: Name of the image used for fill.&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;These parameters can be used in libpart objects to specify the fill properties of an object. Depending on the type of fill, some of these parameters may not be applicable. For example, FILL_PATTERN and FILL_GRADIENT are only relevant when FILL_TYPE is set to "Pattern" or "Gradient", respectively."&lt;/P&gt;</description>
      <pubDate>Thu, 16 Mar 2023 09:19:31 GMT</pubDate>
      <guid>https://community.graphisoft.com/t5/GDL/Label-for-hatch/m-p/373332#M900</guid>
      <dc:creator>mus-a</dc:creator>
      <dc:date>2023-03-16T09:19:31Z</dc:date>
    </item>
  </channel>
</rss>

