Class zebkit.draw.WrappedTextRender
extends <zebkit.draw.TextRender>
<zebkit.draw>

Wrapped text render.

Constructor:
zebkit.draw.WrappedTextRender (text)

Parameters:




private <Array> $breakToLines (w)

Break text model to number of lines taking in account the maximal width.


Parameters:
  • w <Integer>

    a maximal width


Returns: <Array>

an array of lines

public <Object> calcPreferredSize ([pw])

Get preferred size of the text render


Parameters:
  • [pw] <Integer>

    a width the wrapped text has to be computed


Returns: <Object>

a preferred size

{ width: {Integer}, height:{Integer} }


Inherited attributes:
public String color    public String | zebkit.Font font    public Integer lineIndent    protected zebkit.layout.Layoutable owner    public Object target