Ejemplo n.º 1
0
ct_image_window::ct_image_window( ) {
  Fl_Double_Window* w;
  { Fl_Double_Window* o = image_window = new Fl_Double_Window(421, 528);
    w = o;
    o->user_data((void*)(this));
    { Fl_Group* o = new Fl_Group(5, 30, 410, 410);
      o->box(FL_PLASTIC_DOWN_FRAME);
      { ct_draw_area* o = ct_image = new ct_draw_area(10, 35, 400, 400, "label");
        o->box(FL_FLAT_BOX);
        o->color(FL_DARK3);
        o->selection_color(FL_BACKGROUND_COLOR);
        o->labeltype(FL_NORMAL_LABEL);
        o->labelfont(0);
        o->labelsize(14);
        o->labelcolor(FL_BLACK);
        o->align(FL_ALIGN_CENTER);
        o->when(FL_WHEN_RELEASE);
      }
      o->end();
    }
    { Fl_Menu_Bar* o = new Fl_Menu_Bar(0, 0, 100, 25);
      o->box(FL_FLAT_BOX);
      o->menu(menu_);
    }
    { Fl_Value_Slider* o = WL = new Fl_Value_Slider(40, 470, 375, 20, "WL");
      o->type(1);
      o->box(FL_PLASTIC_THIN_DOWN_BOX);
      o->minimum(-2000);
      o->maximum(7000);
      o->step(1);
      o->value(40);
      o->callback((Fl_Callback*)cb_WL);
      o->align(FL_ALIGN_LEFT);
    }
    { Fl_Value_Slider* o = WW = new Fl_Value_Slider(40, 495, 375, 20, "WW");
      o->type(1);
      o->box(FL_PLASTIC_THIN_DOWN_BOX);
      o->minimum(1);
      o->maximum(4000);
      o->step(1);
      o->value(300);
      o->callback((Fl_Callback*)cb_WW);
      o->align(FL_ALIGN_LEFT);
    }
    { Fl_Value_Slider* o = Indx = new Fl_Value_Slider(40, 445, 375, 20, "Indx");
      o->type(1);
      o->box(FL_PLASTIC_THIN_DOWN_BOX);
      o->step(1);
      o->callback((Fl_Callback*)cb_Indx);
      o->align(FL_ALIGN_LEFT);
    }
    { Fl_Progress* o = progress_bar = new Fl_Progress(115, 5, 300, 20);
      o->box(FL_PLASTIC_THIN_UP_BOX);
      o->selection_color((Fl_Color)1);
      o->hide();
    }
    o->end();
  }
}
Ejemplo n.º 2
0
FltDesignUI::FltDesignUI() {
  Fl_Window* w;
  { Fl_Window* o = mainWindow = new Fl_Window(439, 249, "Filter Design UI");
    w = o;
    o->user_data((void*)(this));
    { Fl_Group* o = kernel = new Fl_Group(0, 20, 272, 140, "Filter Kernel");
      o->box(FL_ENGRAVED_FRAME);
      o->when(FL_WHEN_CHANGED);
      { Fl_Value_Input* o = ele0 = new Fl_Value_Input(5, 26, 50, 25);
        o->maximum(255);
        o->callback((Fl_Callback*)cb_ele0);
      }
      { Fl_Value_Input* o = ele1 = new Fl_Value_Input(58, 26, 50, 25);
        o->maximum(255);
        o->callback((Fl_Callback*)cb_ele1);
      }
      { Fl_Value_Input* o = ele2 = new Fl_Value_Input(111, 26, 50, 25);
        o->maximum(255);
        o->callback((Fl_Callback*)cb_ele2);
      }
      { Fl_Value_Input* o = ele3 = new Fl_Value_Input(164, 26, 50, 25);
        o->maximum(255);
        o->callback((Fl_Callback*)cb_ele3);
      }
      { Fl_Value_Input* o = ele4 = new Fl_Value_Input(217, 26, 50, 25);
        o->maximum(255);
        o->callback((Fl_Callback*)cb_ele4);
      }
      { Fl_Value_Input* o = ele5 = new Fl_Value_Input(5, 52, 50, 25);
        o->maximum(255);
        o->callback((Fl_Callback*)cb_ele5);
      }
      { Fl_Value_Input* o = ele6 = new Fl_Value_Input(58, 52, 50, 25);
        o->maximum(255);
        o->callback((Fl_Callback*)cb_ele6);
      }
      { Fl_Value_Input* o = ele7 = new Fl_Value_Input(111, 52, 50, 25);
        o->maximum(255);
        o->callback((Fl_Callback*)cb_ele7);
      }
      { Fl_Value_Input* o = ele8 = new Fl_Value_Input(164, 52, 50, 25);
        o->maximum(255);
        o->callback((Fl_Callback*)cb_ele8);
      }
      { Fl_Value_Input* o = ele9 = new Fl_Value_Input(217, 52, 50, 25);
        o->maximum(255);
        o->callback((Fl_Callback*)cb_ele9);
      }
      { Fl_Value_Input* o = ele10 = new Fl_Value_Input(5, 78, 50, 25);
        o->maximum(255);
        o->callback((Fl_Callback*)cb_ele10);
      }
      { Fl_Value_Input* o = ele11 = new Fl_Value_Input(58, 78, 50, 25);
        o->maximum(255);
        o->callback((Fl_Callback*)cb_ele11);
      }
      { Fl_Value_Input* o = ele12 = new Fl_Value_Input(111, 78, 50, 25);
        o->maximum(255);
        o->value(1);
        o->callback((Fl_Callback*)cb_ele12);
      }
      { Fl_Value_Input* o = ele13 = new Fl_Value_Input(164, 78, 50, 25);
        o->maximum(255);
        o->callback((Fl_Callback*)cb_ele13);
      }
      { Fl_Value_Input* o = ele14 = new Fl_Value_Input(217, 78, 50, 25);
        o->maximum(255);
        o->callback((Fl_Callback*)cb_ele14);
      }
      { Fl_Value_Input* o = ele15 = new Fl_Value_Input(5, 104, 50, 25);
        o->maximum(255);
        o->callback((Fl_Callback*)cb_ele15);
      }
      { Fl_Value_Input* o = ele16 = new Fl_Value_Input(58, 104, 50, 25);
        o->maximum(255);
        o->callback((Fl_Callback*)cb_ele16);
      }
      { Fl_Value_Input* o = ele17 = new Fl_Value_Input(111, 104, 50, 25);
        o->maximum(255);
        o->callback((Fl_Callback*)cb_ele17);
      }
      { Fl_Value_Input* o = ele18 = new Fl_Value_Input(164, 104, 50, 25);
        o->maximum(255);
        o->callback((Fl_Callback*)cb_ele18);
      }
      { Fl_Value_Input* o = ele19 = new Fl_Value_Input(217, 104, 50, 25);
        o->maximum(255);
        o->callback((Fl_Callback*)cb_ele19);
      }
      { Fl_Value_Input* o = ele20 = new Fl_Value_Input(5, 130, 50, 25);
        o->maximum(255);
        o->callback((Fl_Callback*)cb_ele20);
      }
      { Fl_Value_Input* o = ele21 = new Fl_Value_Input(58, 130, 50, 25);
        o->maximum(255);
        o->callback((Fl_Callback*)cb_ele21);
      }
      { Fl_Value_Input* o = ele22 = new Fl_Value_Input(111, 130, 50, 25);
        o->maximum(255);
        o->callback((Fl_Callback*)cb_ele22);
      }
      { Fl_Value_Input* o = ele23 = new Fl_Value_Input(164, 130, 50, 25);
        o->maximum(255);
        o->callback((Fl_Callback*)cb_ele23);
      }
      { Fl_Value_Input* o = ele24 = new Fl_Value_Input(217, 130, 50, 25);
        o->maximum(255);
        o->callback((Fl_Callback*)cb_ele24);
      }
      o->end();
    }
    { Fl_Value_Input* o = scale = new Fl_Value_Input(112, 163, 154, 25, "Divide by::");
      o->maximum(255);
      o->value(1);
      o->callback((Fl_Callback*)cb_scale);
    }
    { Fl_Value_Input* o = offset = new Fl_Value_Input(112, 191, 154, 25, "Offset:");
      o->maximum(255);
      o->callback((Fl_Callback*)cb_offset);
    }
    { Fl_Group* o = new Fl_Group(280, 20, 160, 64, "Filter Range");
      o->box(FL_ENGRAVED_FRAME);
      { Fl_Round_Button* o = image = new Fl_Round_Button(284, 27, 68, 28, "Whole Image");
        o->type(102);
        o->down_box(FL_ROUND_DOWN_BOX);
      }
      { Fl_Round_Button* o = selection = new Fl_Round_Button(284, 51, 68, 28, "Brush Selection");
        o->type(102);
        o->down_box(FL_ROUND_DOWN_BOX);
      }
      o->end();
    }
    { Fl_Button* o = new Fl_Button(4, 224, 124, 24, "Load");
      o->callback((Fl_Callback*)cb_Load);
    }
    { Fl_Button* o = new Fl_Button(144, 224, 124, 24, "Save");
      o->callback((Fl_Callback*)cb_Save);
    }
    { Fl_Button* o = new Fl_Button(280, 125, 156, 24, "Preview");
      o->callback((Fl_Callback*)cb_Preview);
    }
    { Fl_Button* o = new Fl_Button(280, 159, 156, 24, "Cancel");
      o->callback((Fl_Callback*)cb_Cancel);
    }
    { Fl_Button* o = new Fl_Button(280, 192, 156, 24, "Accept");
      o->callback((Fl_Callback*)cb_Accept);
    }
    { Fl_Button* o = new Fl_Button(280, 224, 156, 24, "Close");
      o->callback((Fl_Callback*)cb_Close);
    }
    o->end();
  }
}