469,356 Members | 2,196 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 469,356 developers. It's quick & easy.

temporarily draw freehand on a page using javascript

Hi,

I'm developing an application that is going to be used in schools as
a teaching aid and require the ability to temporarily draw on my (as
in pages produced by my application) web page using javascript (such
as a teacher drawing a circle around part of the text or image on the
page to point it out to the students).

I'm not sure how i would do this but think it may have something to do
with the <canvashtml element?

Does anybody have any ideas?

Thanks.
Nov 12 '08 #1
28 2100
What about generating an object which has onClick function to switch
itself to black (using css) and generating a lot of this object so
that it covers the entire HTML page? (Kind of like the idea of pixels)

I doubt this will be effecient though.
Nov 13 '08 #2
Hmmm, there must be a better way, but thanks for the suggestion...
Nov 13 '08 #3
macca wrote:
I'm developing an application that is going to be used in schools as
a teaching aid and require the ability to temporarily draw on my (as
in pages produced by my application) web page using javascript (such
as a teacher drawing a circle around part of the text or image on the
page to point it out to the students).

I'm not sure how i would do this but think it may have something to do
with the <canvashtml element?

Does anybody have any ideas?
"I have no clue what I'm doing, and I'm too lazy or too stupid to find me
one. Right?"

<http://catb.org/~esr/faqs/smart-questions.html>
PointedEars
--
Prototype.js was written by people who don't know javascript for people
who don't know javascript. People who don't know javascript are not
the best source of advice on designing systems that use javascript.
-- Richard Cornford, cljs, <f8*******************@news.demon.co.uk>
Nov 13 '08 #4
Erm okay.

If you dont have anything useful or constructive bring to the thread,
why bother saying anything at all?

Stupid Troll.
Nov 13 '08 #5
macca wrote:
If you dont have anything useful or constructive bring to the thread,
why bother saying anything at all?
There was something constructive and useful in it, like "please search
before you post" or "please ask intelligible and intelligent questions
here". But you appear to be too stupid to recognize that. Expected
googlodyte behavior confirmed again.
Stupid Troll.
Said the luser.
Score adjusted

PointedEars
--
Anyone who slaps a 'this page is best viewed with Browser X' label on
a Web page appears to be yearning for the bad old days, before the Web,
when you had very little chance of reading a document written on another
computer, another word processor, or another network. -- Tim Berners-Lee
Nov 13 '08 #6
rf

"disappearedng" <di***********@gmail.comwrote in message
news:d7**********************************@v13g2000 pro.googlegroups.com...
What about generating an object which has onClick function to switch
itself to black (using css) and generating a lot of this object so
that it covers the entire HTML page? (Kind of like the idea of pixels)

I doubt this will be effecient though.
Would you care to quote a bit of the message you are replying to? I didn't
get the original message so I have no bloody idea what you are talking
about.
Nov 14 '08 #7
rf

"macca" <pt*******@googlemail.comwrote in message
news:49**********************************@k36g2000 pri.googlegroups.com...
Hmmm, there must be a better way, but thanks for the suggestion...
You too!
Nov 14 '08 #8
rf

"macca" <pt*******@googlemail.comwrote in message
news:7b**********************************@b31g2000 prb.googlegroups.com...
Hi,

I'm developing an application that is going to be used in schools as
a teaching aid and require the ability to temporarily draw on my (as
in pages produced by my application) web page using javascript (such
as a teacher drawing a circle around part of the text or image on the
page to point it out to the students).

I'm not sure how i would do this but think it may have something to do
with the <canvashtml element?

Does anybody have any ideas?
Ah, your original post just hit my server. My prior comments still stand
though.
As to your question: The canvas element and: google.
Nov 14 '08 #9
On Nov 12, 8:20*pm, macca <ptmcna...@googlemail.comwrote:
Hi,

*I'm developing an application that is going to be used in schools as
a teaching aid and require the ability to temporarily draw on my (as
in pages produced by my application) web page using javascript (such
as a teacher drawing a circle around part of the text or image on the
page to point it out to the students).

I'm not sure how i would do this but think it may have something to do
with the <canvashtml element?

Does anybody have any ideas?

Thanks.
Yes, use the "canvas", but note that there's no "canvas" in IEs. See
this thread, it's about ~the same question, and contains a working
example:
http://groups.google.com/group/comp....7f66b3b41cd9d8
HTH,
--
Jorge
"Silly things such as logic, common sense, rational thoughts or good
manners are not allowed in this forum."
Nov 14 '08 #10
Thanks for the link to that thread Jorge. I've managed to modify one
of the examples and get it to work in ff on top of text by adding the
text in a div and giving the div a negative z-index, but as previously
stated it does not work inn IE. Grrr!

