Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8922071
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 15, 20262026-06-15T06:44:20+00:00 2026-06-15T06:44:20+00:00

Need a jquery plugin or any other which will help me draw signature of

  • 0

Signature

Need a jquery plugin or any other which will help me draw signature of similar types. Could anyone tel me where can i find such plugin?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-15T06:44:23+00:00Added an answer on June 15, 2026 at 6:44 am

    A more smooth and natural ‘curvy’ line can be achieved using context.quadraticCurveTo()MDN

    enter image description here

    Just, the quadraticCurveTo can only have a constant thickness so, by using the below you cannot easily alter the line to make shades pen-angles and pressure effects.

    var board = {
      width: 560,
      height: 190
    };
    var pen = {
      color: "rgb(0, 0, 0)",
      size: 2
    };
    var pts = [];
    var isDown = false;
    var isTouch = false;
    var cvs = document.getElementById('canvas');
    var ctx = cvs.getContext('2d');
    var cvs2 = document.createElement('canvas');
    var ctx2 = cvs2.getContext('2d');
    
    cvs.width = cvs2.width = board.width;
    cvs.height = cvs2.height = board.height;
    
    function penDown(ev) {
      ev.preventDefault();
      isTouch = ev.type === "touchstart";
      ev = isTouch ? ev.touches[0] : ev;
      isDown = true;
      pts.push({
        x: ev.clientX,
        y: ev.clientY
      });
      drawPoints();
    }
    
    function penMove(ev) {
      ev.preventDefault();
      ev = isTouch ? ev.touches[0] : ev;
      if (isDown) {
        ctx.clearRect(0, 0, board.width, board.height);
        ctx.drawImage(cvs2, 0, 0); // Draw to inmemory cvs2
        pts.push({
          x: ev.clientX,
          y: ev.clientY
        });
        drawPoints();
      }
    }
    
    function penUp(ev) {
      ev.preventDefault();
      isDown = isTouch = false;
      pts = [];
      // Save state to in-memory cvs2
      ctx2.clearRect(0, 0, board.width, board.height);
      ctx2.drawImage(cvs, 0, 0);
    }
    
    function clear() {
      ctx.clearRect(0, 0, board.width, board.height);
      ctx2.clearRect(0, 0, board.width, board.height);
    }
    
    function drawPoints() {
      var i = 0;
      var i2 = pts.length > 1 ? 1 : 0;
      ctx.beginPath();
      ctx.lineWidth = pen.size;
      ctx.lineJoin = 'round';
      ctx.lineCap = 'round';
      ctx.moveTo(pts[0].x, pts[0].y);
      for (; i < pts.length - i2; i++) {
        ctx.quadraticCurveTo(
          pts[i].x,
          pts[i].y,
          (pts[i].x + pts[i + i2].x) / 2,
          (pts[i].y + pts[i + i2].y) / 2
        );
      }
      ctx.strokeStyle = pen.color;
      ctx.stroke();
      ctx.closePath();
    }
    
    // EVENTS
    
    cvs.addEventListener('touchstart', penDown);
    cvs.addEventListener('touchmove', penMove);
    cvs.addEventListener('touchend', penUp);
    cvs.addEventListener('mousedown', penDown);
    cvs.addEventListener('mousemove', penMove);
    cvs.addEventListener('mouseup', penUp);
    document.getElementById("clear").addEventListener("click", clear);
    body {margin:0;}
    #canvas{display: block; box-shadow: inset 0 0 0 2px #ccc;}
    #clear {position: absolute; top:0; left: 0;}
    <canvas id='canvas'></canvas>
    <button id="clear">CLEAR</button>
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I found this jquery plugin which does exactly what I need, but I want
I'm looking for some jQuery plugin or smth similar. For example, I need to
Im new to jquery/javascript and need help! I want to use the cycle plugin
I am trying to write a jQuery plugin that will have similar functionality to
I need to raise a couple of events with parameters within a jquery plugin,
So I'm writing a jQuery plugin to apply retina graphics. I need to select
I'm looking for a jquery plugin to simulate a vertical marquee. I need it
I use edit-in-place plugin: http://arashkarimzadeh.com/jquery/7-editable-jquery-plugin.html I't works Great! I just need something to check
i need to know if exist a jquery's plugin to limit the number of
I use a jquery validation plugin and I need to add some extra checking,

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.