How to get cursor to follow text when reading a web page? - usability

I know this isn't strictly program related, but I think I've seen this answer on SO before and lost track of it.
The specific question has to do with reading an electronic document. I find it helpful to move the cursor across the words as I'm reading them. This works great with Word documents, but I'm unable to do it with web pages. Is there a way to make a web page see and respond to cursor movement?

I'm not sure what you actually want to do when the cursor moves, but you can capture mouse movements over an element with said element's onMouseMove event.
Like this:
<div id="a" onMouseMove="doSomething(event.clientX, event.clientY)">
Mouse over me!
</div>
This will send the current X and Y coordinate to the "doSomething()" function when the mouse is moved over the DIV

In Firefox, you can do this by going to about:config and modifying the accessibility.browsewithcaret setting. (Type "caret" into the filter field, and right click to change the value of a boolean setting)

Related

How do I refresh the mouse cursor after I remove focus from a TextField?

I want to remove focus and selection on a textfield, if the user types ESC or ENTER, or focuses somewhere else. Thus I do this:
stage.focus = null;
textField.type = TextFieldType.DYNAMIC;
textField.selectable = false;
textField.mouseEnabled = false;
The problem is that, if the mouse is over the editable text field, the mouse is in IBEAM mode (caret cursor) and remains in IBEAM mode, even after the commands above, untill I slightly move the mouse, at which point it returns to the AUTO state.
I want to force the mouse to update itself and satisfy the AUTO state but no matter how much I try to make sure the textfield is disabled, it won't dissapear on its own, only after I move the mouse a bit.
Simplest answer from your comment:
So I was fidling with your suggestion and for the luls, used Mouse.hide() and then Mouse.show() and it worked. Removed the hide() and it works just with Mouse.show()! Guess it refreshes the mouse cursor. No blink, works perfectly <3
My original answer:
This is sort of a workaround but shouldn't be too difficult to implement. Hopefully someone comes along with a native API solution.
Run your code you posted
Then make cursor invisible
Then place your custom cursor at the mouse position (optional if you don't mind the cursor just disappearing)
On MouseEvent.MOUSE_MOVE remove your custom cursor, and make the cursor visible again.
I doubt you need me to write this code for you, but if you think this method would work for you, and you have a problem implementing this technique, let me know.
If you're worried about different systems having different mouse icons and then suddenly getting your custom one for a split second, the easy solution there is to just always use your custom cursor. You can design it to look exactly as you like; either mimic Windows OS or make it unique.

Google Chrome dev tools variable tip bubble too little to see the content

I have just now sended the following message to google chrome developer:
Chrome version: 54.0.2840.59 m
As you know, when debugging a web page with javascript, the Chrome
debugger allows to pause the execution of the code on breakpoints. In
this moment is possible to move the mouse onto a variable to see what
value has in: when the mouse is on the variable chrome code
inspector/debugger shows a little tip showing the variable value.
The problem is that such little bubble tip sometimes is toooo little
and it is not possible to see the content.
Please correct its size (make it resizable) to make possible to read
its content or it isn't useful.
Thanks
Anyone else has noticed the same issue?
Someone has solved it?
Edits
Before the last update was working perfectly (or at least I didn't see anything wrong in its behavior!), but now the following image shows the issue that sometimes happens:
As shown into the above img, part of the bubble tip content is shown, part is hidden, and it is not possible to scroll the bubble tip neither up|down nor left|right: scrollbars are greyed. Sometimes scrollbars don't appear at all.
You can scroll the tool tip as per the animation below:
A possible workaround could be adding the variable to the watch list:
Procedure:
right click on the variable
Into right click menu click on "Add selected text to watches"
This allows to keep an eye on the watchlisted var contents, even if they hidden into the bubble tip.
It is not completely handy, but works.

Tab through a webpage manually

I am trying to navigate through a webpage using just my keyboard. Through the use of my tab key I can enter in data into several input boxes, and press several submit buttons.
However I run into a problem when trying to set focus to an image element on the page. For some reason it does not allow me to select it with the tab key. I can click on it with my mouse and then a popup appears but this really slows down efficiency.
I have considered creating a script in VBA to do this but right now I would prefer a quick-fix without having to spend hours developing a macro.
NOTE: I did quickly try to assign the reference to the <img> element and use the Click and Focus methods in VBA but that didn't work. I don't get an error, the code runs fine but nothing happens on the webpage. This leads me to think that this will be a bigger project than it appears, hence my reluctance to go down that path.
I did a bit of research and it seems that tabindex is not supported by the <img> element. Does that mean what I am trying to accomplish is impossible with the keyboard? Is code my only option?
If anyone knows anything that could help in VBA by all means I will take your advice into consideration.
Unfortunately the webpage is password protected and its a company account therefore I cannot post it.
After right-clicking inspect element in my Chrome browser this is what I see:
<img alt="View Quantities At Other Locations" src="/WebOrder/Images/CheckQtys.gif"
title="View Quantities At Other Locations" class="popup"popupdirection="upperleft"
popupwidth="380" popupcontent="#ProductQuantitiesForAccessibleBranches"
onbeforepopupcreate="onBeforePopupCreate_GetProductQuantitiesForAccessibleBranches(this)"
popupajaxformid="GetProductQuantitiesForAccessibleBranches"
onbeforepopupajaxpost="onBeforePopupAjaxPost_GetProductQuantitiesForAccessibleBranches(this)"
oncompletepopupajaxpost="onCompletePopupAjaxPost_GetProductQuantitiesForAccessibleBranches(this)"
productguid="00000000-0000-0000-0000-000000058927" displayitem="732899500"
brandguid="00000000-0000-0000-0000-000000000000" brandname="" brandsku="">
Does anyone have any ideas how I can set focus to this element (either with my keyboard or VBA)?
You can focus on a div using <div tabindex=0> Stuff Here </div>. Place the image inside the div and use the div to manipulate it.

html dropdownlist cannot type until clicked on

I have tried this in multiple browsers and have done searches for this but have not been able to find a solution.
So here is the problem. I have CHtml::dropDownLists on my page. When you tab to that you can sometimes just type to change to an option that is with in it but there are other times where you have to actually click on that before you can start typing to change. Granted once you click on it you can change it but I need to have more of a hands off mouse control.
I was curious if this was based on how the browser placed items with its DOM or if it is something with Yii.
Any thoughts, pointer, hidden websites about this would be greatly appreciated.

Forcing JAWS to read FLEX content "on-demand"

I'm trying to make an existing FLEX application section-508-compliant, by getting it to work smoothly with the JAWS screen reader. It kinda sorta works, but one immediate problem is that when you first go to the login screen, your cursor ends up in the userid field, but JAWS doesn't read anything useful (like the label of the field you're in!) until you hit TAB or something.
Is there a way to force it to speak immediately on application startup, without making the user tab/backtab just to hear where they are?
For that matter, as cool as it is that it reads interactive controls as the user tabs around, sometimes you just need to make JAWS say something at a particular point in the logic, which might or might not be associated with a control, as if you could write AS code like jaws.speak('blah blah blah');. Does anyone know how to accomplish this?
check out the Tips and Tricks slide (page 16) on this page:
http://www.slideshare.net/fugaciousness/accessibility-in-flex
A few in particular you may find usefull...
start the tabIndex at 1 instead of 0.
Force focus into the app with ExternalInterface.call("s = function() {document.getElementByID('"+this.id+"').focus(); }");
Or force the tab to stay within the app... keyFocusChange="event.preventDefault(); focusManager.getNextFocusManagerComponent(event.shiftKey).setFocus()"