예제 #1
0
EBox::EBox(float x, float y, float w,float h, float marginL, float marginR, float marginU, float marginD) {
	_nIterIndice = 0;
	_minInnerWidth = 0;
	_minInnerHeight = 0;
	_lpParent = NULL;
	_fMaxBlend = 1;
	_fBlend = 1;
   _x = 0;
   _y = 0;

   _nNumMaximizeChild = 0;

	SetVerticalPolicy(VCENTER);
	SetHorisontalPolicy(HCENTER);
	SetSizePolicy(INHERIT);

	SetCentered(false);

	SetGeometry(x,y,w,h);
	SetMargin(marginL,marginR,marginU,marginD);

	_layoutType = VERTICAL;

	if (bg == NULL)
		bg = KPTK::createKGraphic();
   refCount++;
}
예제 #2
0
int TextObject::LuaSetProp(lua_State* ls, string& prop, int index)
{
	if (prop == "center") SetCentered(lua_toboolean(ls, index));
	else return StaticObject::LuaSetProp(ls, prop, index);

	return 1;
}
예제 #3
0
파일: ElementButton.cpp 프로젝트: Ionsto/FA
ElementButton::ElementButton(Vector pos, Vector Size, std::string text) : ElementTexture(pos, Size, text)
{
	//this->Text = new ElementLable(pos,Size,text);
	SetCentered(true);
	Enabled = false;
}
예제 #4
0
파일: bbox.hpp 프로젝트: andyTsing/piccante
 /**
  * @brief BBox
  * @param x0 is the horizontal coordinate in pixels.
  * @param y0 is the vertical coordinate in pixels.
  * @param size is the patch size
  * @param width is the original width of the image.
  * @param height is the original height of the image.
  */
 BBox(int x0, int y0, int size, int width, int height)
 {
     SetCentered(x0, y0, size, width, height);
 }