Package totalcross.ui

Class OutlinedEdit

    • Field Detail

      • totalTime

        public int totalTime
      • borderHeight

        protected int borderHeight
        The height, in pixels, of the border of the image used in the Ninepatch, if you won't change the ninepatch then you shouldn't change this field
    • Constructor Detail

      • OutlinedEdit

        public OutlinedEdit()
      • OutlinedEdit

        public OutlinedEdit​(java.lang.String mask)
    • Method Detail

      • setNinePatch

        public void setNinePatch​(Image img)
        Set the NinePatch of the control. This is used to draw the background image. If you change the Ninepatch you should then change the borderHeight using setBorderHeight().
        Overrides:
        setNinePatch in class Control
        Parameters:
        img - The image with guides to make the NinePatch. The image must be on a NinePatch format
      • setNinePatch

        public void setNinePatch​(Image img,
                                 int borderHeight)
        Set the NinePatch of the control. This is used to draw the background image. This also changes the borderHeight.
        Parameters:
        img - The image with guides to make the NinePatch. The image must be on a NinePatch format
        borderHeight - The height, in pixels, of the border of the image used in the Ninepatch.
      • onEvent

        public void onEvent​(Event event)
        Description copied from class: Edit
        Called by the system to pass events to the edit control.
        Overrides:
        onEvent in class Edit
        Parameters:
        event - the event to process
        See Also:
        Event, KeyEvent, PenEvent
      • setText

        public void setText​(java.lang.String s)
        Description copied from class: Edit
        Sets the text displayed in the edit control. If you're setting the text in CURRENCY mode, the text must be set not formatted (unmasked).
        Specified by:
        setText in interface TextControl
        Overrides:
        setText in class Edit
      • updateListenerTriggered

        public void updateListenerTriggered​(int elapsedMilliseconds)
        Description copied from interface: UpdateListener
        Called regularly by the system.
        Specified by:
        updateListenerTriggered in interface UpdateListener
        Parameters:
        elapsedMilliseconds - number of milliseconds since the last UpdateListenerTriggered call
      • getBorderHeight

        public int getBorderHeight()
        Returns the borderHeight.
      • setBorderHeight

        public void setBorderHeight​(int borderHeight)
        Sets the borderHeight, this number should be the height of the border of your ninepatch in pixels.