Client API. The Codename One framework your app is built on: this runs on the device, not in a backend.

public abstract static class RichText.Visitor

  1. Object
  2. RichText.Visitor
Receives the runs of a text in order. Subclass it and override what you need; methods may be added here for new kinds of inline content, and they will do nothing unless overridden.

Constructors

public Visitor()

Methods

public abstract void run(int offset, String text, TextStyle style)Called once per text run.
public void inline(int offset, Inline object, TextStyle style)Called once per inline object.

Inherited methods

Constructor details

Visitor

public Visitor()

Method details

run

public abstract void run(int offset, String text, TextStyle style)
Called once per text run.

Parameters

offset int
the run’s first character within the whole text
text String
the run’s characters
style TextStyle
the run’s style

inline

public void inline(int offset, Inline object, TextStyle style)
Called once per inline object. Does nothing unless overridden.

Parameters

offset int
the object’s character within the whole text
object Inline
the object
style TextStyle
the style the object’s character has