- QGroupBox* aContentBox = new QGroupBox(1, Qt::Horizontal, wg1, "content box");
- aContentBox->setTitle(tr("SMESH_CONTENT"));
- QFrame* aContent = new QFrame(aContentBox, "content");
- QGridLayout* aLayout = new QGridLayout(aContent, 7, 4);
- aLayout->setSpacing(6);
- aLayout->setAutoAdd(false);
-
- QLabel* aLabel = new QLabel(aContent, "elements label");
- aLabel->setText(tr("SMESH_ID_ELEMENTS"));
- myElements = new QListBox(aContent, "elements list");
- myElements->setSelectionMode(QListBox::Extended);
-
- myFilter = new QPushButton(aContent, "filter");
- myFilter->setText(tr("SMESH_BUT_FILTER"));
- QPushButton* aAddBtn = new QPushButton(aContent, "add");
- aAddBtn->setText(tr("SMESH_BUT_ADD"));
- QPushButton* aRemoveBtn = new QPushButton(aContent, "remove");
- aRemoveBtn->setText(tr("SMESH_BUT_REMOVE"));
- QPushButton* aSortBtn = new QPushButton(aContent, "sort");
- aSortBtn->setText(tr("SMESH_BUT_SORT"));
-
- aLayout->addWidget(aLabel, 0, 0);
- aLayout->addMultiCellWidget(myElements, 1, 6, 0, 0);
- aLayout->addWidget(myFilter, 1, 2);
- aLayout->addWidget(aAddBtn, 3, 2);
- aLayout->addWidget(aRemoveBtn, 4, 2);
- aLayout->addWidget(aSortBtn, 6, 2);
-
- aLayout->setColStretch(0, 1);
- aLayout->addColSpacing(1, 20);
- aLayout->addColSpacing(3, 20);
- aLayout->setRowStretch(2, 1);
- aLayout->setRowStretch(5, 1);
+ QGroupBox* aContentBox = new QGroupBox(tr("SMESH_CONTENT"), wg1);
+ QGridLayout* aContentBoxLayout = new QGridLayout(aContentBox);
+ aContentBoxLayout->setMargin(MARGIN);
+ aContentBoxLayout->setSpacing(SPACING);
+
+ QLabel* aLabel = new QLabel(tr("SMESH_ID_ELEMENTS"), aContentBox);
+ myElements = new QListWidget(aContentBox);
+ myElements->setSelectionMode(QListWidget::ExtendedSelection);
+
+ myFilter = new QPushButton(tr("SMESH_BUT_FILTER"), aContentBox);
+ QPushButton* aAddBtn = new QPushButton(tr("SMESH_BUT_ADD"), aContentBox);
+ QPushButton* aRemoveBtn = new QPushButton(tr("SMESH_BUT_REMOVE"), aContentBox);
+ QPushButton* aSortBtn = new QPushButton(tr("SMESH_BUT_SORT"), aContentBox);
+
+ aContentBoxLayout->addWidget(aLabel, 0, 0);
+ aContentBoxLayout->addWidget(myElements, 1, 0, 6, 1);
+ aContentBoxLayout->addWidget(myFilter, 1, 1);
+ aContentBoxLayout->addWidget(aAddBtn, 3, 1);
+ aContentBoxLayout->addWidget(aRemoveBtn, 4, 1);
+ aContentBoxLayout->addWidget(aSortBtn, 6, 1);
+
+ aContentBoxLayout->setColumnStretch(0, 1);
+ aContentBoxLayout->setRowStretch(2, 1);
+ aContentBoxLayout->setRowStretch(5, 1);