ui

package
v0.4.0 Latest Latest
Warning

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

Go to latest
Published: Nov 14, 2025 License: MIT Imports: 23 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var CoffeeIcon = &fyne.StaticResource{StaticName: "coffee.svg", StaticContent: coffeeLogoBytes}
View Source
var DiscordIcon = &fyne.StaticResource{StaticName: "discord.svg", StaticContent: discordLogoBytes}
View Source
var GithubIcon = &fyne.StaticResource{StaticName: "github.svg", StaticContent: githubLogoBytes}
View Source
var Icons = map[string]*fyne.StaticResource{
	"logo":     LogoIcon,
	"discord":  DiscordIcon,
	"bmc":      CoffeeIcon,
	"github":   GithubIcon,
	"mastodon": MastodonIcon,
	"sponsor":  SponsorIcon,
	"x":        XIcon,
}
View Source
var LogoIcon = &fyne.StaticResource{StaticName: "logo.png", StaticContent: logoBytes}
View Source
var MastodonIcon = &fyne.StaticResource{StaticName: "mastodon.svg", StaticContent: mastodonLogoBytes}
View Source
var SponsorIcon = &fyne.StaticResource{StaticName: "sponsor.svg", StaticContent: sponsorLogoBytes}
View Source
var Version = "dev"
View Source
var XIcon = &fyne.StaticResource{StaticName: "x.svg", StaticContent: xLogoBytes}

Functions

func New

func New(a fyne.App, w fyne.Window)

Types

type CoreUI added in v0.4.0

type CoreUI interface {
	ReloadBin(id int)
	RefreshTabCount(id int)
	ShowErrorDialog(err error)
	UpdatePreview(path string)
	OnTypedKey(e *fyne.KeyEvent)
	OnTypedRune(r rune)
}

type PicsortUI

type PicsortUI struct {
	// contains filtered or unexported fields
}

func (*PicsortUI) GetBinCount

func (p *PicsortUI) GetBinCount() int

func (*PicsortUI) GetWindow

func (p *PicsortUI) GetWindow() fyne.Window

func (*PicsortUI) GoToTab

func (p *PicsortUI) GoToTab(id int)

func (*PicsortUI) HideProgressDialog

func (p *PicsortUI) HideProgressDialog()

func (*PicsortUI) LoadContent

func (p *PicsortUI) LoadContent()

func (*PicsortUI) NewBin

func (p *PicsortUI) NewBin()

func (*PicsortUI) OnTypedKey added in v0.4.0

func (p *PicsortUI) OnTypedKey(e *fyne.KeyEvent)

func (*PicsortUI) OnTypedRune added in v0.4.0

func (p *PicsortUI) OnTypedRune(r rune)

func (*PicsortUI) RefreshTabCount added in v0.4.0

func (p *PicsortUI) RefreshTabCount(id int)

func (*PicsortUI) ReloadAll

func (p *PicsortUI) ReloadAll()

func (*PicsortUI) ReloadBin

func (p *PicsortUI) ReloadBin(id int)

func (*PicsortUI) RemoveBin

func (p *PicsortUI) RemoveBin()

func (*PicsortUI) SetProgress

func (p *PicsortUI) SetProgress(progress float64, f string)

func (*PicsortUI) ShowErrorDialog

func (p *PicsortUI) ShowErrorDialog(err error)

func (*PicsortUI) ShowProgressDialog

func (p *PicsortUI) ShowProgressDialog(msg string)

func (*PicsortUI) UpdatePreview

func (p *PicsortUI) UpdatePreview(path string)

type Thumbnail

type Thumbnail struct {
	widget.BaseWidget
	Image     image.Image
	Checked   bool
	OnChanged func(bool)
}

func NewThumbnail

func NewThumbnail(img image.Image, onChanged func(bool)) *Thumbnail

func (*Thumbnail) CreateRenderer

func (ic *Thumbnail) CreateRenderer() fyne.WidgetRenderer

func (*Thumbnail) Tapped

func (ic *Thumbnail) Tapped(*fyne.PointEvent)

type ThumbnailGridWrap

type ThumbnailGridWrap struct {
	widget.GridWrap
	// contains filtered or unexported fields
}

func NewThumbnailGrid

func NewThumbnailGrid(id int, ui CoreUI, d ThumbnailProvider) *ThumbnailGridWrap

func (*ThumbnailGridWrap) GetImagePaths added in v0.4.0

func (g *ThumbnailGridWrap) GetImagePaths() []string

func (*ThumbnailGridWrap) MoveImages

func (g *ThumbnailGridWrap) MoveImages(destID int)

func (*ThumbnailGridWrap) Reload

func (g *ThumbnailGridWrap) Reload()

func (*ThumbnailGridWrap) TypedKey

func (g *ThumbnailGridWrap) TypedKey(key *fyne.KeyEvent)

func (*ThumbnailGridWrap) TypedRune

func (g *ThumbnailGridWrap) TypedRune(r rune)

type ThumbnailProvider

type ThumbnailProvider interface {
	GetThumbnail(path string) image.Image
	GetImagePaths(bindID int) []string
	MoveImages(paths []string, sourceID, destID int) error
}

The ThumbnailProvider needs to provide way to get thumbnails and its paths, as well as a way to update the preview.

Jump to

Keyboard shortcuts

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