Added a "load settings from current dir" by using shift when clicking on Load or... master
authorGary Macbook <gsteele13@gmail.com>
Fri, 23 Aug 2013 09:20:33 +0000 (11:20 +0200)
committerGary Macbook <gsteele13@gmail.com>
Fri, 23 Aug 2013 09:20:33 +0000 (11:20 +0200)
spyview/spyview_ui.C
spyview/spyview_ui.fl
spyview/spyview_ui.h

index 57e2bf832c91fbe5663465c8ae0448ff1f4794a4..cbf6050b05831a031461e09badd1d46d74ac3e3f 100644 (file)
@@ -1,4 +1,4 @@
-// generated by Fast Light User Interface Designer (fluid) version 1.0110
+// generated by Fast Light User Interface Designer (fluid) version 1.0107
 
 #include "spyview_ui.h"
 #include "spypal_interface.H"
 
 #include "spyview_ui.h"
 #include "spypal_interface.H"
@@ -369,19 +369,45 @@ static void cb_Postscript(Fl_Button*, void*) {
 }
 
 static void cb_Save1(Fl_Button*, void*) {
 }
 
 static void cb_Save1(Fl_Button*, void*) {
-  #ifdef WIN32foo
-warn("Save settings in main window temporarilty\ndisabled in Win32 due to bug\n");
-#else
-char *fname = fl_file_chooser("Save Settings","Settings (*.svs)",spyviewSettingsDir);
+  if (Fl::event_state() & FL_SHIFT)
+{
+       Fl_File_Chooser chooser(".", 
+                       "(*.svs)\t",
+                       Fl_File_Chooser::CREATE,
+                       "Select files");
+       chooser.preview(0);
+       chooser.show();
+       while (chooser.shown()) Fl::wait();
+       if (chooser.value() == NULL) return;
+       savesettings(chooser.value(1));
+}
+else
+{
+       char *fname = fl_file_chooser("Save Settings","Settings (*.svs)",spyviewSettingsDir);
        if(fname != NULL)
          savesettings(fname);
        if(fname != NULL)
          savesettings(fname);
-#endif
+};
 }
 
 static void cb_Load2(Fl_Button*, void*) {
 }
 
 static void cb_Load2(Fl_Button*, void*) {
-  char *fname = fl_file_chooser("Load Spyview Settings","Settings (*.svs)",spyviewSettingsDir);
-if(fname != NULL)
-  loadsettings(fname);
+  if (Fl::event_state() & FL_SHIFT)
+{
+       Fl_File_Chooser chooser(".", 
+                       "(*.svs)\t",
+                       Fl_File_Chooser::CREATE,
+                       "Select files");
+       chooser.preview(0);
+       chooser.show();
+       while (chooser.shown()) Fl::wait();
+       if (chooser.value() == NULL) return;
+       loadsettings(chooser.value(1));
+}
+else
+{
+       char *fname = fl_file_chooser("Load Spyview Settings","Settings (*.svs)",spyviewSettingsDir);
+       if(fname != NULL)
+               loadsettings(fname);
+};
 }
 
 Fl_Value_Output *xsize=(Fl_Value_Output *)0;
 }
 
 Fl_Value_Output *xsize=(Fl_Value_Output *)0;
