author | alpar |
Thu, 14 Jul 2005 12:23:15 +0000 | |
changeset 1557 | 3e8d928e283d |
parent 1512 | e54392395480 |
child 1586 | 1a8630f2e944 |
permissions | -rw-r--r-- |
ladanyi@1442 | 1 |
// -*- C++ -*- // |
ladanyi@1442 | 2 |
|
ladanyi@1442 | 3 |
#ifndef MAP_WIN_H |
ladanyi@1442 | 4 |
#define MAP_WIN_H |
ladanyi@1442 | 5 |
|
hegyi@1512 | 6 |
class MapWin; |
hegyi@1512 | 7 |
|
ladanyi@1442 | 8 |
#include <all_include.h> |
ladanyi@1442 | 9 |
#include <mapstorage.h> |
ladanyi@1442 | 10 |
#include <graph_displayer_canvas.h> |
ladanyi@1442 | 11 |
#include <libgnomecanvasmm.h> |
ladanyi@1442 | 12 |
#include <libgnomecanvasmm/polygon.h> |
ladanyi@1442 | 13 |
|
ladanyi@1442 | 14 |
///This class is responsible for creating a window, |
ladanyi@1442 | 15 |
///on which the visualization attributes can be |
ladanyi@1442 | 16 |
///assigned to maps. |
ladanyi@1442 | 17 |
class MapWin : public Gtk::Window |
ladanyi@1442 | 18 |
{ |
ladanyi@1442 | 19 |
protected: |
ladanyi@1442 | 20 |
///The \ref GraphDisplayerCanvas on which the graph will be drawn. |
ladanyi@1442 | 21 |
///It has to be known for this class, because |
ladanyi@1442 | 22 |
///when a map assigned to a certain attribute |
ladanyi@1442 | 23 |
///a function of the \ref GraphDisplayerCanvas will be called. |
ladanyi@1442 | 24 |
GraphDisplayerCanvas & gdc; |
ladanyi@1442 | 25 |
|
ladanyi@1442 | 26 |
///The \ref MapStorage in which the visualizable maps are stored |
ladanyi@1442 | 27 |
MapStorage & ms; |
ladanyi@1442 | 28 |
|
hegyi@1512 | 29 |
Gtk::Table * table; |
ladanyi@1442 | 30 |
|
hegyi@1512 | 31 |
Gtk::Combo * e_combo_array, * n_combo_array; |
ladanyi@1442 | 32 |
|
hegyi@1446 | 33 |
Gtk::Label * label; |
ladanyi@1442 | 34 |
|
hegyi@1512 | 35 |
Gtk::VBox vbox; |
hegyi@1512 | 36 |
|
ladanyi@1442 | 37 |
public: |
ladanyi@1442 | 38 |
///Constructor of MapWin creates the widgets shown in MapWin. |
ladanyi@1442 | 39 |
MapWin(const std::string& title, MapStorage &, GraphDisplayerCanvas &); |
ladanyi@1442 | 40 |
|
ladanyi@1442 | 41 |
///If a radiobutton is clicked, this function determines |
ladanyi@1442 | 42 |
///which button was that and after that calls the |
ladanyi@1442 | 43 |
///appropriate function of the \ref GraphDisplayerCanvas |
ladanyi@1442 | 44 |
///to change the visible values of that attribute. |
hegyi@1524 | 45 |
virtual void eComboChanged(int); |
hegyi@1512 | 46 |
///If a radiobutton is clicked, this function determines |
hegyi@1512 | 47 |
///which button was that and after that calls the |
hegyi@1512 | 48 |
///appropriate function of the \ref GraphDisplayerCanvas |
hegyi@1512 | 49 |
///to change the visible values of that attribute. |
hegyi@1524 | 50 |
virtual void nComboChanged(int); |
hegyi@1512 | 51 |
|
hegyi@1512 | 52 |
///This function is created to set the appropriate maps on the newly created node |
hegyi@1524 | 53 |
void updateNode(Graph::Node); |
hegyi@1512 | 54 |
|
hegyi@1512 | 55 |
///This function is created to set the appropriate maps on the newly created edge |
hegyi@1524 | 56 |
void updateEdge(Graph::Edge); |
hegyi@1512 | 57 |
|
hegyi@1524 | 58 |
virtual bool closeIfEscapeIsPressed(GdkEventKey*); |
ladanyi@1442 | 59 |
}; |
ladanyi@1442 | 60 |
|
ladanyi@1442 | 61 |
#endif //MAP_WIN_H |