<?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: Overrule and polyline in ObjectARX Forum</title>
    <link>https://forums.autodesk.com/t5/objectarx-forum/overrule-and-polyline/m-p/9169787#M4967</link>
    <description>&lt;P&gt;I'm not sure what you want to do. It seems you're mixing width and thickness.&lt;/P&gt;
&lt;P&gt;&lt;FONT face="courier new,courier"&gt;AcDbPolyline&lt;/FONT&gt; has no &lt;FONT face="courier new,courier"&gt;&lt;SPAN style="font-weight: bold;"&gt;setConstantThickness()&lt;/SPAN&gt; &lt;/FONT&gt;method. Only &lt;FONT face="courier new,courier"&gt;setConstantWidth(double)&lt;/FONT&gt; and&lt;/P&gt;
&lt;P&gt;&lt;FONT face="courier new,courier"&gt;setWidthsAt(unsigned index, double start, double end)&lt;/FONT&gt; and &lt;FONT face="courier new,courier"&gt;setThickness(double)&lt;/FONT&gt;.&lt;/P&gt;
&lt;P&gt;"Thickness" means the extrusion lenght along the pline's plane normal.&lt;/P&gt;
&lt;P&gt;"Width" means the width of a polyline segment in the pline's plane.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I think you want to modify the displayed &lt;U&gt;width&lt;/U&gt; of a specific polyline segment. Right?&lt;/P&gt;
&lt;P&gt;Maybe it works like this:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;MyAcGiDrawableOverrule::worldDraw(AcGiDrawable* pSubject, AcGiWorldDraw * wd) {
	AcDbPolyline *myPline = AcDbPolyline::cast(pSubject);
	if (myPline) {
		AcDbPolyline *tempPline = AcDbPolyline::cast(myPline-&amp;gt;clone()); // create a copy
		tempPline-&amp;gt;setWidthsAt(m_myIndex, m_myWidth, m_myWidth);  // modify width at segment m_myIndex
		wd-&amp;gt;geometry().geo.pline(*tempPline); // draw the temporary polyline
		delete tempPline; // CAUTION! Not sure whether GS still needs to access tempPline! Test!!!
	}
}&lt;/PRE&gt;</description>
    <pubDate>Wed, 27 Nov 2019 14:01:00 GMT</pubDate>
    <dc:creator>tbrammer</dc:creator>
    <dc:date>2019-11-27T14:01:00Z</dc:date>
    <item>
      <title>Overrule and polyline</title>
      <link>https://forums.autodesk.com/t5/objectarx-forum/overrule-and-polyline/m-p/9169031#M4966</link>
      <description>&lt;P&gt;&lt;STRONG&gt;Hi&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&lt;SPAN&gt;I have implemented overrule, i want show line with different thickness on particular call, so I override method 'setAttributes' and in this i set thickness to 'AcGiDrawableTraits' but for polylines this does't work as for polyline in need to set globlal thickness.&lt;/SPAN&gt;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;One way I override wordDraw in overrule and then open polyline for modify and set constant thickness but this modifies entity and later i need to restore original&amp;nbsp;thickness again on ending overrule.&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;&lt;SPAN style="font-weight: bold;"&gt;Is there any way that using AcGiDrawableTraits I can set global thickness of polyline without calling setConstantThickness()?&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-weight: bold;"&gt;Regards,&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-weight: bold;"&gt;Dhanraj&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 27 Nov 2019 06:49:54 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/objectarx-forum/overrule-and-polyline/m-p/9169031#M4966</guid>
      <dc:creator>dhanraj.dhokale</dc:creator>
      <dc:date>2019-11-27T06:49:54Z</dc:date>
    </item>
    <item>
      <title>Re: Overrule and polyline</title>
      <link>https://forums.autodesk.com/t5/objectarx-forum/overrule-and-polyline/m-p/9169787#M4967</link>
      <description>&lt;P&gt;I'm not sure what you want to do. It seems you're mixing width and thickness.&lt;/P&gt;
&lt;P&gt;&lt;FONT face="courier new,courier"&gt;AcDbPolyline&lt;/FONT&gt; has no &lt;FONT face="courier new,courier"&gt;&lt;SPAN style="font-weight: bold;"&gt;setConstantThickness()&lt;/SPAN&gt; &lt;/FONT&gt;method. Only &lt;FONT face="courier new,courier"&gt;setConstantWidth(double)&lt;/FONT&gt; and&lt;/P&gt;
&lt;P&gt;&lt;FONT face="courier new,courier"&gt;setWidthsAt(unsigned index, double start, double end)&lt;/FONT&gt; and &lt;FONT face="courier new,courier"&gt;setThickness(double)&lt;/FONT&gt;.&lt;/P&gt;
&lt;P&gt;"Thickness" means the extrusion lenght along the pline's plane normal.&lt;/P&gt;
&lt;P&gt;"Width" means the width of a polyline segment in the pline's plane.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I think you want to modify the displayed &lt;U&gt;width&lt;/U&gt; of a specific polyline segment. Right?&lt;/P&gt;
&lt;P&gt;Maybe it works like this:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;MyAcGiDrawableOverrule::worldDraw(AcGiDrawable* pSubject, AcGiWorldDraw * wd) {
	AcDbPolyline *myPline = AcDbPolyline::cast(pSubject);
	if (myPline) {
		AcDbPolyline *tempPline = AcDbPolyline::cast(myPline-&amp;gt;clone()); // create a copy
		tempPline-&amp;gt;setWidthsAt(m_myIndex, m_myWidth, m_myWidth);  // modify width at segment m_myIndex
		wd-&amp;gt;geometry().geo.pline(*tempPline); // draw the temporary polyline
		delete tempPline; // CAUTION! Not sure whether GS still needs to access tempPline! Test!!!
	}
}&lt;/PRE&gt;</description>
      <pubDate>Wed, 27 Nov 2019 14:01:00 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/objectarx-forum/overrule-and-polyline/m-p/9169787#M4967</guid>
      <dc:creator>tbrammer</dc:creator>
      <dc:date>2019-11-27T14:01:00Z</dc:date>
    </item>
    <item>
      <title>Re: Overrule and polyline</title>
      <link>https://forums.autodesk.com/t5/objectarx-forum/overrule-and-polyline/m-p/9171618#M4968</link>
      <description>&lt;P&gt;Thanks for reply.&lt;/P&gt;&lt;P&gt;Sorry I mean '&lt;SPAN&gt;setConstantWidth' not thickness.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;cloning and setting thickness I tried already this works but this has some other issues in my application.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;So I want to know is there any drawable trait property which can be set and polyline will be drawn accordingly.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;I will try your solution, I think to set a property to line I will need to add this in database first.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Regards,&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Dhanraj&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 28 Nov 2019 10:08:46 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/objectarx-forum/overrule-and-polyline/m-p/9171618#M4968</guid>
      <dc:creator>dhanraj.dhokale</dc:creator>
      <dc:date>2019-11-28T10:08:46Z</dc:date>
    </item>
  </channel>
</rss>

