<?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: Changing a Modal Dialog size in Archicad C++ API</title>
    <link>https://community.graphisoft.com/t5/Archicad-C-API/SOLVED-Changing-a-Modal-Dialog-size/m-p/250686#M5477</link>
    <description>&lt;BLOCKQUOTE&gt;paulk wrote:&lt;BR /&gt;Hi&lt;BR /&gt;
&lt;BR /&gt;
I have a modal dialog defined in a GRC file with a fixed width/height.  This dialog has been unchanged for 12 months, however now I need to add 5 fields to it - so the height needs to be increased.  But when I increase the height in the GRC file it "remembers" the old height.&lt;BR /&gt;
&lt;BR /&gt;
The GRC set up the modal dialog as:
&lt;PRE&gt;'GDLG'  32580    Modal | normalFrame | noGrow   0    0  310  540  " Configuration "  {&lt;/PRE&gt;
How can I force the dialog to use the new height pls?  I know the height is stored in the Windows registry, but I cannot get all the users of my plugin to hack their registry to fix this.&lt;BR /&gt;
&lt;BR /&gt;
Thanks&lt;BR /&gt;
&lt;BR /&gt;
Paul&lt;/BLOCKQUOTE&gt;

You can try by this way&lt;BR /&gt;
this-&amp;gt;SetClientSize(x, y)&lt;BR /&gt;
In my case every dialog is a class which inherits from DG::ModalDialog &lt;BR /&gt;
&lt;BR /&gt;
How you build your dialog ?</description>
    <pubDate>Wed, 04 Mar 2015 12:23:11 GMT</pubDate>
    <dc:creator>Anonymous</dc:creator>
    <dc:date>2015-03-04T12:23:11Z</dc:date>
    <item>
      <title>[SOLVED] Changing a Modal Dialog size</title>
      <link>https://community.graphisoft.com/t5/Archicad-C-API/SOLVED-Changing-a-Modal-Dialog-size/m-p/250685#M5476</link>
      <description>&lt;DIV class="actalk-migrated-content"&gt;Hi&lt;BR /&gt;&lt;BR /&gt;I have a modal dialog defined in a GRC file with a fixed width/height. This dialog has been unchanged for 12 months, however now I need to add 5 fields to it - so the height needs to be increased. But when I increase the height in the GRC file it "remembers" the old height.&lt;BR /&gt;&lt;BR /&gt;The GRC set up the modal dialog as:
&lt;PRE&gt;'GDLG'  32580    Modal | normalFrame | noGrow   0    0  310  540  " Configuration "  {&lt;/PRE&gt;
How can I force the dialog to use the new height pls? I know the height is stored in the Windows registry, but I cannot get all the users of my plugin to hack their registry to fix this.&lt;BR /&gt;&lt;BR /&gt;Thanks&lt;BR /&gt;&lt;BR /&gt;Paul&lt;/DIV&gt;</description>
      <pubDate>Tue, 01 Aug 2023 11:35:53 GMT</pubDate>
      <guid>https://community.graphisoft.com/t5/Archicad-C-API/SOLVED-Changing-a-Modal-Dialog-size/m-p/250685#M5476</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2023-08-01T11:35:53Z</dc:date>
    </item>
    <item>
      <title>Re: Changing a Modal Dialog size</title>
      <link>https://community.graphisoft.com/t5/Archicad-C-API/SOLVED-Changing-a-Modal-Dialog-size/m-p/250686#M5477</link>
      <description>&lt;BLOCKQUOTE&gt;paulk wrote:&lt;BR /&gt;Hi&lt;BR /&gt;
&lt;BR /&gt;
I have a modal dialog defined in a GRC file with a fixed width/height.  This dialog has been unchanged for 12 months, however now I need to add 5 fields to it - so the height needs to be increased.  But when I increase the height in the GRC file it "remembers" the old height.&lt;BR /&gt;
&lt;BR /&gt;
The GRC set up the modal dialog as:
&lt;PRE&gt;'GDLG'  32580    Modal | normalFrame | noGrow   0    0  310  540  " Configuration "  {&lt;/PRE&gt;
How can I force the dialog to use the new height pls?  I know the height is stored in the Windows registry, but I cannot get all the users of my plugin to hack their registry to fix this.&lt;BR /&gt;
&lt;BR /&gt;
Thanks&lt;BR /&gt;
&lt;BR /&gt;
Paul&lt;/BLOCKQUOTE&gt;

You can try by this way&lt;BR /&gt;
this-&amp;gt;SetClientSize(x, y)&lt;BR /&gt;
In my case every dialog is a class which inherits from DG::ModalDialog &lt;BR /&gt;
&lt;BR /&gt;
How you build your dialog ?</description>
      <pubDate>Wed, 04 Mar 2015 12:23:11 GMT</pubDate>
      <guid>https://community.graphisoft.com/t5/Archicad-C-API/SOLVED-Changing-a-Modal-Dialog-size/m-p/250686#M5477</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2015-03-04T12:23:11Z</dc:date>
    </item>
    <item>
      <title>Re: Changing a Modal Dialog size</title>
      <link>https://community.graphisoft.com/t5/Archicad-C-API/SOLVED-Changing-a-Modal-Dialog-size/m-p/250687#M5478</link>
      <description>Hi&lt;BR /&gt;
&lt;BR /&gt;
I am running my dialog with&lt;PRE&gt;DGModalDialog (ACAPI_GetOwnResModule(), ConfigurationDLG_GDLGID, ACAPI_GetOwnResModule(), ConfigurationDlgCallBack, NULL);&lt;/PRE&gt;I tried adding &lt;PRE&gt;DGSetDialogMinSize (ConfigurationDLG_GDLGID, DG_FRAME, 310, 700);&lt;/PRE&gt;in the DG_MSG_INIT handler, but that does nothing.&lt;BR /&gt;
&lt;BR /&gt;
EDIT: Using DGSetDialogSize in the DG_MSG_INIT handler works.  A bit odd needing to hardcode the dialog size, but it resolves the issue.&lt;BR /&gt;
&lt;BR /&gt;
Thanks&lt;BR /&gt;
&lt;BR /&gt;
Paul</description>
      <pubDate>Thu, 05 Mar 2015 02:45:28 GMT</pubDate>
      <guid>https://community.graphisoft.com/t5/Archicad-C-API/SOLVED-Changing-a-Modal-Dialog-size/m-p/250687#M5478</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2015-03-05T02:45:28Z</dc:date>
    </item>
    <item>
      <title>Re: Changing a Modal Dialog size</title>
      <link>https://community.graphisoft.com/t5/Archicad-C-API/SOLVED-Changing-a-Modal-Dialog-size/m-p/250688#M5479</link>
      <description>&lt;BLOCKQUOTE&gt;paulk wrote:&lt;BR /&gt;Using DGSetDialogSize in the DG_MSG_INIT handler works.  A bit odd needing to hardcode the dialog size, but it resolves the issue.&lt;/BLOCKQUOTE&gt;
You can avoid hardcoding the size by asking the API to give you the size of the dialog as defined in the resources. Just call &lt;I&gt;&lt;/I&gt;&lt;S&gt;&lt;I&gt;&lt;I&gt;&lt;/I&gt;&lt;/I&gt;&lt;/S&gt;DGGetDialogSize&lt;E&gt;&lt;/E&gt; with the rectType set to &lt;I&gt;&lt;/I&gt;&lt;S&gt;&lt;I&gt;&lt;I&gt;&lt;/I&gt;&lt;/I&gt;&lt;/S&gt;DG_ORIGCLIENT&lt;E&gt;&lt;/E&gt;</description>
      <pubDate>Thu, 05 Mar 2015 10:47:17 GMT</pubDate>
      <guid>https://community.graphisoft.com/t5/Archicad-C-API/SOLVED-Changing-a-Modal-Dialog-size/m-p/250688#M5479</guid>
      <dc:creator>Ralph Wessel</dc:creator>
      <dc:date>2015-03-05T10:47:17Z</dc:date>
    </item>
    <item>
      <title>Re: Changing a Modal Dialog size</title>
      <link>https://community.graphisoft.com/t5/Archicad-C-API/SOLVED-Changing-a-Modal-Dialog-size/m-p/250689#M5480</link>
      <description>Thanks Ralph.</description>
      <pubDate>Fri, 06 Mar 2015 03:29:53 GMT</pubDate>
      <guid>https://community.graphisoft.com/t5/Archicad-C-API/SOLVED-Changing-a-Modal-Dialog-size/m-p/250689#M5480</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2015-03-06T03:29:53Z</dc:date>
    </item>
  </channel>
</rss>

