当前位置: 首页>>代码示例>>C++>>正文


C++ Fl_Box::labeltype方法代码示例

本文整理汇总了C++中Fl_Box::labeltype方法的典型用法代码示例。如果您正苦于以下问题:C++ Fl_Box::labeltype方法的具体用法?C++ Fl_Box::labeltype怎么用?C++ Fl_Box::labeltype使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在Fl_Box的用法示例。


在下文中一共展示了Fl_Box::labeltype方法的7个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。

示例1: main

int main(int argc, char **argv) {
  Fl_Window *window = new Fl_Window(300,180);
  Fl_Box *box = new Fl_Box(FL_UP_BOX,20,40,260,100,"Hello, World!");
  box->labelfont(FL_BOLD+FL_ITALIC);
  box->labelsize(36);
  box->labeltype(FL_SHADOW_LABEL);
  window->end();
  window->show(argc, argv);
  return Fl::run();
}
开发者ID:tasosbull,项目名称:yewtic,代码行数:10,代码来源:main.cpp

示例2: main

int main(int argc, char *argv[]) {
    	Fl_Window *window = new Fl_Window (800,700,"TETRIS");
	window->color(56);
	Board *b = new Board();
	Fl_Box *scorebox = new Fl_Box(tilesize*xmaxtiles+10,50,300,200,"Score: 0\0");
	scorebox->box(FL_UP_BOX);
	scorebox->labelfont(FL_BOLD+FL_ITALIC);
    scorebox->labelsize(36);
    scorebox->labeltype(FL_ENGRAVED_LABEL);
	b->setScoreBox(&scorebox); 
	Fl_Box *exi = new Fl_Box(tilesize*2,ymaxtiles*15,300,200,"Press Escape to Exit");
	exi->box(FL_UP_BOX);
	exi->labelfont(FL_BOLD+FL_ITALIC);
	exi->labelsize(36);
	exi->labeltype(FL_ENGRAVED_LABEL);
	window->end(); 
   	window->show();
   	
	Fl::add_timeout(0.1, timeractions,b);
    	return(Fl::run());
}
开发者ID:vaibhavb007,项目名称:advanced_graphics,代码行数:21,代码来源:tetris.cpp

示例3: main

int main(int argc, char **argv) {
  Fl_Window *window = new Fl_Window(340,180,"世界へようこそ!");
  Fl_Box *box = new Fl_Box(20,40,300,100,"ようこそ、世界!"); 
  Fl::set_font(FL_HELVETICA, "Kochi Mincho");

  window->begin();

  // Fl_Widget(x, y, width, height, label)

  //box->box(FL_UP_BOX);
  box->box(FL_NO_BOX);
  box->labelsize(36);
  box->labeltype(FL_SHADOW_LABEL);

  window->end();
  window->show(argc, argv);

  return Fl::run();
}
开发者ID:tiborh,项目名称:cplusplus,代码行数:19,代码来源:hello_jp.cpp

示例4: calImageWindow

