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 9006425
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 16, 20262026-06-16T01:24:29+00:00 2026-06-16T01:24:29+00:00

I found this in a stackoverflow question on how to draw in canvas http://jsfiddle.net/ArtBIT/kneDX/

  • 0

I found this in a stackoverflow question on how to draw in canvas http://jsfiddle.net/ArtBIT/kneDX/ and now I want the canvas to cover my whole html page. For example:

<body>
  <div id="2">
    //code
  </div>
  <div id="2">
    //code
  </div>
</body>

So the canvas will be attached to the page and the user could draw over the content of the page. So is there any way to create the canvas inorder to take the 100% of the body be hidden apart from the drawing lines?

Edited:

How can I draw lines continuously without making circles in the above code? Also is there any way to draw something over the text without selecting it when you pass the mouse over it?

  • 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-16T01:24:31+00:00Added an answer on June 16, 2026 at 1:24 am

    First, make the height and width properties of the canvas equal to the page height and page width. (Getting those values is quite difficult, so see the linked questions for the best way to do it — or just use jQuery.)

    Next, add some CSS to make the canvas sit in the absolute top-left corner of the page:

    #canvas {
        position: absolute;
        top: 0;
        left: 0;
    }
    

    Then, don’t change the background color of the canvas as you currently do by calling ctx.clearTo. Canvases are transparent by default, so you’ll be able to see the page underneath of it, as long as you don’t change the background color.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I found this on another stack question: //http://stackoverflow.com/questions/3418231/c-replace-part-of-a-string-with-another-string // void replaceAll(std::string& str, const std::string&
I've found this question on StackOverflow Adding div below images in colorbox But it
I found this answer to this question https://stackoverflow.com/a/7244888/1473523 , but in my situation am
I have this code (found from another StackOverflow question: $(document).ready(function() { $.ajax({ url: soundfile.mp3,
I've found this question many times on Google and on StackOverflow, though none answer
I found this question https://stackoverflow.com/questions/4612563/get-push-notification-from-twitter-on-status-updates , but there was no answer. I'm looking to
Please note: This question is very similar to this one I found on stackoverflow.
I found (after another question here on StackOverflow) this interesting library written in Python
Searching StackOverflow, I found this question on how to Retrieve SMTP settings from Web.Config
I use this piece of code (found on stackoverflow) to generate an OrderBy static

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.