Agregar boton borrar a HTML creado con Canvas y Konva
$10-30 USD
已取消
已发布将近 6 年前
$10-30 USD
货到付款
I have a javascript and an html that together make it possible to draw on a canvas. In its initial version it was necessary to add a button that would allow to erase the colors that are used in the drawing. I need to add that functionality. Agrego un framento del codigo para que tengan la dimension tecnica del ajuste
var defaults ={
"cs" : 1,
"ck" : 5,
"ct" : "pencil",
"element" : "tools",
"circle" : [[50,50,5],[90,50,10],[140,50,15]],
"rect" : [[200,30,'yellow'],[320,30,'blue'],[440,30,'green'],[560,30,'red'],[680,30,'black']],
"paint" : [[950,30,'pencil','img/[login to view URL]'], [1020,30,'brush','img/[login to view URL]']]
};
[login to view URL] = new [login to view URL]({
container: [login to view URL],
width: $('#'+[login to view URL]).width(),
height: $('#'+[login to view URL]).height()
});
var result={
"option" : oPtion,
"delta" : 0,
"circle" : [],
"linePoints": [],
"linePointXY": [],
"planPoints": [],
"brushLayer": new [login to view URL](),
"backLayer" : new [login to view URL](),
"panelLayer": new [login to view URL](),
"lineLayer" : new [login to view URL](),
};
if([login to view URL] == "pencil" || [login to view URL] == "brush") {
//planPoints
var xy = [login to view URL]();
var pxy ={x:0, y:0, f:0}
for(var i=0; i<[login to view URL]; i++){
if(xy.x > [login to view URL][i][0]-5 && xy.x < [login to view URL][i][0]+5){
if(xy.y > [login to view URL][i][1]-5 && xy.y < [login to view URL][i][1]+5){
pxy.x = [login to view URL][i][0];
pxy.y = [login to view URL][i][1];
pxy.f = 1;
}
}
}
if([login to view URL] == "brush" && [login to view URL] == false && isInside([login to view URL], xy) == true) {
Hi,
I understood your requirement. I have 5 years experience in my skills and able to do your tasks for canvas. Feel free to contact me anytime for further discussion.
Thanks
It does not matter how much you pay after delivery work in the end
We will work on it now
We will offer you the same day
Quick implementation
Deal seriously
I am ready to work
Professional design
Very professional
designer Distinguish coordination
and speed of performance Responsive
design with all devices
It does not matter
I want you to send work
What explain what you want to do exactly
The work will be sent as soon
I am a professional web Designer.
Relevant Skills and Experience
I will create & design a professional and responsive good looking website for you in HTML, CSS Bootstrap, UI kit, JAVA script, JQUARY. I can design any kind of website outstanding. Thanks.