[Qgis-user] Use size of label background rectangle in python function

Fuenfer-Koenigstein.Benjamin2 at swm.de Fuenfer-Koenigstein.Benjamin2 at swm.de
Mon Aug 28 00:01:48 PDT 2017


Hi all,

in QGIS, there is the possibility to draw a rectangle around a label text with "Labels -> Background -> Shape: Rectangle; Size type: buffer". This way, the rectangle fits to text extend.

Does onyone know a way to use the size or the corner coordinates of this buffer rectangle in a python function? Would be very helpful to create leader lines from the object to the nearest corner of the rectangle.

Best regards

Benjamin 



More information about the Qgis-user mailing list