I've even added the excanvas.js script in my header etc to try and get
it working in IE but no cigar. I don't proclaim to be a js guru so
would appreciate any useful help.
Nov 14 '08 #11
In comp.lang.javascript message <96fbdc45-be96-413f-8051-edb4ca5bed81@u1
8g2000pro.googlegroups.com>, Thu, 13 Nov 2008 12:58:30, macca
<pt*******@googlemail.composted:
>Erm okay.

If you dont have anything useful or constructive bring to the thread,
why bother saying anything at all?

Stupid Troll.
Since you are developing material for use in schools, you need a better
understanding of the psychologically abnormal than you have so far
demonstrated. Thomas Lahn serves to remind us of what so many famous
Germans of the past have been like.

--
(c) John Stockton, nr London, UK. ?@merlyn.demon.co.uk Turnpike v6.05 IE 7.
Web <URL:http://www.merlyn.demon.co.uk/- FAQish topics, acronyms, & links.
I find MiniTrue useful for viewing/searching/altering files, at a DOS prompt;
free, DOS/Win/UNIX, <URL:http://www.idiotsdelight.net/minitrue/unsupported.
Nov 14 '08 #12
On Nov 14, 3:39*pm, macca <ptmcna...@googlemail.comwrote:
Thanks for the link to that thread Jorge. I've managed to modify one
of the examples and get it to work in ff on top of text by adding the
text in a div and giving the div a negative z-index, but as previously
stated it does not work inn IE. Grrr!

I've even added the excanvas.js script in my header etc to try and get
it working in IE but no cigar. I don't proclaim to be a js guru so
would appreciate any useful help.
I don't think anybody but M$ can help you with this. And not even
them, as 50% of the world is still using IEs 6s and 7s. Nothing will
change when IE8 finally comes out (wow, they must have been working so
hard at redmond, 3rd M$ browser in ~8 years !). It's just that M$
feels that the web might hurt their (so lucrative) OS/Windows API lock
business, so they are doing and have been doing and will keep doing as
much as possible to impede the web evolution as much as possible.

That has created a business opportunity, and macromedia, now adobe,
has seen it and happily provides you their propietary solution: flash.

I, for one, would develop it using the canvas tag, and happily splash
a beautiful "Sorry, but your browser is so way outdated and full of
bugs that we don't support it anymore." in the face of IE users...
"Any (other) modern standards-compliant browser will do: try with
Safari, FireFox or Opera".

--
Jorge.
Nov 14 '08 #13
On Nov 14, 8:45*pm, Jorge <jo...@jorgechamorro.comwrote:
>
"Any (other) modern standards-compliant browser will do: try with
Safari, FireFox or Opera".
....or Chrome, of course.

--
Jorge.
Nov 14 '08 #14
On 2008-11-14 14:32, Dr J R Stockton wrote:
Thomas Lahn serves to remind us of what so many famous Germans of the
past have been like.
That comment was completely uncalled for and in incredibly bad taste.
- Conrad
Nov 14 '08 #15
Dr J R Stockton meinte:
Since you are developing material for use in schools, you need a better
understanding of the psychologically abnormal than you have so far
demonstrated. Thomas Lahn serves to remind us of what so many famous
Germans of the past have been like.
Ah, the famous British humour, Sun style.

Gregor

But anyway, since he's developing material for use in schools, he should
have an idea how to formulate meaningful questions.
Nov 14 '08 #16
But anyway, since he's developing material for use in schools, he should
have an idea how to formulate meaningful questions.
Are you trying to say that my question is not meaningful? If so, maybe
you should go back to school yourself.

What's the matter with some of you people? If you can't say something
H E L P F U L ...go away!

Nov 14 '08 #17
macca wrote on 14 nov 2008 in comp.lang.javascript:
>
>But anyway, since he's developing material for use in schools, he should
have an idea how to formulate meaningful questions.

Are you trying to say that my question is not meaningful? If so, maybe
you should go back to school yourself.

What's the matter with some of you people? If you can't say something
H E L P F U L ...go away!
Hey, this is usenet, not a helpdesk.

And please quote properly by not stripping the name od the one you are
quoting.

