예제 #1
0
PrintDialog::PrintDialog(QWidget* parent, const char* name)
  : Inherited( parent, name )
{
  // ###########################################################################
  buttonOK->setDefault(true);
  buttonOK->setAutoDefault(true);
  buttonOK->setFocus();
  labelHeadline->setText(i18n("Headline text:"));
  labelRightFooter->setText(i18n("Right footer text:"));
  labelLeftFooter->setText(i18n("Left footer text:"));
  connect(kapp, SIGNAL(appearanceChanged()), SLOT(initializeGeometry()));
  initializeGeometry();
  // ###########################################################################
}
예제 #2
0
void cwGLGridPlane::initialize()
{
    initializeShaders();
    initializeGeometry();

    vVertex = Program->attributeLocation("vVertex");

}
예제 #3
0
GLWidget::GLWidget(QWidget *parent)
    : QGLWidget(QGLFormat(QGL::SampleBuffers), parent)
    , geom(0)
    , cube(0)
{
    // create the pbuffer
    QGLFormat pbufferFormat = format();
    pbufferFormat.setSampleBuffers(false);
    pbuffer = new QGLPixelBuffer(QSize(512, 512), pbufferFormat, this);
    setWindowTitle(tr("OpenGL pbuffers"));
    initializeGeometry();
}
예제 #4
0
StringListSelectSetDialog::StringListSelectSetDialog
(QWidget* parent, const char* name)
  : DialogBase(parent, name)
{
  // ############################################################################
  lbStrings=new QListBox(this);
  lbStrings->setMultiSelection(true);
  setMainWidget(lbStrings);
  enableButtonApply(false);
  initializeGeometry();
  resize(minimumSize());
  // ############################################################################
}
void StringListSAndRSetDialog::fixSize(bool state)
{
  // ############################################################################
  if(state!=sizeIsFixed)
    {
      sizeIsFixed=state;
      initializeGeometry();
      if(state==true)
	{
	  setFixedSize(minimumSize());
	}
    }
  // ############################################################################
}
예제 #6
0
SearchDialog::SearchDialog(QWidget* parent, const char* name)
  : DialogBase(parent, name),
    widget(0)
{
  // ############################################################################
  const char* Descriptions[]= {
    i18n("The title"),
    i18n("The first name"),
    i18n("The additional name"),
    i18n("The name prefix"),
    i18n("The name"),
    i18n("The formatted name"),
    i18n("The address"),
    i18n("The town"),
    i18n("The organization"),
    i18n("The role"),
    i18n("The org unit"),
    i18n("The org subunit"),
    i18n("The email address"),
    i18n("The second email address"),
    i18n("The third email address"),
    i18n("The telephone number"),
    i18n("The fax number"),
    i18n("The modem number"),
    i18n("The homepage URL"),
    i18n("The comment") };
  const int Size=sizeof(Descriptions)/sizeof(Descriptions[0]);
  int count;
  // ----- create main widget:
  widget=new SearchDialogMainWidget(this);
  CHECK(widget!=0);
  setMainWidget(widget);
  // ----- configure dialog:
  setCaption(i18n("kab: Search entries"));
  enableButtonApply(false);
  // showMainFrameTile(false);
  // -----
  for(count=0; count<Size; count++)
    {
      widget->comboSelector->insertItem(Descriptions[count]);
    }
  connect(widget->comboSelector, SIGNAL(activated(int)), SLOT(keySelected(int)));
  connect(widget->lePattern, SIGNAL(textChanged(const char*)), 
	  SLOT(valueChanged(const char*)));
  connect(widget, SIGNAL(sizeChanged()), SLOT(initializeGeometry()));
  keySelected(0);
  resize(minimumSize());
  widget->lePattern->setFocus();
  // ############################################################################
}
예제 #7
0
void createGeom(std::vector<std::vector<Module*>* > myGeo) {
  std::vector<std::vector<Module*>* >::iterator layIt;
  std::vector<Module*>::iterator modIt;


  initializeGeometry();
  
  for (layIt=myGeo.begin(); layIt!=myGeo.end(); layIt++) {
    for (modIt=(*layIt)->begin(); modIt!=(*layIt)->end(); modIt++) {
      placeModule(*modIt);
    }
  }
  
  closeSaveGeometry();
}
void MusikQuadRender::initializeGL()
{
    initializeOpenGLFunctions();

    //glClearColor(0.0f, 0.0f, 0.0f, 1.0f);

    initializeShader();
    initializeTexShader();
    initializeGeometry();
    initializeTexGeometry();
    initializeFrameBuffer();
    glEnable(GL_DEPTH_TEST);


  //  timer->start(25,this);
}
bool IntersectionObservation::computeGeometry(IntersectionGeometry& geometry)
{
    ASSERT(m_target);
    LayoutObject* rootLayoutObject = m_observer->rootLayoutObject();
    LayoutObject* targetLayoutObject = target()->layoutObject();
    if (!rootLayoutObject->isBoxModelObject())
        return false;
    if (!targetLayoutObject->isBoxModelObject() && !targetLayoutObject->isText())
        return false;

    // Initialize targetRect and intersectionRect to bounds of target, in target's coordinate space.
    initializeGeometry(geometry);

    // TODO(szager): Support intersection observations for zero-area targets.  For now, we just
    // punt on the observation.
    if (!geometry.targetRect.size().width() || !geometry.targetRect.size().height())
        return false;

    // Clip intersectionRect to the root, and map it to root coordinates.
    clipToRoot(geometry.intersectionRect);

    // Map targetRect into document coordinates.
    mapRectToDocumentCoordinates(*targetLayoutObject, geometry.targetRect);

    // Map intersectionRect into document coordinates.
    mapRectToDocumentCoordinates(*rootLayoutObject, geometry.intersectionRect);

    // Clip intersectionRect to FrameView visible area if necessary, and map all geometry to frame coordinates.
    clipToFrameView(geometry);

    if (geometry.intersectionRect.size().isZero())
        geometry.intersectionRect = LayoutRect();
    if (!m_shouldReportRootBounds)
        geometry.rootRect = LayoutRect();

    return true;
}
예제 #10
0
파일: Box.cpp 프로젝트: npapier/vgsdk
void Box::setToDefaults( void )
{
	VertexShape::setToDefaults();
	
	initializeGeometry();
}
예제 #11
0
파일: WireQuad.cpp 프로젝트: npapier/vgsdk
void WireQuad::setToDefaults( void )
{
	WireShape::setToDefaults();
	
	initializeGeometry();
}