stereogui::stereogui() {
  { stereo_calibration = new Fl_Window(785, 400, "Stereo Calibration");
    stereo_calibration->labelsize(11);
    stereo_calibration->user_data((void*)(this));
    { Fl_Group* o = new Fl_Group(10, 10, 850, 355);
      { window_tab = new Fl_Tabs(10, 10, 665, 285);
        window_tab->box(FL_UP_BOX);
        window_tab->labeltype(FL_NO_LABEL);
        { tab0 = new Fl_Group(25, 55, 660, 250, "Stereo               ");
          tab0->labelsize(11);
          tab0->user_data((void*)(-1));
          { Fl_Group* o = new Fl_Group(30, 55, 645, 245);
            { Fl_Group* o = new Fl_Group(30, 55, 320, 245);
              { Fl_Box* o = new Fl_Box(30, 55, 320, 240);
                o->box(FL_EMBOSSED_FRAME);
                o->labeltype(FL_NO_LABEL);
              } // Fl_Box* o
              { calLeft0 = new calImageWindow(30, 55, 320, 240);
                calLeft0->box(FL_NO_BOX);
                calLeft0->color(FL_BACKGROUND_COLOR);
                calLeft0->selection_color(FL_BACKGROUND_COLOR);
                calLeft0->labeltype(FL_NO_LABEL);
                calLeft0->labelfont(0);
                calLeft0->labelsize(14);
                calLeft0->labelcolor(FL_FOREGROUND_COLOR);
                calLeft0->align(FL_ALIGN_CENTER);
                calLeft0->when(FL_WHEN_RELEASE);
              } // calImageWindow* calLeft0
              o->end();
            } // Fl_Group* o
            { Fl_Group* o = new Fl_Group(355, 55, 320, 245);
              { Fl_Box* o = new Fl_Box(355, 55, 320, 240);
                o->box(FL_EMBOSSED_FRAME);
                o->labeltype(FL_NO_LABEL);
              } // Fl_Box* o
              { calRight0 = new calImageWindow(355, 55, 320, 240);
                calRight0->box(FL_NO_BOX);
                calRight0->color(FL_BACKGROUND_COLOR);
                calRight0->selection_color(FL_BACKGROUND_COLOR);
                calRight0->labeltype(FL_NO_LABEL);
                calRight0->labelfont(0);
                calRight0->labelsize(14);
                calRight0->labelcolor(FL_FOREGROUND_COLOR);
                calRight0->align(FL_ALIGN_CENTER);
                calRight0->when(FL_WHEN_RELEASE);
              } // calImageWindow* calRight0
              o->end();
            } // Fl_Group* o
            o->end();
          } // Fl_Group* o
          tab0->end();
        } // Fl_Group* tab0
        { tab1 = new Fl_Group(15, 45, 660, 250, " 1 ");
          tab1->labelsize(11);
          tab1->user_data((void*)(0));
          tab1->hide();
          tab1->deactivate();
          { Fl_Group* o = new Fl_Group(20, 45, 645, 245);
            { Fl_Group* o = new Fl_Group(20, 45, 320, 245);
              { Fl_Box* o = new Fl_Box(20, 45, 320, 240);
                o->box(FL_EMBOSSED_FRAME);
                o->labeltype(FL_NO_LABEL);
              } // Fl_Box* o
              { calLeft1 = new calImageWindow(20, 45, 320, 240);
                calLeft1->box(FL_NO_BOX);
                calLeft1->color(FL_BACKGROUND_COLOR);
                calLeft1->selection_color(FL_BACKGROUND_COLOR);
                calLeft1->labeltype(FL_NO_LABEL);
                calLeft1->labelfont(0);
                calLeft1->labelsize(14);
                calLeft1->labelcolor(FL_FOREGROUND_COLOR);
                calLeft1->align(FL_ALIGN_CENTER);
                calLeft1->when(FL_WHEN_RELEASE);
              } // calImageWindow* calLeft1
              o->end();
            } // Fl_Group* o
            { Fl_Group* o = new Fl_Group(345, 45, 320, 245);
              { Fl_Box* o = new Fl_Box(345, 45, 320, 240);
                o->box(FL_EMBOSSED_FRAME);
                o->labeltype(FL_NO_LABEL);
              } // Fl_Box* o
              { calRight1 = new calImageWindow(345, 45, 320, 240);
                calRight1->box(FL_NO_BOX);
                calRight1->color(FL_BACKGROUND_COLOR);
                calRight1->selection_color(FL_BACKGROUND_COLOR);
                calRight1->labeltype(FL_NO_LABEL);
                calRight1->labelfont(0);
                calRight1->labelsize(14);
                calRight1->labelcolor(FL_FOREGROUND_COLOR);
                calRight1->align(FL_ALIGN_CENTER);
                calRight1->when(FL_WHEN_RELEASE);
              } // calImageWindow* calRight1
              o->end();
            } // Fl_Group* o
            o->end();
          } // Fl_Group* o
          tab1->end();
        } // Fl_Group* tab1
        { tab2 = new Fl_Group(15, 35, 660, 260, " 2");
          tab2->labelsize(11);
//.........这里部分代码省略.........
开发者ID:janfrs,项目名称:kwc-ros-pkg,代码行数:101,代码来源:stereogui.cpp

示例5: getMeshInfoForHighOrder

highOrderToolsWindow::highOrderToolsWindow(int deltaFontSize)
{
  getMeshInfoForHighOrder(GModel::current(), meshOrder, complete, CAD);
  FL_NORMAL_SIZE -= deltaFontSize;

  int width = 3 * IW + 4 * WB;
  int height = 24 * BH;

  win = new paletteWindow
    (width, height, CTX::instance()->nonModalWindows ? true : false, "High order tools");
  win->box(GMSH_WINDOW_BOX);

  int y = WB;
  int x = 2 * WB;

  box[0] = new Fl_Box(x, y, width - 4 * WB, BH);
  box[0]->align(FL_ALIGN_LEFT|FL_ALIGN_INSIDE);

  y += BH;

  butt[1] = new Fl_Check_Button
    (x, y, width - 4 * WB, BH, "Only apply high order tools to visible entities");
  butt[1]->type(FL_TOGGLE_BUTTON);
  butt[1]->value(1);

  y += BH;

  butt[3] = new Fl_Check_Button
    (x, y, width - 4 * WB, BH, "Show detailed log messages");
  butt[3]->type(FL_TOGGLE_BUTTON);
  butt[3]->value(1);

  {
    y += BH / 2;
    Fl_Box* b = new Fl_Box(x, y + BH - WB, width - 4 * WB, 2);
    b->box(FL_ENGRAVED_FRAME);
    b->labeltype(FL_NO_LABEL);
  }

  {
    y += BH;
    Fl_Box *b = new Fl_Box
      (x - WB, y, width, BH, "1. Generation of high order vertices");
    b->align(FL_ALIGN_LEFT | FL_ALIGN_INSIDE);
  }

  y += BH;

  value[0] = new Fl_Value_Input
    (x, y, IW, BH, "Polynomial order");
  value[0]->minimum(1);
  value[0]->maximum(10);
  value[0]->step(1);
  value[0]->align(FL_ALIGN_RIGHT);
  value[0]->value(meshOrder);

  y += BH;

  butt[0] = new Fl_Check_Button
    (x, y, width - 4 * WB, BH, "Use incomplete elements");
  butt[0]->type(FL_TOGGLE_BUTTON);
  butt[0]->value(!complete);
  butt[0]->callback(change_completeness_cb);

  y += BH;

  butt[2] = new Fl_Check_Button
    (x, y, width - 4 * WB, BH, "Use CAD model to curve mesh");
  butt[2]->type(FL_TOGGLE_BUTTON);
  butt[2]->value(1);

  y += BH;

  push[0] = new Fl_Button
    (width - BB - 2 * WB, y, BB, BH, "Generate");
  push[0]->callback(highordertools_runp_cb);

  {
    y += BH / 2;
    Fl_Box* b = new Fl_Box(x, y + BH - WB, width - 4 * WB, 2);
    b->box(FL_ENGRAVED_FRAME);
    b->labeltype(FL_NO_LABEL);
  }

  {
    y += BH;
    Fl_Box *b = new Fl_Box
      (x - WB, y, width, BH, "2. Regularization of high order elements");
    b->align(FL_ALIGN_LEFT | FL_ALIGN_INSIDE);
  }

  y += BH;
  static Fl_Menu_Item menu_method[] = {
    {"Optimization", 0, 0, 0},
    {"Elastic Analogy", 0, 0, 0},
    {"Fast Curving", 0, 0, 0},
    {0}
  };
  choice[2] = new Fl_Choice
    (x, y, IW, BH, "Algorithm");
//.........这里部分代码省略.........
开发者ID:feelpp,项目名称:debian-gmsh,代码行数:101,代码来源:highOrderToolsWindow.cpp

示例6: box

Mixer::Mixer ( int X, int Y, int W, int H, const char *L ) :
    Fl_Group( X, Y, W, H, L )
{
    Loggable::dirty_callback( &Mixer::handle_dirty, this );

    _rows = 1;
    box( FL_FLAT_BOX );
    labelsize( 96 );
    { Fl_Group *o = new Fl_Group( X, Y, W, 24 );

        { Fl_Menu_Bar *o = menubar = new Fl_Menu_Bar( X, Y, W, 24 );
            o->add( "&Project/&New" );
            o->add( "&Project/&Open" );
            o->add( "&Project/&Save", FL_CTRL + 's', 0, 0 );
            o->add( "&Project/&Quit", FL_CTRL + 'q', 0, 0 );
            o->add( "&Mixer/&Add Strip", 'a', 0, 0 );
            o->add( "&Mixer/Add &N Strips" );
            o->add( "&Mixer/&Import Strip" );
            o->add( "&Mixer/&Rows/One", '1', 0, 0 );
            o->add( "&Mixer/&Rows/Two", '2', 0, 0 );
            o->add( "&Mixer/&Rows/Three", '3', 0, 0 );
            o->add( "&View/&Theme", 0, 0, 0 );
            o->add( "_&Options/&Display/&Knobs/&Arc", 0, 0, 0, FL_MENU_RADIO   );
            o->add( "_&Options/&Display/&Knobs/&Burnished", 0, 0, 0, FL_MENU_RADIO );
            o->add( "_&Options/&Display/&Knobs/&Plastic", 0, 0, 0, FL_MENU_RADIO | FL_MENU_VALUE );
            o->add( "_&Options/&Display/&Sliders/&Nice", 0, 0, 0, FL_MENU_RADIO | FL_MENU_VALUE );
            o->add( "_&Options/&Display/&Sliders/&Fill", 0, 0, 0, FL_MENU_RADIO );
            o->add( "_&Options/&Display/&Sliders/&Simple", 0, 0, 0, FL_MENU_RADIO );
            o->add( "_&Options/&Display/&Colors/&System", 0, 0, 0, FL_MENU_RADIO );
            o->add( "&Help/&Manual" );
            o->add( "&Help/&About" );
            o->callback( cb_menu, this );
        }
        { Fl_Box *o = project_name = new Fl_Box( X + 150, Y, W, 24 );
            o->labelfont( FL_HELVETICA_ITALIC );
            o->label( 0 );
            o->align( FL_ALIGN_INSIDE | FL_ALIGN_CENTER );
            o->labeltype( FL_SHADOW_LABEL );
            Fl_Group::current()->resizable( o );
        }
        { sm_blinker = new Fl_Button( ( X + W) - 37, Y + 4, 35, 15, "SM");
            sm_blinker->box(FL_ROUNDED_BOX);
            sm_blinker->down_box(FL_ROUNDED_BOX);
            sm_blinker->color(FL_DARK2);
            sm_blinker->selection_color((Fl_Color)93);
            sm_blinker->labeltype(FL_NORMAL_LABEL);
            sm_blinker->labelfont(3);
            sm_blinker->labelsize(14);
            sm_blinker->labelcolor(FL_DARK3);
            sm_blinker->align(Fl_Align(FL_ALIGN_CENTER));
            sm_blinker->when(FL_WHEN_RELEASE);
            sm_blinker->deactivate();

        } // Fl_Blink_Button* sm_blinker
        o->end();
    }
    { Fl_Scroll *o = scroll = new Fl_Scroll( X, Y + 24, W, H - 24 );
        o->box( FL_FLAT_BOX );
//        o->type( Fl_Scroll::HORIZONTAL_ALWAYS );
//        o->box( Fl_Scroll::BOTH );
        {
            Fl_Flowpack *o = mixer_strips = new Fl_Flowpack( X, Y + 24, W, H - 18 - 24 );
//            label( "Non-Mixer" );
            align( (Fl_Align)(FL_ALIGN_CENTER | FL_ALIGN_INSIDE) );
            o->box( FL_FLAT_BOX );
            o->type( Fl_Pack::HORIZONTAL );
            o->hspacing( 2 );
            o->vspacing( 2 );
            o->end();
            Fl_Group::current()->resizable( o );
        }
        o->end();
        Fl_Group::current()->resizable( o );
    }

    end();

//    Fl::add_timeout( STATUS_UPDATE_FREQ, update_cb, this );

    update_menu();

    load_options();
}
开发者ID:imv,项目名称:non,代码行数:83,代码来源:Mixer.C

示例7: selected

classificationEditor::classificationEditor() : selected(0)
{
  opt_mesh_lines(0, GMSH_SET | GMSH_GUI, 1.);

  drawContext::global()->draw();

  int BBB = (int)(1.4 * BB);
  const int width = (int)(3.15 * BBB), height = (int)(9.5 * BH);

  window = new paletteWindow
    (width, height, CTX::instance()->nonModalWindows ? true : false, "Reclassify 2D");
  window->box(GMSH_WINDOW_BOX);

  int x = WB, y = WB;
  {
    Fl_Box *b = new Fl_Box
      (x, y, width, BH, "1. Select mesh elements on which to perform edge detection");
    b->align(FL_ALIGN_LEFT | FL_ALIGN_INSIDE);

    x += WB;
    y += BH;
    buttons[CLASS_BUTTON_SELECT_ELEMENTS] = new Fl_Button
      (x, y, BBB, BH, "Select elements");
    buttons[CLASS_BUTTON_SELECT_ELEMENTS]->callback(select_elements_cb, this);

    buttons[CLASS_BUTTON_SELECT_ALL_ELEMENTS] = new Fl_Button
      (x + BBB + WB, y, (int)(0.5 * BBB) - WB, BH, "All");
    buttons[CLASS_BUTTON_SELECT_ALL_ELEMENTS]->callback(select_elements_cb, this);

    toggles[CLASS_TOGGLE_HIDE] = new Fl_Check_Button
      ((int)(x + 1.5 * BBB + WB), y, (int)(width - 1.5 * BBB - x - 2 * WB), BH,
       "Hide unselected elements");
    toggles[CLASS_TOGGLE_HIDE]->type(FL_TOGGLE_BUTTON);
    toggles[CLASS_TOGGLE_HIDE]->callback(hide_cb, this);

    x -= WB;
  }
  {
    y += BH / 2;
    Fl_Box* b = new Fl_Box(x, y + BH - WB, width - 2 * WB, 2);
    b->box(FL_ENGRAVED_FRAME);
    b->labeltype(FL_NO_LABEL);
  }
  {
    y += BH;
    Fl_Box *b = new Fl_Box
      (x, y, width, BH, "2. Fine-tune edge selection");
    b->align(FL_ALIGN_LEFT | FL_ALIGN_INSIDE);

    x += WB;
    y += BH;
    inputs[CLASS_VALUE_ANGLE] = new Fl_Value_Input
      (x, y, 2 * BBB / 3, BH, "Threshold angle");
    inputs[CLASS_VALUE_ANGLE]->value(40);
    inputs[CLASS_VALUE_ANGLE]->maximum(180);
    inputs[CLASS_VALUE_ANGLE]->minimum(0);
    inputs[CLASS_VALUE_ANGLE]->align(FL_ALIGN_RIGHT);
    inputs[CLASS_VALUE_ANGLE]->step(1);
    inputs[CLASS_VALUE_ANGLE]->when(FL_WHEN_RELEASE);
    inputs[CLASS_VALUE_ANGLE]->callback(update_edges_cb, this);

    toggles[CLASS_TOGGLE_SHOW_ONLY_EDGES] = new Fl_Check_Button
      ((int)(x + 1.5 * BBB + WB), y, (int)(width - x - 1.5 * BBB - 2 * WB), BH,
       "Show only edges");
    toggles[CLASS_TOGGLE_SHOW_ONLY_EDGES]->type(FL_TOGGLE_BUTTON);
    toggles[CLASS_TOGGLE_SHOW_ONLY_EDGES]->callback(show_only_edges_cb, this);

    y += BH;
    toggles[CLASS_TOGGLE_BOUNDARY] = new Fl_Check_Button
      (x, y, width - x - 2 * WB, BH, "Include edges on boundary (closure)");
    toggles[CLASS_TOGGLE_BOUNDARY]->type(FL_TOGGLE_BUTTON);
    toggles[CLASS_TOGGLE_BOUNDARY]->callback(update_edges_cb, this);

    y += BH;
    buttons[CLASS_BUTTON_DELETE_FROM_SELECTION] = new Fl_Button
      (x, y, (int)(1.5 * BBB), BH, "Delete edges from selection");
    buttons[CLASS_BUTTON_DELETE_FROM_SELECTION]->callback(delete_edge_cb, this);
    buttons[CLASS_BUTTON_DELETE_FROM_SELECTION]->deactivate();

    buttons[CLASS_BUTTON_RESET_SELECTION] = new Fl_Button
      (x + (int)(1.5 * BBB + WB), y, BBB, BH, "Reset selection");
    buttons[CLASS_BUTTON_RESET_SELECTION]->callback(reset_selection_cb, this);
    buttons[CLASS_BUTTON_RESET_SELECTION]->deactivate();

    x -= WB;
  }
  {
    y += BH / 2;
    Fl_Box* b = new Fl_Box(x, y + BH - WB, width - 2 * WB, 2);
    b->box(FL_ENGRAVED_FRAME);
    b->labeltype(FL_NO_LABEL);
  }
  {
    y += BH;
    Fl_Box *b = new Fl_Box
      (x, y, width, BH, "3. Reclassify surfaces using selected edges");
    b->align(FL_ALIGN_LEFT | FL_ALIGN_INSIDE);

    x += WB;
    y += BH;
//.........这里部分代码省略.........
开发者ID:iyer-arvind,项目名称:gmsh,代码行数:101,代码来源:classificationEditor.cpp


注:本文中的Fl_Box::labeltype方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。