Class Placeholder

    • Method Detail

      • changeAlpha

        public void changeAlpha​(float alpha)
        Convenience method to change the alpha value of the current foreground Color to the specific value.
        Parameters:
        alpha - value in the range of 0 - 1.0.
      • changeAlpha

        public void changeAlpha​(int alpha)
        Convenience method to change the alpha value of the current foreground Color to the specific value.
        Parameters:
        alpha - value in the range of 0 - 255.
      • changeStyle

        public void changeStyle​(int style)
        Convenience method to change the style of the current Font. The style values are found in the Font class. Common values might be: Font.BOLD, Font.ITALIC and Font.BOLD + Font.ITALIC.
        Parameters:
        style - value representing the the new style of the Font.
      • getShow

        public Placeholder.Show getShow()
        Get the Show property
        Returns:
        the Show property.
      • setShow

        public void setShow​(Placeholder.Show show)
        Set the prompt Show property to control when the prompt is shown. Valid values are:

        Show.ALWAYS (default) - always show the prompt Show.Focus_GAINED - show the prompt when the component gains focus (and hide the prompt when focus is lost) Show.Focus_LOST - show the prompt when the component loses focus (and hide the prompt when focus is gained)

        Parameters:
        show - a valid Show enum
      • getShowPromptOnce

        public boolean getShowPromptOnce()
        Get the showPromptOnce property
        Returns:
        the showPromptOnce property.
      • setShowPromptOnce

        public void setShowPromptOnce​(boolean showPromptOnce)
        Show the prompt once. Once the component has gained/lost focus once, the prompt will not be shown again.
        Parameters:
        showPromptOnce - when true the prompt will only be shown once, otherwise it will be shown repeatedly.