The module CanvasItem
exports basic classes and
general functionality on canvas items.
- data Canvas
- class HasCoords w where
- class GUIObject w => CanvasItem w
- class CanvasItem w => FilledCanvasItem w where
- filling :: ColourDesignator c => c -> Config w
- getFilling :: w -> IO Colour
- outline :: ColourDesignator c => c -> Config w
- getOutline :: w -> IO Colour
- stipple :: BitMapHandle -> Config w
- getStipple :: w -> IO BitMapHandle
- outlinewidth :: Distance -> Config w
- getOutlineWidth :: w -> IO Distance
- class CanvasItem w => SegmentedCanvasItem w where
- moveItem :: (Synchronized w, CanvasItem w) => w -> Distance -> Distance -> IO ()
- scaleItem :: (Synchronized w, CanvasItem w) => w -> Distance -> Distance -> Double -> Double -> IO ()
- raiseItem :: (CanvasItem ci, CanvasItem w) => ci -> w -> IO ()
- lowerItem :: (CanvasItem ci, CanvasItem w) => ci -> w -> IO ()
- putItemOnTop :: CanvasItem w => w -> IO ()
- putItemAtBottom :: CanvasItem ci => ci -> IO ()
- itemsNotOnSameCanvas :: IOError
- declVar :: CanvasTagOrID -> TclScript
- declVarList :: CanvasTagOrID -> TclCmd
Documentation
The Canvas
datatype.
Eq Canvas | |
Destroyable Canvas | A canvas widget can be destroyed. |
Synchronized Canvas | You can synchronize on a canvas object (in JAVA style). |
GUIObject Canvas | Internal. |
HasEnable Canvas | A canvas widget is a stateful widget, it can be enabled or disabled. |
HasBorder Canvas | A canvas widget has a configureable border. |
HasSize Canvas | You can specify the size of a canvas. |
HasColour Canvas | A canvas widget has a foreground and background colour. |
HasTooltip Canvas | A canvas can have a tooltip (only displayed if you are using tixwish). |
Widget Canvas | A canvas widget has standard widget properties (concerning focus, cursor). |
HasPostscript Canvas | The contents of a canvas is printable. |
Container Canvas | A canvas is also a container for widgets, because it can contain widgets in embedded windows. |
HasScroller Canvas | A canvas is a scrollable widget. |
GUIObject c => HasBBox Canvas c | You can request the bounding box size of a canvas item (use a canvas tag for the bounding box of a set of items). |
You can set the coords (position / size) of a canvas item on the parent canvas.
CanvasItem w => HasCoords w | Any canvas item has coords on the parent canvas. |
class GUIObject w => CanvasItem w Source
Any canvas item is an instance of the abstract
class CanvasItem
.
CanvasItem CanvasTag | A canvas tag is a canvas item (any canvas item is an instance of the
abstract |
CanvasItem Arc | An arc is a canvas item (any canvas item is an instance of the abstract
|
CanvasItem BitMapItem | A bitmap item is a canvas item (any canvas item is an instance of the
abstract |
CanvasItem ImageItem | An image item is a canvas item (any canvas item is an instance of the
abstract |
CanvasItem Line | A line item is a canvas item (any canvas item is an instance of the
abstract |
CanvasItem Oval | An oval item is a canvas item (any canvas item is an instance of the
abstract |
CanvasItem Polygon | A polygon item is a canvas item (any canvas item is an instance of the
abstract |
CanvasItem Rectangle | A rectangle item is a canvas item (any canvas item is an instance of
the abstract |
CanvasItem TextItem | A text item is a canvas item (any canvas item is an instance of the
abstract |
CanvasItem EmbeddedCanvasWin | An embedded canvas window is a canvas item (any canvas item is an
instance of the abstract |
class CanvasItem w => FilledCanvasItem w whereSource
Any canvas item has a filling, outline, outline width and stipple configuration.
filling :: ColourDesignator c => c -> Config wSource
getFilling :: w -> IO ColourSource
outline :: ColourDesignator c => c -> Config wSource
getOutline :: w -> IO ColourSource
stipple :: BitMapHandle -> Config wSource
getStipple :: w -> IO BitMapHandleSource
outlinewidth :: Distance -> Config wSource
getOutlineWidth :: w -> IO DistanceSource
FilledCanvasItem Arc | An arc is a filled canvas item (it has filling, outline, outline width, and stipple configurations). |
FilledCanvasItem BitMapItem | A bitmap item is a filled canvas item (it has filling, outline, outline width, and stipple configurations). |
FilledCanvasItem Line | A line item has filling, outline width and stipple configurations. |
FilledCanvasItem Oval | An oval item is a filled canvas item (it has filling, outline, outline width, and stipple configurations). |
FilledCanvasItem Polygon | A polygon item is a filled canvas item (it has filling, outline, outline width, and stipple configurations). |
FilledCanvasItem Rectangle | A rectangle item is a filled canvas item (it has filling, outline, outline width, and stipple configurations). |
FilledCanvasItem TextItem | An oval item is a filled canvas item (it has filling, outline width, and stipple configurations). |
class CanvasItem w => SegmentedCanvasItem w whereSource
Segmented canvas items have a splinesteps and smooth configuration.
splinesteps :: Int -> Config wSource
getSplinesteps :: w -> IO IntSource
SegmentedCanvasItem Line | A line is a segmented canvas item. It has a splinesteps and smooth configuration. |
SegmentedCanvasItem Polygon | A line is a segmented canvas item. It has a splinesteps and smooth configuration. |
moveItem :: (Synchronized w, CanvasItem w) => w -> Distance -> Distance -> IO ()Source
Moves a canvas item horizontally and vertically by the given distances.
scaleItem :: (Synchronized w, CanvasItem w) => w -> Distance -> Distance -> Double -> Double -> IO ()Source
Scales a canvas item horizontally and vertically by the given distances.
raiseItem :: (CanvasItem ci, CanvasItem w) => ci -> w -> IO ()Source
Moves an item above another item in the display list.
lowerItem :: (CanvasItem ci, CanvasItem w) => ci -> w -> IO ()Source
Moves an item below another item in the display list.
putItemOnTop :: CanvasItem w => w -> IO ()Source
Puts an item on top of the display list.
putItemAtBottom :: CanvasItem ci => ci -> IO ()Source
Puts an items at bottom of the display list.
itemsNotOnSameCanvas :: IOErrorSource
Exception raised by CanasItem.onSameCanvas
.
declVar :: CanvasTagOrID -> TclScriptSource
Retrieve all tagnames in a complex tag expression and declare them global in form of a TclScript
declVarList :: CanvasTagOrID -> TclCmdSource
Retrieve all tagnames in a complex tag expression and declare them global in form of a TclCmd