# ipeqt::Tool Class Reference
[Ipe Qt canvas]

Abstract base class for various canvas tools. More...

`#include <ipetool.h>`

Inherited by ipeqt::PanTool, ipeqt::SelectTool, and ipeqt::TransformTool.

List of all members.

## Public Member Functions

- virtual ~Tool ()
- virtual void draw (Painter &painter) const =0
- virtual void mouseButton (int button, bool press)
- virtual void mouseMove (int button)
- virtual bool key (int code, int modifiers, String text)

## Protected Member Functions

- Tool (Canvas *canvas)

## Protected Attributes

- Canvas * iCanvas

## Detailed Description

Abstract base class for various canvas tools.

The Canvas doesn't know about the various modes for object creation, editing, and moving, but delegates the handling to a subclass of Tool.

## Constructor & Destructor Documentation

Tool::~Tool | ( |  | ) | `[virtual]`

Virtual destructor.

Tool::Tool | ( | Canvas * | canvas | ) | `[protected]`

Constructor.

## Member Function Documentation

virtual void ipeqt::Tool::draw | ( | Painter & | painter | ) | const`[pure virtual]`

Implemented in ipeqt::PanTool, ipeqt::SelectTool, and ipeqt::TransformTool.

void Tool::mouseButton | ( | int | button,
|  | bool | press |
| ) |  |  | `[virtual]`

Reimplemented in ipeqt::PanTool, ipeqt::SelectTool, and ipeqt::TransformTool.

void Tool::mouseMove | ( | int | button | ) | `[virtual]`

Reimplemented in ipeqt::PanTool, ipeqt::SelectTool, and ipeqt::TransformTool.

bool Tool::key | ( | int | code,
|  | int | modifiers,
|  | String | text |
| ) |  |  | `[virtual]`

Reimplemented in ipeqt::SelectTool.

## Member Data Documentation

Canvas* ipeqt::Tool::iCanvas `[protected]`

The documentation for this class was generated from the following files:

- ipetool.h
- ipetool.cpp