Package org.eclipse.jface.util
Class StructuredTextSegmentListener
- java.lang.Object
-
- org.eclipse.jface.util.StructuredTextSegmentListener
-
- All Implemented Interfaces:
EventListener,SegmentListener,SWTEventListener
public class StructuredTextSegmentListener extends Object implements SegmentListener
Segment listener that implements bidi-structured text reordering. The reordering is specified by the structured text type that is passed to the constructor.Note: This class only works if the
org.eclipse.equinox.bidibundle is on the classpath!- Since:
- 3.9
- Restriction:
- This class is not intended to be subclassed by clients.
-
-
Constructor Summary
Constructors Constructor Description StructuredTextSegmentListener(String textType)Creates a new structured text segment listener.StructuredTextSegmentListener(StructuredTextTypeHandler textTypeHandler)Creates a new structured text segment listener.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidgetSegments(SegmentEvent event)This method is called when text content is being modified.
-
-
-
Constructor Detail
-
StructuredTextSegmentListener
public StructuredTextSegmentListener(String textType)
Creates a new structured text segment listener.- Parameters:
textType- the structured text type. Possible values are the structured text type ids supported byStructuredTextTypeHandlerFactory.getHandler(String).- Throws:
IllegalArgumentException- iftextTypeis not a known type identifier
-
StructuredTextSegmentListener
public StructuredTextSegmentListener(StructuredTextTypeHandler textTypeHandler)
Creates a new structured text segment listener.- Parameters:
textTypeHandler- the structured text type handler- Throws:
IllegalArgumentException- if thehandlerisnull
-
-
Method Detail
-
getSegments
public void getSegments(SegmentEvent event)
Description copied from interface:SegmentListenerThis method is called when text content is being modified.The following event fields are used:
- event.lineText text content (input)
- event.segments text offsets for segment characters (output)
- event.segmentsChars characters that should be inserted (output, optional)
- Specified by:
getSegmentsin interfaceSegmentListener- Parameters:
event- the given event- See Also:
SegmentEvent
-
-