editor

package
v0.0.0-...-c5c556b Latest Latest
Warning

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

Go to latest
Published: May 2, 2024 License: GPL-2.0 Imports: 9 Imported by: 2

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	MagnifyX2 = Magnify{
		Display:      10,
		Value:        2,
		WidthPixels:  64,
		HeightPixels: 64,
	}
	MagnifyX4 = Magnify{
		Display:      20,
		Value:        4,
		WidthPixels:  32,
		HeightPixels: 32,
	}
	MagnifyX8 = Magnify{
		Display:      25,
		Value:        8,
		WidthPixels:  16,
		HeightPixels: 16,
	}
)

Functions

This section is empty.

Types

type ClickableImage

type ClickableImage struct {
	*widget.Icon
	// contains filtered or unexported fields
}

func NewClickableImage

func NewClickableImage(i image.Image, tapped func(float32, float32)) *ClickableImage

func (*ClickableImage) CreateRenderer

func (ci *ClickableImage) CreateRenderer() fyne.WidgetRenderer

func (*ClickableImage) Move

func (ci *ClickableImage) Move(position fyne.Position)

func (*ClickableImage) SetImage

func (c *ClickableImage) SetImage(i image.Image)

func (*ClickableImage) Tapped

func (c *ClickableImage) Tapped(pe *fyne.PointEvent)

func (*ClickableImage) TappedSecondary

func (c *ClickableImage) TappedSecondary(_ *fyne.PointEvent)

type Editor

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

func NewEditor

func NewEditor(i image.Image, m Magnify, p color.Palette, ca color.Palette, s func(image.Image, color.Palette), w fyne.Window) *Editor

func (*Editor) NewAvailablePalette

func (e *Editor) NewAvailablePalette(p color.Palette)

func (*Editor) NewEditor

func (e *Editor) NewEditor() *fyne.Container

func (*Editor) NewEmbededEditor

func (e *Editor) NewEmbededEditor(buttonLabel string) *fyne.Container

func (*Editor) NewImageAndPalette

func (e *Editor) NewImageAndPalette(i image.Image, p color.Palette)

type Magnify

type Magnify struct {
	Display      float32
	Value        int
	WidthPixels  int
	HeightPixels int
}

type PixelsMap

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

func NewPixelsMap

func NewPixelsMap(m Magnify, sz fyne.Size, s func(x, y int, c color.Color)) *PixelsMap

func (*PixelsMap) NewPixelsMap

func (pm *PixelsMap) NewPixelsMap() *fyne.Container

func (*PixelsMap) SelectedCell

func (p *PixelsMap) SelectedCell() (x int, y int)

func (*PixelsMap) SetColor

func (p *PixelsMap) SetColor(c color.Color)

func (*PixelsMap) SetColors

func (p *PixelsMap) SetColors(cs [][]color.Color)

func (*PixelsMap) SetMagnify

func (p *PixelsMap) SetMagnify(m Magnify)

Jump to

Keyboard shortcuts

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