Bruno Postle > Draft-0.06 > Draft::TkGui

Download:
Draft-0.06.tar.gz

Dependencies

Annotate this POD

View/Report Bugs
Source  

NAME ^

Draft::TkGui - Display a Draft world

SYNOPSIS ^

Opens a Tk GUI window, displays a drawing and allows some user interaction.

DESCRIPTION ^

This module knows a little bit about Draft drawings and displays them on screen using TK::WorldCanvas which takes care of all the drawing, panning etc..

This module is a sub-class of Tk::WorldCanvas and so inherits all Tk::Canvas methods.

USAGE ^

Create a Draft::TkGui object like so:

  my $canvas = Draft::TkGui->new;

This should show a window and display the drawing, some interaction is possible:

You can redraw the canvas window like so:

  $canvas->Draw;

This scans all drawing elements and updates the display with any changes. No files are accessed unnecessarily, so feel free to call this method as often as you like; by default this method is called whenever a mouse pointer enters the canvas area.

syntax highlighting: