epubimage

package
v3.0.1 Latest Latest
Warning

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

Go to latest
Published: Jan 29, 2025 License: MIT Imports: 3 Imported by: 0

Documentation

Overview

Package epubimage EPUBImage helpers to transform image.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type EPUBImage

type EPUBImage struct {
	Id                  int
	Part                int
	Raw                 image.Image
	Width               int
	Height              int
	IsBlank             bool
	DoublePage          bool
	Path                string
	Name                string
	Position            string
	Format              string
	OriginalAspectRatio float64
	Error               error
}

func (EPUBImage) EPUBImgPath

func (i EPUBImage) EPUBImgPath() string

EPUBImgPath image path into the EPUB

func (EPUBImage) EPUBPagePath

func (i EPUBImage) EPUBPagePath() string

EPUBPagePath page path into the EPUB

func (EPUBImage) EPUBSpacePath

func (i EPUBImage) EPUBSpacePath() string

EPUBSpacePath path of the blank page into the EPUB

func (EPUBImage) ImgKey

func (i EPUBImage) ImgKey() string

ImgKey key for image

func (EPUBImage) ImgPath

func (i EPUBImage) ImgPath() string

ImgPath image path

func (EPUBImage) ImgStyle

func (i EPUBImage) ImgStyle(viewWidth, viewHeight int, align string) string

ImgStyle style to apply to the image.

center by default. align to left or right if it's part of the split double page.

func (EPUBImage) PageKey

func (i EPUBImage) PageKey() string

PageKey key for page

func (EPUBImage) PagePath

func (i EPUBImage) PagePath() string

PagePath page path linked to the image

func (EPUBImage) PartKey

func (i EPUBImage) PartKey() string

func (EPUBImage) RelSize

func (i EPUBImage) RelSize(viewWidth, viewHeight int) (relWidth, relHeight int)

func (EPUBImage) SpaceKey

func (i EPUBImage) SpaceKey() string

SpaceKey key name of the blank page after the image

func (EPUBImage) SpacePath

func (i EPUBImage) SpacePath() string

SpacePath path of the blank page

Jump to

Keyboard shortcuts

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