Forgot the meat.
3 * This file is a part of LEMON, a generic C++ optimization library
5 * Copyright (C) 2003-2006
6 * Egervary Jeno Kombinatorikus Optimalizalasi Kutatocsoport
7 * (Egervary Research Group on Combinatorial Optimization, EGRES).
9 * Permission to use, modify and distribute this software is granted
10 * provided that this copyright notice appears in all copies. For
11 * precise terms see the accompanying LICENSE file.
13 * This software is provided "AS IS" with no warranty of any kind,
14 * express or implied, and with no claim as to its suitability for any
24 #include <all_include.h>
26 #include <mapselector.h>
27 #include <libgnomecanvasmm.h>
28 #include <libgnomecanvasmm/polygon.h>
30 ///Graph visualization setup window.
32 ///This class is responsible for creating a window,
33 ///on which the visualization attributes can be
35 class MapWin : public Gtk::Window
38 ///\ref NoteBookTab to that the \ref MapWin belongs to.
44 ///\ref MapSelectors for each property
46 ///Each property has an own \ref MapSelector through which
47 ///the map to visualize by the property van be set.
48 MapSelector ** e_combo_array;
50 ///\ref MapSelectors for each property
52 ///Each property has an own \ref MapSelector through which
53 ///the map to visualize by the property van be set.
54 MapSelector ** n_combo_array;
59 ///Container in which elements are organized.
65 ///It creates the widgets shown in \ref MapWin and
66 ///binds the needed signal to the correct place.
67 ///\param title title of window
68 ///\param eml edgemap list
69 ///\param nml nodemap list
70 ///\param mw the owner \ref NoteBookTab (\ref mytab)
71 MapWin(const std::string& title, std::vector<std::string> eml, std::vector<std::string> nml, NoteBookTab & mw);
73 ///Deregistrates \ref MapWin in its \ref NoteBookTab (\ref mytab)
74 virtual bool on_delete_event(GdkEventAny *);
76 ///Handles changement in nodemap selection
78 ///If \ref MapSelector emits a signal that indicates
79 ///changement in nodemap selection this function will
80 ///be called. It calls the appropriate handler function,
81 ///\ref NoteBookTab::propertyChange with parameters describing the changement.
82 ///\param mapname the recently selected map
83 ///\param prop the changed property
84 void nodeMapChanged(std::string mapname, int prop);
86 ///Handles changement in edgemap selection
88 ///If \ref MapSelector emits a signal that indicates
89 ///changement in edgemap selection this function will
90 ///be called. It calls the appropriate handler function,
91 ///\ref NoteBookTab::propertyChange with parameters describing the changement.
92 ///\param mapname the recently selected map
93 ///\param prop the changed property
94 void edgeMapChanged(std::string mapname, int prop);
96 ///Indicates to the owner \ref NoteBookTab that a \ref NewMapWin should be opened.
98 ///This function is bound to the
99 ///signal emitted by the \ref MapSelector in case of
100 ///the user wants to create a new map. It only pass the
101 ///information further to the tab owning this \ref MapWin that is needed to open the
102 ///\ref NewMapWin. (\ref NoteBookTab::popupNewMapWin)
103 ///\param itisedge should the new map will be an edgemap? (or nodemap)
104 void newMapWinNeeded(bool itisedge);
106 ///This function inserts name of the new edgemap in the name list in \ref MapSelector s
110 void registerNewEdgeMap(std::string new_name);
112 ///This function inserts name of the new nodemap in the name list in \ref MapSelector s
116 void registerNewNodeMap(std::string new_name);
118 ///Close window if Esc key pressed.
119 virtual bool closeIfEscapeIsPressed(GdkEventKey*);
121 ///Updates list of maps in all \ref MapSelector
123 ///This function is called by \ref NoteBookTab, when the file
124 ///showed in it has changed, therefore the contained maps
125 ///have changed as well. \ref NoteBookTab knows, whether it
126 ///has to call this function or not from the \ref NoteBookTab::mapwinexists
128 ///\param eml edge map list
129 ///\param nml node map list
130 void update(std::vector<std::string> eml, std::vector<std::string> nml);
132 void changeEntry(bool, int, std::string);
134 void set_title(std::string);