Changeset 155:74065e83844d in glemon-0.x
- Timestamp:
- 09/28/06 11:26:48 (19 years ago)
- Branch:
- default
- Phase:
- public
- Convert:
- svn:c9d7d8f5-90d6-0310-b91f-818b3a526b0e/glemon/trunk@2960
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
graph_displayer_canvas-node.cc
r154 r155 2 2 #include <cmath> 3 3 4 const int minimum_node_radius=0; 4 5 5 6 int GraphDisplayerCanvas::changeNodeRadius (std::string mapname, Node node) … … 25 26 else 26 27 { 27 w=(int)( radius_min+(v-min)/(max-min)*(radius_max-radius_min));28 w=(int)(minimum_node_radius+(v-min)/(max-min)*(radius_max-minimum_node_radius)); 28 29 } 29 30 } 30 31 else 31 32 { 32 w=5+(int)(v/radius_unit); 33 } 33 w=(int)(v*radius_max); 34 } 35 36 if(w<5) 37 { 38 w=5; 39 } 40 34 41 if(w>=0) 35 42 { -
main_win.cc
r154 r155 211 211 212 212 Gtk::Label * unit_label= new Gtk::Label("Unit:"); 213 table2.attach(*unit_label, 2,3,0,1);213 // table2.attach(*unit_label, 2,3,0,1); 214 214 215 215 Gtk::Adjustment * adjustment_unit=new Gtk::Adjustment(20, 5, 200, 5, 10); … … 217 217 radius_unit = new Gtk::SpinButton(*adjustment_unit, 5,0); 218 218 radius_unit->signal_value_changed().connect(sigc::mem_fun(*this, &MainWin::nodeViewChanged)); 219 table2.attach(*radius_unit, 3,4,0,1);219 // table2.attach(*radius_unit, 3,4,0,1); 220 220 221 221 Gtk::Label * min_label= new Gtk::Label("Min:"); 222 table2.attach(*min_label, 0,1,1,2);222 // table2.attach(*min_label, 0,1,1,2); 223 223 224 224 Gtk::Adjustment * adjustment_min=new Gtk::Adjustment(20, 5, 200, 5, 10); … … 226 226 radius_min = new Gtk::SpinButton(*adjustment_min, 5,0); 227 227 radius_min->signal_value_changed().connect(sigc::mem_fun(*this, &MainWin::nodeViewChanged)); 228 table2.attach(*radius_min, 1,2,1,2);229 230 Gtk::Label * max_label= new Gtk::Label(" Max:");228 // table2.attach(*radius_min, 1,2,1,2); 229 230 Gtk::Label * max_label= new Gtk::Label("Size:"); 231 231 table2.attach(*max_label, 2,3,1,2); 232 232 233 Gtk::Adjustment * adjustment_max=new Gtk::Adjustment(20, 5, 200, 5, 10);233 Gtk::Adjustment * adjustment_max=new Gtk::Adjustment(20, 0, 200, 5, 10); 234 234 235 235 radius_max = new Gtk::SpinButton(*adjustment_max, 5,0);
Note: See TracChangeset
for help on using the changeset viewer.