lab 6 start
This commit is contained in:
43
Lab6/line.h
Normal file
43
Lab6/line.h
Normal file
@@ -0,0 +1,43 @@
|
||||
#ifndef line_h
|
||||
#define line_h
|
||||
/**
|
||||
* @file line.h
|
||||
* @author Trevor Barnes (barnestr@msoe.edu)
|
||||
* @brief
|
||||
* @version 1.0
|
||||
* @date 2022-04-12
|
||||
*
|
||||
* @copyright Copyright (c) 2022
|
||||
*
|
||||
*/
|
||||
|
||||
#include "shape.h"
|
||||
|
||||
class ViewContext;
|
||||
|
||||
class Line: public Shape{
|
||||
public:
|
||||
// Line constructor
|
||||
Line(int x0, int y0, int x1, int y1, uint32_t color);
|
||||
|
||||
// Line copy constructor
|
||||
Line(const Line& from);
|
||||
|
||||
// Line destructor
|
||||
~Line();
|
||||
|
||||
// Line assignment operator
|
||||
Line& operator=(const Line& rhs);
|
||||
|
||||
// Draw function
|
||||
void draw(GraphicsContext *gc, const ViewContext* vc);
|
||||
|
||||
// Outputs line data to os
|
||||
void out(std::ostream& os) const;
|
||||
|
||||
// Clones a line
|
||||
Shape* clone();
|
||||
|
||||
};
|
||||
|
||||
#endif
|
||||
Reference in New Issue
Block a user