Package org.zkoss.zul

Class Timebox

  • All Implemented Interfaces:
    java.io.Serializable, java.lang.Cloneable, Component, Disable, Readonly, Scope, ComponentCtrl, Constrainted

    public class Timebox
    extends DateTimeFormatInputElement
    An input box for holding a time (a java.util.Date Object), but only Hour & Minute are used.

    Default getZclass(): z-timebox. (since 3.5.0)

    timebox supports below key events.

    • 0-9 : set the time digit depend on the position on the inner text box.
    • up : increase time digit depend on the position on the inner text box.
    • down : decrease time digit depend on the position on the inner text box.
    • delete : clear the time to empty (null)

    Like Combobox and Datebox, the value of a read-only time box (InputElement.isReadonly()) can be changed by clicking the up or down button (though users cannot type anything in the input box).

    Since 10.0.0, if cols is not set by user, it will match the formatted value at the beginning (or 5 when value is null).

    Since:
    3.0.0
    Author:
    Dennis Chen
    See Also:
    Serialized Form