--
Evertjan.
The Netherlands.
(Please change the x'es to dots in my emailaddress)
Nov 14 '08 #18
macca meinte:
Are you trying to say that my question is not meaningful?
Indeed. And I'm gonna prove that.
If so, maybe you should go back to school yourself.
I do that frequently.

But let's see:

"I'm not sure how i would do this but think it may have something to do
with the <canvashtml element?"

That's no question, despite the question mark. Really.
Anyway, even if we're so kind to reformulate it into
"Has this something to do with the 'canvas' element?" more than
satisfactory responses would be (Macca are you listening!?):

"It depends."
"Could be."
"Perhaps."

HTH, Gregor
What's the matter with some of you people? If you can't say something
H E L P F U L ...go away!
You could sod off just as well. In fact *you* are the first-timer.
Nov 14 '08 #19
On Nov 14, 11:15*pm, Conrad Lender <crlen...@yahoo.comwrote:
On 2008-11-14 14:32, Dr J R Stockton wrote:
Thomas Lahn serves to remind us of what so many famous Germans of the
past have been like.

That comment was completely uncalled for and in incredibly bad taste.
That's been completely uncalled for and in incredibly bad manners as
well:

"I have no clue what I'm doing, and I'm too lazy or too stupid to find
me
one. Right?"

Why don't you say so in the first place ?

--
Jorge.
Nov 15 '08 #20
On Nov 14, 11:27*pm, Gregor Kofler <use...@gregorkofler.atwrote:
>
But anyway, since he's developing material for use in schools, he should
have an idea how to formulate meaningful questions.
Me thinks it's really you who's got a problem if you didn't get it...

Anyway, if you don't know, don't mind, don't like the wording, or
don't understand the question, just stay away from the thread and
we'll all be happy then. Because this isn't no one's private garden,
did you know ?

--
Jorge.
Nov 15 '08 #21
Jorge meinte:
On Nov 14, 11:27 pm, Gregor Kofler <use...@gregorkofler.atwrote:
>But anyway, since he's developing material for use in schools, he should
have an idea how to formulate meaningful questions.

Me thinks it's really you who's got a problem if you didn't get it...
Whatever...
Anyway, if you don't know, don't mind, don't like the wording, or
don't understand the question, just stay away from the thread and
we'll all be happy then. Because this isn't no one's private garden,
did you know ?
It's not your newsgroup either. Didn't you know?

For the more perceptive: I was replying to Doc Stockton's answer (which
in turn yielded nothing for the OP).

Gregor
Nov 15 '08 #22
On Nov 15, 12:43*pm, Gregor Kofler <use...@gregorkofler.atwrote:
>
For the more perceptive: I was replying to Doc Stockton's answer (which
in turn yielded nothing for the OP).
Nor Thomas' nor Conrad's nor yours nor Evertjan's.

--
Jorge.
Nov 15 '08 #23
Jorge wrote on 15 nov 2008 in comp.lang.javascript:
On Nov 15, 12:43’pm, Gregor Kofler <use...@gregorkofler.atwrote:
>>
For the more perceptive: I was replying to Doc Stockton's answer (which
in turn yielded nothing for the OP).

Nor Thomas' nor Conrad's nor yours nor Evertjan's.
Which is no matter, as

1 usenet is NOT a helpdesk.

2 yield is a subjective measure.

