viewer

package
v0.2.3 Latest Latest
Warning

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

Go to latest
Published: Sep 9, 2023 License: MIT Imports: 41 Imported by: 0

Documentation

Index

Constants

View Source
const BINARY_DATA_MSG = `` /* 606-byte string literal not displayed */
View Source
const OSM_URL_PREFIX = "https://nominatim.openstreetmap.org"

Variables

This section is empty.

Functions

This section is empty.

Types

type CommandEvent

type CommandEvent struct {
	Cmd string
}

type HeaderLine

type HeaderLine struct {
	parse.Token
	// contains filtered or unexported fields
}

func HeaderLineInit

func HeaderLineInit(tkn parse.Token, th *Theme) *HeaderLine

func (*HeaderLine) Layout

func (h *HeaderLine) Layout(gtx layout.Context, peek Line) layout.Dimensions

func (*HeaderLine) Matches

func (h *HeaderLine) Matches(anchor string, re *regexp.Regexp) bool

type ImageFrame

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

func NewImageFrame

func NewImageFrame(th *Theme, reader io.Reader, w *app.Window) *ImageFrame

func (*ImageFrame) Events

func (imgf *ImageFrame) Events() []interface{}

func (*ImageFrame) Find

func (imgf *ImageFrame) Find(anchor string) error

func (*ImageFrame) IsEmpty

func (imgf *ImageFrame) IsEmpty() bool

func (*ImageFrame) Layout

func (imgf *ImageFrame) Layout(gtx layout.Context) layout.Dimensions

func (*ImageFrame) Title added in v0.2.0

func (imgf *ImageFrame) Title() string

type Line

type Line interface {
	Layout(gtx layout.Context, peek Line) layout.Dimensions
	Matches(anchor string, re *regexp.Regexp) bool
}

type LinkEvent

type LinkEvent struct {
	Link string
}

type LinkLine

type LinkLine struct {
	parse.Token
	// contains filtered or unexported fields
}

func LinkLineInit

func LinkLineInit(tkn parse.Token, st *SuperTxtFrame, th *Theme) *LinkLine

func (*LinkLine) Layout

func (l *LinkLine) Layout(gtx layout.Context, peek Line) layout.Dimensions

func (*LinkLine) Matches

func (l *LinkLine) Matches(anchor string, re *regexp.Regexp) bool

type LoadedEvent added in v0.2.3

type LoadedEvent Viewer

type ParaLine

type ParaLine struct {
	parse.Token
	// contains filtered or unexported fields
}

func ParaLineInit

func ParaLineInit(tkn parse.Token, th *Theme) *ParaLine

func (*ParaLine) Layout

func (p *ParaLine) Layout(gtx layout.Context, peek Line) layout.Dimensions

func (*ParaLine) Matches

func (p *ParaLine) Matches(anchor string, re *regexp.Regexp) bool

type PointLine

type PointLine struct {
	parse.Token
	// contains filtered or unexported fields
}

func PointLineInit

func PointLineInit(tkn parse.Token, th *Theme, w *app.Window) *PointLine

func (*PointLine) Layout

func (p *PointLine) Layout(gtx layout.Context, peek Line) layout.Dimensions

func (*PointLine) Matches

func (p *PointLine) Matches(anchor string, re *regexp.Regexp) bool

type PreformattedLine

type PreformattedLine struct {
	parse.Token
	// contains filtered or unexported fields
}

func PreformattedLineInit

func PreformattedLineInit(tkn parse.Token, st *SuperTxtFrame, th *Theme, w *app.Window) *PreformattedLine

func (*PreformattedLine) Layout

func (p *PreformattedLine) Layout(gtx layout.Context, peek Line) layout.Dimensions

func (*PreformattedLine) Matches

func (p *PreformattedLine) Matches(anchor string, re *regexp.Regexp) bool

type QuoteLine

type QuoteLine struct {
	parse.Token
	// contains filtered or unexported fields
}

func QuoteLineInit

func QuoteLineInit(tkn parse.Token, th *Theme) *QuoteLine

func (*QuoteLine) Layout

func (q *QuoteLine) Layout(gtx layout.Context, peek Line) layout.Dimensions

func (*QuoteLine) Matches

func (q *QuoteLine) Matches(anchor string, re *regexp.Regexp) bool

type ResolveLabelEvent added in v0.2.3

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

type SuperTxtFrame

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

func NewSuperTxtFrame

func NewSuperTxtFrame(th *Theme, reader io.Reader, w *app.Window) *SuperTxtFrame

func (*SuperTxtFrame) Events

