taffybar-2.1.1: A desktop bar similar to xmobar, but with more GUI

Safe HaskellNone
LanguageHaskell2010

System.Taffybar.Widget

Contents

Synopsis

Documentation

System.Taffybar.Widget.Battery

System.Taffybar.Widget.CPUMonitor

cpuMonitorNew Source #

Arguments

:: MonadIO m 
=> GraphConfig

Configuration data for the Graph.

-> Double

Polling period (in seconds).

-> String

Name of the core to watch (e.g. "cpu", "cpu0").

-> m Widget 

Creates a new CPU monitor. This is a PollingGraph fed by regular calls to getCPUInfo, associated to an IORef used to remember the values yielded by the last call to this function.

System.Taffybar.Widget.CommandRunner

commandRunnerNew Source #

Arguments

:: MonadIO m 
=> Double

Polling period (in seconds).

-> String

Command to execute. Should be in $PATH or an absolute path

-> [String]

Command argument. May be []

-> String

If command fails this will be displayed.

-> m Widget 

Creates a new command runner widget. This is a PollingLabel fed by regular calls to command given by argument. The results of calling this function are displayed as string.

System.Taffybar.Widget.Decorators

System.Taffybar.Widget.DiskIOMonitor

dioMonitorNew Source #

Arguments

:: MonadIO m 
=> GraphConfig

Configuration data for the Graph.

-> Double

Polling period (in seconds).

-> String

Name of the disk or partition to watch (e.g. "sda", "sdb1").

-> m Widget 

Creates a new disk IO monitor widget. This is a PollingGraph fed by regular calls to getDiskTransfer. The results of calling this function are normalized to the maximum value of the obtained probe (either read or write transfer).

System.Taffybar.Widget.FSMonitor

fsMonitorNew Source #

Arguments

:: MonadIO m 
=> Double

Polling interval (in seconds, e.g. 500)

-> [String]

Names of the partitions to monitor (e.g. ["/", "/home"])

-> m Widget 

Creates a new filesystem monitor widget. It contains one PollingLabel that displays the data returned by the df command. The usage level of all requested partitions is extracted in one single operation.

System.Taffybar.Widget.FreedesktopNotifications

data NotificationConfig Source #

Constructors

NotificationConfig 

Fields

defaultNotificationConfig :: NotificationConfig Source #

The default formatter is one of * Summary : Body * Summary * (N) Summary : Body * (N) Summary depending on the presence of a notification body, and where N is the number of queued notifications.

notifyAreaNew :: MonadIO m => NotificationConfig -> m Widget Source #

Create a new notification area with the given configuration.

System.Taffybar.Widget.Layout

layoutNew :: LayoutConfig -> TaffyIO Widget Source #

Create a new Layout widget that will use the given Pager as its source of events.

System.Taffybar.Widget.MPRIS2

System.Taffybar.Widget.NetworkGraph

System.Taffybar.Widget.SNITray

System.Taffybar.Widget.SimpleClock

textClockNew :: MonadIO m => Maybe TimeLocale -> String -> Double -> m Widget Source #

Create the widget. I recommend passing Nothing for the TimeLocale parameter. The format string can include Pango markup (http:/developer.gnome.orgpangostablePangoMarkupFormat.html).

textClockNewWith :: MonadIO m => ClockConfig -> String -> Double -> m Widget Source #

A configurable text-based clock widget. It currently allows for a configurable time zone through the ClockConfig.

See also textClockNew.

defaultClockConfig :: ClockConfig Source #

A clock configuration that defaults to the current locale

System.Taffybar.Widget.Text.CPUMonitor

System.Taffybar.Widget.Text.MemoryMonitor

System.Taffybar.Widget.Text.NetworkMonitor

System.Taffybar.Widget.Weather

data WeatherConfig Source #

The configuration for the weather widget. You can provide a custom format string through weatherTemplate as described above, or you can provide a custom function to turn a WeatherInfo into a String via the weatherFormatter field.

Constructors

WeatherConfig 

Fields

data WeatherFormatter Source #

A wrapper to allow users to specify a custom weather formatter. The default interpolates variables into a string as described above. Custom formatters can do basically anything.

Constructors

WeatherFormatter (WeatherInfo -> String)

Specify a custom formatter for WeatherInfo

weatherNew Source #

Arguments

:: WeatherConfig

Configuration to render

-> Double

Polling period in _minutes_

-> IO Widget 

Create a periodically-updating weather widget that polls NOAA.

weatherCustomNew Source #

Arguments

:: MonadIO m 
=> IO (Either String WeatherInfo)

Weather querying action

-> String

Weather template

-> String

Weather template

-> WeatherFormatter

Weather formatter

-> Double

Polling period in _minutes_

-> m Widget 

Create a periodically-updating weather widget using custom weather getter

defaultWeatherConfig :: String -> WeatherConfig Source #

A sensible default configuration for the weather widget that just renders the temperature.

System.Taffybar.Widget.Windows

windowsNew :: WindowsConfig -> TaffyIO Widget Source #

Create a new Windows widget that will use the given Pager as its source of events.

data WindowsConfig Source #

Constructors

WindowsConfig 

Fields

System.Taffybar.Widget.Workspaces

System.Taffybar.Widget.XDGMenu.MenuWidget