Well, the filling of a region of contiguous pixels from one point, as with the
paint bucket in MacPaint and its descendents (including Photoshop), is more of
a bitmapped concept than a vector graphics concept. One does not really have
access to pixels in SVG (though there are certainly times at which it would be
nice if we did!).
However, suppose we have a pre-existing vector map: a collection of basic
elements like paths and rects and so forth. Then, using JavaScript, one can
attach event handlers to all the elements of that vector map, let the cursor
turn into a paint bucket shaped icon, and allow the click of the mouse on any
particular element be translated into a command that colors that object with
the actively chosen color, gradient or pattern.
So if this is what you mean, then the answer would be with JavaScript as in:
VM = [ list of basic elements ]
for (var i in VM) VM.setAttributeNS(null, "onclick", "paintfill(evt)")
function paintfill(evt){
var O=evt.target
O.setAttributeNS(null, "fill", activeColor)
}
This answer rather presupposes that you're building some kind of drawing app,
of which several proofs of concept have already been demonstrated here and
there.
Hope this makes sense
David Dailey
----- Original Message -----
From: chandra reddy
To: [email protected]
Sent: Wednesday, December 17, 2008 3:47 AM
Subject: [svg-developers] Please can any one help me ,how to fill color at
particular point on image using svg
Hi All
Please can any one help me ,how to fill color at particular point on image
using svg
Advanced Thanks.
Regards
P.Chandra Shaker Reddy
[Non-text portions of this message have been removed]
[Non-text portions of this message have been removed]
------------------------------------
-----
To unsubscribe send a message to: [email protected]
-or-
visit http://groups.yahoo.com/group/svg-developers and click "edit my
membership"
----Yahoo! Groups Links
<*> To visit your group on the web, go to:
http://groups.yahoo.com/group/svg-developers/
<*> Your email settings:
Individual Email | Traditional
<*> To change settings online go to:
http://groups.yahoo.com/group/svg-developers/join
(Yahoo! ID required)
<*> To change settings via email:
mailto:[email protected]
mailto:[email protected]
<*> To unsubscribe from this group, send an email to:
[email protected]
<*> Your use of Yahoo! Groups is subject to:
http://docs.yahoo.com/info/terms/