--
Evertjan.
The Netherlands.
(Please change the x'es to dots in my emailaddress)
Nov 15 '08 #24
On 2008-11-15 09:53, Jorge wrote:
On Nov 14, 11:15 pm, Conrad Lender <crlen...@yahoo.comwrote:
>On 2008-11-14 14:32, Dr J R Stockton wrote:
Thomas Lahn serves to remind us of what so many famous Germans of the
past have been like.

That comment was completely uncalled for and in incredibly bad taste.

That's been completely uncalled for and in incredibly bad manners as
well:

"I have no clue what I'm doing, and I'm too lazy or too stupid to find
me
one. Right?"
I'm certainly not defending Thomas's fondness for harsh replies, but
that doesn't give Dr Stockton the right to associate him with a regime
that ended when his parents likely weren't even born. Stereotypical
remarks like that are far more insulting than being called "lazy or
stupid", and an educated person should know better than to resort to
knee-jerk generalizations like that. I hope that makes my reaction
clearer to you.

Anyway, Stockton's remark has Godwinned the thread, and there's no point
in further discussion. The OP's attitude doesn't exactly motivate me to
help him either, even though there are numerous examples for what he's
trying to do.
Why don't you say so in the first place ?
Say what?
- Conrad
Nov 15 '08 #25
Conrad Lender wrote:
On 2008-11-14 14:32, Dr J R Stockton wrote:
>Thomas Lahn serves to remind us of what so many famous Germans of the
past have been like.

That comment was completely uncalled for and in incredibly bad taste.
Yeah, comparing Thomas to Daniel Gottlob Moritz Schreber is really
beyond the pale.

--
Michael Wojcik
Micro Focus
Rhetoric & Writing, Michigan State University
Nov 16 '08 #26
In comp.lang.javascript message <4dudnYyeqJEEZYDUnZ2dnUVZ_rydnZ2d@supern
ews.com>, Fri, 14 Nov 2008 23:15:52, Conrad Lender <cr******@yahoo.com>
posted:
>On 2008-11-14 14:32, Dr J R Stockton wrote:
>Thomas Lahn serves to remind us of what so many famous Germans of the
past have been like.

That comment was completely uncalled for and in incredibly bad taste.
You seem to be unaware of all the famous German writers, technicians and
mathematicians of the past - enlighten yourself by reference to
<http://en.wikipedia.org/wiki/List_of_germans>. Examples include Benz,
Bessel, Bethe, Born, von Braun, Bunsen, Cantor, Copernicus, Diesel,
Heisenberg, Lilienthal, Nernst, Noether, Ohm, Planck, Rienmann,
Roentgen, Weyl, Zuse ; and by inclination an honorary place goes to
Albert of Saxe-Coburg-Gotha, ancestor of the famous chopper of Dutch
wood. And Bruch Pachelbel, Handel, Mendelssohn, Offenbach, a plethora
of other Bachs, Beethoven, (I omit Stockhausen), Wagner, ...

Granted, Lahn is undoubtedly their intellectual inferior; but you must
have judged his nature to be more reminiscent of the minority of an
altogether different sort.

--
(c) John Stockton, nr London, UK. ??*@merlyn.demon.co.uk Turnpike v6.05 MIME.
Web <URL:http://www.merlyn.demon.co.uk/- FAQish topics, acronyms, & links.

Food expiry ambiguities: <URL:http://www.merlyn.demon.co.uk/date2k-3.htm#Food>
Nov 16 '08 #27
On 2008-11-16 17:37, Dr J R Stockton wrote:
In comp.lang.javascript message <4dudnYyeqJEEZYDUnZ2dnUVZ_rydnZ2d@supern
ews.com>, Fri, 14 Nov 2008 23:15:52, Conrad Lender <cr******@yahoo.com>
posted:
>>On 2008-11-14 14:32, Dr J R Stockton wrote:
>>Thomas Lahn serves to remind us of what so many famous Germans of the
past have been like.

That comment was completely uncalled for and in incredibly bad taste.

You seem to be unaware of all the famous German writers [snipping list
of random names copied from Wikipedia]
So you were only comparing Thomas Lahn to Beethoven and Zuse, and
actually making him a compliment? Please excuse me if I find this hard
to believe - your remark wouldn't make any sense at all in that context
(you did call him "psychologically abnormal" in the same paragraph).

On the other hand, "weaseling out of things [we wrote] is important to
learn. It's what separates us from the animals. ...except the weasel."
- Conrad
Nov 17 '08 #28
Conrad Lender wrote:
On 2008-11-16 17:37, Dr J R Stockton wrote:
>Conrad Lender posted:
>>On 2008-11-14 14:32, Dr J R Stockton wrote:
Thomas Lahn serves to remind us of what so many famous Germans of the
past have been like.
That comment was completely uncalled for and in incredibly bad taste.
You seem to be unaware of all the famous German writers [snipping list
of random names copied from Wikipedia]

So you were only comparing Thomas Lahn to Beethoven and Zuse, and
actually making him a compliment? Please excuse me if I find this hard
to believe [...]
Although I'm glad and thankful to see some common sense here:
Never argue with an idiot ... or, IOW, do not feed the troll.
HTH

PointedEars
--
realism: HTML 4.01 Strict
evangelism: XHTML 1.0 Strict
madness: XHTML 1.1 as application/xhtml+xml
-- Bjoern Hoehrmann
Nov 17 '08 #29

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

11 posts views Thread by Eric Osman | last post: by
4 posts views Thread by ianv2 | last post: by
2 posts views Thread by simon.wilkinson | last post: by
7 posts views Thread by vunet.us | last post: by
1 post views Thread by CARIGAR | last post: by
reply views Thread by zhoujie | last post: by
1 post views Thread by Marylou17 | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.