If you want to create a completely new component, you should subclass Component and create a corresponding skin (which will generally extend org.apache.pivot.wtk.skin.ComponentSkin, but can simply implement org.apache.pivot.wtk.Skin if you prefer).
If your class bears any similarity to an existing component, you would almost certainly be better off subclassing that. In this case, you'll probably also want to create a custom skin subclass that extends the default skin for that component. However, if you do want to create an entirely new component, you can look at the Ruler component in the ScrollPane tutorial for an example: http://svn.apache.org/repos/asf/pivot/trunk/tutorials/src/org/apache/pivot/tutorials/navigation/ See Ruler.java, RulerListener.java, and RulerSkin.java. G On Dec 1, 2010, at 8:04 PM, Bill van Melle wrote: > In WPF, if I want to make some sort of custom control (which I do a lot, for > modularity's sake, even if the control is only used in one place), I most > often subclass UserControl, which is a boring class that has a single Content > element. What's the corresponding thing in Pivot? >
