Eraser and "Pick color"

53 views
Skip to first unread message

Leo Barichello

unread,
Dec 2, 2011, 3:12:51 PM12/2/11
to kdeedu-...@googlegroups.com
Hi,

Another two commands I like to know if they already exist and, in case of they dont, suggest to implement:

- eraser: the turtle starts to use a eraser while deslocate in the screen erasing to the background color everything under it. It is possible to do it changing the color of the pencil, but sometimes it is also necessary to make the pencil larger to make sure everything is gone.

- pickcolor: return the color of the pixel right under the turtle. It is very useful to make pixels work like variables and the screen like array or even matrices.

Regards,
Leo

--
Sócio-diretor da Mais educacional - www.mais.mat.br
Professor do Colégio Villa Lobos e PUC-Campinas


Niels Slot

unread,
Dec 2, 2011, 3:28:11 PM12/2/11
to kdeedu-...@googlegroups.com
Hi Leo,

Both commands currently don't exist and I'm afraid there gonna be hard to implement.

KTurtle makes use of Qt's GraphicsView framework. For KTurtle is means that we can do things like zooming and export to SVG. It also means that we don't have a raster of pixels, but a collections of lines (with a length, width and location) and let Qt render them. With the canvas implemented as is, I know of no way to implement the function you propose.

I've been thinking lately that we could move it back to a pixel based canvas like KTurtle had in KDE 3, but that would almost certainly mean losing some features. On the other hand, working with pixels is really what logo was all about.

In conclusion it's not trivial, maybe some day. Thanks for the feedback though and you're of course always welcome to try to implement it yourself. (If you can live with the loss of features it might not even be that hard.)

Regards,

Niels

2011/12/2 Leo Barichello <baric...@gmail.com>
--
You received this message because you are subscribed to the Google Groups "KTurtle; an educational programming environment" group.
To post to this group, send email to kdeedu-...@googlegroups.com.
To unsubscribe from this group, send email to kdeedu-kturtl...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/kdeedu-kturtle?hl=en.

Leo Barichello

unread,
Dec 3, 2011, 10:11:11 AM12/3/11
to kdeedu-...@googlegroups.com
Hi Niels,

I see your point and you are right.
I have no experience in QT, but i am taking a look at Qt's GraphicsView framework trying to find out a way of implement those stuff.

In fact, i am considering to create a small workgroup in the university i work (PUC) to develop stuff for kturtle in the computational sense and also in the educational.

Thank you for all the attention,
Leo

2011/12/2 Niels Slot <niel...@gmail.com>
Reply all
Reply to author
Forward
0 new messages