<div dir="ltr"><div class="gmail_default" style="font-family:arial,helvetica,sans-serif;font-size:small">Hi Paul</div><div class="gmail_default" style="font-family:arial,helvetica,sans-serif;font-size:small"><br></div><div class="gmail_default" style="font-family:arial,helvetica,sans-serif;font-size:small">AFAIK you need to keep track of all the rubber bands you add and then reset them when you want to clean them up. See some example code here:</div><div class="gmail_default" style="font-family:arial,helvetica,sans-serif;font-size:small"><br></div><div class="gmail_default" style="font-family:arial,helvetica,sans-serif;font-size:small"><a href="https://github.com/inasafe/inasafe/blob/develop/safe/gui/tools/rectangle_map_tool.py#L56">https://github.com/inasafe/inasafe/blob/develop/safe/gui/tools/rectangle_map_tool.py#L56</a></div><div class="gmail_default" style="font-family:arial,helvetica,sans-serif;font-size:small"><br></div><div class="gmail_default" style="font-family:arial,helvetica,sans-serif;font-size:small">Regards</div><div class="gmail_default" style="font-family:arial,helvetica,sans-serif;font-size:small"><br></div><div class="gmail_default" style="font-family:arial,helvetica,sans-serif;font-size:small">Tim<br></div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Tue, Sep 22, 2020 at 9:02 AM Paul Wittle <<a href="mailto:paul.wittle@dorsetcouncil.gov.uk">paul.wittle@dorsetcouncil.gov.uk</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">
<div lang="EN-GB">
<div class="gmail-m_-8924650652006491221WordSection1">
<p class="MsoNormal">Hi,<u></u><u></u></p>
<p class="MsoNormal"><u></u> <u></u></p>
<p class="MsoNormal">I’m having an issue with the documentation this morning. I’m writing a small python plugin and adding rubberbands to the canvas which is fine but for some reason I can’t seem to remove them from the canvas at the end.
<u></u><u></u></p>
<p class="MsoNormal"><u></u> <u></u></p>
<p class="MsoNormal">To start with, this is because I’d not put anything in to remove them but now I’m using the
<span style="font-size:9.5pt;font-family:Consolas;color:black">iface.mapCanvas.scene().removeItem() function and they still are present.
<u></u><u></u></span></p>
<p class="MsoNormal"><span style="font-size:9.5pt;font-family:Consolas;color:black"><u></u> <u></u></span></p>
<p class="MsoNormal"><span style="font-size:9.5pt;font-family:Consolas;color:black">I have two questions really:<u></u><u></u></span></p>
<ol style="margin-top:0cm" type="1" start="1">
<li class="gmail-m_-8924650652006491221MsoListParagraph" style="margin-left:5.4pt">I can’t see scene defined in the documentation for QgsMapCanvas; is this something that should be there?<u></u><u></u></li><li class="gmail-m_-8924650652006491221MsoListParagraph" style="margin-left:5.4pt">Is there a way to simply remove all scenes from the canvas?<u></u><u></u></li></ol>
<p class="MsoNormal"><u></u> <u></u></p>
<p class="MsoNormal">Any help would be great <span style="font-family:"Segoe UI Emoji",sans-serif">
😊</span><u></u><u></u></p>
<p class="MsoNormal">Thanks,<u></u><u></u></p>
<p class="MsoNormal"><u></u> <u></u></p>
<table cellspacing="3" cellpadding="0" border="0">
<tbody>
<tr>
<td style="padding:0.75pt 15pt 0.75pt 0.75pt">
<p class="MsoNormal"><b><span style="font-size:11.5pt;font-family:"Arial",sans-serif">Paul Wittle
</span></b><span style="font-size:11.5pt;font-family:"Arial",sans-serif"><u></u><u></u></span></p>
</td>
<td rowspan="6" style="border-color:currentcolor currentcolor currentcolor rgb(47,85,151);border-style:none none none solid;border-width:medium medium medium 1.5pt;padding:0.75pt 0.75pt 0.75pt 15pt">
<p class="MsoNormal"><a href="https://www.dorsetcouncil.gov.uk/" target="_blank"><span style="color:windowtext;text-decoration:none"><img style="width: 2.3666in; height: 1.0083in;" id="gmail-m_-8924650652006491221Picture_x0020_1" src="cid:174b51c28e74ce8e91" width="227" height="97" border="0"></span></a><span style="font-family:"Arial",sans-serif"><u></u><u></u></span></p>
</td>
</tr>
<tr>
<td style="padding:0.75pt 15pt 0.75pt 0.75pt">
<p class="MsoNormal"><b><span style="font-family:"Arial",sans-serif">Business Solutions Analyst (GIS)</span></b><span style="font-family:"Arial",sans-serif"><u></u><u></u></span></p>
</td>
</tr>
<tr>
<td style="padding:0.75pt 15pt 0.75pt 0.75pt">
<p class="MsoNormal"><b><span style="font-family:"Arial",sans-serif">ICT Operations
</span></b><span style="font-family:"Arial",sans-serif"><u></u><u></u></span></p>
</td>
</tr>
<tr>
<td style="padding:0.75pt 15pt 15pt 0.75pt">
<p class="MsoNormal"><b><span style="font-family:"Arial",sans-serif">Dorset Council</span></b><span style="font-family:"Arial",sans-serif"><u></u><u></u></span></p>
</td>
</tr>
<tr>
<td style="padding:0.75pt 15pt 0.75pt 0.75pt">
<p class="MsoNormal"><span style="font-family:"Arial",sans-serif"><a href="tel:01305%20228473%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20" target="_blank"><span style="color:blue">01305 228473
</span></a><u></u><u></u></span></p>
</td>
</tr>
<tr>
<td style="padding:0.75pt 15pt 0.75pt 0.75pt">
<p class="MsoNormal"><span style="font-family:"Arial",sans-serif"><a href="https://www.dorsetcouncil.gov.uk" target="_blank"><span style="color:blue">dorsetcouncil.gov.uk</span></a><u></u><u></u></span></p>
</td>
</tr>
</tbody>
</table>
<p class="MsoNormal"><span style="display:none"><u></u> <u></u></span></p>
<table cellspacing="3" cellpadding="0" border="0">
<tbody>
<tr>
<td style="padding:15pt 3.75pt 0.75pt 0.75pt">
<p class="MsoNormal"><a href="https://www.facebook.com/DorsetCouncilUK" target="_blank"><span style="color:windowtext;text-decoration:none"><img style="width: 0.4833in; height: 0.4833in;" id="gmail-m_-8924650652006491221Picture_x0020_2" src="cid:174b51c28e75b16b22" width="46" height="46" border="0"></span></a><span><u></u><u></u></span></p>
</td>
<td style="padding:15pt 3.75pt 0.75pt 0.75pt">
<p class="MsoNormal"><a href="https://instagram.com/DorsetCouncilUK" target="_blank"><span style="color:windowtext;text-decoration:none"><img style="width: 0.4833in; height: 0.4833in;" id="gmail-m_-8924650652006491221Picture_x0020_3" src="cid:174b51c28e7692e333" width="46" height="46" border="0"></span></a><span><u></u><u></u></span></p>
</td>
<td style="padding:15pt 3.75pt 0.75pt 0.75pt">
<p class="MsoNormal"><a href="https://twitter.com/DorsetCouncilUK" target="_blank"><span style="color:windowtext;text-decoration:none"><img style="width: 0.4833in; height: 0.4833in;" id="gmail-m_-8924650652006491221Picture_x0020_4" src="cid:174b51c28e77745b44" width="46" height="46" border="0"></span></a><span><u></u><u></u></span></p>
</td>
</tr>
</tbody>
</table>
<p class="MsoNormal"><u></u> <u></u></p>
</div>
This e-mail and any files transmitted with it are intended solely for the use of the individual or entity to whom they are addressed. It may contain unclassified but sensitive or protectively marked material and should be handled accordingly. Unless you are
the named addressee (or authorised to receive it for the addressee) you may not copy or use it, or disclose it to anyone else. If you have received this transmission in error please notify the sender immediately. All traffic may be subject to recording and/or
monitoring in accordance with relevant legislation. Any views expressed in this message are those of the individual sender, except where the sender specifies and with authority, states them to be the views of Dorset Council. Dorset Council does not accept
service of documents by fax or other electronic means. Virus checking: Whilst all reasonable steps have been taken to ensure that this electronic communication and its attachments whether encoded, encrypted or otherwise supplied are free from computer viruses,
Dorset Council accepts no liability in respect of any loss, cost, damage or expense suffered as a result of accessing this message or any of its attachments. For information on how Dorset Council processes your information, please see <a href="http://www.dorsetcouncil.gov.uk/416433" target="_blank">www.dorsetcouncil.gov.uk/416433</a>
</div>
_______________________________________________<br>
QGIS-Developer mailing list<br>
<a href="mailto:QGIS-Developer@lists.osgeo.org" target="_blank">QGIS-Developer@lists.osgeo.org</a><br>
List info: <a href="https://lists.osgeo.org/mailman/listinfo/qgis-developer" rel="noreferrer" target="_blank">https://lists.osgeo.org/mailman/listinfo/qgis-developer</a><br>
Unsubscribe: <a href="https://lists.osgeo.org/mailman/listinfo/qgis-developer" rel="noreferrer" target="_blank">https://lists.osgeo.org/mailman/listinfo/qgis-developer</a></blockquote></div><br clear="all"><br>-- <br><div dir="ltr" class="gmail_signature"><div dir="ltr"><div><div dir="ltr"><div style="text-align:center">------------------------------------------------------------------------------------------</div><div style="text-align:center"><div style="color:rgb(0,0,0);font-family:arial,helvetica,sans-serif;font-size:small;display:inline"></div><img src="https://mail.google.com/mail/u/0/?ui=2&ik=7ebbf93252&view=fimg&th=15a9e43c0bbf93ca&attid=0.1&disp=emb&realattid=9436e64174762963_0.1.1&attbid=ANGjdJ-WL_J24nvBiYidJ0V0xpdsYqRwswi5nq5oywcJEHC7twYVMrxG0y-GNPu_ahJthV8ktXwYuHoVm5DI2FrRAtPzelTRHrsE2wweR9uu8wT-zz2hNRqFwi4SorQ&sz=s0-l75-ft&ats=1488721675176&rm=15a9e43c0bbf93ca&atsh=1" style="color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px;"><br></div><div style="text-align:center">Tim Sutton</div><div style="text-align:center"><span style="text-align:start">Visit </span><a href="http://kartoza.com/" style="text-align:start" target="_blank">http://kartoza.com</a><span style="text-align:start"> to find out about open source:</span><br style="text-align:start"><span style="text-align:start"> * Desktop GIS programming services</span><br style="text-align:start"><span style="text-align:start"> * Geospatial web development</span></div><div style="text-align:center"><span style="text-align:start">* GIS Training</span></div><div style="text-align:center"><span style="text-align:start">* Consulting Services</span></div><div style="text-align:center"><div style="text-align:center">Skype: timlinux Irc: timlinux on #qgis at <a href="http://freenode.net/" target="_blank">freenode.net</a></div><div style="text-align:start"><div style="text-align:center">Tim is a member of the QGIS Project Steering Committee</div><div style="text-align:center">-------------------------------------------------------------------------------------------</div><div style="text-align:center">Kartoza is a merger between Linfiniti and Afrispatial</div></div></div></div></div></div></div>