@@ -1384,1102 +1410,1100 @@ static void cb_dismiss3(Fl_Button*, void*) {
 }
 
 void make_window() {
 }
 
 void make_window() {
-  { control = new Fl_Double_Window(570, 425, "Controls");
-    { filech = new Fl_Choice(50, 5, 190, 25, "file:");
-      filech->down_box(FL_BORDER_BOX);
-      filech->callback((Fl_Callback*)filech_cb);
-      filech->when(FL_WHEN_RELEASE_ALWAYS);
-    } // Fl_Choice* filech
-    { plothistb = new Fl_Light_Button(75, 35, 75, 25, "Plot Hist.");
-      plothistb->labelsize(12);
-      plothistb->callback((Fl_Callback*)cb_plothistb);
-    } // Fl_Light_Button* plothistb
-    { plotcmapb = new Fl_Light_Button(155, 35, 85, 25, "Plot Colmap");
-      plotcmapb->labelsize(11);
-      plotcmapb->callback((Fl_Callback*)cb_plotcmapb);
-    } // Fl_Light_Button* plotcmapb
-    { centerv = new Fl_Value_Input(55, 65, 50, 20, "center");
-      centerv->maximum(65535);
-      centerv->step(1);
-      centerv->textsize(9);
-      centerv->callback((Fl_Callback*)cb_centerv);
-    } // Fl_Value_Input* centerv
-    { centerslider = new Fl_Slider(105, 65, 135, 20);
-      centerslider->type(3);
-      centerslider->maximum(65535);
-      centerslider->callback((Fl_Callback*)cb_centerslider);
-    } // Fl_Slider* centerslider
-    { centerroller = new Fl_Roller(105, 85, 135, 20);
-      centerroller->type(1);
-      centerroller->maximum(65535);
-      centerroller->step(10);
-      centerroller->callback((Fl_Callback*)cb_centerroller);
-    } // Fl_Roller* centerroller
-    { centerv_units = new Fl_Value_Input(35, 85, 70, 20);
-      centerv_units->color((Fl_Color)53);
-      centerv_units->textsize(9);
-      centerv_units->callback((Fl_Callback*)cb_centerv_units);
-      centerv_units->when(FL_WHEN_ENTER_KEY);
-    } // Fl_Value_Input* centerv_units
-    { widthv = new Fl_Value_Input(55, 110, 50, 20, "width");
-      widthv->maximum(65535);
-      widthv->step(1);
-      widthv->value(1);
-      widthv->textsize(9);
-      widthv->callback((Fl_Callback*)cb_widthv);
-    } // Fl_Value_Input* widthv
-    { widthslider = new Fl_Slider(105, 110, 135, 20);
-      widthslider->type(3);
-      widthslider->maximum(65535);
-      widthslider->callback((Fl_Callback*)cb_widthslider);
-    } // Fl_Slider* widthslider
-    { widthroller = new Fl_Roller(105, 130, 135, 20);
-      widthroller->type(1);
-      widthroller->maximum(65535);
-      widthroller->step(10);
-      widthroller->callback((Fl_Callback*)cb_widthroller);
-    } // Fl_Roller* widthroller
-    { widthv_units = new Fl_Value_Input(35, 130, 70, 20);
-      widthv_units->color((Fl_Color)53);
-      widthv_units->textsize(9);
-      widthv_units->callback((Fl_Callback*)cb_widthv_units);
-      widthv_units->when(FL_WHEN_ENTER_KEY);
-    } // Fl_Value_Input* widthv_units
-    { minv = new Fl_Value_Input(55, 155, 50, 20, "min");
-      minv->maximum(65535);
-      minv->step(1);
-      minv->textsize(9);
-      minv->callback((Fl_Callback*)cb_minv);
-    } // Fl_Value_Input* minv
-    { minslider = new Fl_Slider(105, 155, 135, 20);
-      minslider->type(3);
-      minslider->maximum(65535);
-      minslider->callback((Fl_Callback*)cb_minslider);
-    } // Fl_Slider* minslider
-    { minroller = new Fl_Roller(105, 175, 135, 20);
-      minroller->type(1);
-      minroller->maximum(65535);
-      minroller->step(10);
-      minroller->callback((Fl_Callback*)cb_minroller);
-    } // Fl_Roller* minroller
-    { minv_units = new Fl_Value_Input(35, 175, 70, 20);
-      minv_units->color((Fl_Color)53);
-      minv_units->textsize(9);
-      minv_units->callback((Fl_Callback*)cb_minv_units);
-      minv_units->when(FL_WHEN_ENTER_KEY);
-    } // Fl_Value_Input* minv_units
-    { maxv = new Fl_Value_Input(55, 200, 50, 20, "max");
-      maxv->maximum(65535);
-      maxv->step(1);
-      maxv->value(1);
-      maxv->textsize(9);
-      maxv->callback((Fl_Callback*)cb_maxv);
-    } // Fl_Value_Input* maxv
-    { maxslider = new Fl_Slider(105, 200, 135, 20);
-      maxslider->type(3);
-      maxslider->maximum(65535);
-      maxslider->callback((Fl_Callback*)cb_maxslider);
-    } // Fl_Slider* maxslider
-    { maxroller = new Fl_Roller(105, 220, 135, 20);
-      maxroller->type(1);
-      maxroller->maximum(65535);
-      maxroller->step(10);
-      maxroller->callback((Fl_Callback*)cb_maxroller);
-    } // Fl_Roller* maxroller
-    { maxv_units = new Fl_Value_Input(35, 220, 70, 20);
-      maxv_units->color((Fl_Color)FL_LIGHT2);
-      maxv_units->textsize(9);
-      maxv_units->callback((Fl_Callback*)cb_maxv_units);
-      maxv_units->when(FL_WHEN_ENTER_KEY);
-    } // Fl_Value_Input* maxv_units
-    { gammav = new Fl_Value_Input(55, 245, 50, 20, "gamma");
-      gammav->labelsize(12);
-      gammav->value(1);
-      gammav->callback((Fl_Callback*)cb_gammav);
-      gammav->when(FL_WHEN_ENTER_KEY);
-    } // Fl_Value_Input* gammav
-    { gammaslider = new Fl_Slider(105, 245, 135, 20);
-      gammaslider->type(3);
-      gammaslider->minimum(-4.6);
-      gammaslider->maximum(4.6);
-      gammaslider->step(0.001);
-      gammaslider->callback((Fl_Callback*)cb_gammaslider);
-    } // Fl_Slider* gammaslider
-    { gammaroller = new Fl_Roller(105, 265, 135, 20);
-      gammaroller->type(1);
-      gammaroller->minimum(-4.6);
-      gammaroller->maximum(4.6);
-      gammaroller->callback((Fl_Callback*)cb_gammaroller);
-    } // Fl_Roller* gammaroller
-    { squareb = new Fl_Light_Button(5, 335, 85, 25, "Square");
-      squareb->callback((Fl_Callback*)cb_squareb);
-    } // Fl_Light_Button* squareb
+  Fl_Double_Window* w;
+  { Fl_Double_Window* o = control = new Fl_Double_Window(570, 425, "Controls");
+    w = o;
+    { Fl_Choice* o = filech = new Fl_Choice(50, 5, 190, 25, "file:");
+      o->down_box(FL_BORDER_BOX);
+      o->callback((Fl_Callback*)filech_cb);
+      o->when(FL_WHEN_RELEASE_ALWAYS);
+    }
+    { Fl_Light_Button* o = plothistb = new Fl_Light_Button(75, 35, 75, 25, "Plot Hist.");
+      o->labelsize(12);
+      o->callback((Fl_Callback*)cb_plothistb);
+    }
+    { Fl_Light_Button* o = plotcmapb = new Fl_Light_Button(155, 35, 85, 25, "Plot Colmap");
+      o->labelsize(11);
+      o->callback((Fl_Callback*)cb_plotcmapb);
+    }
+    { Fl_Value_Input* o = centerv = new Fl_Value_Input(55, 65, 50, 20, "center");
+      o->maximum(65535);
+      o->step(1);
+      o->textsize(9);
+      o->callback((Fl_Callback*)cb_centerv);
+    }
+    { Fl_Slider* o = centerslider = new Fl_Slider(105, 65, 135, 20);
+      o->type(3);
+      o->maximum(65535);
+      o->callback((Fl_Callback*)cb_centerslider);
+    }
+    { Fl_Roller* o = centerroller = new Fl_Roller(105, 85, 135, 20);
+      o->type(1);
+      o->maximum(65535);
+      o->step(10);
+      o->callback((Fl_Callback*)cb_centerroller);
+    }
+    { Fl_Value_Input* o = centerv_units = new Fl_Value_Input(35, 85, 70, 20);
+      o->color((Fl_Color)53);
+      o->textsize(9);
+      o->callback((Fl_Callback*)cb_centerv_units);
+      o->when(FL_WHEN_ENTER_KEY);
+    }
+    { Fl_Value_Input* o = widthv = new Fl_Value_Input(55, 110, 50, 20, "width");
+      o->maximum(65535);
+      o->step(1);
+      o->value(1);
+      o->textsize(9);
+      o->callback((Fl_Callback*)cb_widthv);
+    }
+    { Fl_Slider* o = widthslider = new Fl_Slider(105, 110, 135, 20);
+      o->type(3);
+      o->maximum(65535);
+      o->callback((Fl_Callback*)cb_widthslider);
+    }
+    { Fl_Roller* o = widthroller = new Fl_Roller(105, 130, 135, 20);
+      o->type(1);
+      o->maximum(65535);
+      o->step(10);
+      o->callback((Fl_Callback*)cb_widthroller);
+    }
+    { Fl_Value_Input* o = widthv_units = new Fl_Value_Input(35, 130, 70, 20);
+      o->color((Fl_Color)53);
+      o->textsize(9);
+      o->callback((Fl_Callback*)cb_widthv_units);
+      o->when(FL_WHEN_ENTER_KEY);
+    }
+    { Fl_Value_Input* o = minv = new Fl_Value_Input(55, 155, 50, 20, "min");
+      o->maximum(65535);
+      o->step(1);
+      o->textsize(9);
+      o->callback((Fl_Callback*)cb_minv);
+    }
+    { Fl_Slider* o = minslider = new Fl_Slider(105, 155, 135, 20);
+      o->type(3);
+      o->maximum(65535);
+      o->callback((Fl_Callback*)cb_minslider);
+    }
+    { Fl_Roller* o = minroller = new Fl_Roller(105, 175, 135, 20);
+      o->type(1);
+      o->maximum(65535);
+      o->step(10);
+      o->callback((Fl_Callback*)cb_minroller);
+    }
+    { Fl_Value_Input* o = minv_units = new Fl_Value_Input(35, 175, 70, 20);
+      o->color((Fl_Color)53);
+      o->textsize(9);
+      o->callback((Fl_Callback*)cb_minv_units);
+      o->when(FL_WHEN_ENTER_KEY);
+    }
+    { Fl_Value_Input* o = maxv = new Fl_Value_Input(55, 200, 50, 20, "max");
+      o->maximum(65535);
+      o->step(1);
+      o->value(1);
+      o->textsize(9);
+      o->callback((Fl_Callback*)cb_maxv);
+    }
+    { Fl_Slider* o = maxslider = new Fl_Slider(105, 200, 135, 20);
+      o->type(3);
+      o->maximum(65535);
+      o->callback((Fl_Callback*)cb_maxslider);
+    }
+    { Fl_Roller* o = maxroller = new Fl_Roller(105, 220, 135, 20);
+      o->type(1);
+      o->maximum(65535);
+      o->step(10);
+      o->callback((Fl_Callback*)cb_maxroller);
+    }
+    { Fl_Value_Input* o = maxv_units = new Fl_Value_Input(35, 220, 70, 20);
+      o->color(FL_LIGHT2);
+      o->textsize(9);
+      o->callback((Fl_Callback*)cb_maxv_units);
+      o->when(FL_WHEN_ENTER_KEY);
+    }
+    { Fl_Value_Input* o = gammav = new Fl_Value_Input(55, 245, 50, 20, "gamma");
+      o->labelsize(12);
+      o->value(1);
+      o->callback((Fl_Callback*)cb_gammav);
+      o->when(FL_WHEN_ENTER_KEY);
+    }
+    { Fl_Slider* o = gammaslider = new Fl_Slider(105, 245, 135, 20);
+      o->type(3);
+      o->minimum(-4.6);
+      o->maximum(4.6);
+      o->step(0.001);
+      o->callback((Fl_Callback*)cb_gammaslider);
+    }
+    { Fl_Roller* o = gammaroller = new Fl_Roller(105, 265, 135, 20);
+      o->type(1);
+      o->minimum(-4.6);
+      o->maximum(4.6);
+      o->callback((Fl_Callback*)cb_gammaroller);
+    }
+    { Fl_Light_Button* o = squareb = new Fl_Light_Button(5, 335, 85, 25, "Square");
+      o->callback((Fl_Callback*)cb_squareb);
+    }
     { Fl_Button* o = new Fl_Button(95, 335, 145, 25, "Image Processing");
       o->callback((Fl_Callback*)cb_Image);
     { Fl_Button* o = new Fl_Button(95, 335, 145, 25, "Image Processing");
       o->callback((Fl_Callback*)cb_Image);
-    } // Fl_Button* o
+    }
     { Fl_Button* o = new Fl_Button(5, 365, 140, 25, "Axis Units && Ranges");
       o->labelsize(12);
       o->callback((Fl_Callback*)cb_Axis);
     { Fl_Button* o = new Fl_Button(5, 365, 140, 25, "Axis Units && Ranges");
       o->labelsize(12);
       o->callback((Fl_Callback*)cb_Axis);
-    } // Fl_Button* o
-    { cmapch = new Fl_Choice(315, 5, 140, 25, "ColorMap");
-      cmapch->down_box(FL_BORDER_BOX);
-      cmapch->callback((Fl_Callback*)cmapch_cb);
-      cmapch->when(FL_WHEN_RELEASE_ALWAYS);
-    } // Fl_Choice* cmapch
-    { invertb = new Fl_Light_Button(335, 40, 75, 25, "Invert");
-      invertb->tooltip("Individually invert each color channel");
-      invertb->callback((Fl_Callback*)cb_invertb);
-    } // Fl_Light_Button* invertb
-    { negateb = new Fl_Light_Button(415, 40, 70, 25, "Negate");
-      negateb->tooltip("Negate the data before plotting");
-      negateb->callback((Fl_Callback*)cb_negateb);
-    } // Fl_Light_Button* negateb
-    { normb = new Fl_Button(250, 40, 80, 25, "Normalize");
-      normb->callback((Fl_Callback*)cb_normb);
-    } // Fl_Button* normb
+    }
+    { Fl_Choice* o = cmapch = new Fl_Choice(315, 5, 140, 25, "ColorMap");
+      o->down_box(FL_BORDER_BOX);
+      o->callback((Fl_Callback*)cmapch_cb);
+      o->when(FL_WHEN_RELEASE_ALWAYS);
+    }
+    { Fl_Light_Button* o = invertb = new Fl_Light_Button(335, 40, 75, 25, "Invert");
+      o->tooltip("Individually invert each color channel");
+      o->callback((Fl_Callback*)cb_invertb);
+    }
+    { Fl_Light_Button* o = negateb = new Fl_Light_Button(415, 40, 70, 25, "Negate");
+      o->tooltip("Negate the data before plotting");
+      o->callback((Fl_Callback*)cb_negateb);
+    }
+    { Fl_Button* o = normb = new Fl_Button(250, 40, 80, 25, "Normalize");
+      o->callback((Fl_Callback*)cb_normb);
+    }
     { Fl_Button* o = new Fl_Button(250, 70, 115, 25, "Load Options");
       o->callback((Fl_Callback*)cb_Load);
     { Fl_Button* o = new Fl_Button(250, 70, 115, 25, "Load Options");
       o->callback((Fl_Callback*)cb_Load);
-    } // Fl_Button* o
-    { bpbox = new Fl_Value_Input(315, 110, 50, 25, "Black %");
-      bpbox->maximum(100);
-      bpbox->step(0.1);
-      bpbox->callback((Fl_Callback*)cb_bpbox);
-    } // Fl_Value_Input* bpbox
-    { wpbox = new Fl_Value_Input(435, 110, 50, 25, "White %");
-      wpbox->maximum(100);
-      wpbox->step(0.1);
-      wpbox->callback((Fl_Callback*)cb_wpbox);
-    } // Fl_Value_Input* wpbox
-    { savebox = new Fl_Input(320, 300, 245, 25, "basename:");
-      savebox->labelsize(11);
-      savebox->textsize(10);
-      savebox->callback((Fl_Callback*)cb_savebox);
-    } // Fl_Input* savebox
-    { saveb = new Fl_Button(415, 335, 70, 25, "Save PPM");
-      saveb->tooltip("Save color image as PPM");
-      saveb->labelsize(12);
-      saveb->callback((Fl_Callback*)saveb_cb);
-    } // Fl_Button* saveb
-    { dismissb = new Fl_Button(460, 365, 60, 25, "dismiss");
-      dismissb->callback((Fl_Callback*)cb_dismissb);
-    } // Fl_Button* dismissb
-    { exitb = new Fl_Button(525, 365, 40, 25, "exit");
-      exitb->shortcut(0x80071);
-      exitb->callback((Fl_Callback*)cb_exitb);
-    } // Fl_Button* exitb
+    }
+    { Fl_Value_Input* o = bpbox = new Fl_Value_Input(315, 110, 50, 25, "Black %");
+      o->maximum(100);
+      o->step(0.1);
+      o->callback((Fl_Callback*)cb_bpbox);
+    }
+    { Fl_Value_Input* o = wpbox = new Fl_Value_Input(435, 110, 50, 25, "White %");
+      o->maximum(100);
+      o->step(0.1);
+      o->callback((Fl_Callback*)cb_wpbox);
+    }
+    { Fl_Input* o = savebox = new Fl_Input(320, 300, 245, 25, "basename:");
+      o->labelsize(11);
+      o->textsize(10);
+      o->callback((Fl_Callback*)cb_savebox);
+    }
+    { Fl_Button* o = saveb = new Fl_Button(415, 335, 70, 25, "Save PPM");
+      o->tooltip("Save color image as PPM");
+      o->labelsize(12);
+      o->callback((Fl_Callback*)saveb_cb);
+    }
+    { Fl_Button* o = dismissb = new Fl_Button(460, 365, 60, 25, "dismiss");
+      o->callback((Fl_Callback*)cb_dismissb);
+    }
+    { Fl_Button* o = exitb = new Fl_Button(525, 365, 40, 25, "exit");
+      o->shortcut(0x80071);
+      o->callback((Fl_Callback*)cb_exitb);
+    }
     { Fl_Button* o = new Fl_Button(55, 265, 50, 20, "reset");
       o->labelsize(12);
       o->callback((Fl_Callback*)cb_reset);
     { Fl_Button* o = new Fl_Button(55, 265, 50, 20, "reset");
       o->labelsize(12);
       o->callback((Fl_Callback*)cb_reset);
-    } // Fl_Button* o
-    { xsecb = new Fl_Button(150, 365, 90, 25, "3D XSection");
-      xsecb->labelsize(12);
-      xsecb->callback((Fl_Callback*)cb_xsecb);
-    } // Fl_Button* xsecb
+    }
+    { Fl_Button* o = xsecb = new Fl_Button(150, 365, 90, 25, "3D XSection");
+      o->labelsize(12);
+      o->callback((Fl_Callback*)cb_xsecb);
+    }
     { Fl_Button* o = new Fl_Button(250, 335, 80, 25, "Save MTX");
       o->tooltip("Save the file with an MTX extension");
       o->labelsize(12);
       o->callback((Fl_Callback*)cb_Save);
     { Fl_Button* o = new Fl_Button(250, 335, 80, 25, "Save MTX");
       o->tooltip("Save the file with an MTX extension");
       o->labelsize(12);
       o->callback((Fl_Callback*)cb_Save);
-    } // Fl_Button* o
-    { location_bar = new Fl_Button(5, 395, 210, 25, "button");
-      location_bar->labelsize(10);
-      location_bar->callback((Fl_Callback*)cb_location_bar);
-      location_bar->align(FL_ALIGN_LEFT|FL_ALIGN_INSIDE);
-    } // Fl_Button* location_bar
-    { help_bar = new Fl_Output(215, 395, 240, 25);
-      help_bar->color((Fl_Color)FL_BACKGROUND_COLOR);
-      help_bar->textfont(8);
-      help_bar->textsize(10);
-    } // Fl_Output* help_bar
-    { colormap_placeholder = new Fl_Box(495, 35, 35, 260);
-      colormap_placeholder->box(FL_DOWN_BOX);
-    } // Fl_Box* colormap_placeholder
+    }
+    { Fl_Button* o = location_bar = new Fl_Button(5, 395, 210, 25, "button");
+      o->labelsize(10);
+      o->callback((Fl_Callback*)cb_location_bar);
+      o->align(FL_ALIGN_LEFT|FL_ALIGN_INSIDE);
+    }
+    { Fl_Output* o = help_bar = new Fl_Output(215, 395, 240, 25);
+      o->color(FL_BACKGROUND_COLOR);
+      o->textfont(8);
+      o->textsize(10);
+    }
+    { Fl_Box* o = colormap_placeholder = new Fl_Box(495, 35, 35, 260);
+      o->box(FL_DOWN_BOX);
+    }
     { Fl_Button* o = new Fl_Button(495, 5, 70, 25, "Save Cmap");
       o->labelsize(10);
       o->callback((Fl_Callback*)save_cmap_cb);
     { Fl_Button* o = new Fl_Button(495, 5, 70, 25, "Save Cmap");
       o->labelsize(10);
       o->callback((Fl_Callback*)save_cmap_cb);
-    } // Fl_Button* o
-    { exportb = new Fl_Button(335, 335, 75, 25, "Export");
-      exportb->tooltip("Export data to file basename.export.xxx");
-      exportb->callback((Fl_Callback*)cb_exportb);
-    } // Fl_Button* exportb
-    { xzoom_value = new Fl_Value_Input(515, 395, 25, 25);
-      xzoom_value->tooltip("X Zoom");
-      xzoom_value->minimum(-100);
-      xzoom_value->maximum(100);
-      xzoom_value->callback((Fl_Callback*)cb_xzoom_value);
-      xzoom_value->when(FL_WHEN_ENTER_KEY);
-    } // Fl_Value_Input* xzoom_value
-    { yzoom_value = new Fl_Value_Input(540, 395, 25, 25);
-      yzoom_value->tooltip("Y  Zoom");
-      yzoom_value->minimum(-100);
-      yzoom_value->maximum(100);
-      yzoom_value->callback((Fl_Callback*)cb_yzoom_value);
-      yzoom_value->when(FL_WHEN_ENTER_KEY);
-    } // Fl_Value_Input* yzoom_value
-    { cmap_min = new Fl_Slider(534, 35, 15, 260);
-      cmap_min->minimum(1);
-      cmap_min->maximum(0);
-      cmap_min->callback((Fl_Callback*)cb_cmap_min);
-    } // Fl_Slider* cmap_min
-    { cmap_max = new Fl_Slider(550, 35, 15, 260);
-      cmap_max->minimum(1);
-      cmap_max->maximum(0);
-      cmap_max->value(1);
-      cmap_max->callback((Fl_Callback*)cb_cmap_max);
-    } // Fl_Slider* cmap_max
+    }
+    { Fl_Button* o = exportb = new Fl_Button(335, 335, 75, 25, "Export");
+      o->tooltip("Export data to file basename.export.xxx");
+      o->callback((Fl_Callback*)cb_exportb);
+    }
+    { Fl_Value_Input* o = xzoom_value = new Fl_Value_Input(515, 395, 25, 25);
+      o->tooltip("X Zoom");
+      o->minimum(-100);
+      o->maximum(100);
+      o->callback((Fl_Callback*)cb_xzoom_value);
+      o->when(FL_WHEN_ENTER_KEY);
+    }
+    { Fl_Value_Input* o = yzoom_value = new Fl_Value_Input(540, 395, 25, 25);
+      o->tooltip("Y  Zoom");
+      o->minimum(-100);
+      o->maximum(100);
+      o->callback((Fl_Callback*)cb_yzoom_value);
+      o->when(FL_WHEN_ENTER_KEY);
+    }
+    { Fl_Slider* o = cmap_min = new Fl_Slider(534, 35, 15, 260);
+      o->minimum(1);
+      o->maximum(0);
+      o->callback((Fl_Callback*)cb_cmap_min);
+    }
+    { Fl_Slider* o = cmap_max = new Fl_Slider(550, 35, 15, 260);
+      o->minimum(1);
+      o->maximum(0);
+      o->value(1);
+      o->callback((Fl_Callback*)cb_cmap_max);
+    }
     { Fl_Button* o = new Fl_Button(5, 35, 65, 25, "Load...");
       o->tooltip("Add or load new files from a pattern or browser");
       o->labelsize(13);
       o->callback((Fl_Callback*)cb_Load1);
     { Fl_Button* o = new Fl_Button(5, 35, 65, 25, "Load...");
       o->tooltip("Add or load new files from a pattern or browser");
       o->labelsize(13);
       o->callback((Fl_Callback*)cb_Load1);
-    } // Fl_Button* o
+    }
     { Fl_Button* o = new Fl_Button(490, 335, 75, 25, "Postscript");
       o->labelsize(12);
       o->callback((Fl_Callback*)cb_Postscript);
     { Fl_Button* o = new Fl_Button(490, 335, 75, 25, "Postscript");
       o->labelsize(12);
       o->callback((Fl_Callback*)cb_Postscript);
-    } // Fl_Button* o
+    }
     { Fl_Button* o = new Fl_Button(250, 365, 105, 25, "Save Settings");
       o->tooltip("Save the spyview settings");
       o->labelsize(12);
       o->callback((Fl_Callback*)cb_Save1);
     { Fl_Button* o = new Fl_Button(250, 365, 105, 25, "Save Settings");
       o->tooltip("Save the spyview settings");
       o->labelsize(12);
       o->callback((Fl_Callback*)cb_Save1);
-    } // Fl_Button* o
+    }
     { Fl_Button* o = new Fl_Button(360, 365, 95, 25, "Load Settings");
       o->tooltip("Load the Spyview settings");
       o->labelsize(12);
       o->callback((Fl_Callback*)cb_Load2);
     { Fl_Button* o = new Fl_Button(360, 365, 95, 25, "Load Settings");
       o->tooltip("Load the Spyview settings");
       o->labelsize(12);
       o->callback((Fl_Callback*)cb_Load2);
-    } // Fl_Button* o
-    { xsize = new Fl_Value_Output(455, 395, 30, 25);
-      xsize->tooltip("Data Height");
-      xsize->textsize(11);
-    } // Fl_Value_Output* xsize
-    { ysize = new Fl_Value_Output(485, 395, 30, 25);
-      ysize->tooltip("Data Width");
-      ysize->textsize(11);
-    } // Fl_Value_Output* ysize
-    { gcenterv = new Fl_Value_Input(55, 290, 50, 20, "gamma");
-      gcenterv->labelsize(12);
-      gcenterv->maximum(0.999);
-      gcenterv->callback((Fl_Callback*)cb_gcenterv);
-      gcenterv->when(FL_WHEN_ENTER_KEY);
-    } // Fl_Value_Input* gcenterv
-    { gcenterslider = new Fl_Slider(105, 290, 135, 20);
-      gcenterslider->type(3);
-      gcenterslider->maximum(0.999);
-      gcenterslider->step(0.001);
-      gcenterslider->callback((Fl_Callback*)cb_gcenterslider);
-    } // Fl_Slider* gcenterslider
-    { gcenterroller = new Fl_Roller(105, 310, 135, 20);
-      gcenterroller->type(1);
-      gcenterroller->maximum(0.999);
-      gcenterroller->callback((Fl_Callback*)cb_gcenterroller);
-    } // Fl_Roller* gcenterroller
+    }
+    { Fl_Value_Output* o = xsize = new Fl_Value_Output(455, 395, 30, 25);
+      o->tooltip("Data Height");
+      o->textsize(11);
+    }
+    { Fl_Value_Output* o = ysize = new Fl_Value_Output(485, 395, 30, 25);
+      o->tooltip("Data Width");
+      o->textsize(11);
+    }
+    { Fl_Value_Input* o = gcenterv = new Fl_Value_Input(55, 290, 50, 20, "gamma");
+      o->labelsize(12);
+      o->maximum(0.999);
+      o->callback((Fl_Callback*)cb_gcenterv);
+      o->when(FL_WHEN_ENTER_KEY);
+    }
+    { Fl_Slider* o = gcenterslider = new Fl_Slider(105, 290, 135, 20);
+      o->type(3);
+      o->maximum(0.999);
+      o->step(0.001);
+      o->callback((Fl_Callback*)cb_gcenterslider);
+    }
+    { Fl_Roller* o = gcenterroller = new Fl_Roller(105, 310, 135, 20);
+      o->type(1);
+      o->maximum(0.999);
+      o->callback((Fl_Callback*)cb_gcenterroller);
+    }
     { Fl_Button* o = new Fl_Button(55, 310, 50, 20, "reset");
       o->labelsize(12);
       o->callback((Fl_Callback*)cb_reset1);
     { Fl_Button* o = new Fl_Button(55, 310, 50, 20, "reset");
       o->labelsize(12);
       o->callback((Fl_Callback*)cb_reset1);
-    } // Fl_Button* o
+    }
     { Fl_Box* o = new Fl_Box(20, 308, 32, 17, "center");
       o->labelsize(12);
       o->align(FL_ALIGN_RIGHT|FL_ALIGN_INSIDE);
     { Fl_Box* o = new Fl_Box(20, 308, 32, 17, "center");
       o->labelsize(12);
       o->align(FL_ALIGN_RIGHT|FL_ALIGN_INSIDE);
-    } // Fl_Box* o
-    { export_type = new Fl_Choice(350, 270, 135, 25, "Export Type:");
-      export_type->down_box(FL_BORDER_BOX);
-      export_type->menu(menu_export_type);
-    } // Fl_Choice* export_type
+    }
+    { Fl_Choice* o = export_type = new Fl_Choice(350, 270, 135, 25, "Export Type:");
+      o->down_box(FL_BORDER_BOX);
+      o->menu(menu_export_type);
+    }
     { Fl_Button* o = new Fl_Button(370, 70, 115, 25, "Edit cmap...");
       o->callback((Fl_Callback*)cb_Edit);
     { Fl_Button* o = new Fl_Button(370, 70, 115, 25, "Edit cmap...");
       o->callback((Fl_Callback*)cb_Edit);
-    } // Fl_Button* o
+    }
     { Fl_Button* o = new Fl_Button(255, 145, 110, 25, "Fixed colors");
       o->tooltip("Keep colormapping and quantization fixed for new images (Disable normalize an\
 d Autoquantize)");
       o->callback((Fl_Callback*)cb_Fixed);
     { Fl_Button* o = new Fl_Button(255, 145, 110, 25, "Fixed colors");
       o->tooltip("Keep colormapping and quantization fixed for new images (Disable normalize an\
 d Autoquantize)");
       o->callback((Fl_Callback*)cb_Fixed);
-    } // Fl_Button* o
+    }
     { Fl_Button* o = new Fl_Button(370, 145, 115, 25, "Auto colors");
       o->tooltip("Audjust colormap and quantization for each image (Re-enable normalize and aut\
 o quantize)");
       o->callback((Fl_Callback*)cb_Auto);
     { Fl_Button* o = new Fl_Button(370, 145, 115, 25, "Auto colors");
       o->tooltip("Audjust colormap and quantization for each image (Re-enable normalize and aut\
 o quantize)");
       o->callback((Fl_Callback*)cb_Auto);
-    } // Fl_Button* o
+    }
     { Fl_Button* o = new Fl_Button(255, 175, 100, 25, "Reload file");
       o->callback((Fl_Callback*)cb_Reload);
     { Fl_Button* o = new Fl_Button(255, 175, 100, 25, "Reload file");
       o->callback((Fl_Callback*)cb_Reload);
-    } // Fl_Button* o
+    }
     { Fl_Button* o = new Fl_Button(360, 175, 125, 25, "Plane settings");
       o->callback((Fl_Callback*)cb_Plane);
     { Fl_Button* o = new Fl_Button(360, 175, 125, 25, "Plane settings");
       o->callback((Fl_Callback*)cb_Plane);
-    } // Fl_Button* o
+    }
     { Fl_Button* o = new Fl_Button(320, 205, 95, 25, "Load default");
       o->tooltip("Load colors from a \".colors\" file with the default name (same as filename)");
       o->labelsize(12);
       o->callback((Fl_Callback*)cb_Load3);
     { Fl_Button* o = new Fl_Button(320, 205, 95, 25, "Load default");
       o->tooltip("Load colors from a \".colors\" file with the default name (same as filename)");
       o->labelsize(12);
       o->callback((Fl_Callback*)cb_Load3);
-    } // Fl_Button* o
+    }
     { Fl_Box* o = new Fl_Box(255, 218, 55, 17, "Color");
       o->labelsize(12);
       o->align(FL_ALIGN_LEFT|FL_ALIGN_INSIDE);
     { Fl_Box* o = new Fl_Box(255, 218, 55, 17, "Color");
       o->labelsize(12);
       o->align(FL_ALIGN_LEFT|FL_ALIGN_INSIDE);
-    } // Fl_Box* o
+    }
     { Fl_Button* o = new Fl_Button(320, 235, 95, 25, "Save default");
       o->tooltip("Save colors to a \".colors\" file with the default name (same as filename)");
       o->labelsize(12);
       o->callback((Fl_Callback*)cb_Save2);
     { Fl_Button* o = new Fl_Button(320, 235, 95, 25, "Save default");
       o->tooltip("Save colors to a \".colors\" file with the default name (same as filename)");
       o->labelsize(12);
       o->callback((Fl_Callback*)cb_Save2);
-    } // Fl_Button* o
+    }
     { Fl_Button* o = new Fl_Button(420, 205, 65, 25, "Load...");
       o->tooltip("Load color settings from file");
       o->labelsize(12);
       o->callback((Fl_Callback*)cb_Load4);
     { Fl_Button* o = new Fl_Button(420, 205, 65, 25, "Load...");
       o->tooltip("Load color settings from file");
       o->labelsize(12);
       o->callback((Fl_Callback*)cb_Load4);
-    } // Fl_Button* o
+    }
     { Fl_Button* o = new Fl_Button(420, 235, 65, 25, "Save...");
       o->tooltip("Save color settings to file");
       o->labelsize(12);
       o->callback((Fl_Callback*)cb_Save3);
     { Fl_Button* o = new Fl_Button(420, 235, 65, 25, "Save...");
       o->tooltip("Save color settings to file");
       o->labelsize(12);
       o->callback((Fl_Callback*)cb_Save3);
-    } // Fl_Button* o
+    }
     { Fl_Box* o = new Fl_Box(255, 236, 55, 19, "Settings:");
       o->labelsize(12);
       o->align(FL_ALIGN_LEFT|FL_ALIGN_INSIDE);
     { Fl_Box* o = new Fl_Box(255, 236, 55, 19, "Settings:");
       o->labelsize(12);
       o->align(FL_ALIGN_LEFT|FL_ALIGN_INSIDE);
-    } // Fl_Box* o
+    }
     { Fl_Button* o = new Fl_Button(460, 5, 25, 25);
       o->tooltip("Edit the current colormap.  If the colormap is a .ppm file, an import wizard \
 will open to help you convert it to .spp");
       o->image(image_edit);
       o->callback((Fl_Callback*)cmapedit_cb);
     { Fl_Button* o = new Fl_Button(460, 5, 25, 25);
       o->tooltip("Edit the current colormap.  If the colormap is a .ppm file, an import wizard \
 will open to help you convert it to .spp");
       o->image(image_edit);
       o->callback((Fl_Callback*)cmapedit_cb);
-    } // Fl_Button* o
-    control->end();
-  } // Fl_Double_Window* control
-  { iw = new ImageWindow(136, 125, "image");
-    iw->box(FL_FLAT_BOX);
-    iw->color((Fl_Color)FL_BACKGROUND_COLOR);
-    iw->selection_color((Fl_Color)FL_BACKGROUND_COLOR);
-    iw->labeltype(FL_NO_LABEL);
-    iw->labelfont(0);
-    iw->labelsize(14);
-    iw->labelcolor((Fl_Color)FL_FOREGROUND_COLOR);
-    iw->align(FL_ALIGN_TOP);
-    iw->when(FL_WHEN_RELEASE);
-    iw->end();
-    iw->resizable(iw);
-  } // ImageWindow* iw
-  { procwin = new Fl_Double_Window(330, 445, "Image Processing");
-    { proc_description = new Fl_Output(0, 420, 330, 25);
-    } // Fl_Output* proc_description
+    }
+    o->end();
+  }
+  { ImageWindow* o = iw = new ImageWindow(136, 125, "image");
+    w = o;
+    o->box(FL_FLAT_BOX);
+    o->color(FL_BACKGROUND_COLOR);
+    o->selection_color(FL_BACKGROUND_COLOR);
+    o->labeltype(FL_NO_LABEL);
+    o->labelfont(0);
+    o->labelsize(14);
+    o->labelcolor(FL_FOREGROUND_COLOR);
+    o->align(FL_ALIGN_TOP);
+    o->when(FL_WHEN_RELEASE);
+    o->end();
+    o->resizable(o);
+  }
+  { Fl_Double_Window* o = procwin = new Fl_Double_Window(330, 445, "Image Processing");
+    w = o;
+    proc_description = new Fl_Output(0, 420, 330, 25);
     { Fl_Input* o = new Fl_Input(210, 240, 110, 25, "input:");
       o->type(1);
       o->callback((Fl_Callback*)cb_input);
       proc_parameters.push_back(o);
       o->hide();
     { Fl_Input* o = new Fl_Input(210, 240, 110, 25, "input:");
       o->type(1);
       o->callback((Fl_Callback*)cb_input);
       proc_parameters.push_back(o);
       o->hide();
-    } // Fl_Input* o
+    }
     { Fl_Input* o = new Fl_Input(210, 270, 110, 25, "input:");
       o->type(1);
       o->callback((Fl_Callback*)cb_input1);
       proc_parameters.push_back(o);
       o->hide();
     { Fl_Input* o = new Fl_Input(210, 270, 110, 25, "input:");
       o->type(1);
       o->callback((Fl_Callback*)cb_input1);
       proc_parameters.push_back(o);
       o->hide();
-    } // Fl_Input* o
+    }
     { Fl_Input* o = new Fl_Input(210, 300, 110, 25, "input:");
       o->type(1);
       o->callback((Fl_Callback*)cb_input2);
       proc_parameters.push_back(o);
       o->hide();
     { Fl_Input* o = new Fl_Input(210, 300, 110, 25, "input:");
       o->type(1);
       o->callback((Fl_Callback*)cb_input2);
       proc_parameters.push_back(o);
       o->hide();
-    } // Fl_Input* o
+    }
     { Fl_Input* o = new Fl_Input(210, 330, 110, 25, "input:");
       o->type(1);
       o->callback((Fl_Callback*)cb_input3);
       proc_parameters.push_back(o);
       o->hide();
     { Fl_Input* o = new Fl_Input(210, 330, 110, 25, "input:");
       o->type(1);
       o->callback((Fl_Callback*)cb_input3);
       proc_parameters.push_back(o);
       o->hide();
-    } // Fl_Input* o
+    }
     { Fl_Input* o = new Fl_Input(210, 360, 110, 25, "input:");
       o->type(1);
       o->callback((Fl_Callback*)cb_input4);
       proc_parameters.push_back(o);
       o->hide();
     { Fl_Input* o = new Fl_Input(210, 360, 110, 25, "input:");
       o->type(1);
       o->callback((Fl_Callback*)cb_input4);
       proc_parameters.push_back(o);
       o->hide();
-    } // Fl_Input* o
+    }
     { Fl_Check_Button* o = new Fl_Check_Button(300, 240, 20, 25, "button");
       o->down_box(FL_DOWN_BOX);
       o->callback((Fl_Callback*)cb_button);
       o->align(FL_ALIGN_LEFT);
       proc_bool_parameters.push_back(o);
       o->hide();
     { Fl_Check_Button* o = new Fl_Check_Button(300, 240, 20, 25, "button");
       o->down_box(FL_DOWN_BOX);
       o->callback((Fl_Callback*)cb_button);
       o->align(FL_ALIGN_LEFT);
       proc_bool_parameters.push_back(o);
       o->hide();
-    } // Fl_Check_Button* o
+    }
     { Fl_Check_Button* o = new Fl_Check_Button(300, 270, 20, 25, "button");
       o->down_box(FL_DOWN_BOX);
       o->callback((Fl_Callback*)cb_button1);
       o->align(FL_ALIGN_LEFT);
       proc_bool_parameters.push_back(o);
       o->hide();
     { Fl_Check_Button* o = new Fl_Check_Button(300, 270, 20, 25, "button");
       o->down_box(FL_DOWN_BOX);
       o->callback((Fl_Callback*)cb_button1);
       o->align(FL_ALIGN_LEFT);
       proc_bool_parameters.push_back(o);
       o->hide();
-    } // Fl_Check_Button* o
+    }
     { Fl_Check_Button* o = new Fl_Check_Button(300, 300, 20, 25, "button");
       o->down_box(FL_DOWN_BOX);
       o->callback((Fl_Callback*)cb_button2);
       o->align(FL_ALIGN_LEFT);
       proc_bool_parameters.push_back(o);
       o->hide();
     { Fl_Check_Button* o = new Fl_Check_Button(300, 300, 20, 25, "button");
       o->down_box(FL_DOWN_BOX);
       o->callback((Fl_Callback*)cb_button2);
       o->align(FL_ALIGN_LEFT);
       proc_bool_parameters.push_back(o);
       o->hide();
-    } // Fl_Check_Button* o
+    }
     { Fl_Check_Button* o = new Fl_Check_Button(300, 330, 20, 25, "button");
       o->down_box(FL_DOWN_BOX);
       o->callback((Fl_Callback*)cb_button3);
       o->align(FL_ALIGN_LEFT);
       proc_bool_parameters.push_back(o);
       o->hide();
     { Fl_Check_Button* o = new Fl_Check_Button(300, 330, 20, 25, "button");
       o->down_box(FL_DOWN_BOX);
       o->callback((Fl_Callback*)cb_button3);
       o->align(FL_ALIGN_LEFT);
       proc_bool_parameters.push_back(o);
       o->hide();
-    } // Fl_Check_Button* o
+    }
     { Fl_Check_Button* o = new Fl_Check_Button(300, 360, 20, 25, "button");
       o->down_box(FL_DOWN_BOX);
       o->callback((Fl_Callback*)cb_button4);
       o->align(FL_ALIGN_LEFT);
       proc_bool_parameters.push_back(o);
       o->hide();
     { Fl_Check_Button* o = new Fl_Check_Button(300, 360, 20, 25, "button");
       o->down_box(FL_DOWN_BOX);
       o->callback((Fl_Callback*)cb_button4);
       o->align(FL_ALIGN_LEFT);
       proc_bool_parameters.push_back(o);
       o->hide();
-    } // Fl_Check_Button* o
-    { enable_filter = new Fl_Check_Button(10, 390, 110, 25, "&Enable Filter");
-      enable_filter->down_box(FL_DOWN_BOX);
-      enable_filter->callback((Fl_Callback*)cb_enable_filter);
-      enable_filter->when(FL_WHEN_CHANGED);
-      enable_filter->deactivate();
-    } // Fl_Check_Button* enable_filter
+    }
+    { Fl_Check_Button* o = enable_filter = new Fl_Check_Button(10, 390, 110, 25, "&Enable Filter");
+      o->down_box(FL_DOWN_BOX);
+      o->callback((Fl_Callback*)cb_enable_filter);
+      o->when(FL_WHEN_CHANGED);
+      o->deactivate();
+    }
     { Fl_Group* o = new Fl_Group(0, 0, 330, 385);
     { Fl_Group* o = new Fl_Group(0, 0, 330, 385);
-      { options = new Fl_Browser(10, 20, 110, 365, "Options");
-        options->type(2);
-        options->callback((Fl_Callback*)cb_options);
-        options->align(FL_ALIGN_TOP);
-      } // Fl_Browser* options
-      { pqueue = new Fl_Browser(210, 20, 110, 215, "Queue");
-        pqueue->type(2);
-        pqueue->callback((Fl_Callback*)cb_pqueue);
-        pqueue->align(FL_ALIGN_TOP);
-      } // Fl_Browser* pqueue
+      { Fl_Browser* o = options = new Fl_Browser(10, 20, 110, 365, "Options");
+        o->type(2);
+        o->callback((Fl_Callback*)cb_options);
+        o->align(FL_ALIGN_TOP);
+      }
+      { Fl_Browser* o = pqueue = new Fl_Browser(210, 20, 110, 215, "Queue");
+        o->type(2);
+        o->callback((Fl_Callback*)cb_pqueue);
+        o->align(FL_ALIGN_TOP);
+      }
       { Fl_Button* o = new Fl_Button(130, 20, 70, 20, "@->  add");
         o->callback((Fl_Callback*)cb_add);
         o->align(FL_ALIGN_CENTER|FL_ALIGN_INSIDE);
       { Fl_Button* o = new Fl_Button(130, 20, 70, 20, "@->  add");
         o->callback((Fl_Callback*)cb_add);
         o->align(FL_ALIGN_CENTER|FL_ALIGN_INSIDE);
-      } // Fl_Button* o
+      }
       { Fl_Button* o = new Fl_Button(130, 105, 70, 20, "remove");
         o->callback((Fl_Callback*)cb_remove);
       { Fl_Button* o = new Fl_Button(130, 105, 70, 20, "remove");
         o->callback((Fl_Callback*)cb_remove);
-      } // Fl_Button* o
+      }
       { Fl_Button* o = new Fl_Button(130, 130, 70, 20, "clear");
         o->callback((Fl_Callback*)cb_clear);
       { Fl_Button* o = new Fl_Button(130, 130, 70, 20, "clear");
         o->callback((Fl_Callback*)cb_clear);
-      } // Fl_Button* o
+      }
       { Fl_Button* o = new Fl_Button(130, 50, 70, 20, "up @8->");
         o->callback((Fl_Callback*)cb_up);
         o->align(FL_ALIGN_CENTER|FL_ALIGN_INSIDE);
       { Fl_Button* o = new Fl_Button(130, 50, 70, 20, "up @8->");
         o->callback((Fl_Callback*)cb_up);
         o->align(FL_ALIGN_CENTER|FL_ALIGN_INSIDE);
-      } // Fl_Button* o
+      }
       { Fl_Button* o = new Fl_Button(130, 75, 70, 20, "down @2");
         o->callback((Fl_Callback*)cb_down);
         o->align(FL_ALIGN_CENTER|FL_ALIGN_INSIDE);
       { Fl_Button* o = new Fl_Button(130, 75, 70, 20, "down @2");
         o->callback((Fl_Callback*)cb_down);
         o->align(FL_ALIGN_CENTER|FL_ALIGN_INSIDE);
-      } // Fl_Button* o
+      }
       { Fl_Button* o = new Fl_Button(130, 215, 70, 20, "dismiss");
         o->callback((Fl_Callback*)cb_dismiss);
       { Fl_Button* o = new Fl_Button(130, 215, 70, 20, "dismiss");
         o->callback((Fl_Callback*)cb_dismiss);
-      } // Fl_Button* o
+      }
       { Fl_Button* o = new Fl_Button(175, 160, 25, 20, "def");
         o->tooltip("Load with default name");
         o->labelsize(10);
         o->callback((Fl_Callback*)cb_def);
       { Fl_Button* o = new Fl_Button(175, 160, 25, 20, "def");
         o->tooltip("Load with default name");
         o->labelsize(10);
         o->callback((Fl_Callback*)cb_def);
-      } // Fl_Button* o
+      }
       { Fl_Button* o = new Fl_Button(175, 185, 25, 20, "def");
         o->tooltip("Save with default name");
         o->labelsize(10);
         o->callback((Fl_Callback*)cb_def1);
       { Fl_Button* o = new Fl_Button(175, 185, 25, 20, "def");
         o->tooltip("Save with default name");
         o->labelsize(10);
         o->callback((Fl_Callback*)cb_def1);
-      } // Fl_Button* o
+      }
       { Fl_Button* o = new Fl_Button(130, 160, 45, 20, "Load...");
         o->labelsize(10);
         o->callback((Fl_Callback*)cb_Load5);
       { Fl_Button* o = new Fl_Button(130, 160, 45, 20, "Load...");
         o->labelsize(10);
         o->callback((Fl_Callback*)cb_Load5);
-      } // Fl_Button* o
+      }
       { Fl_Button* o = new Fl_Button(130, 185, 45, 20, "Save...");
         o->labelsize(10);
         o->callback((Fl_Callback*)cb_Save4);
       { Fl_Button* o = new Fl_Button(130, 185, 45, 20, "Save...");
         o->labelsize(10);
         o->callback((Fl_Callback*)cb_Save4);
-      } // Fl_Button* o
+      }
       o->end();
       Fl_Group::current()->resizable(o);
       o->end();
       Fl_Group::current()->resizable(o);
-    } // Fl_Group* o
+    }
     { Fl_Choice* o = new Fl_Choice(210, 240, 110, 25, "choice:");
       o->down_box(FL_BORDER_BOX);
       o->callback((Fl_Callback*)cb_choice);
       proc_choice_parameters.push_back(o);
       o->hide();
     { Fl_Choice* o = new Fl_Choice(210, 240, 110, 25, "choice:");
       o->down_box(FL_BORDER_BOX);
       o->callback((Fl_Callback*)cb_choice);
       proc_choice_parameters.push_back(o);
       o->hide();
-    } // Fl_Choice* o
+    }
     { Fl_Choice* o = new Fl_Choice(210, 270, 110, 25, "choice:");
       o->down_box(FL_BORDER_BOX);
       o->callback((Fl_Callback*)cb_choice1);
       proc_choice_parameters.push_back(o);
       o->hide();
     { Fl_Choice* o = new Fl_Choice(210, 270, 110, 25, "choice:");
       o->down_box(FL_BORDER_BOX);
       o->callback((Fl_Callback*)cb_choice1);
       proc_choice_parameters.push_back(o);
       o->hide();
-    } // Fl_Choice* o
+    }
     { Fl_Choice* o = new Fl_Choice(210, 300, 110, 25, "choice:");
       o->down_box(FL_BORDER_BOX);
       o->callback((Fl_Callback*)cb_choice2);
       proc_choice_parameters.push_back(o);
       o->hide();
     { Fl_Choice* o = new Fl_Choice(210, 300, 110, 25, "choice:");
       o->down_box(FL_BORDER_BOX);
       o->callback((Fl_Callback*)cb_choice2);
       proc_choice_parameters.push_back(o);
       o->hide();
-    } // Fl_Choice* o
+    }
     { Fl_Choice* o = new Fl_Choice(210, 330, 110, 25, "choice:");
       o->down_box(FL_BORDER_BOX);
       o->callback((Fl_Callback*)cb_choice3);
       proc_choice_parameters.push_back(o);
       o->hide();
     { Fl_Choice* o = new Fl_Choice(210, 330, 110, 25, "choice:");
       o->down_box(FL_BORDER_BOX);
       o->callback((Fl_Callback*)cb_choice3);
       proc_choice_parameters.push_back(o);
       o->hide();
-    } // Fl_Choice* o
+    }
     { Fl_Choice* o = new Fl_Choice(210, 360, 110, 25, "choice:");
       o->down_box(FL_BORDER_BOX);
       o->callback((Fl_Callback*)cb_choice4);
       proc_choice_parameters.push_back(o);
       o->hide();
     { Fl_Choice* o = new Fl_Choice(210, 360, 110, 25, "choice:");
       o->down_box(FL_BORDER_BOX);
       o->callback((Fl_Callback*)cb_choice4);
       proc_choice_parameters.push_back(o);
       o->hide();
-    } // Fl_Choice* o
+    }
     { Fl_Button* o = new Fl_Button(120, 390, 95, 25, "button");
       proc_button_parameters.push_back(o);
       o->hide();
     { Fl_Button* o = new Fl_Button(120, 390, 95, 25, "button");
       proc_button_parameters.push_back(o);
       o->hide();
-    } // Fl_Button* o
+    }
     { Fl_Button* o = new Fl_Button(225, 390, 95, 25, "button");
       proc_button_parameters.push_back(o);
       o->hide();
     { Fl_Button* o = new Fl_Button(225, 390, 95, 25, "button");
       proc_button_parameters.push_back(o);
       o->hide();
-    } // Fl_Button* o
-    procwin->end();
-  } // Fl_Double_Window* procwin
-  { normwin = new Fl_Double_Window(275, 485, "Options on Loading File");
+    }
+    o->end();
+  }
+  { Fl_Double_Window* o = normwin = new Fl_Double_Window(275, 485, "Options on Loading File");
+    w = o;
     { Fl_Box* o = new Fl_Box(5, 371, 135, 24, "Window Size:");
       o->labelfont(1);
       o->align(FL_ALIGN_LEFT|FL_ALIGN_INSIDE);
     { Fl_Box* o = new Fl_Box(5, 371, 135, 24, "Window Size:");
       o->labelfont(1);
       o->align(FL_ALIGN_LEFT|FL_ALIGN_INSIDE);
-    } // Fl_Box* o
+    }
     { Fl_Button* o = new Fl_Button(190, 450, 75, 25, "Dismiss");
       o->callback((Fl_Callback*)cb_Dismiss);
     { Fl_Button* o = new Fl_Button(190, 450, 75, 25, "Dismiss");
       o->callback((Fl_Callback*)cb_Dismiss);
-    } // Fl_Button* o
+    }
     { Fl_Group* o = new Fl_Group(25, 388, 185, 67);
     { Fl_Group* o = new Fl_Group(25, 388, 185, 67);
-      { keep_zoom = new Fl_Round_Button(25, 394, 170, 25, "Keep Zoom");
-        keep_zoom->type(102);
-        keep_zoom->down_box(FL_ROUND_DOWN_BOX);
-        keep_zoom->value(1);
-        keep_zoom->callback((Fl_Callback*)cb_keep_zoom);
-      } // Fl_Round_Button* keep_zoom
-      { keep_size = new Fl_Round_Button(25, 419, 170, 25, "Keep Size");
-        keep_size->type(102);
-        keep_size->down_box(FL_ROUND_DOWN_BOX);
-        keep_size->callback((Fl_Callback*)cb_keep_size);
-      } // Fl_Round_Button* keep_size
-      { reset_zoom = new Fl_Round_Button(135, 394, 70, 25, "Reset zoom");
-        reset_zoom->type(102);
-        reset_zoom->down_box(FL_ROUND_DOWN_BOX);
-        reset_zoom->callback((Fl_Callback*)cb_reset_zoom);
-      } // Fl_Round_Button* reset_zoom
+      { Fl_Round_Button* o = keep_zoom = new Fl_Round_Button(25, 394, 170, 25, "Keep Zoom");
+        o->type(102);
+        o->down_box(FL_ROUND_DOWN_BOX);
+        o->value(1);
+        o->callback((Fl_Callback*)cb_keep_zoom);
+      }
+      { Fl_Round_Button* o = keep_size = new Fl_Round_Button(25, 419, 170, 25, "Keep Size");
+        o->type(102);
+        o->down_box(FL_ROUND_DOWN_BOX);
+        o->callback((Fl_Callback*)cb_keep_size);
+      }
+      { Fl_Round_Button* o = reset_zoom = new Fl_Round_Button(135, 394, 70, 25, "Reset zoom");
+        o->type(102);
+        o->down_box(FL_ROUND_DOWN_BOX);
+        o->callback((Fl_Callback*)cb_reset_zoom);
+      }
       o->end();
       o->end();
-    } // Fl_Group* o
-    { norm_on_load = new Fl_Check_Button(25, 35, 95, 15, "Normalize");
-      norm_on_load->down_box(FL_DOWN_BOX);
-      norm_on_load->value(1);
-    } // Fl_Check_Button* norm_on_load
+    }
+    { Fl_Check_Button* o = norm_on_load = new Fl_Check_Button(25, 35, 95, 15, "Normalize");
+      o->down_box(FL_DOWN_BOX);
+      o->value(1);
+    }
     { Fl_Box* o = new Fl_Box(5, 6, 135, 24, "Contrast Adjustments:");
       o->labelfont(1);
       o->align(FL_ALIGN_LEFT|FL_ALIGN_INSIDE);
     { Fl_Box* o = new Fl_Box(5, 6, 135, 24, "Contrast Adjustments:");
       o->labelfont(1);
       o->align(FL_ALIGN_LEFT|FL_ALIGN_INSIDE);
-    } // Fl_Box* o
+    }
     { Fl_Box* o = new Fl_Box(5, 56, 135, 24, "Quantization Control:");
       o->labelfont(1);
       o->align(FL_ALIGN_LEFT|FL_ALIGN_INSIDE);
     { Fl_Box* o = new Fl_Box(5, 56, 135, 24, "Quantization Control:");
       o->labelfont(1);
       o->align(FL_ALIGN_LEFT|FL_ALIGN_INSIDE);
-    } // Fl_Box* o
+    }
     { Fl_Group* o = new Fl_Group(25, 80, 170, 90);
       o->callback((Fl_Callback*)cb_);
     { Fl_Group* o = new Fl_Group(25, 80, 170, 90);
       o->callback((Fl_Callback*)cb_);
-      { a_quant = new Fl_Round_Button(25, 85, 120, 15, "Auto Quantize:");
-        a_quant->tooltip("Automatically pick quantization");
-        a_quant->type(102);
-        a_quant->down_box(FL_ROUND_DOWN_BOX);
-        a_quant->value(1);
-        a_quant->callback((Fl_Callback*)cb_a_quant);
-      } // Fl_Round_Button* a_quant
-      { man_quant = new Fl_Round_Button(25, 110, 170, 15, "Manually set Min/Max:");
-        man_quant->type(102);
-        man_quant->down_box(FL_ROUND_DOWN_BOX);
-        man_quant->callback((Fl_Callback*)cb_man_quant);
-      } // Fl_Round_Button* man_quant
+      { Fl_Round_Button* o = a_quant = new Fl_Round_Button(25, 85, 120, 15, "Auto Quantize:");
+        o->tooltip("Automatically pick quantization");
+        o->type(102);
+        o->down_box(FL_ROUND_DOWN_BOX);
+        o->value(1);
+        o->callback((Fl_Callback*)cb_a_quant);
+      }
+      { Fl_Round_Button* o = man_quant = new Fl_Round_Button(25, 110, 170, 15, "Manually set Min/Max:");
+        o->type(102);
+        o->down_box(FL_ROUND_DOWN_BOX);
+        o->callback((Fl_Callback*)cb_man_quant);
+      }
       o->end();
       o->end();
-    } // Fl_Group* o
-    { a_quant_percent = new Fl_Value_Input(220, 82, 45, 20, "Percent:");
-      a_quant_percent->tooltip("Percent of dynamic range to use");
-      a_quant_percent->labelsize(12);
-      a_quant_percent->maximum(1000);
-      a_quant_percent->value(50);
-      a_quant_percent->callback((Fl_Callback*)cb_a_quant_percent);
-      a_quant_percent->when(FL_WHEN_ENTER_KEY);
-    } // Fl_Value_Input* a_quant_percent
-    { manual_quant = new Fl_Group(60, 130, 211, 57);
-      { qmin = new Fl_Value_Input(70, 135, 115, 20, "Min:");
-        qmin->callback((Fl_Callback*)cb_qmin);
-      } // Fl_Value_Input* qmin
-      { qmax = new Fl_Value_Input(70, 160, 115, 20, "Max:");
-        qmax->callback((Fl_Callback*)cb_qmax);
-      } // Fl_Value_Input* qmax
+    }
+    { Fl_Value_Input* o = a_quant_percent = new Fl_Value_Input(220, 82, 45, 20, "Percent:");
+      o->tooltip("Percent of dynamic range to use");
+      o->labelsize(12);
+      o->maximum(1000);
+      o->value(50);
+      o->callback((Fl_Callback*)cb_a_quant_percent);
+      o->when(FL_WHEN_ENTER_KEY);
+    }
+    { Fl_Group* o = manual_quant = new Fl_Group(60, 130, 211, 57);
+      { Fl_Value_Input* o = qmin = new Fl_Value_Input(70, 135, 115, 20, "Min:");
+        o->callback((Fl_Callback*)cb_qmin);
+      }
+      { Fl_Value_Input* o = qmax = new Fl_Value_Input(70, 160, 115, 20, "Max:");
+        o->callback((Fl_Callback*)cb_qmax);
+      }
       { Fl_Button* o = new Fl_Button(190, 135, 75, 20, "Use Slider");
         o->tooltip("Pick value based on \"Min\" slider in control window");
         o->labelsize(12);
         o->callback((Fl_Callback*)cb_Use);
       { Fl_Button* o = new Fl_Button(190, 135, 75, 20, "Use Slider");
         o->tooltip("Pick value based on \"Min\" slider in control window");
         o->labelsize(12);
         o->callback((Fl_Callback*)cb_Use);
-      } // Fl_Button* o
+      }
       { Fl_Button* o = new Fl_Button(190, 160, 75, 20, "Use Slider");
         o->tooltip("Pick value based on \"Max\" slider in control window");
         o->labelsize(12);
         o->callback((Fl_Callback*)cb_Use1);
       { Fl_Button* o = new Fl_Button(190, 160, 75, 20, "Use Slider");
         o->tooltip("Pick value based on \"Max\" slider in control window");
         o->labelsize(12);
         o->callback((Fl_Callback*)cb_Use1);
-      } // Fl_Button* o
-      manual_quant->end();
-    } // Fl_Group* manual_quant
+      }
+      o->end();
+    }
     { Fl_Box* o = new Fl_Box(5, 191, 135, 24, "DAT File Handling:");
       o->labelfont(1);
       o->align(FL_ALIGN_LEFT|FL_ALIGN_INSIDE);
     { Fl_Box* o = new Fl_Box(5, 191, 135, 24, "DAT File Handling:");
       o->labelfont(1);
       o->align(FL_ALIGN_LEFT|FL_ALIGN_INSIDE);
-    } // Fl_Box* o
+    }
     { Fl_Group* o = new Fl_Group(25, 195, 240, 165);
     { Fl_Group* o = new Fl_Group(25, 195, 240, 165);
-      { dat_type_mat = new Fl_Round_Button(25, 220, 115, 15, "Matrix Format");
-        dat_type_mat->type(102);
-        dat_type_mat->down_box(FL_ROUND_DOWN_BOX);
-        dat_type_mat->value(1);
-        dat_type_mat->callback((Fl_Callback*)cb_dat_type_mat);
-      } // Fl_Round_Button* dat_type_mat
-      { dat_type_gp = new Fl_Round_Button(25, 245, 130, 15, "Gnuplot Format");
-        dat_type_gp->type(102);
-        dat_type_gp->down_box(FL_ROUND_DOWN_BOX);
-        dat_type_gp->callback((Fl_Callback*)cb_dat_type_gp);
-      } // Fl_Round_Button* dat_type_gp
+      { Fl_Round_Button* o = dat_type_mat = new Fl_Round_Button(25, 220, 115, 15, "Matrix Format");
+        o->type(102);
+        o->down_box(FL_ROUND_DOWN_BOX);
+        o->value(1);
+        o->callback((Fl_Callback*)cb_dat_type_mat);
+      }
+      { Fl_Round_Button* o = dat_type_gp = new Fl_Round_Button(25, 245, 130, 15, "Gnuplot Format");
+        o->type(102);
+        o->down_box(FL_ROUND_DOWN_BOX);
+        o->callback((Fl_Callback*)cb_dat_type_gp);
+      }
       { Fl_Group* o = new Fl_Group(45, 265, 105, 50);
       { Fl_Group* o = new Fl_Group(45, 265, 105, 50);
-        { gp_type_col = new Fl_Round_Button(45, 270, 70, 15, "2D");
-          gp_type_col->tooltip("3rd dimension from column number (indices ignored)");
-          gp_type_col->type(102);
-          gp_type_col->down_box(FL_ROUND_DOWN_BOX);
-          gp_type_col->value(1);
-          gp_type_col->callback((Fl_Callback*)cb_gp_type_col);
-        } // Fl_Round_Button* gp_type_col
-        { gp_type_index = new Fl_Round_Button(45, 295, 70, 15, "3D");
-          gp_type_index->tooltip("3rd dimension from index number");
-          gp_type_index->type(102);
-          gp_type_index->down_box(FL_ROUND_DOWN_BOX);
-          gp_type_index->callback((Fl_Callback*)cb_gp_type_index);
-        } // Fl_Round_Button* gp_type_index
+        { Fl_Round_Button* o = gp_type_col = new Fl_Round_Button(45, 270, 70, 15, "2D");
+          o->tooltip("3rd dimension from column number (indices ignored)");
+          o->type(102);
+          o->down_box(FL_ROUND_DOWN_BOX);
+          o->value(1);
+          o->callback((Fl_Callback*)cb_gp_type_col);
+        }
+        { Fl_Round_Button* o = gp_type_index = new Fl_Round_Button(45, 295, 70, 15, "3D");
+          o->tooltip("3rd dimension from index number");
+          o->type(102);
+          o->down_box(FL_ROUND_DOWN_BOX);
+          o->callback((Fl_Callback*)cb_gp_type_index);
+        }
         o->end();
         o->end();
-      } // Fl_Group* o
-      { dat_type_delft = new Fl_Round_Button(25, 320, 155, 15, "Delft Legacy Format");
-        dat_type_delft->type(102);
-        dat_type_delft->down_box(FL_ROUND_DOWN_BOX);
-        dat_type_delft->callback((Fl_Callback*)cb_dat_type_delft);
-      } // Fl_Round_Button* dat_type_delft
-      { gp_parse_txt = new Fl_Check_Button(145, 265, 70, 15, "Parse txt file");
-        gp_parse_txt->tooltip("Read metadata from the delft txt file");
-        gp_parse_txt->down_box(FL_DOWN_BOX);
-        gp_parse_txt->labelsize(10);
-        gp_parse_txt->callback((Fl_Callback*)cb_gp_parse_txt);
-      } // Fl_Check_Button* gp_parse_txt
-      { gp_delft_raw = new Fl_Check_Button(145, 280, 70, 15, "Raw units");
-        gp_delft_raw->tooltip("Use the raw units from the deflt txt file");
-        gp_delft_raw->down_box(FL_DOWN_BOX);
-        gp_delft_raw->labelsize(10);
-        gp_delft_raw->callback((Fl_Callback*)cb_gp_delft_raw);
-      } // Fl_Check_Button* gp_delft_raw
-      { dat_type_meta = new Fl_Round_Button(25, 345, 155, 15, "DAT with meta.txt");
-        dat_type_meta->type(102);
-        dat_type_meta->down_box(FL_ROUND_DOWN_BOX);
-        dat_type_meta->callback((Fl_Callback*)cb_dat_type_meta);
-      } // Fl_Round_Button* dat_type_meta
-      { gp_delft_set = new Fl_Check_Button(145, 295, 70, 15, "Settings");
-        gp_delft_set->tooltip("Put settings in \"sweep\" axis name");
-        gp_delft_set->down_box(FL_DOWN_BOX);
-        gp_delft_set->labelsize(10);
-        gp_delft_set->callback((Fl_Callback*)cb_gp_delft_set);
-      } // Fl_Check_Button* gp_delft_set
+      }
+      { Fl_Round_Button* o = dat_type_delft = new Fl_Round_Button(25, 320, 155, 15, "Delft Legacy Format");
+        o->type(102);
+        o->down_box(FL_ROUND_DOWN_BOX);
+        o->callback((Fl_Callback*)cb_dat_type_delft);
+      }
+      { Fl_Check_Button* o = gp_parse_txt = new Fl_Check_Button(145, 265, 70, 15, "Parse txt file");
+        o->tooltip("Read metadata from the delft txt file");
+        o->down_box(FL_DOWN_BOX);
+        o->labelsize(10);
+        o->callback((Fl_Callback*)cb_gp_parse_txt);
+      }
+      { Fl_Check_Button* o = gp_delft_raw = new Fl_Check_Button(145, 280, 70, 15, "Raw units");
+        o->tooltip("Use the raw units from the deflt txt file");
+        o->down_box(FL_DOWN_BOX);
+        o->labelsize(10);
+        o->callback((Fl_Callback*)cb_gp_delft_raw);
+      }
+      { Fl_Round_Button* o = dat_type_meta = new Fl_Round_Button(25, 345, 155, 15, "DAT with meta.txt");
+        o->type(102);
+        o->down_box(FL_ROUND_DOWN_BOX);
+        o->callback((Fl_Callback*)cb_dat_type_meta);
+      }
+      { Fl_Check_Button* o = gp_delft_set = new Fl_Check_Button(145, 295, 70, 15, "Settings");
+        o->tooltip("Put settings in \"sweep\" axis name");
+        o->down_box(FL_DOWN_BOX);
+        o->labelsize(10);
+        o->callback((Fl_Callback*)cb_gp_delft_set);
+      }
       o->end();
       o->end();
-    } // Fl_Group* o
-    { requantize = new Fl_Button(10, 450, 100, 25, "Requantize");
-      requantize->callback((Fl_Callback*)cb_requantize);
-    } // Fl_Button* requantize
+    }
+    { Fl_Button* o = requantize = new Fl_Button(10, 450, 100, 25, "Requantize");
+      o->callback((Fl_Callback*)cb_requantize);
+    }
     { Fl_Button* o = new Fl_Button(115, 450, 70, 25, "Reload");
       o->callback((Fl_Callback*)cb_Reload1);
     { Fl_Button* o = new Fl_Button(115, 450, 70, 25, "Reload");
       o->callback((Fl_Callback*)cb_Reload1);
-    } // Fl_Button* o
-    { gp_col = new Fl_Value_Input(205, 242, 45, 20, "Col #:");
-      gp_col->tooltip("Set column for 3D data, or default displayed column for 2D data\\nNote: first\
+    }
+    { Fl_Value_Input* o = gp_col = new Fl_Value_Input(205, 242, 45, 20, "Col #:");
+      o->tooltip("Set column for 3D data, or default displayed column for 2D data\\nNote: first\
  column is 1!");
  column is 1!");
-      gp_col->labelsize(12);
-      gp_col->callback((Fl_Callback*)cb_gp_col);
-    } // Fl_Value_Input* gp_col
-    normwin->end();
-  } // Fl_Double_Window* normwin
-  { unitswin = new Fl_Double_Window(290, 235, "Units");
+      o->labelsize(12);
+      o->callback((Fl_Callback*)cb_gp_col);
+    }
+    o->end();
+  }
+  { Fl_Double_Window* o = unitswin = new Fl_Double_Window(290, 235, "Units");
+    w = o;
     { Fl_Group* o = new Fl_Group(200, 25, 85, 85);
       o->end();
       Fl_Group::current()->resizable(o);
     { Fl_Group* o = new Fl_Group(200, 25, 85, 85);
       o->end();
       Fl_Group::current()->resizable(o);
-    } // Fl_Group* o
-    { xmin = new Fl_Value_Input(20, 25, 85, 25, "X");
-      xmin->tooltip("left of image");
-      xmin->callback((Fl_Callback*)cb_xmin);
-      xmin->when(FL_WHEN_RELEASE);
-    } // Fl_Value_Input* xmin
-    { xmax = new Fl_Value_Input(110, 25, 85, 25);
-      xmax->tooltip("right of image");
-      xmax->callback((Fl_Callback*)cb_xmax);
-      xmax->when(FL_WHEN_RELEASE);
-    } // Fl_Value_Input* xmax
-    { xunitname = new Fl_Input(200, 25, 85, 25);
-      xunitname->callback((Fl_Callback*)cb_xunitname);
-    } // Fl_Input* xunitname
-    { ymin = new Fl_Value_Input(20, 55, 85, 25, "Y");
-      ymin->tooltip("bottom of image");
-      ymin->callback((Fl_Callback*)cb_ymin);
-      ymin->when(FL_WHEN_RELEASE);
-    } // Fl_Value_Input* ymin
-    { ymax = new Fl_Value_Input(110, 55, 85, 25);
-      ymax->tooltip("top of image");
-      ymax->callback((Fl_Callback*)cb_ymax);
-      ymax->when(FL_WHEN_RELEASE);
-    } // Fl_Value_Input* ymax
-    { yunitname = new Fl_Input(200, 55, 85, 25);
-      yunitname->callback((Fl_Callback*)cb_yunitname);
-    } // Fl_Input* yunitname
-    { zmin = new Fl_Value_Input(20, 85, 85, 25);
-      zmin->when(FL_WHEN_RELEASE);
-      zmin->deactivate();
-    } // Fl_Value_Input* zmin
-    { zmax = new Fl_Value_Input(110, 85, 85, 25);
-      zmax->when(FL_WHEN_RELEASE);
-      zmax->deactivate();
-    } // Fl_Value_Input* zmax
-    { zunitname = new Fl_Input(200, 85, 85, 25);
-      zunitname->callback((Fl_Callback*)cb_zunitname);
-    } // Fl_Input* zunitname
-    { new Fl_Box(200, 3, 85, 25, "Unit");
-    } // Fl_Box* o
-    { new Fl_Box(20, 3, 85, 25, "Min (b/l)");
-    } // Fl_Box* o
-    { new Fl_Box(110, 3, 85, 25, "Max (t/r)");
-    } // Fl_Box* o
-    { gpusing = new Fl_Input(5, 130, 210, 25, "Gnuplot \"using\" string:");
-      gpusing->callback((Fl_Callback*)cb_gpusing);
-      gpusing->align(FL_ALIGN_TOP);
-    } // Fl_Input* gpusing
-    { gpwith = new Fl_Input(220, 130, 65, 25, "GP \"with\":");
-      gpwith->tooltip("Line style (gnuplot \"with ...\")");
-      gpwith->callback((Fl_Callback*)cb_gpwith);
-      gpwith->align(FL_ALIGN_TOP);
-    } // Fl_Input* gpwith
+    }
+    { Fl_Value_Input* o = xmin = new Fl_Value_Input(20, 25, 85, 25, "X");
+      o->tooltip("left of image");
+      o->callback((Fl_Callback*)cb_xmin);
+      o->when(FL_WHEN_RELEASE);
+    }
+    { Fl_Value_Input* o = xmax = new Fl_Value_Input(110, 25, 85, 25);
+      o->tooltip("right of image");
+      o->callback((Fl_Callback*)cb_xmax);
+      o->when(FL_WHEN_RELEASE);
+    }
+    { Fl_Input* o = xunitname = new Fl_Input(200, 25, 85, 25);
+      o->callback((Fl_Callback*)cb_xunitname);
+    }
+    { Fl_Value_Input* o = ymin = new Fl_Value_Input(20, 55, 85, 25, "Y");
+      o->tooltip("bottom of image");
+      o->callback((Fl_Callback*)cb_ymin);
+      o->when(FL_WHEN_RELEASE);
+    }
+    { Fl_Value_Input* o = ymax = new Fl_Value_Input(110, 55, 85, 25);
+      o->tooltip("top of image");
+      o->callback((Fl_Callback*)cb_ymax);
+      o->when(FL_WHEN_RELEASE);
+    }
+    { Fl_Input* o = yunitname = new Fl_Input(200, 55, 85, 25);
+      o->callback((Fl_Callback*)cb_yunitname);
+    }
+    { Fl_Value_Input* o = zmin = new Fl_Value_Input(20, 85, 85, 25);
+      o->when(FL_WHEN_RELEASE);
+      o->deactivate();
+    }
+    { Fl_Value_Input* o = zmax = new Fl_Value_Input(110, 85, 85, 25);
+      o->when(FL_WHEN_RELEASE);
+      o->deactivate();
+    }
+    { Fl_Input* o = zunitname = new Fl_Input(200, 85, 85, 25);
+      o->callback((Fl_Callback*)cb_zunitname);
+    }
+    new Fl_Box(200, 3, 85, 25, "Unit");
+    new Fl_Box(20, 3, 85, 25, "Min (b/l)");
+    new Fl_Box(110, 3, 85, 25, "Max (t/r)");
+    { Fl_Input* o = gpusing = new Fl_Input(5, 130, 210, 25, "Gnuplot \"using\" string:");
+      o->callback((Fl_Callback*)cb_gpusing);
+      o->align(FL_ALIGN_TOP);
+    }
+    { Fl_Input* o = gpwith = new Fl_Input(220, 130, 65, 25, "GP \"with\":");
+      o->tooltip("Line style (gnuplot \"with ...\")");
+      o->callback((Fl_Callback*)cb_gpwith);
+      o->align(FL_ALIGN_TOP);
+    }
     { Fl_Input* o = new Fl_Input(5, 175, 210, 25, "Send Gnuplot Command");
       o->callback((Fl_Callback*)cb_Send);
       o->align(FL_ALIGN_TOP);
       o->when(FL_WHEN_ENTER_KEY);
     { Fl_Input* o = new Fl_Input(5, 175, 210, 25, "Send Gnuplot Command");
       o->callback((Fl_Callback*)cb_Send);
       o->align(FL_ALIGN_TOP);
       o->when(FL_WHEN_ENTER_KEY);
-    } // Fl_Input* o
+    }
     { Fl_Button* o = new Fl_Button(200, 205, 85, 25, "Dismiss");
       o->callback((Fl_Callback*)cb_Dismiss1);
     { Fl_Button* o = new Fl_Button(200, 205, 85, 25, "Dismiss");
       o->callback((Fl_Callback*)cb_Dismiss1);
-    } // Fl_Button* o
-    { axis_type = new Fl_Choice(110, 205, 85, 25, "Diag. LC axis:");
-      axis_type->tooltip("Data to use for x-axis on diagonal line cuts");
-      axis_type->down_box(FL_BORDER_BOX);
-      axis_type->callback((Fl_Callback*)cb_axis_type);
-      axis_type->menu(menu_axis_type);
-    } // Fl_Choice* axis_type
-    { new Fl_Box(200, 25, 85, 85);
-    } // Fl_Box* o
-    { new Fl_Box(-3, 88, 32, 17, "Z");
-    } // Fl_Box* o
-    { xrange = new Fl_Light_Button(220, 175, 65, 25, "Auto");
-      xrange->callback((Fl_Callback*)cb_xrange);
-    } // Fl_Light_Button* xrange
+    }
+    { Fl_Choice* o = axis_type = new Fl_Choice(110, 205, 85, 25, "Diag. LC axis:");
+      o->tooltip("Data to use for x-axis on diagonal line cuts");
+      o->down_box(FL_BORDER_BOX);
+      o->callback((Fl_Callback*)cb_axis_type);
+      o->menu(menu_axis_type);
+    }
+    new Fl_Box(200, 25, 85, 85);
+    new Fl_Box(-3, 88, 32, 17, "Z");
+    { Fl_Light_Button* o = xrange = new Fl_Light_Button(220, 175, 65, 25, "Auto");
+      o->callback((Fl_Callback*)cb_xrange);
+    }
     { Fl_Box* o = new Fl_Box(219, 158, 55, 15, "Xrange:");
       o->align(FL_ALIGN_LEFT|FL_ALIGN_INSIDE);
     { Fl_Box* o = new Fl_Box(219, 158, 55, 15, "Xrange:");
       o->align(FL_ALIGN_LEFT|FL_ALIGN_INSIDE);
-    } // Fl_Box* o
-    unitswin->end();
-  } // Fl_Double_Window* unitswin
-  { xsecwin = new Fl_Double_Window(295, 210, "3D Cross Section Control");
-    { units3d = new Fl_Group(60, 20, 230, 80);
-      { mtx_xname = new Fl_Input(60, 20, 80, 20, "Name:");
-        mtx_xname->callback((Fl_Callback*)cb_mtx_xname);
-      } // Fl_Input* mtx_xname
-      { mtx_yname = new Fl_Input(140, 20, 75, 20);
-        mtx_yname->callback((Fl_Callback*)cb_mtx_yname);
-      } // Fl_Input* mtx_yname
-      { mtx_zname = new Fl_Input(215, 20, 75, 20);
-        mtx_zname->callback((Fl_Callback*)cb_mtx_zname);
-      } // Fl_Input* mtx_zname
-      { mtx_xmin = new Fl_Value_Input(60, 60, 80, 20, "Min:");
-        mtx_xmin->callback((Fl_Callback*)cb_mtx_xmin);
-        mtx_xmin->when(FL_WHEN_RELEASE);
-      } // Fl_Value_Input* mtx_xmin
-      { mtx_ymin = new Fl_Value_Input(140, 60, 75, 20);
-        mtx_ymin->callback((Fl_Callback*)cb_mtx_ymin);
-        mtx_ymin->when(FL_WHEN_RELEASE);
-      } // Fl_Value_Input* mtx_ymin
-      { mtx_zmin = new Fl_Value_Input(215, 60, 75, 20);
-        mtx_zmin->callback((Fl_Callback*)cb_mtx_zmin);
-        mtx_zmin->when(FL_WHEN_RELEASE);
-      } // Fl_Value_Input* mtx_zmin
-      { mtx_xmax = new Fl_Value_Input(60, 80, 80, 20, "Max:");
-        mtx_xmax->callback((Fl_Callback*)cb_mtx_xmax);
-        mtx_xmax->when(FL_WHEN_RELEASE);
-      } // Fl_Value_Input* mtx_xmax
-      { mtx_ymax = new Fl_Value_Input(140, 80, 75, 20);
-        mtx_ymax->callback((Fl_Callback*)cb_mtx_ymax);
-        mtx_ymax->when(FL_WHEN_RELEASE);
-      } // Fl_Value_Input* mtx_ymax
-      { mtx_zmax = new Fl_Value_Input(215, 80, 75, 20);
-        mtx_zmax->callback((Fl_Callback*)cb_mtx_zmax);
-        mtx_zmax->when(FL_WHEN_RELEASE);
-      } // Fl_Value_Input* mtx_zmax
-      { mtx_x = new Fl_Value_Output(60, 40, 80, 20, "Size:");
-        mtx_x->box(FL_DOWN_BOX);
-      } // Fl_Value_Output* mtx_x
-      { mtx_y = new Fl_Value_Output(140, 40, 75, 20);
-      } // Fl_Value_Output* mtx_y
-      { mtx_z = new Fl_Value_Output(215, 40, 75, 20);
-      } // Fl_Value_Output* mtx_z
-      units3d->end();
-      Fl_Group::current()->resizable(units3d);
-    } // Fl_Group* units3d
-    { controls3d = new Fl_Group(10, 105, 280, 40);
-      { indexbox = new Fl_Value_Input(55, 105, 35, 20, "Index:");
-        indexbox->callback((Fl_Callback*)cb_indexbox);
-        indexbox->when(FL_WHEN_ENTER_KEY);
-      } // Fl_Value_Input* indexbox
-      { indexslider = new Fl_Slider(90, 105, 200, 20);
-        indexslider->type(3);
-        indexslider->step(1);
-        indexslider->callback((Fl_Callback*)cb_indexslider);
-      } // Fl_Slider* indexslider
-      { indexroller = new Fl_Roller(90, 125, 200, 20);
-        indexroller->type(1);
-        indexroller->step(1);
-        indexroller->callback((Fl_Callback*)cb_indexroller);
-      } // Fl_Roller* indexroller
-      { index_value = new Fl_Value_Output(10, 125, 80, 20);
-      } // Fl_Value_Output* index_value
-      controls3d->end();
-    } // Fl_Group* controls3d
+    }
+    o->end();
+  }
+  { Fl_Double_Window* o = xsecwin = new Fl_Double_Window(295, 210, "3D Cross Section Control");
+    w = o;
+    { Fl_Group* o = units3d = new Fl_Group(60, 20, 230, 80);
+      { Fl_Input* o = mtx_xname = new Fl_Input(60, 20, 80, 20, "Name:");
+        o->callback((Fl_Callback*)cb_mtx_xname);
+      }
+      { Fl_Input* o = mtx_yname = new Fl_Input(140, 20, 75, 20);
+        o->callback((Fl_Callback*)cb_mtx_yname);
+      }
+      { Fl_Input* o = mtx_zname = new Fl_Input(215, 20, 75, 20);
+        o->callback((Fl_Callback*)cb_mtx_zname);
+      }
+      { Fl_Value_Input* o = mtx_xmin = new Fl_Value_Input(60, 60, 80, 20, "Min:");
+        o->callback((Fl_Callback*)cb_mtx_xmin);
+        o->when(FL_WHEN_RELEASE);
+      }
+      { Fl_Value_Input* o = mtx_ymin = new Fl_Value_Input(140, 60, 75, 20);
+        o->callback((Fl_Callback*)cb_mtx_ymin);
+        o->when(FL_WHEN_RELEASE);
+      }
+      { Fl_Value_Input* o = mtx_zmin = new Fl_Value_Input(215, 60, 75, 20);
+        o->callback((Fl_Callback*)cb_mtx_zmin);
+        o->when(FL_WHEN_RELEASE);
+      }
+      { Fl_Value_Input* o = mtx_xmax = new Fl_Value_Input(60, 80, 80, 20, "Max:");
+        o->callback((Fl_Callback*)cb_mtx_xmax);
+        o->when(FL_WHEN_RELEASE);
+      }
+      { Fl_Value_Input* o = mtx_ymax = new Fl_Value_Input(140, 80, 75, 20);
+        o->callback((Fl_Callback*)cb_mtx_ymax);
+        o->when(FL_WHEN_RELEASE);
+      }
+      { Fl_Value_Input* o = mtx_zmax = new Fl_Value_Input(215, 80, 75, 20);
+        o->callback((Fl_Callback*)cb_mtx_zmax);
+        o->when(FL_WHEN_RELEASE);
+      }
+      { Fl_Value_Output* o = mtx_x = new Fl_Value_Output(60, 40, 80, 20, "Size:");
+        o->box(FL_DOWN_BOX);
+      }
+      mtx_y = new Fl_Value_Output(140, 40, 75, 20);
+      mtx_z = new Fl_Value_Output(215, 40, 75, 20);
+      o->end();
+      Fl_Group::current()->resizable(o);
+    }
+    { Fl_Group* o = controls3d = new Fl_Group(10, 105, 280, 40);
+      { Fl_Value_Input* o = indexbox = new Fl_Value_Input(55, 105, 35, 20, "Index:");
+        o->callback((Fl_Callback*)cb_indexbox);
+        o->when(FL_WHEN_ENTER_KEY);
+      }
+      { Fl_Slider* o = indexslider = new Fl_Slider(90, 105, 200, 20);
+        o->type(3);
+        o->step(1);
+        o->callback((Fl_Callback*)cb_indexslider);
+      }
+      { Fl_Roller* o = indexroller = new Fl_Roller(90, 125, 200, 20);
+        o->type(1);
+        o->step(1);
+        o->callback((Fl_Callback*)cb_indexroller);
+      }
+      index_value = new Fl_Value_Output(10, 125, 80, 20);
+      o->end();
+    }
     { Fl_Group* o = new Fl_Group(95, 150, 80, 25);
       { Fl_Group* o = new Fl_Group(95, 150, 80, 25);
     { Fl_Group* o = new Fl_Group(95, 150, 80, 25);
       { Fl_Group* o = new Fl_Group(95, 150, 80, 25);
-        { dim = new Fl_Choice(95, 150, 80, 25, "Dimension:");
-          dim->down_box(FL_BORDER_BOX);
-          dim->callback((Fl_Callback*)cb_dim);
-          dim->align(36);
-          dim->menu(menu_dim);
-        } // Fl_Choice* dim
+        { Fl_Choice* o = dim = new Fl_Choice(95, 150, 80, 25, "Dimension:");
+          o->down_box(FL_BORDER_BOX);
+          o->callback((Fl_Callback*)cb_dim);
+          o->align(36);
+          o->menu(menu_dim);
+        }
         o->end();
         o->end();
-      } // Fl_Group* o
+      }
       o->end();
       o->end();
-    } // Fl_Group* o
-    { new Fl_Box(235, 3, 32, 17, "Z");
-    } // Fl_Box* o
-    { new Fl_Box(160, 3, 32, 17, "Y");
-    } // Fl_Box* o
-    { new Fl_Box(85, 3, 32, 17, "X");
-    } // Fl_Box* o
+    }
+    new Fl_Box(235, 3, 32, 17, "Z");
+    new Fl_Box(160, 3, 32, 17, "Y");
+    new Fl_Box(85, 3, 32, 17, "X");
     { Fl_Button* o = new Fl_Button(10, 180, 280, 25, "dismiss");
       o->callback((Fl_Callback*)cb_dismiss1);
     { Fl_Button* o = new Fl_Button(10, 180, 280, 25, "dismiss");
       o->callback((Fl_Callback*)cb_dismiss1);
-    } // Fl_Button* o
-    { mtx_label = new Fl_Light_Button(180, 150, 110, 25, "Label");
-      mtx_label->tooltip("Label data name (Z name in units) with the cross section position");
-      mtx_label->callback((Fl_Callback*)cb_mtx_label);
-    } // Fl_Light_Button* mtx_label
-    xsecwin->end();
-  } // Fl_Double_Window* xsecwin
-  { reload_window = new Fl_Double_Window(360, 65, "Load Files");
-    { reload_text = new Fl_Input(65, 5, 285, 25, "Pattern:");
-      reload_text->tooltip("Enter a list of files or shell wildcards");
-      reload_text->callback((Fl_Callback*)reload_cb);
-      reload_text->when(FL_WHEN_ENTER_KEY_ALWAYS);
-    } // Fl_Input* reload_text
+    }
+    { Fl_Light_Button* o = mtx_label = new Fl_Light_Button(180, 150, 110, 25, "Label");
+      o->tooltip("Label data name (Z name in units) with the cross section position");
+      o->callback((Fl_Callback*)cb_mtx_label);
+    }
+    o->end();
+  }
+  { Fl_Double_Window* o = reload_window = new Fl_Double_Window(360, 65, "Load Files");
+    w = o;
+    { Fl_Input* o = reload_text = new Fl_Input(65, 5, 285, 25, "Pattern:");
+      o->tooltip("Enter a list of files or shell wildcards");
+      o->callback((Fl_Callback*)reload_cb);
+      o->when(FL_WHEN_ENTER_KEY_ALWAYS);
+    }
     { Fl_Button* o = new Fl_Button(260, 35, 90, 25, "Dismiss");
       o->callback((Fl_Callback*)cb_Dismiss2);
     { Fl_Button* o = new Fl_Button(260, 35, 90, 25, "Dismiss");
       o->callback((Fl_Callback*)cb_Dismiss2);
-    } // Fl_Button* o
+    }
     { Fl_Button* o = new Fl_Button(160, 35, 95, 25, "Browse...");
       o->callback((Fl_Callback*)cb_Browse);
     { Fl_Button* o = new Fl_Button(160, 35, 95, 25, "Browse...");
       o->callback((Fl_Callback*)cb_Browse);
-    } // Fl_Button* o
+    }
     { Fl_Group* o = new Fl_Group(5, 35, 170, 25);
       { Fl_Round_Button* o = new Fl_Round_Button(15, 40, 70, 15, "Add");
         o->type(102);
         o->down_box(FL_ROUND_DOWN_BOX);
     { Fl_Group* o = new Fl_Group(5, 35, 170, 25);
       { Fl_Round_Button* o = new Fl_Round_Button(15, 40, 70, 15, "Add");
         o->type(102);
         o->down_box(FL_ROUND_DOWN_BOX);
-      } // Fl_Round_Button* o
-      { replaceb = new Fl_Round_Button(70, 40, 70, 15, "Replace");
-        replaceb->type(102);
-        replaceb->down_box(FL_ROUND_DOWN_BOX);
-        replaceb->value(1);
-      } // Fl_Round_Button* replaceb
+      }
+      { Fl_Round_Button* o = replaceb = new Fl_Round_Button(70, 40, 70, 15, "Replace");
+        o->type(102);
+        o->down_box(FL_ROUND_DOWN_BOX);
+        o->value(1);
+      }
       o->end();
       o->end();
-    } // Fl_Group* o
-    reload_window->end();
-  } // Fl_Double_Window* reload_window
-  { cmapedwin = new Fl_Double_Window(250, 90, "Colormap Editor");
-    { cmrot = new Fl_Value_Slider(45, 10, 195, 20);
-      cmrot->type(3);
-      cmrot->minimum(-360);
-      cmrot->maximum(360);
-      cmrot->step(0.1);
-      cmrot->callback((Fl_Callback*)cb_cmrot);
-      cmrot->align(FL_ALIGN_LEFT);
-    } // Fl_Value_Slider* cmrot
+    }
+    o->end();
+  }
+  { Fl_Double_Window* o = cmapedwin = new Fl_Double_Window(250, 90, "Colormap Editor");
+    w = o;
+    { Fl_Value_Slider* o = cmrot = new Fl_Value_Slider(45, 10, 195, 20);
+      o->type(3);
+      o->minimum(-360);
+      o->maximum(360);
+      o->step(0.1);
+      o->callback((Fl_Callback*)cb_cmrot);
+      o->align(FL_ALIGN_LEFT);
+    }
     { Fl_Button* o = new Fl_Button(45, 30, 35, 20, "zero");
       o->labelsize(9);
       o->callback((Fl_Callback*)cb_zero);
     { Fl_Button* o = new Fl_Button(45, 30, 35, 20, "zero");
       o->labelsize(9);
       o->callback((Fl_Callback*)cb_zero);
-    } // Fl_Button* o
-    { m60 = new Fl_Button(80, 30, 25, 20, "-60");
-      m60->labelsize(9);
-      m60->callback((Fl_Callback*)cb_m60);
-    } // Fl_Button* m60
-    { cmrot_roller = new Fl_Roller(105, 30, 110, 20);
-      cmrot_roller->type(1);
-      cmrot_roller->minimum(-360);
-      cmrot_roller->maximum(360);
-      cmrot_roller->step(0.1);
-      cmrot_roller->callback((Fl_Callback*)cb_cmrot_roller);
-    } // Fl_Roller* cmrot_roller
-    { p60 = new Fl_Button(215, 30, 25, 20, "+60");
-      p60->labelsize(9);
-      p60->callback((Fl_Callback*)cb_p60);
-    } // Fl_Button* p60
-    { new Fl_Box(10, 5, 25, 25, "HSV");
-    } // Fl_Box* o
-    { new Fl_Box(10, 20, 25, 25, "Rot.");
-    } // Fl_Box* o
+    }
+    { Fl_Button* o = m60 = new Fl_Button(80, 30, 25, 20, "-60");
+      o->labelsize(9);
+      o->callback((Fl_Callback*)cb_m60);
+    }
+    { Fl_Roller* o = cmrot_roller = new Fl_Roller(105, 30, 110, 20);
+      o->type(1);
+      o->minimum(-360);
+      o->maximum(360);
+      o->step(0.1);
+      o->callback((Fl_Callback*)cb_cmrot_roller);
+    }
+    { Fl_Button* o = p60 = new Fl_Button(215, 30, 25, 20, "+60");
+      o->labelsize(9);
+      o->callback((Fl_Callback*)cb_p60);
+    }
+    new Fl_Box(10, 5, 25, 25, "HSV");
+    new Fl_Box(10, 20, 25, 25, "Rot.");
     { Fl_Button* o = new Fl_Button(10, 58, 230, 25, "Dismiss");
       o->callback((Fl_Callback*)cb_Dismiss3);
     { Fl_Button* o = new Fl_Button(10, 58, 230, 25, "Dismiss");
       o->callback((Fl_Callback*)cb_Dismiss3);
-    } // Fl_Button* o
-    cmapedwin->end();
-  } // Fl_Double_Window* cmapedwin
-  { location_window = new Fl_Double_Window(395, 160, "Cursor Position");
-    { location_x = new Fl_Output(45, 20, 145, 20, "X");
-      location_x->color((Fl_Color)FL_BACKGROUND_COLOR);
-      location_x->labelsize(12);
-      location_x->textfont(8);
-      location_x->textsize(10);
-      location_x->align(FL_ALIGN_TOP);
-    } // Fl_Output* location_x
-    { location_y = new Fl_Output(240, 20, 150, 20, "Y");
-      location_y->color((Fl_Color)FL_BACKGROUND_COLOR);
-      location_y->labelsize(12);
-      location_y->textfont(8);
-      location_y->textsize(10);
-      location_y->align(FL_ALIGN_TOP);
-    } // Fl_Output* location_y
-    { location_data = new Fl_Output(250, 45, 140, 20);
-      location_data->color((Fl_Color)FL_BACKGROUND_COLOR);
-      location_data->labelsize(11);
-      location_data->textfont(8);
-      location_data->textsize(10);
-    } // Fl_Output* location_data
-    { location_fmt = new Fl_Input(65, 135, 125, 20, "Format:");
-      location_fmt->labelsize(12);
-      location_fmt->textsize(12);
-      location_fmt->when(FL_WHEN_CHANGED);
-    } // Fl_Input* location_fmt
+    }
+    o->end();
+  }
+  { Fl_Double_Window* o = location_window = new Fl_Double_Window(395, 160, "Cursor Position");
+    w = o;
+    { Fl_Output* o = location_x = new Fl_Output(45, 20, 145, 20, "X");
+      o->color(FL_BACKGROUND_COLOR);
+      o->labelsize(12);
+      o->textfont(8);
+      o->textsize(10);
+      o->align(FL_ALIGN_TOP);
+    }
+    { Fl_Output* o = location_y = new Fl_Output(240, 20, 150, 20, "Y");
+      o->color(FL_BACKGROUND_COLOR);
+      o->labelsize(12);
+      o->textfont(8);
+      o->textsize(10);
+      o->align(FL_ALIGN_TOP);
+    }
+    { Fl_Output* o = location_data = new Fl_Output(250, 45, 140, 20);
+      o->color(FL_BACKGROUND_COLOR);
+      o->labelsize(11);
+      o->textfont(8);
+      o->textsize(10);
+    }
+    { Fl_Input* o = location_fmt = new Fl_Input(65, 135, 125, 20, "Format:");
+      o->labelsize(12);
+      o->textsize(12);
+      o->when(FL_WHEN_CHANGED);
+    }
     { Fl_Button* o = new Fl_Button(195, 135, 195, 20, "dismiss");
       o->labelsize(12);
       o->callback((Fl_Callback*)cb_dismiss2);
     { Fl_Button* o = new Fl_Button(195, 135, 195, 20, "dismiss");
       o->labelsize(12);
       o->callback((Fl_Callback*)cb_dismiss2);
-    } // Fl_Button* o
-    { zoom_group = new Fl_Group(0, 63, 390, 67);
-      { zx1v = new Fl_Output(45, 85, 145, 20);
-        zx1v->color((Fl_Color)FL_BACKGROUND_COLOR);
-        zx1v->labelsize(12);
-        zx1v->textfont(8);
-        zx1v->textsize(10);
-        zx1v->align(FL_ALIGN_TOP);
-      } // Fl_Output* zx1v
-      { zx2v = new Fl_Output(45, 105, 145, 20);
-        zx2v->color((Fl_Color)FL_BACKGROUND_COLOR);
-        zx2v->labelsize(12);
-        zx2v->textfont(8);
-        zx2v->textsize(10);
-        zx2v->align(FL_ALIGN_TOP);
-      } // Fl_Output* zx2v
-      { zy2v = new Fl_Output(240, 105, 145, 20);
-        zy2v->color((Fl_Color)FL_BACKGROUND_COLOR);
-        zy2v->labelsize(12);
-        zy2v->textfont(8);
-        zy2v->textsize(10);
-        zy2v->align(FL_ALIGN_TOP);
-      } // Fl_Output* zy2v
-      { zy1v = new Fl_Output(240, 85, 145, 20);
-        zy1v->color((Fl_Color)FL_BACKGROUND_COLOR);
-        zy1v->labelsize(12);
-        zy1v->textfont(8);
-        zy1v->textsize(10);
-        zy1v->align(FL_ALIGN_TOP);
-      } // Fl_Output* zy1v
-      { zx1 = new Fl_Value_Output(5, 85, 40, 20);
-        zx1->textsize(10);
-      } // Fl_Value_Output* zx1
-      { zx2 = new Fl_Value_Output(5, 105, 40, 20);
-        zx2->textsize(10);
-      } // Fl_Value_Output* zx2
-      { zy2 = new Fl_Value_Output(200, 105, 40, 20);
-        zy2->textsize(10);
-      } // Fl_Value_Output* zy2
-      { zy1 = new Fl_Value_Output(200, 85, 40, 20);
-        zy1->textsize(10);
-      } // Fl_Value_Output* zy1
+    }
+    { Fl_Group* o = zoom_group = new Fl_Group(0, 63, 390, 67);
+      { Fl_Output* o = zx1v = new Fl_Output(45, 85, 145, 20);
+        o->color(FL_BACKGROUND_COLOR);
+        o->labelsize(12);
+        o->textfont(8);
+        o->textsize(10);
+        o->align(FL_ALIGN_TOP);
+      }
+      { Fl_Output* o = zx2v = new Fl_Output(45, 105, 145, 20);
+        o->color(FL_BACKGROUND_COLOR);
+        o->labelsize(12);
+        o->textfont(8);
+        o->textsize(10);
+        o->align(FL_ALIGN_TOP);
+      }
+      { Fl_Output* o = zy2v = new Fl_Output(240, 105, 145, 20);
+        o->color(FL_BACKGROUND_COLOR);
+        o->labelsize(12);
+        o->textfont(8);
+        o->textsize(10);
+        o->align(FL_ALIGN_TOP);
+      }
+      { Fl_Output* o = zy1v = new Fl_Output(240, 85, 145, 20);
+        o->color(FL_BACKGROUND_COLOR);
+        o->labelsize(12);
+        o->textfont(8);
+        o->textsize(10);
+        o->align(FL_ALIGN_TOP);
+      }
+      { Fl_Value_Output* o = zx1 = new Fl_Value_Output(5, 85, 40, 20);
+        o->textsize(10);
+      }
+      { Fl_Value_Output* o = zx2 = new Fl_Value_Output(5, 105, 40, 20);
+        o->textsize(10);
+      }
+      { Fl_Value_Output* o = zy2 = new Fl_Value_Output(200, 105, 40, 20);
+        o->textsize(10);
+      }
+      { Fl_Value_Output* o = zy1 = new Fl_Value_Output(200, 85, 40, 20);
+        o->textsize(10);
+      }
       { Fl_Box* o = new Fl_Box(5, 68, 32, 17, "Zoom Window:");
         o->labelsize(11);
         o->align(FL_ALIGN_LEFT|FL_ALIGN_INSIDE);
       { Fl_Box* o = new Fl_Box(5, 68, 32, 17, "Zoom Window:");
         o->labelsize(11);
         o->align(FL_ALIGN_LEFT|FL_ALIGN_INSIDE);
-      } // Fl_Box* o
-      zoom_group->end();
-    } // Fl_Group* zoom_group
-    { x_col = new Fl_Value_Output(5, 20, 40, 20);
-      x_col->textsize(10);
-    } // Fl_Value_Output* x_col
-    { y_row = new Fl_Value_Output(200, 20, 40, 20);
-      y_row->textsize(10);
-    } // Fl_Value_Output* y_row
-    { data_name = new Fl_Output(5, 45, 245, 20);
-      data_name->box(FL_NO_BOX);
-      data_name->color((Fl_Color)FL_BACKGROUND_COLOR);
-      data_name->labelsize(11);
-      data_name->textfont(8);
-      data_name->textsize(10);
-    } // Fl_Output* data_name
-    location_window->end();
-    location_window->resizable(location_window);
-  } // Fl_Double_Window* location_window
-  { helpwin = new Fl_Double_Window(325, 500);
-    { help_text = new Fl_Text_Display(5, 5, 315, 465);
-      help_text->textfont(5);
-      help_text->textsize(11);
-      Fl_Group::current()->resizable(help_text);
-    } // Fl_Text_Display* help_text
+      }
+      o->end();
+    }
+    { Fl_Value_Output* o = x_col = new Fl_Value_Output(5, 20, 40, 20);
+      o->textsize(10);
+    }
+    { Fl_Value_Output* o = y_row = new Fl_Value_Output(200, 20, 40, 20);
+      o->textsize(10);
+    }
+    { Fl_Output* o = data_name = new Fl_Output(5, 45, 245, 20);
+      o->box(FL_NO_BOX);
+      o->color(FL_BACKGROUND_COLOR);
+      o->labelsize(11);
+      o->textfont(8);
+      o->textsize(10);
+    }
+    o->end();
+    o->resizable(o);
+  }
+  { Fl_Double_Window* o = helpwin = new Fl_Double_Window(325, 500);
+    w = o;
+    { Fl_Text_Display* o = help_text = new Fl_Text_Display(5, 5, 315, 465);
+      o->textfont(5);
+      o->textsize(11);
+      Fl_Group::current()->resizable(o);
+    }
     { Fl_Button* o = new Fl_Button(5, 475, 315, 20, "Dismiss");
       o->callback((Fl_Callback*)cb_Dismiss4);
     { Fl_Button* o = new Fl_Button(5, 475, 315, 20, "Dismiss");
       o->callback((Fl_Callback*)cb_Dismiss4);
-    } // Fl_Button* o
-    helpwin->end();
-  } // Fl_Double_Window* helpwin
-  { plane_win = new Fl_Double_Window(245, 165, "Plane subtraction");
-    { planeb = new Fl_Light_Button(5, 5, 115, 25, "Subt. Plane");
-      planeb->tooltip("Enable or disable the plane correction");
-      planeb->callback((Fl_Callback*)cb_planeb);
-    } // Fl_Light_Button* planeb
-    { fitplane = new Fl_Button(125, 5, 55, 25, "Fit");
-      fitplane->tooltip("Do a least-squares fit of the plane correction to the data set");
-      fitplane->callback((Fl_Callback*)cb_fitplane);
-    } // Fl_Button* fitplane
-    { zeroplane = new Fl_Button(185, 5, 55, 25, "Zero ");
-      zeroplane->tooltip("Zero the plane correction");
-      zeroplane->callback((Fl_Callback*)cb_zeroplane);
-    } // Fl_Button* zeroplane
-    { plane_a = new Fl_Value_Input(55, 40, 70, 20, "Vert:");
-      plane_a->minimum(-2);
-      plane_a->maximum(2);
-      plane_a->callback((Fl_Callback*)cb_plane_a);
-      plane_a->when(FL_WHEN_ENTER_KEY);
-    } // Fl_Value_Input* plane_a
-    { plane_aslider = new Fl_Slider(125, 40, 115, 20);
-      plane_aslider->type(3);
-      plane_aslider->minimum(-2);
-      plane_aslider->maximum(2);
-      plane_aslider->step(0.0001);
-      plane_aslider->callback((Fl_Callback*)cb_plane_aslider);
-    } // Fl_Slider* plane_aslider
-    { plane_aroller = new Fl_Roller(55, 60, 185, 20);
-      plane_aroller->type(1);
-      plane_aroller->minimum(-2);
-      plane_aroller->maximum(2);
-      plane_aroller->step(0.0001);
-      plane_aroller->callback((Fl_Callback*)cb_plane_aroller);
-    } // Fl_Roller* plane_aroller
-    { plane_b = new Fl_Value_Input(55, 90, 70, 20, "Horz:");
-      plane_b->minimum(-2);
-      plane_b->maximum(2);
-      plane_b->callback((Fl_Callback*)cb_plane_b);
-      plane_b->when(FL_WHEN_ENTER_KEY);
-    } // Fl_Value_Input* plane_b
-    { plane_bslider = new Fl_Slider(125, 90, 115, 20);
-      plane_bslider->type(3);
-      plane_bslider->minimum(-2);
-      plane_bslider->maximum(2);
-      plane_bslider->step(0.0001);
-      plane_bslider->callback((Fl_Callback*)cb_plane_bslider);
-    } // Fl_Slider* plane_bslider
-    { plane_broller = new Fl_Roller(55, 110, 185, 20);
-      plane_broller->type(1);
-      plane_broller->minimum(-2);
-      plane_broller->maximum(2);
-      plane_broller->step(0.0001);
-      plane_broller->callback((Fl_Callback*)cb_plane_broller);
-    } // Fl_Roller* plane_broller
+    }
+    o->end();
+  }
+  { Fl_Double_Window* o = plane_win = new Fl_Double_Window(245, 165, "Plane subtraction");
+    w = o;
+    { Fl_Light_Button* o = planeb = new Fl_Light_Button(5, 5, 115, 25, "Subt. Plane");
+      o->tooltip("Enable or disable the plane correction");
+      o->callback((Fl_Callback*)cb_planeb);
+    }
+    { Fl_Button* o = fitplane = new Fl_Button(125, 5, 55, 25, "Fit");
+      o->tooltip("Do a least-squares fit of the plane correction to the data set");
+      o->callback((Fl_Callback*)cb_fitplane);
+    }
+    { Fl_Button* o = zeroplane = new Fl_Button(185, 5, 55, 25, "Zero ");
+      o->tooltip("Zero the plane correction");
+      o->callback((Fl_Callback*)cb_zeroplane);
+    }
+    { Fl_Value_Input* o = plane_a = new Fl_Value_Input(55, 40, 70, 20, "Vert:");
+      o->minimum(-2);
+      o->maximum(2);
+      o->callback((Fl_Callback*)cb_plane_a);
+      o->when(FL_WHEN_ENTER_KEY);
+    }
+    { Fl_Slider* o = plane_aslider = new Fl_Slider(125, 40, 115, 20);
+      o->type(3);
+      o->minimum(-2);
+      o->maximum(2);
+      o->step(0.0001);
+      o->callback((Fl_Callback*)cb_plane_aslider);
+    }
+    { Fl_Roller* o = plane_aroller = new Fl_Roller(55, 60, 185, 20);
+      o->type(1);
+      o->minimum(-2);
+      o->maximum(2);
+      o->step(0.0001);
+      o->callback((Fl_Callback*)cb_plane_aroller);
+    }
+    { Fl_Value_Input* o = plane_b = new Fl_Value_Input(55, 90, 70, 20, "Horz:");
+      o->minimum(-2);
+      o->maximum(2);
+      o->callback((Fl_Callback*)cb_plane_b);
+      o->when(FL_WHEN_ENTER_KEY);
+    }
+    { Fl_Slider* o = plane_bslider = new Fl_Slider(125, 90, 115, 20);
+      o->type(3);
+      o->minimum(-2);
+      o->maximum(2);
+      o->step(0.0001);
+      o->callback((Fl_Callback*)cb_plane_bslider);
+    }
+    { Fl_Roller* o = plane_broller = new Fl_Roller(55, 110, 185, 20);
+      o->type(1);
+      o->minimum(-2);
+      o->maximum(2);
+      o->step(0.0001);
+      o->callback((Fl_Callback*)cb_plane_broller);
+    }
     { Fl_Button* o = new Fl_Button(5, 135, 235, 25, "dismiss");
       o->callback((Fl_Callback*)cb_dismiss3);
     { Fl_Button* o = new Fl_Button(5, 135, 235, 25, "dismiss");
       o->callback((Fl_Callback*)cb_dismiss3);
-    } // Fl_Button* o
-    plane_win->end();
-  } // Fl_Double_Window* plane_win
-}
-std::vector<Fl_Input *> proc_parameters; 
-Fl_Browser *last_proc_side; // Last side clicked on in the proc window
-std::vector<Fl_Check_Button *> proc_bool_parameters; 
-std::vector<Fl_Choice *> proc_choice_parameters; 
-std::vector<Fl_Button *> proc_button_parameters; 
+    }
+    o->end();
+  }
+}
+std::vector<Fl_Input *> proc_parameters;
+Fl_Browser *last_proc_side; // Last side clicked on in the proc window;
+std::vector<Fl_Check_Button *> proc_bool_parameters;
+std::vector<Fl_Choice *> proc_choice_parameters;
+std::vector<Fl_Button *> proc_button_parameters;
 
 void reload_data() {
   iw->reRunQueue();
 
 void reload_data() {
   iw->reRunQueue();
index 34abb1f1b25b370da084a1eaebe97746e3623021..2292d88c440808352871bf5d2366f853e18fadea 100644 (file)
@@ -1,9 +1,8 @@
 # data file for the Fltk User Interface Designer (fluid)
 # data file for the Fltk User Interface Designer (fluid)
-version 1.0109 
+version 1.0107 
 header_name {.h} 
 code_name {.C}
 header_name {.h} 
 code_name {.C}
-decl {\#include "spypal_interface.H"} {global
-} 
+decl {\#include "spypal_interface.H"} {} 
 
 decl {\#include "ImageWindow.H"} {public
 } 
 
 decl {\#include "ImageWindow.H"} {public
 } 
@@ -26,7 +25,7 @@ Function {make_window()} {open C return_type void
 } {
   Fl_Window control {
     label Controls open
 } {
   Fl_Window control {
     label Controls open
-    xywh {320 341 570 425} type Double visible
+    xywh {507 252 570 425} type Double visible
   } {
     Fl_Choice filech {
       label {file:}
   } {
     Fl_Choice filech {
       label {file:}
@@ -239,7 +238,7 @@ normb->do_callback();}
     }
     Fl_Input savebox {
       label {basename:}
     }
     Fl_Input savebox {
       label {basename:}
-      callback {strncpy(iw->output_basename,savebox->value(),256); }
+      callback {strncpy(iw->output_basename,savebox->value(),256);}
       xywh {320 300 245 25} labelsize 11 textsize 10
     }
     Fl_Button saveb {
       xywh {320 300 245 25} labelsize 11 textsize 10
     }
     Fl_Button saveb {
@@ -360,20 +359,46 @@ else
     }
     Fl_Button {} {
       label {Save Settings}
     }
     Fl_Button {} {
       label {Save Settings}
-      callback {\#ifdef WIN32foo
-warn("Save settings in main window temporarilty\\ndisabled in Win32 due to bug\\n");
-\#else
-char *fname = fl_file_chooser("Save Settings","Settings (*.svs)",spyviewSettingsDir);
+      callback {if (Fl::event_state() & FL_SHIFT)
+{
+       Fl_File_Chooser chooser(".", 
+                       "(*.svs)\\t",
+                       Fl_File_Chooser::CREATE,
+                       "Select files");
+       chooser.preview(0);
+       chooser.show();
+       while (chooser.shown()) Fl::wait();
+       if (chooser.value() == NULL) return;
+       savesettings(chooser.value(1));
+}
+else
+{
+       char *fname = fl_file_chooser("Save Settings","Settings (*.svs)",spyviewSettingsDir);
        if(fname != NULL)
          savesettings(fname);
        if(fname != NULL)
          savesettings(fname);
-\#endif}
+}}
       tooltip {Save the spyview settings} xywh {250 365 105 25} labelsize 12
     }
     Fl_Button {} {
       label {Load Settings}
       tooltip {Save the spyview settings} xywh {250 365 105 25} labelsize 12
     }
     Fl_Button {} {
       label {Load Settings}
-      callback {char *fname = fl_file_chooser("Load Spyview Settings","Settings (*.svs)",spyviewSettingsDir);
-if(fname != NULL)
-  loadsettings(fname);}
+      callback {if (Fl::event_state() & FL_SHIFT)
+{
+       Fl_File_Chooser chooser(".", 
+                       "(*.svs)\\t",
+                       Fl_File_Chooser::CREATE,
+                       "Select files");
+       chooser.preview(0);
+       chooser.show();
+       while (chooser.shown()) Fl::wait();
+       if (chooser.value() == NULL) return;
+       loadsettings(chooser.value(1));
+}
+else
+{
+       char *fname = fl_file_chooser("Load Spyview Settings","Settings (*.svs)",spyviewSettingsDir);
+       if(fname != NULL)
+               loadsettings(fname);
+}} selected
       tooltip {Load the Spyview settings} xywh {360 365 95 25} labelsize 12
     }
     Fl_Value_Output xsize {
       tooltip {Load the Spyview settings} xywh {360 365 95 25} labelsize 12
     }
     Fl_Value_Output xsize {
@@ -524,7 +549,7 @@ saveColors(chooser.value(1));}
       xywh {255 236 55 19} labelsize 12 align 20
     }
     Fl_Button {} {
       xywh {255 236 55 19} labelsize 12 align 20
     }
     Fl_Button {} {
-      callback cmapedit_cb selected
+      callback cmapedit_cb
       tooltip {Edit the current colormap.  If the colormap is a .ppm file, an import wizard will open to help you convert it to .spp} image {edit.png} xywh {460 5 25 25}
     }
   }
       tooltip {Edit the current colormap.  If the colormap is a .ppm file, an import wizard will open to help you convert it to .spp} image {edit.png} xywh {460 5 25 25}
     }
   }
index 83a283cf53008e37421d229c2a8f51ad17947e94..2a15a5c7389cb9623f88143750bbf4aa187dd098 100644 (file)
@@ -1,4 +1,4 @@
-// generated by Fast Light User Interface Designer (fluid) version 1.0110
+// generated by Fast Light User Interface Designer (fluid) version 1.0107
 
 #ifndef spyview_ui_h
 #define spyview_ui_h
 
 #ifndef spyview_ui_h
 #define spyview_ui_h
@@ -184,10 +184,10 @@ extern "C" { void make_window(); }
 extern Fl_Menu_Item menu_export_type[];
 extern Fl_Menu_Item menu_axis_type[];
 extern Fl_Menu_Item menu_dim[];
 extern Fl_Menu_Item menu_export_type[];
 extern Fl_Menu_Item menu_axis_type[];
 extern Fl_Menu_Item menu_dim[];
-extern std::vector<Fl_Input *> proc_parameters; 
-extern Fl_Browser *last_proc_side; // Last side clicked on in the proc window
-extern std::vector<Fl_Check_Button *> proc_bool_parameters; 
-extern std::vector<Fl_Choice *> proc_choice_parameters; 
-extern std::vector<Fl_Button *> proc_button_parameters; 
+extern std::vector<Fl_Input *> proc_parameters;
+extern Fl_Browser *last_proc_side; // Last side clicked on in the proc window;
+extern std::vector<Fl_Check_Button *> proc_bool_parameters;
+extern std::vector<Fl_Choice *> proc_choice_parameters;
+extern std::vector<Fl_Button *> proc_button_parameters;
 void reload_data();
 #endif
 void reload_data();
 #endif