Documentation
¶
Overview ¶
SPDX-License-Identifier: MIT
Index ¶
- Variables
- type Button
- func (b *Button) Draw(screen *ebiten.Image)
- func (b *Button) IsClicked() bool
- func (b *Button) IsInvisible() bool
- func (b *Button) IsRoundedCorners() bool
- func (b *Button) IsUneditable() bool
- func (btn *Button) SetColorScheme(scheme colorscheme.ColorScheme)
- func (b *Button) SetColors(background, hover, pressed, border, text color.RGBA)
- func (b *Button) SetCornerRadius(radius float32)
- func (b *Button) SetEnabled(enabled bool)
- func (b *Button) SetFontSize(size int32)
- func (b *Button) SetInvisible(invisible bool)
- func (b *Button) SetPadding(padding float32)
- func (b *Button) SetPointyAmount(amount float32)
- func (b *Button) SetPointyStyle(pointy bool)
- func (b *Button) SetRoundedCorners(rounded bool)
- func (b *Button) SetUneditable(uneditable bool)
- func (b *Button) Update()
- type Rect
Constants ¶
This section is empty.
Variables ¶
View Source
var DefaultFont font.Face
DefaultFont is a package-level font face used for drawing text. Ensure that you set this variable (e.g., in your initialization code) to a valid font.Face.
Functions ¶
This section is empty.
Types ¶
type Button ¶
type Button struct { Bounds Rect Label string BackgroundColor color.RGBA HoverColor color.RGBA PressedColor color.RGBA BorderColor color.RGBA TextColor color.RGBA FontSize int32 FontFace font.Face IsHovered bool IsPressed bool AnimationProgress float32 Padding float32 CornerRadius float32 Enabled bool Invisible bool Uneditable bool UseRoundedCorners bool UsePointyStyle bool // New field for pointy buttons PointyAmount float32 // How pointy the buttons are (arrow length) // contains filtered or unexported fields }
func (*Button) Draw ¶
func (b *Button) Draw(screen *ebiten.Image)
Draw draws the button onto the given screen.
func (*Button) IsInvisible ¶
func (*Button) IsRoundedCorners ¶
func (*Button) IsUneditable ¶
func (*Button) SetColorScheme ¶
func (btn *Button) SetColorScheme(scheme colorscheme.ColorScheme)
func (*Button) SetCornerRadius ¶
func (*Button) SetEnabled ¶
func (*Button) SetFontSize ¶
func (*Button) SetInvisible ¶
func (*Button) SetPadding ¶
func (*Button) SetPointyAmount ¶
func (*Button) SetPointyStyle ¶
func (*Button) SetRoundedCorners ¶
func (*Button) SetUneditable ¶
Click to show internal directories.
Click to hide internal directories.