Is there a way, perhaps using selenium, to make the mouse pointer get to and hover over a specific color pixel? I'm trying to get my mouse to get to the pixel in green/white: image. I'm trying this to be able to extract the coordinates of each point.
The site uses GIS cloud.
I guess this is more a concept question.
1 Selenium can to to an element with ActionChains
from selenium.webdriver import ActionChains
actions = ActionChains(driver)
actions.move_to_element("your_locator")
actions.click().perform()
2 Selenium can get a pixel color with value_of_css_property
function.
element_color = your_locator.value_of_css_property("background-image")
I don't really think that you will need to get elements color. You should find its css or xpath locator and move to it with ActionChains
.
So, ActionChains is what you really need.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.