[QGIS-Developer] QgsRubberband

Tim Sutton tim at kartoza.com
Sun Sep 23 13:38:19 PDT 2018


Hi Adam

I think the idiomatic way to do this would be to rather make (convert rubber bands to) a memory layer with some features that you need displayed for printing and then remove it again after the print is done (aka a redlining layer).

Regards

Tim

> On 23 Sep 2018, at 15:45, Adam Borczyk <adam.borczyk at gis-support.pl> wrote:
> 
> Hello everyone,
> I'm automating map printing in PyQGIS 3 and encountered an issue with QgsRubberband - the rubberband is not visible on map rendered from composer.
> 
> I guess there is a good reason to not to include it, but is there a way to do so anyway? I just need to mark a very temporary polygon on the map and place it on exported layout, so creating a memory layer for just one, small polygon seems to be an overkill for me.
> 
> Currently I load a QPT file into QgsLayout and have QgsLayoutItemMap item in there. Everything renders fine except for the rubberband. I'd appreciate any hints on that.
> 
> Best regards
> Adam Borczyk
> _______________________________________________
> QGIS-Developer mailing list
> QGIS-Developer at lists.osgeo.org
> List info: https://lists.osgeo.org/mailman/listinfo/qgis-developer
> Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-developer

—








Tim Sutton

Co-founder: Kartoza
Ex Project chair: QGIS.org

Visit http://kartoza.com <http://kartoza.com/> to find out about open source:

Desktop GIS programming services
Geospatial web development
GIS Training
Consulting Services

Skype: timlinux
IRC: timlinux on #qgis at freenode.net

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/qgis-developer/attachments/20180923/5a4222e2/attachment-0001.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: KartozaNewLogoThumbnail.jpg
Type: image/jpeg
Size: 6122 bytes
Desc: not available
URL: <http://lists.osgeo.org/pipermail/qgis-developer/attachments/20180923/5a4222e2/attachment-0001.jpg>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 488 bytes
Desc: Message signed with OpenPGP
URL: <http://lists.osgeo.org/pipermail/qgis-developer/attachments/20180923/5a4222e2/attachment-0001.sig>


More information about the QGIS-Developer mailing list