Esempio n. 1
0
static int cfMaskMatRemove(lua_State *L)
{
  iupmaskMatRemove(iuplua_checkihandle(L,1),
                   luaL_checkinteger(L,2),
                   luaL_checkinteger(L,3));
  return 0;
}
Esempio n. 2
0
/* Main program */
int main(int argc, char **argv)
{
  Ihandle *dlg;
  IupOpen(&argc, &argv);       
  IupControlsOpen();
 
  IupSetFunction("removeline", (Icallback)removeline);
  IupSetFunction("addline", (Icallback)addline);
  IupSetFunction("removecol", (Icallback)removecol);
  IupSetFunction("addcol", (Icallback)addcol);
  IupSetFunction("redraw", (Icallback)redraw);

  createmenu();
  
  dlg = IupDialog(
          IupTabs(
            IupSetAttributes(
              IupVbox((create_mat()), IupText(""), IupLabel("Label Text"), IupVal("HORIZONTAL"), 
                NULL), "MARGIN=10x10, GAP=10, TABTITLE=Test1"),
            IupSetAttributes(
              IupVbox(IupFrame(create_mat()), IupText(""), IupLabel("Label Text"), IupVal("HORIZONTAL"), 
//                NULL), "BGCOLOR=\"0 255 255\", MARGIN=10x10, GAP=10, TABTITLE=Test2,FONT=HELVETICA_ITALIC_14"), 
                NULL), "FONT=HELVETICA_NORMAL_12, BGCOLOR=\"0 255 255\", MARGIN=10x10, GAP=10, TABTITLE=Test2"), 
            NULL)); 
  IupSetAttribute(dlg,IUP_TITLE, "IupMatrix");
  IupSetAttribute(dlg,IUP_MENU, "mymenu");
//  IupSetAttribute(dlg,"BGCOLOR", "255 0 255");

  //IupSetAttribute(dlg,"COMPOSITED", "YES");
  //IupSetAttribute(dlg,"LAYERED", "YES");
  //IupSetAttribute(dlg,"LAYERALPHA", "192");

  IupShowXY(dlg,IUP_CENTER,IUP_CENTER) ;
  IupMainLoop();

  iupmaskMatRemove(IupGetHandle("mat1"), 2, 1) ;
  iupmaskMatRemove(IupGetHandle("mat2"), 2, 1) ;
  IupDestroy(dlg);

  IupControlsClose();
  IupClose();  
  return 0;
}