Class TextRegionEventFilter
- java.lang.Object
-
- com.itextpdf.kernel.pdf.canvas.parser.filter.TextRegionEventFilter
-
- All Implemented Interfaces:
IEventFilter
public class TextRegionEventFilter extends java.lang.Object implements IEventFilter
ThisIEventFilterimplementation only accepts text render events within the specified rectangular region.
-
-
Field Summary
Fields Modifier and Type Field Description private RectanglefilterRect
-
Constructor Summary
Constructors Constructor Description TextRegionEventFilter(Rectangle filterRect)Constructs a filter instance.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanaccept(IEventData data, EventType type)This method checks an event and decides whether it should be processed further (corresponds totruereturn value), or filtered out (corresponds tofalsereturn value).
-
-
-
Field Detail
-
filterRect
private final Rectangle filterRect
-
-
Constructor Detail
-
TextRegionEventFilter
public TextRegionEventFilter(Rectangle filterRect)
Constructs a filter instance.- Parameters:
filterRect- the rectangle to filter text against
-
-
Method Detail
-
accept
public boolean accept(IEventData data, EventType type)
Description copied from interface:IEventFilterThis method checks an event and decides whether it should be processed further (corresponds totruereturn value), or filtered out (corresponds tofalsereturn value).- Specified by:
acceptin interfaceIEventFilter- Parameters:
data- event datatype- event type- Returns:
- true to process event further, false to filter event out
-
-