<div dir="ltr"><div dir="ltr">Nyall,<div><br></div><div>As usual thank you so much for your answers. I have one further question with this. You said I need to set SqgMapSettings with the map scale and extent. I probably want the map scale and extent from the canvas, but in a processing algorithm I don't know how to get that information.</div><div><br></div><div>Thanks,</div><div><br></div><div>Calvin</div><div><br></div></div><div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">As far as creating a render context goes -- the easiest way is via<br>
QgsRenderContext.fromMapSettings(). You create a QgsMapSettings<br>
object, set it all up with the desired map scale and extent, etc, and<br>
then convert it to a render context. This ensures that regardless of<br>
the size units used by the symbol (e.g. if it's in map units) it will<br>
be correctly sized...<br>
<br>
Nyall<br>
</blockquote></div></div>