40 lines
659 B
C++
40 lines
659 B
C++
#ifndef MATRIX_H
|
|
#define MATRIX_H
|
|
|
|
#include <gtkmm.h>
|
|
#include <list>
|
|
#include "rect.h"
|
|
#include "colour.h"
|
|
|
|
typedef std::list<Base *> BaseList;
|
|
|
|
class Matrix : public Gtk::DrawingArea
|
|
{
|
|
private:
|
|
int m_client_width;
|
|
int m_client_height;
|
|
int m_port_width;
|
|
int m_port_height;
|
|
int m_separation;
|
|
int m_width;
|
|
int m_height;
|
|
|
|
BaseList across;
|
|
BaseList down;
|
|
|
|
public:
|
|
Matrix();
|
|
virtual ~Matrix();
|
|
|
|
void Refresh();
|
|
|
|
Gtk::Window *parent;
|
|
|
|
protected:
|
|
void Box(Cairo::RefPtr<Cairo::Context> cr, Colour &c, Rect &rect);
|
|
virtual bool on_expose_event(GdkEventExpose *event);
|
|
virtual bool on_button_press_event(GdkEventButton *event);
|
|
};
|
|
|
|
#endif // MATRIX_H
|