Documentation ¶
Index ¶
Constants ¶
const ( TYPE_NO_COMPONENT = -1 TYPE_BOOL = 0 TYPE_SLIDER = 1 TYPE_DROP_MENU = 2 )
const (
CHECKBOX_SIZE = 100
)
const DURATION = 3
Variables ¶
var (
CheckBoxRect graphic.Rect
)
var (
ImageButtonPhysicalPosition graphic.Vector2
)
var (
SliderRect graphic.Rect
)
Functions ¶
func NewNotificationText ¶ added in v1.1.0
func NewNotificationText(notifText string)
func UpdateNotification ¶ added in v1.1.0
func UpdateNotification()
Types ¶
type CheckBox ¶
type CheckBox struct { HoverState bool // contains filtered or unexported fields }
la CheckBox est une case à cocher
func NewCheckBox ¶
Initialisation de la checkbox
type ImageButton ¶
type ImageButton struct { HoverState bool PressedState bool // contains filtered or unexported fields }
l'objet ImageButton désigne un bouton qui a pour hitbox et pour visuel une texture
func NewImageButton ¶
func NewImageButton(position graphic.Vector2, texture rl.Texture2D, horizontalAnchor int8, verticalAnchor int8) *ImageButton
Initialisation du bouton
func (*ImageButton) Update ¶
func (b *ImageButton) Update(containingRect graphic.Rect)
Fonction de mise à jour du bouton
type ImageLabel ¶
type ImageLabel struct {
// contains filtered or unexported fields
}
le TextLabel est un objet désignant une texture, qui est statique, et qui est destiné à être affiché.
func NewImageLabel ¶
func NewImageLabel(texture rl.Texture2D, position graphic.Vector2, horizontalAnchor int8, verticalAnchor int8) *ImageLabel
Initialisation du texte, qui est rendu sur une texture qui fait renderer
func (*ImageLabel) GetSize ¶
func (i *ImageLabel) GetSize() graphic.Vector2
retourne la taille du label
func (*ImageLabel) Render ¶
func (i *ImageLabel) Render(surfaceRect graphic.Rect)
Fonctions permettant d'afficher le texte
type Setting ¶
type Setting struct {
// contains filtered or unexported fields
}
l'objet Setting est un objet qui représente un paramètre à afficher graphiquement. Il joue le rôle d'interface et permet ainsi de simplifer la création de l'interface faite manuellement
func NewSetting ¶
func NewSetting(name string, componentType int, font rl.Font, fontSize float32, position graphic.Vector2, horizontalAnchor int8, verticalAnchor int8) *Setting
Initialisation d'un paramètre
func (*Setting) SetSliderValue ¶
type Slider ¶
type Slider struct { HoverState bool // contains filtered or unexported fields }
le slider, ou "curseur" est une barre verticale qui permet d'ajuster une valeur en déplaçant le rond qui est devant
type TextLabel ¶
type TextLabel struct {
// contains filtered or unexported fields
}
le TextLabel est un objet désignant un texte, qui est statique, et qui est destiné à être affiché.
func Newlabel ¶
func Newlabel(text string, font rl.Font, fontSize float32, position graphic.Vector2, horizontalAnchor int8, verticalAnchor int8) *TextLabel
Initialisation du texte, qui est rendu sur une texture qui fait renderer