Drawing Program
Lab 02 Core Exercise HIT3172
 All Classes Functions Variables
Public Member Functions | List of all members
Line Class Reference

#include <Line.h>

Inheritance diagram for Line:
Shape

Public Member Functions

void draw ()
void highlight ()
- Public Member Functions inherited from Shape
 Shape ()
color get_color ()
color get_highlight_color ()
point2d get_position ()
int get_width ()
int get_height ()
float get_x ()
float get_y ()
void set_color (color)
void set_highlight_color (color)
void set_position (point2d)
void set_width (int)
void set_height (int)
void set_x (float)
void set_y (float)
bool is_at (point2d)

Additional Inherited Members

- Protected Member Functions inherited from Shape
void calculate_highlight_color ()
- Protected Attributes inherited from Shape
color _color
color _highlight_color
point2d _position
int _width
int _height

Detailed Description

Line class holds all logic to creating and drawing lines to the Drawing, and inherits basic attributes and methods from the Shape class

Member Function Documentation

void Line::draw ( )
virtual

This method draws a diagonal line to the screen using the Shape's attributes

Implements Shape.

void Line::highlight ( )
virtual

This method draws crosses at each end of the line

Implements Shape.


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