Query on creating Controls using the SWT Accessibility API [message #10278] |
Tue, 01 August 2006 08:49 |
Eclipse User |
|
|
|
Originally posted by: melangov.in.ibm.com
Hi.,
I am trying to develop controls which is compatible and readable by IBM
HomePageReader(Desktop Reader),
Firstly i used SWT Accessibility API (org.eclipse.swt.*) to create
controls such as Checkbox and Labels.
For eg : Consider wizard having 2 controls
Label Control Type
===== ===========
COA unchecked Checkbox
OfferLetter combobox
The desktop reader reads the message as follows ( COA --- unchecked
checkbox ---- COA ----Offerletter )
COA is read twice instead of once at the start.
It is reading the label ,checkbox and again the name of the first label
and then the other label...
Here,the first label is read twice...
So,as to fix this issue,I tried creating the label in the following way...
final Label label_15 = new Label(container, SWT.NONE);
access=label_15.getAccessible();
final FormData formData_34 = new FormData();
formData_34.bottom = new FormAttachment(0, 395);
formData_34.right = new FormAttachment(label_13, 135,
SWT.LEFT);
formData_34.top = new FormAttachment(0, 375);
formData_34.left = new FormAttachment(label_13, 0,
SWT.LEFT);
label_15.setLayoutData(formData_34);
access.addAccessibleListener(new AccessibleAdapter(){
public void getName(AccessibleEvent arg0) {
super.getName(arg0);
if(arg0.childID==1){
//Control lab=access.getControl();
//lab.setData(GcpsClientCustomerWizardMessages.getString(
//"CustomerPanel.OL/COA_rollup_indicator"));
label_15.setText(
GcpsClientCustomerWizardMessages.getString("CustomerPanel.OL_BSP "));
}
}
});
Similarly,i tried creating the checkbox also.,
Are there any alternate ways of doing this to make it work correctly .
I appreciate if u could please look into this and do any help in this
regard.
Thanks & Regards.,
Meenakshi E
IBM India Pvt. Ltd.,
Prestige Towers,Level 2,
#99,Residency Road,
Bangalore-560001.
INDIA
Ph.No.: +91-80-4007-2137
E-Mail : melangov@in.ibm.com
|
|
|
Powered by
FUDForum. Page generated in 0.02755 seconds