1 /*******************************************************************************
2 * Copyright (c) 2000, 2017 IBM Corporation and others.
4 * This program and the accompanying materials
5 * are made available under the terms of the Eclipse Public License 2.0
6 * which accompanies this distribution, and is available at
7 * https://www.eclipse.org/legal/epl-2.0/
9 * SPDX-License-Identifier: EPL-2.0
12 * IBM Corporation - initial API and implementation
13 *******************************************************************************/
14 package org.eclipse.swt.accessibility;
19 import org.eclipse.swt.graphics.*;
22 * Instances of this class are sent as a result of
23 * accessibility clients sending messages to controls
24 * asking for detailed information about the implementation
25 * of the control instance. Typically, only implementors
26 * of custom controls need to listen for this event.
28 * Note: The meaning of each field depends on the
29 * message that was sent.
32 * @see AccessibleTextListener
33 * @see AccessibleTextAdapter
34 * @see <a href="http://www.eclipse.org/swt/">Sample code and further information</a>
38 public class AccessibleTextEvent extends EventObject {
39 public int childID; // IN
40 public int offset, length; // OUT
42 public Accessible accessible;
45 * The value of this field must be set in the accessible text extended listener method
46 * before returning. What to set it to depends on the listener method called.
56 public int start, end;
60 public int x, y, width, height;
64 public Rectangle [] rectangles;
66 static final long serialVersionUID = 3977019530868308275L;
69 * Constructs a new instance of this class.
71 * @param source the object that fired the event
73 public AccessibleTextEvent (Object source) {
78 * Returns a string containing a concise, human-readable
79 * description of the receiver.
81 * @return a string representation of the event
84 public String toString () {
85 return "AccessibleTextEvent {childID=" + childID + //$NON-NLS-1$
86 " offset=" + offset + //$NON-NLS-1$
87 " length=" + length + //$NON-NLS-1$