-
May 1st, 2011, 02:02 PM
#1
See whether mouse is on a link -- web browser
Hey, I am creating a web browser which is a bit like chrome/ ie in the sense that I want the context menu strip to change once a link is hovered upon.
So when you right click on a link it displays a different context menu to the one before if no link has the mouse hovered on them.
Thanks in advance!
Basically when a link is hovered upon I would like to see if it is a link and if it is then to change the web browser's context menu
-
May 2nd, 2011, 10:43 PM
#2
Re: See whether mouse is on a link -- web browser
Well question one: why are you doing this? If it's a student project, to learn or for fun, then that's fine. If it's for something real that you plan to use, I'd go with a ready-made solution. (Either just using a web browser -- there are lots of small ones if you don't like FF/IE/Opera/Chrome/Safari or use a code library for C#).
Anyway, I'm not sure. Presumably you could figure out the coordinates on the screen of the rectangle (or rectangles if it splits across lines) that enclose the link. Then you could use the MouseMove or MouseHover events of the control to check if the mouse if in one of the link-rectangles and display the appropriate message on the status strip.
I suspect that solution would be non-trivial, but not impossible.
Anyone else have a better solution?
Best Regards,
BioPhysEngr
http://blog.biophysengr.net
--
All advice is offered in good faith only. You are ultimately responsible for effects of your programs and the integrity of the machines they run on.
-
May 3rd, 2011, 11:30 AM
#3
Re: See whether mouse is on a link -- web browser
As a way of learning for my computer program GCSE -- a bit like revision
-
May 3rd, 2011, 11:26 PM
#4
Re: See whether mouse is on a link -- web browser
Fair enough; there is never anything wrong with programming to learn!
Good luck with your exams!
Best Regards,
BioPhysEngr
http://blog.biophysengr.net
--
All advice is offered in good faith only. You are ultimately responsible for effects of your programs and the integrity of the machines they run on.
-
May 9th, 2011, 11:44 AM
#5
Re: See whether mouse is on a link -- web browser
Thanks
-
May 9th, 2011, 11:44 AM
#6
Re: See whether mouse is on a link -- web browser
I have got the answer, by using csEXWB -- a .Net wrapper
Tags for this Thread
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|