package metadata
import "fyne.io/fyne/v2/internal/metadata"
Index ¶
- func Save(f *FyneApp, w io.Writer) error
- func SaveStandard(f *FyneApp, dir string) error
- func ScaleIcon(data fyne.Resource, size int) fyne.Resource
- type AppDetails
- type AppSource
- type FyneApp
- type LinuxAndBSD
Functions ¶
func Save ¶
Save attempts to write a FyneApp metadata to the provided writer. If the encoding fails an error will be returned.
func SaveStandard ¶
SaveStandard attempts to save a FyneApp metadata to the `FyneApp.toml` file in the specified dir. If the file cannot be written or encoding fails an error will be returned.
func ScaleIcon ¶
func ScaleIcon(data fyne.Resource, size int) fyne.Resource
Types ¶
type AppDetails ¶
type AppDetails struct { Icon string `toml:",omitempty"` Name, ID string `toml:",omitempty"` Version string `toml:",omitempty"` Build int `toml:",omitempty"` }
AppDetails describes the build information, this group may be OS or arch specific
type AppSource ¶
type AppSource struct { Repo, Dir string `toml:",omitempty"` }
type FyneApp ¶
type FyneApp struct { Website string `toml:",omitempty"` Details AppDetails Development map[string]string `toml:",omitempty"` Release map[string]string `toml:",omitempty"` Source *AppSource `toml:",omitempty"` LinuxAndBSD *LinuxAndBSD `toml:",omitempty"` Languages []string `toml:",omitempty"` }
FyneApp describes the top level metadata for building a fyne application
func Load ¶
Load attempts to read a FyneApp metadata from the provided reader. If this cannot be done an error will be returned.
func LoadStandard ¶
LoadStandard attempts to read a FyneApp metadata from the `FyneApp.toml` file in the specified dir. If the file cannot be found or parsed an error will be returned.
type LinuxAndBSD ¶
type LinuxAndBSD struct { GenericName string `toml:",omitempty"` Categories []string `toml:",omitempty"` Comment string `toml:",omitempty"` Keywords []string `toml:",omitempty"` ExecParams string `toml:",omitempty"` }
LinuxAndBSD describes specific metadata for desktop files on Linux and BSD.
Source Files ¶
data.go icon.go load.go save.go
- Version
- v2.5.4 (latest)
- Published
- Feb 1, 2025
- Platform
- linux/amd64
- Imports
- 9 packages
- Last checked
- 1 month ago –
Tools for package owners.