Page 1 of 1

How to connect to chromium Accessibility

Posted: 30 Sep 2017, 13:27
by arcticir
chromium Use the command line parameter "--force-renderer-accessibility" to allow us to use the ACC.
But its interface seems to be somewhat incomplete, it rarely provides "accName" or "accValue".
And if you use Firefox, the same page, we can get the complete information.


On this page: chrome://accessibility
To view the "show accessibility tree" option on the page, we can see that its ACC contains all the information.
But the problem is that we can not get this information.

I found some relevant documentation, for example here:
https://chromium.googlesource.com/chrom ... verview.md
On Windows, the root node implements the IAccessible protocol and if you call IAccessible::get_accRole, it returns ROLE_SYSTEM_DOCUMENT, and if you call IAccessible::get_accName, it returns “How old are you?”. Other methods let you walk the tree.
But I can not understand how these data are connected.

https://www.chromium.org/developers/des ... essibility

Re: How to connect to chromium Accessibility

Posted: 30 Sep 2017, 14:13
by HotKeyIt
Can you post an example and explain where it does not work?

Re: How to connect to chromium Accessibility

Posted: 30 Sep 2017, 15:55
by arcticir
Using the same code, chromium and Firefox have different information.

Code: Select all

	Acc := Acc_ObjectFromPoint(ChildId)
	role:=Acc_GetRoleText(Acc.accRole(ChildId))
	state:=Acc_GetStateText(Acc.accState(ChildId))
	action:=Acc.accDefaultAction(ChildId)
	f:={role:role,state:state,action:action,ChildId:ChildId}
	if role
		f.name:=Acc.accName(ChildId),f.value:=Acc.accValue(ChildId)
ImageImage

Re: How to connect to chromium Accessibility

Posted: 30 Sep 2017, 16:40
by HotKeyIt
I am not sure but as I understand chromium uses different structure.
If I get it right the value is an object that contains the information, try f.value:=(ChildId2:=Acc.AccValue(ChildId)).accName(ChildId2) or something similar.

Re: How to connect to chromium Accessibility

Posted: 30 Sep 2017, 17:08
by arcticir
But I did not find who's the value is an object.
Even if you use "for wach, child in Acc_Children (AccObj)", no useful data is found.

Re: How to connect to chromium Accessibility  Topic is solved

Posted: 01 Oct 2017, 04:24
by arcticir
I use "Acc_Parent (Acc)" to get the parent data, which seems to be the correct answer.
thank you very much. :D