Client API. The Codename One framework your app is built on: this runs on the device, not in a backend.
public interface KanbanCardRenderer
Known subtypesDefaultKanbanCardRenderer
Paints the cards of a
KanbanBoard, and says how tall each is.Methods
public abstract int getCardHeight(KanbanBoard board, KanbanCard card, int width) | The height of a card that is width pixels wide, without the component a KanbanCardFactory adds under it. |
public abstract void paintCard(Graphics g, KanbanBoard board, KanbanCard card, int x, int y, int w, int h, boolean selected, float lift) | Paints a card into a rectangle. |
Method details
getCardHeight
public abstract int getCardHeight(KanbanBoard board, KanbanCard card, int width)The height of a card that is
width pixels wide, without the
component a KanbanCardFactory adds under it.paintCard
public abstract void paintCard(Graphics g, KanbanBoard board, KanbanCard card, int x, int y, int w, int h, boolean selected, float lift)Paints a card into a rectangle.
Parameters
gGraphics- the graphics, with the colour and alpha the renderer may change
boardKanbanBoard- the component
cardKanbanCard- the card
xint- ,
y,w,h: the card on screen; the bottomboard.getCardComponentHeight(card)pixels belong to its component yint- Not documented.
wint- Not documented.
hint- Not documented.
selectedboolean- true for the selected card
liftfloat- how far the card is off the board, from 0 to 1, while it is dragged