#include<CNCL/EZDWindow>
CN_EZDWINDOW
BASE CLASSES
EZD
None
EZDDrawing, EZDObject, EZDPushButton
With EZD a drawing can only be displayed when it is mapped into a window. For
this, EZDWindow
creates named windows and maps drawings into it.
The window is always displayed in the upper left corner of the
screen and is w_width
pixels wide and w_heigth
pixels
high. The background color is white and the foreground color is black.
Note: If the named window already exists, the old window is deleted.
Windows are only visible if drawings are displayed in them.
Constructors:
EZDWindow();
EZDWindow(CNParam *param);
EZDWindow(int w, int h);
EZDWindow(int x, int y, int w, int h);
EZDWindow(const CNString &name, int w, int h);
EZDWindow(const CNString &name, int x, int y, int w, int h);
EZDWindow(const CNString &name, const CNString &title, int w, int h)
EZDWindow(const CNString &name, const CNString &title, int x, int y, int w, int h);
name
(default: "win") with the title
title
(default setting equals name
). The window is
w
pixels wide (default: 200) and h
pixels high (default:
200). It is positioned at the coordinates (x,y)
(default: (-1,-1)).
Destructor:
~EZDWindow();
In addition to the member functions required by CNCL, EZDWindow
provides:
int heigth() const;
int width() const;
int wherex() const;
int wherey() const;
void overlay(EZDDrawing *d);
void underlay(EZDDrawing *d);
d
over the existing drawings in the
current window.
void scale_drawing(EZDDrawing *draw, const int origin_x, const int origin_y,
const float d_scale_x, const float d_scale_y, const int scale_linewidth);
draw
with a cartesian coordinate system onto the
current window. The origin_(x,y)
parameters specifie the size of
the origin coordinate system, d_scale_(x,y)
and
scale_linewidth
are the scaling factors.
void set_zoom(EZDDrawing *, const float factor);
factor
.
void set_norm(EZDDrawing *);
void set_auto_resize(const int nargs, EZDDrawing * ...);
nargs
is the number of arguments.
void delete_drawing(EZDDrawing *d);
d
in the current window.
void print_window(const CNString &filename);
Go to the first, previous, next, last section, table of contents.