application

package
v0.0.0-...-81aed03 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 22, 2024 License: MIT Imports: 18 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ErrorNeedsToBeLaunchedBeforeRun = eh.Errorf("application needs to be launched before run")
View Source
var MaximumNumberOfRelaunches = eh.Errorf("maximum number of re-launches reached")

Functions

This section is empty.

Types

type Application

type Application struct {
	IconFont imgui.ImFontPtr

	FffiEstablishedHandler      func(fffi *runtime.Fffi2) error
	BeforeFirstFrameInitHandler func() error
	RenderLoopHandler           func(marshaller *runtime.Marshaller) error
	Config                      *Config
	// contains filtered or unexported fields
}

func NewApplication

func NewApplication(cfg *Config) (app *Application, err error)

func (*Application) Launch

func (inst *Application) Launch() (err error)

func (*Application) Run

func (inst *Application) Run() (err error)

type Config

type Config struct {
	MainFontTTF          string
	MainFontSizeInPixels float32
	ImGuiBinary          string
	UseWasm              bool
	MaxRelaunches        int
	// contains filtered or unexported fields
}

func (*Config) FromContext

func (inst *Config) FromContext(nameTransf config.NameTransformFunc, ctx *cli.Context) (nMessages int)

func (*Config) ToCliFlags

func (inst *Config) ToCliFlags(nameTransf config.NameTransformFunc, envVarNameTransf config.NameTransformFunc) []cli.Flag

func (*Config) Validate

func (inst *Config) Validate(force bool) (nMessages int)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL