ui

package
v0.9.5 Latest Latest
Warning

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

Go to latest
Published: Mar 8, 2026 License: MIT Imports: 13 Imported by: 0

Documentation

Index

Constants

View Source
const SystrayIcon = "notifiarr.png"

SystrayIcon is the icon in the system tray or task bar.

View Source
const ToastIcon = "notifiarr.png"

ToastIcon is the icon in the menu bar.

Variables

This section is empty.

Functions

func CreateStartupLink(_ context.Context) (bool, string, error)
func DeleteStartupLink() (string, error)

func Entry

func Entry(msg, val string) (string, bool, error)

Entry wraps zenity.Entry. Returns the entry text and true if ok is clicked.

func Error

func Error(msg string)

Error wraps zenity.Error.

func GetPNG added in v0.8.1

func GetPNG() string

GetPNG purposely returns an empty string when there is no verified file. This is used to give the toast notification an icon. Do not throw errors if the icon is missing, it's nbd, just return empty "".

func HasGUI

func HasGUI() bool

HasGUI returns true on Linux if USEGUI env var is true.

func HasStartupLink() (string, bool)

func Info

func Info(msg string)

Info wraps zenity.Info.

func OpenCmd

func OpenCmd(ctx context.Context, cmd ...string) error

OpenCmd opens anything.

func OpenFile

func OpenFile(ctx context.Context, filePath string) error

OpenFile open Config Files.

func OpenLog

func OpenLog(ctx context.Context, logFile string) error

OpenLog opens Log Files.

func OpenURL

func OpenURL(ctx context.Context, url string) error

OpenURL opens URL Links.

func Question

func Question(text string, defaultCancel bool) (bool, error)

Question wraps zenity.Question. Returns true if yes or ok is clicked.

func StartCmd

func StartCmd(ctx context.Context, command string, args ...string) error

StartCmd starts a command.

func Toast added in v0.8.1

func Toast(_ context.Context, msg string, v ...any) error

func Warning

func Warning(msg string)

Warning wraps dlgs.Warning.

Types

This section is empty.

Jump to

Keyboard shortcuts

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