[Qgis-developer] adding point/multipoint to the QgsRubberBand drawing capabilities?

G. Allegri giohappy at gmail.com
Wed Nov 14 04:12:13 PST 2012


Wow, great!
I alreay know the logics behind it. I have done many QgsMapCanvasItem
subclasses in my Python plugins to customize the marker graphics.
Having it incorporated in QgsRubberBand saves some boilerplate code ;)

giovanni



2012/11/14 Matthias Kuhn <matthias.kuhn at gmx.ch>

> On the other hand, there is already QgsVertexMarker, which offers
> similar possibilities.
>
> On Wed, 2012-11-14 at 13:01 +0100, Matthias Kuhn wrote:
> > Already done:
> >
> > https://github.com/matthias-kuhn/Quantum-GIS/tree/rubberband-point
> >
> > Please have a look at it.
> >
> > from qgis.gui import *
> > rb = QgsRubberBand( qgis.utils.iface.mapCanvas(), QGis.Point )
> > rb.setWidth( 5 )
> > [Add some points]
> >
> > On Wed, 2012-11-14 at 12:54 +0100, G. Allegri wrote:
> > > I'll try to implement it as soon as I find a slot of time.
> > > I don't guarantee it because my C++ programming skills are not so
> > > high...
> > >
> > >
> > > giovanni
> > >
> > > 2012/11/14 Matthias Kuhn <matthias.kuhn at gmx.ch>
> > >         On Mon, 2012-11-12 at 21:27 +0100, G. Allegri wrote:
> > >         > Let me clarify my request a bit more. I know QgsRubberBand
> > >         can manage
> > >         > points and paint them as square graphics.
> > >         > What I mean is painting circles (drawEllipse).
> > >
> > >         I think it's reasonable to introduce such a thing.
> > >         QgsRubberBand is used
> > >         for temporary highlighting / painting of features and I see no
> > >         reason
> > >         why this should not be allowed for points. I would also have
> > >         use for
> > >         that.
> > >
> > >         Matthias
> > >
> > >         > giovanni
> > >         >
> > >         > Sent from Nexus
> > >         >
> > >         > Il giorno 12/nov/2012 18:27, "G. Allegri"
> > >         <giohappy at gmail.com> ha
> > >         > scritto:
> > >         >         Bear with me if this is a trivial request.
> > >         >         QgsRubberBand only supports lines and polygons, why
> > >         don't we
> > >         >         extend it to support points/multipoints too?
> > >         >
> > >         >
> > >         >         giovanni
> > >         > _______________________________________________
> > >         > Qgis-developer mailing list
> > >         > Qgis-developer at lists.osgeo.org
> > >         > http://lists.osgeo.org/mailman/listinfo/qgis-developer
> > >
> > >
> > >
> > >
> >
> >
> > _______________________________________________
> > Qgis-developer mailing list
> > Qgis-developer at lists.osgeo.org
> > http://lists.osgeo.org/mailman/listinfo/qgis-developer
>
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/qgis-developer/attachments/20121114/6a4416da/attachment-0001.html>


More information about the Qgis-developer mailing list