Fyne API "container.Navigation"
container.Navigation
import "fyne.io/fyne/v2/container"
Usage
type Navigation
type Navigation struct {
widget.BaseWidget
Root fyne.CanvasObject
Title string
OnBack func()
OnForward func()
}
Navigation container is used to provide your application with a control bar and an area for content objects. Objects can be any CanvasObject, and only the most recent one will be visible.
2.7
func NewNavigation
func NewNavigation(root fyne.CanvasObject) *Navigation
NewNavigation creates a new navigation container with a given root object.
2.7
func NewNavigationWithTitle
func NewNavigationWithTitle(root fyne.CanvasObject, s string) *Navigation
NewNavigationWithTitle creates a new navigation container with a given root object and a default title.
2.7
func (*Navigation) Back
func (nav *Navigation) Back() fyne.CanvasObject
Back returns the top level CanvasObject, adjusts the title accordingly, and disabled the back button when no more objects are left to go back to.
2.7
func (*Navigation) CreateRenderer
func (nav *Navigation) CreateRenderer() fyne.WidgetRenderer
func (*Navigation) Forward
func (nav *Navigation) Forward() fyne.CanvasObject
Forward shows the next object in the stack again.
2.7
func (*Navigation) Push
func (nav *Navigation) Push(obj fyne.CanvasObject)
Push puts the given object on top of the navigation stack and hides the object below.
2.7
func (*Navigation) PushWithTitle
func (nav *Navigation) PushWithTitle(obj fyne.CanvasObject, s string)
PushWithTitle puts the given CanvasObject on top, hides the object below, and uses the given title as label text.
2.7
func (*Navigation) SetCurrentTitle
func (nav *Navigation) SetCurrentTitle(s string)
SetCurrentTitle changes the navigation title for the current level.
2.7
func (*Navigation) SetTitle
func (nav *Navigation) SetTitle(s string)
SetTitle changes the root navigation title shown by default.
2.7