473,626 Members | 3,343 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

How to find an image based upon an x-y screen coordinate

1 New Member
I am working on an iPhone application which uses a version of safari (UIWebView) to display web pages. I want to be able to capture images shown on the webview. To do so, I can capture a "touch event" which will give me an x-y coordinate. To find the correct image, I need to be able to scan all the image tags in the web page and determine which image tag encompasses the point captured from the iphone touch event.

It turns out that the ability to execute a java script against the html page is provided in the UIWebView, so if a javascript procedure can either find the image based upon an inputed point or return a list of the images with x-y point locations and their height and widths, I should be able to do what I want.

Your help is much appreciated.

Jim
Mar 22 '10 #1
1 2663
gits
5,390 Recognized Expert Moderator Expert
never developed something for the iPhone but i think your approach seems a bit weired ... just bind the events to the page's elements itself ... probably this link helps ...

kind regards
Mar 25 '10 #2

Sign in to post your reply or Sign up for a free account.

Similar topics

15
7044
by: Tony Gahlinger | last post by:
I'm using my browser (Mozilla/5.0 Linux i686 Gecko/20031007 Firebird/0.7) to do some client-side image processing. I want to capture the sequence of coordinates a user clicks on in xxx.jpg in the following html <a href="#"><IMG SRC="xxx.jpg" ISMAP></a> and save these to a file for later handling. The coordinates appear on the bottom left of the window as I move the mouse, so I know they're being passed around somehow, but I haven't...
2
9157
by: Kevin Lyons | last post by:
Hello, Can anyone assist me with what I am trying to do with the following code (six different scenarios to try to make the functionality work correctly)? I want to always (and ONLY) display in the status bar 'Symantec Corporation' whenever anyone mouses over (onMouseOver) my image or link OR when one clicks while holding the left mouse down (onClick) on the same image or link. Upon releasing the mouse (onMouseOut), the
14
11069
by: D. Alvarado | last post by:
Hello, I am trying to open a window containing an image and I would like the image to be flush against the window -- i.e. have no padding or border. Can I make this happen with a single call to a window.open function? I would prefer not to create a separate HTML page. So far all I have is the basic var cwin = window.open('images/KJV-THANKS.gif', 'Thanks', 'width=243,height=420,'); cwin.focus();
2
2449
by: mike_newsgroups | last post by:
hello, I want to be able to create an image from asp where I: 1) paste in an image at a given coordinate 2) draw a line from one coordinate to another 3) write text at a given coordinate Any ideas what I could use to do this?
2
1921
by: SirPoonga | last post by:
What would you suggest I do for the following problem. I want to make an application (vb.net or c#) that has a picture of a dartboard and you can click on certain cells of the dartboard. I am wondering what the best way to determine where on a dartboard the user clicked. An image map or custom buttons for each cell. if image map how would I map out the cells?
3
12879
by: Chris | last post by:
Hi, I need to get an image of a control (ListView) so i can save it to a file. It's pretty easy to get the Graphics with the CreateGraphics() function on every control, but I don't know how I might save the Graphics object as an image. Has anyone done this? Chris
30
1938
by: Elhanan | last post by:
hi all i have a question in desgning a form.. the application in question is something a indexing station. the user in this indexing station views a document in pdf/tiff format on the right side of the form and enters the index data through various fields and listboxes on the left side.
7
2618
by: Georges Bessis | last post by:
The image I set as background are left at original size. In a picturebox, I can decide to strech the image. Can I do that to fill my background ? Regards GB
12
2561
by: Charlie King | last post by:
As I understand it, the use of FIR* to replace heading tags with images in visually enabled CSS browsers is now frowned upon on the basis that some screen readers will *nor* read back text that is marked up by CSS to be invisible or hidden. So... If I want to replace headings with images (because my client wants to use his specific font for headings where possible), what's the best way to do it?
3
1828
by: wolfing1 | last post by:
Normally I would do something like if request.form("submitbutton.x") <"" then .... end if But I found a problem when the browser uses the 'alt text' instead of the image (when the image is not found, or if the browser is not displaying graphics, etc. How do you detect that? or should I?
0
8272
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
8205
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
8713
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
8514
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
7206
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
6126
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
4094
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
4208
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
2632
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.