uni-htk-2.2.1.3: Graphical User Interface for Haskell Programs

Safe HaskellNone
LanguageHaskell98

HTk.Widgets.ListBox

Description

HTk's listbox widget . A scrollable widget that displays a set of text lines with selection functionality.

Synopsis

Documentation

data ListBox a Source #

The ListBox datatype - parametrised over the type of the list elements.

Instances

Eq (ListBox a) Source # 

Methods

(==) :: ListBox a -> ListBox a -> Bool #

(/=) :: ListBox a -> ListBox a -> Bool #

Destroyable (ListBox a) Source #

A listbox widget can be destroyed.

Methods

destroy :: ListBox a -> IO () #

Synchronized (ListBox a) Source #

You can synchronize on a listbox object (in JAVA style).

Methods

synchronize :: ListBox a -> IO b -> IO b #

GUIObject (ListBox a) Source #

Internal.

HasEnable (ListBox a) Source #

A listbox is a stateful widget - it can be enabled or disabled.

HasGrid (ListBox a) Source # 
HasFont (ListBox a) Source #

You can specify the font of a listbox.

HasBorder (ListBox a) Source #

A listbox widget has a configureable border.

HasSize (ListBox a) Source #

You can specify the size of a listbox.

HasColour (ListBox a) Source #

A listbox widget has a foreground and background colour.

HasTooltip (ListBox a) Source #

A listbox can have a tooltip (only displayed if you are using tixwish).

Widget (ListBox a) Source #

A listbox widget has standard widget properties (concerning focus, cursor).

GUIValue a => CanBeSubwidget (ListBox a) Source # 
HasScroller (ListBox a) Source #

A listbox is a scrollable widget.

HasSelection (ListBox a) Source #

You can select entries inside a listbox widget.

Methods

clearSelection :: ListBox a -> IO () Source #

HasXSelection (ListBox a) Source #

A listbox widget has an X selection.

HasIndex (ListBox a) i Int => HasBBox (ListBox a) i Source #

You can find out the bounding box of a list box element.

HasSelectionBaseIndexRange (ListBox a) Int Source #

You can select a range of entries inside a listbox widget.

HasIndex (ListBox a) i Int => HasSelectionIndex (ListBox a) i Source #

A listbox'es entries are selectable.

Methods

selection :: i -> Config (ListBox a) Source #

isSelected :: ListBox a -> i -> IO Bool Source #

(HasIndex (ListBox a) i1 Int, HasIndex (ListBox a) i2 Int) => HasSelectionIndexRange (ListBox a) i1 i2 Source #

You can select a range of elements inside a listbox widget.

Methods

selectionRange :: i1 -> i2 -> Config (ListBox a) Source #

HasIndex (ListBox a) Pixels Int Source #

A position in pixels is a valid index position inside an editor widget.

HasIndex (ListBox a) EndOfText Int Source #

The EndOfText index is a valid index position inside a listbox widget.

HasIndex (ListBox a) Int Int Source #

An integer value is a valid index position inside a listbox widget.

Methods

getBaseIndex :: ListBox a -> Int -> IO Int Source #

(Eq a, GUIValue a, GUIValue [a]) => HasIndex (ListBox a) Int (ListBoxElem a) Source #

Internal.

Methods

getBaseIndex :: ListBox a -> Int -> IO (ListBoxElem a) Source #

(GUIValue a, GUIValue [a]) => HasValue (ListBox a) [a] Source #

The value of a listbox is the list of the displayed objects (these are instances of class GUIValue and therefore instances of class Show).

Methods

value :: [a] -> Config (ListBox a) Source #

getValue :: ListBox a -> IO [a] Source #

HasSelectionBaseIndex (ListBox a) [Int] Source #

You can select a range of elements inside a listbox widget.

Methods

getSelection :: ListBox a -> IO (Maybe [Int]) Source #

(Eq a, GUIValue a) => HasIndex (ListBox [a]) (ListBoxElem a) Int Source #

A listbox element is a valid index position inside an editor widget.

Methods

getBaseIndex :: ListBox [a] -> ListBoxElem a -> IO Int Source #

newListBox Source #

Arguments

:: (Container par, GUIValue a) 
=> par

the parent widget, which has to be a container widget (an instance of class Container).

-> [Config (ListBox a)]

the list of configuration options for this listbox widget.

-> IO (ListBox a)

A listbox widget.

Constructs a new listbox widget and returns a handler.

selectMode Source #

Arguments

:: GUIValue a 
=> SelectMode

the select mode to set.

-> ListBox a

the concerned listbox.

-> IO (ListBox a)

The concerned listbox.

Sets the select mode of a listbox.

getSelectMode Source #

Arguments

:: GUIValue a 
=> ListBox a

the concerned listbox.

-> IO SelectMode

The current select mode.

Gets the set select mode from a listbox.

activateElem Source #

Arguments

:: HasIndex (ListBox a) i Int 
=> ListBox a

the concerned listbox.

-> i

the index of the line to activate.

-> IO ()

Nothing.

Activates the specified line.

selectionAnchor Source #

Arguments

:: HasIndex (ListBox a) i Int 
=> ListBox a

the concerned listbox.

-> i

the index of the line to anchor the selection at.

-> IO ()

Nothing.

Anchors the selection at the specified line.

data Eq a => ListBoxElem a Source #

The ListBoxElem datatype.

Constructors

ListBoxElem a 

Instances

Eq a => Eq (ListBoxElem a) Source # 
(Eq a, GUIValue a, GUIValue [a]) => HasIndex (ListBox a) Int (ListBoxElem a) Source #

Internal.

Methods

getBaseIndex :: ListBox a -> Int -> IO (ListBoxElem a) Source #

(Eq a, GUIValue a) => HasIndex (ListBox [a]) (ListBoxElem a) Int Source #

A listbox element is a valid index position inside an editor widget.

Methods

getBaseIndex :: ListBox [a] -> ListBoxElem a -> IO Int Source #