func (f *SuperTxtFrame) Events() []interface{}

func (*SuperTxtFrame) Find

func (f *SuperTxtFrame) Find(anchor string) error

func (*SuperTxtFrame) IsEmpty

func (f *SuperTxtFrame) IsEmpty() bool

func (*SuperTxtFrame) Layout

func (f *SuperTxtFrame) Layout(gtx layout.Context) layout.Dimensions

func (*SuperTxtFrame) Title added in v0.2.0

func (f *SuperTxtFrame) Title() string

type SvgBobFrame added in v0.2.0

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

func NewSvgBobFrame added in v0.2.0

func NewSvgBobFrame(th *Theme, reader io.Reader, w *app.Window) *SvgBobFrame

func (*SvgBobFrame) Events added in v0.2.0

func (df *SvgBobFrame) Events() []interface{}

func (*SvgBobFrame) Find added in v0.2.0

func (df *SvgBobFrame) Find(anchor string) error

func (*SvgBobFrame) IsEmpty added in v0.2.0

func (df *SvgBobFrame) IsEmpty() bool

func (*SvgBobFrame) Layout added in v0.2.0

func (df *SvgBobFrame) Layout(gtx layout.Context) layout.Dimensions

func (*SvgBobFrame) Title added in v0.2.0

func (df *SvgBobFrame) Title() string

type SvgFrame added in v0.2.0

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

func NewSvgFrame added in v0.2.0

func NewSvgFrame(th *Theme, reader io.Reader, w *app.Window) *SvgFrame

func (*SvgFrame) Events added in v0.2.0

func (df *SvgFrame) Events() []interface{}

func (*SvgFrame) Find added in v0.2.0

func (df *SvgFrame) Find(anchor string) error

func (*SvgFrame) IsEmpty added in v0.2.0

func (df *SvgFrame) IsEmpty() bool

func (*SvgFrame) Layout added in v0.2.0

func (df *SvgFrame) Layout(gtx layout.Context) layout.Dimensions

func (*SvgFrame) Title added in v0.2.0

func (df *SvgFrame) Title() string

type TableFrame added in v0.2.3

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

func NewCSVFrame

func NewCSVFrame(th *Theme, reader io.Reader, w *app.Window) *TableFrame

func NewLTSVFrame added in v0.2.3

func NewLTSVFrame(th *Theme, reader io.Reader, w *app.Window) *TableFrame

func NewSWVFrame added in v0.2.3

func NewSWVFrame(th *Theme, reader io.Reader, w *app.Window) *TableFrame

func NewTSVFrame

func NewTSVFrame(th *Theme, reader io.Reader, w *app.Window) *TableFrame

func (*TableFrame) Events added in v0.2.3

func (f *TableFrame) Events() []interface{}

func (*TableFrame) Find added in v0.2.3

func (f *TableFrame) Find(anchor string) error

func (*TableFrame) IsEmpty added in v0.2.3

func (f *TableFrame) IsEmpty() bool

func (*TableFrame) Layout added in v0.2.3

func (f *TableFrame) Layout(gtx layout.Context) layout.Dimensions

func (*TableFrame) Title added in v0.2.3

func (f *TableFrame) Title() string

type Theme

type Theme struct {
	Sh           *text.Shaper
	ShMono       *text.Shaper
	ParaSz       unit.Sp
	HeadSz       unit.Sp
	QuotSz       unit.Sp
	SmallSz      unit.Sp
	BgColr       color.NRGBA
	ForeColr     color.NRGBA
	SelColr      color.NRGBA
	RaisedBgColr color.NRGBA
}

type TxtFrame

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

func NewTxtFrame

func NewTxtFrame(th *Theme, ext string, reader io.Reader, w *app.Window) *TxtFrame

func (*TxtFrame) Events

func (f *TxtFrame) Events() []interface{}

func (*TxtFrame) Find

func (f *TxtFrame) Find(anchor string) error

func (*TxtFrame) IsEmpty

func (f *TxtFrame) IsEmpty() bool

func (*TxtFrame) Layout

func (f *TxtFrame) Layout(gtx layout.Context) layout.Dimensions

func (*TxtFrame) Title added in v0.2.0

func (f *TxtFrame) Title() string

type Viewer

type Viewer interface {
	Layout(gtx layout.Context) layout.Dimensions
	Events() []interface{}
	IsEmpty() bool
	Find(string) error
	Title() string
}

func NewViewerForReader

func NewViewerForReader(th *Theme, ext string, reader io.Reader, w *app.Window) Viewer

Jump to

Keyboard shortcuts

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