fancyfs

package module
v0.0.1 Latest Latest
Warning

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

Go to latest
Published: Nov 4, 2025 License: BSD-3-Clause Imports: 7 Imported by: 2

README

Fancy FS

A Go library for adding fancy additions to the filesystem. This is useful for file managers and other tools that have a graphical representation of a users files and folders.

Example

Create an overlay image

This over image can be placed over a folder or other item indicating the type of content in a fancy folder.

over := &canvas.Image{}

if ff, _ := fancyfs.DetailsForFolder(folderURI); ff != nil {
		if ff.BackgroundURI != nil {
			over.File = ff.BackgroundURI.Path()
		}
		if ff.BackgroundResource != nil {
			over.Resource = theme.NewColoredResource(ff.BackgroundResource, theme.ColorNameBackground)
		}
		s.over.FillMode = ff.BackgroundFill
	}

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ErrNoMetadata = errors.New("no metadata for requested folder")

Functions

This section is empty.

Types

type FancyFolder

type FancyFolder struct {
	BackgroundURI      fyne.URI
	BackgroundResource fyne.Resource
	BackgroundFill     canvas.ImageFill
}

func DetailsForFolder

func DetailsForFolder(dir fyne.URI) (*FancyFolder, error)

Jump to

Keyboard shortcuts

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