Eclipse Draw2d 3.7

## org.eclipse.draw2d.text
Class BidiProcessor

    java.lang.Object
      org.eclipse.draw2d.text.BidiProcessor

    public final class BidiProcessor

extends Object

A helper class for a BlockFlow that does Bidi evaluation of all the text in that block.

WARNING: This class is for INTERNAL use only.

Since:
  3.1

Field Summary
`static BidiProcessor` `INSTANCE` A singleton instance.

Method Summary
`void` `add(FlowFigure fig, char c)` Records a character contribution for this bidi context.
`void` `add(FlowFigure fig, String str)` Records a String contribution for this bidi context.
`void` `addControlChar(char c)` This methods allows FlowFigures to contribute text that may effect the bidi evaluation, but is not text that is visible on the screen.
`void` `process()` Processes the contributed text, determines the Bidi levels, and assigns them to the FlowFigures that made thet contributions.
`void` `setOrientation(int newOrientation)` Sets the paragraph embedding.

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Field Detail

### INSTANCE

    public static final BidiProcessor INSTANCE

  A singleton instance.

Method Detail

### add

    public void add(FlowFigure fig,
                    String str)

  Records a String contribution for this bidi context. Contributions are concatenated (in the order that they were contributed) to make the final String which will determine the bidi info for all contributors.

  Parameters:
    `fig` - the figure that is contributing the given text
    `str` - the text contributed by the given figure
  See Also:
    `addControlChar(char)`

### add

    public void add(FlowFigure fig,
                    char c)

  Records a character contribution for this bidi context. Contributions are concatenated (in the order that they were contributed) to make the final String which will determine the bidi info for all contributors.

  Parameters:
    `fig` - the figure that is contributing the given text
    `c` - the character being added
  See Also:
    `addControlChar(char)`

### addControlChar

    public void addControlChar(char c)

  This methods allows FlowFigures to contribute text that may effect the bidi evaluation, but is not text that is visible on the screen. The bidi level of such text is reported back to the contributing figure.

  Parameters:
    `c` - the control character

### process

    public void process()

  Processes the contributed text, determines the Bidi levels, and assigns them to the FlowFigures that made thet contributions. This class is for INTERNAL use only. Shaping of visually contiguous Arabic characters that are split in different figures is also handled. This method will do nothing if the contributed text does not require Bidi evaluation. All contributions are discarded at the end of this method.

### setOrientation

    public void setOrientation(int newOrientation)

  Sets the paragraph embedding. The given orientation will be used on TextLayout when determining the Bidi levels.

  Parameters:
    `newOrientation` - SWT.LEFT_TO_RIGHT or SWT.RIGHT_TO_LEFT

Eclipse Draw2d 3.7

Copyright (c) IBM Corp. and others 2000, 2011. All Rights Reserved.