myHorBW = aResourceMgr->integerValue("VISU", propertyName + "bar_width", 0);
myHorBH = aResourceMgr->integerValue("VISU", propertyName + "bar_height",0);
- aMainLayout->setSpacing(6);
- //setMargin(11);
+ //aMainLayout->setSpacing(6);
// Range ============================================================
RangeGroup = new QButtonGroup ( this );
QGroupBox* aGB = new QGroupBox( tr("SCALAR_RANGE_GRP"),this );
aMainLayout->addWidget( aGB );
- //RangeGroup->setColumnLayout(0, Qt::Vertical );
- //RangeGroup->layout()->setSpacing( 0 );
- //RangeGroup->layout()->setMargin( 0 );
QGridLayout* RangeGroupLayout = new QGridLayout( aGB );
RangeGroupLayout->setAlignment( Qt::AlignTop );
- RangeGroupLayout->setSpacing( 6 );
- RangeGroupLayout->setMargin( 11 );
+ //RangeGroupLayout->setSpacing( 6 );
+ //RangeGroupLayout->setMargin( 11 );
myModeLbl = new QLabel("Scalar Mode", aGB);
MinEdit = new QLineEdit( aGB );
MinEdit->setSizePolicy( QSizePolicy( QSizePolicy::Expanding, QSizePolicy::Fixed ) );
- MinEdit->setMinimumWidth( 70 );
+ //MinEdit->setMinimumWidth( 70 );
MinEdit->setValidator( new QDoubleValidator(this) );
MinEdit->setText( "0.0" );
QLabel* MinLabel = new QLabel (tr("LBL_MIN"), aGB);
MaxEdit = new QLineEdit( aGB );
MaxEdit->setSizePolicy( QSizePolicy( QSizePolicy::Expanding, QSizePolicy::Fixed ) );
- MaxEdit->setMinimumWidth( 70 );
+ //MaxEdit->setMinimumWidth( 70 );
MaxEdit->setValidator( new QDoubleValidator(this) );
MaxEdit->setText( "0.0" );
QLabel* MaxLabel = new QLabel (tr("LBL_MAX"), aGB);
RangeGroupLayout->addWidget( MaxLabel, 2, 2 );
RangeGroupLayout->addWidget( MaxEdit, 2, 3 );
- //TopLayout->addWidget( RangeGroup );
-
// Colors and Labels ========================================================
QGroupBox* ColLabGroup = new QGroupBox (tr("COLORS_LABELS_GRP"), this);
aMainLayout->addWidget( ColLabGroup );
- //ColLabGroup->setColumnLayout(0, Qt::Vertical );
- //ColLabGroup->layout()->setSpacing( 0 );
- //ColLabGroup->layout()->setMargin( 0 );
QGridLayout* ColLabGroupLayout = new QGridLayout( ColLabGroup );
ColLabGroupLayout->setAlignment( Qt::AlignTop );
- ColLabGroupLayout->setSpacing( 6 );
- ColLabGroupLayout->setMargin( 11 );
+ //ColLabGroupLayout->setSpacing( 6 );
+ //ColLabGroupLayout->setMargin( 11 );
QLabel* ColorLabel = new QLabel (tr("LBL_NB_COLORS"), ColLabGroup);
ColorSpin = new QSpinBox( ColLabGroup );
ColorSpin->setMaximum( 256 );
ColorSpin->setSingleStep( 1 );
ColorSpin->setSizePolicy( QSizePolicy( QSizePolicy::Expanding, QSizePolicy::Fixed ) );
- ColorSpin->setMinimumWidth( 70 );
+ //ColorSpin->setMinimumWidth( 70 );
ColorSpin->setValue( 64 );
QLabel* LabelLabel = new QLabel (tr("LBL_NB_LABELS"), ColLabGroup);
LabelSpin->setSingleStep( 1 );
LabelSpin->setSizePolicy( QSizePolicy( QSizePolicy::Expanding, QSizePolicy::Fixed ) );
- LabelSpin->setMinimumWidth( 70 );
+ //LabelSpin->setMinimumWidth( 70 );
LabelSpin->setValue( 5 );
ColLabGroupLayout->addWidget( ColorLabel, 0, 0);
ColLabGroupLayout->addWidget( LabelLabel, 0, 2);
ColLabGroupLayout->addWidget( LabelSpin, 0, 3);
- //TopLayout->addWidget( ColLabGroup );
-
// Orientation ==========================================================
QButtonGroup* OrientGroup = new QButtonGroup ( this );
QGroupBox* OrientGB = new QGroupBox( tr("ORIENTATION_GRP"),this );
aMainLayout->addWidget( OrientGB );
- //OrientGroup->setColumnLayout(0, Qt::Vertical );
- //OrientGroup->layout()->setSpacing( 0 );
- //OrientGroup->layout()->setMargin( 0 );
QGridLayout* OrientGroupLayout = new QGridLayout( OrientGB );
OrientGroupLayout->setAlignment( Qt::AlignTop );
- OrientGroupLayout->setSpacing( 6 );
- OrientGroupLayout->setMargin( 11 );
+ //OrientGroupLayout->setSpacing( 6 );
+ //OrientGroupLayout->setMargin( 11 );
RBvert = new QRadioButton (tr("VERTICAL_BTN"), OrientGB);
RBvert->setChecked( true );
OrientGroupLayout->addWidget( RBvert, 0, 0 );
OrientGroupLayout->addWidget( RBhori, 0, 1 );
- // TopLayout->addWidget( OrientGroup );
-
// Origin ===============================================================
QGroupBox* OriginGroup = new QGroupBox (tr("ORIGIN_GRP"), this);
aMainLayout->addWidget( OriginGroup );
- //OriginGroup->setColumnLayout(0, Qt::Vertical );
- //OriginGroup->layout()->setSpacing( 0 );
- // OriginGroup->layout()->setMargin( 0 );
QGridLayout* OriginGroupLayout = new QGridLayout( OriginGroup );
OriginGroupLayout->setAlignment( Qt::AlignTop );
- OriginGroupLayout->setSpacing( 6 );
- OriginGroupLayout->setMargin( 11 );
+ //OriginGroupLayout->setSpacing( 6 );
+ //OriginGroupLayout->setMargin( 11 );
QLabel* XLabel = new QLabel (tr("LBL_X"), OriginGroup);
XSpin = new QtxDoubleSpinBox( OriginGroup );
VISU::initSpinBox(XSpin, 0.0, +1.0);
XSpin->setSizePolicy( QSizePolicy( QSizePolicy::Expanding, QSizePolicy::Fixed ) );
- XSpin->setMinimumWidth( 70 );
+ //XSpin->setMinimumWidth( 70 );
XSpin->setValue( 0.01 );
QLabel* YLabel = new QLabel (tr("LBL_Y"), OriginGroup);
YSpin = new QtxDoubleSpinBox( OriginGroup );
VISU::initSpinBox(YSpin, 0.0, +1.0);
YSpin->setSizePolicy( QSizePolicy( QSizePolicy::Expanding, QSizePolicy::Fixed ) );
- YSpin->setMinimumWidth( 70 );
+ //YSpin->setMinimumWidth( 70 );
YSpin->setValue( 0.01 );
OriginGroupLayout->addWidget( XLabel, 0, 0);
OriginGroupLayout->addWidget( YLabel, 0, 2);
OriginGroupLayout->addWidget( YSpin, 0, 3);
- //TopLayout->addWidget( OriginGroup );
-
// Dimensions =========================================================
QGroupBox* DimGroup = new QGroupBox (tr("DIMENSIONS_GRP"), this );
aMainLayout->addWidget( DimGroup );
- //DimGroup->setColumnLayout(0, Qt::Vertical );
- //DimGroup->layout()->setSpacing( 0 );
- //DimGroup->layout()->setMargin( 0 );
QGridLayout* DimGroupLayout = new QGridLayout( DimGroup );
DimGroupLayout->setAlignment( Qt::AlignTop );
- DimGroupLayout->setSpacing( 6 );
- DimGroupLayout->setMargin( 11 );
+ //DimGroupLayout->setSpacing( 6 );
+ //DimGroupLayout->setMargin( 11 );
QLabel* WidthLabel = new QLabel (tr("LBL_WIDTH"), DimGroup);
WidthSpin = new QtxDoubleSpinBox( DimGroup );
VISU::initSpinBox(WidthSpin, 0.0, +1.0);
WidthSpin->setSizePolicy( QSizePolicy( QSizePolicy::Expanding, QSizePolicy::Fixed ) );
- WidthSpin->setMinimumWidth( 70 );
+ //WidthSpin->setMinimumWidth( 70 );
WidthSpin->setValue( 0.1 );
QLabel* HeightLabel = new QLabel (tr("LBL_HEIGHT"), DimGroup);
HeightSpin = new QtxDoubleSpinBox( DimGroup );
VISU::initSpinBox(HeightSpin, 0.0, +1.0);
HeightSpin->setSizePolicy( QSizePolicy( QSizePolicy::Expanding, QSizePolicy::Fixed ) );
- HeightSpin->setMinimumWidth( 70 );
+ //HeightSpin->setMinimumWidth( 70 );
HeightSpin->setValue( 0.8 );
DimGroupLayout->addWidget( WidthLabel, 0, 0);
DimGroupLayout->addWidget( HeightLabel, 0, 2);
DimGroupLayout->addWidget( HeightSpin, 0, 3);
- //TopLayout->addWidget( DimGroup );
-
// Save check box ===========================================================
QWidget* aSaveBox = new QWidget(this);
aMainLayout->addWidget( aSaveBox );
QGroupBox* CheckGroup = new QGroupBox("", this );
aMainLayout->addWidget( CheckGroup );
- QHBoxLayout* CheckGroupLayout = new QHBoxLayout( CheckGroup );
+ //QHBoxLayout* CheckGroupLayout = new QHBoxLayout( CheckGroup );
+ QGridLayout* CheckGroupLayout = new QGridLayout( CheckGroup );
myPreviewCheck = new QCheckBox(tr("LBL_SHOW_PREVIEW"), CheckGroup);
myPreviewCheck->setChecked(false);
- //myPreviewCheck->setSizePolicy( QSizePolicy( QSizePolicy::Expanding, QSizePolicy::Fixed ) );
- CheckGroupLayout->addWidget(myPreviewCheck);
+ CheckGroupLayout->addWidget(myPreviewCheck, 0, 0);
+ myHideBar = new QCheckBox(tr("HIDE_SCALAR_BAR"), CheckGroup);
+ myHideBar->setChecked(false);
+ CheckGroupLayout->addWidget(myHideBar, 0, 1);
+
// RKV : Begin
CBDistr = new QCheckBox (tr("SHOW_DISTRIBUTION"), CheckGroup);
- //CBDistr->setSizePolicy( QSizePolicy( QSizePolicy::Expanding, QSizePolicy::Fixed ) );
- CheckGroupLayout->addWidget(CBDistr);
+ CheckGroupLayout->addWidget(CBDistr, 1, 0);
// RKV : End
if (!thePreview) {
CBSave = new QCheckBox (tr("SAVE_DEFAULT_CHK"), CheckGroup);
- CheckGroupLayout->addWidget( CBSave );
+ CheckGroupLayout->addWidget( CBSave, 1, 1 );
}
else {
CBSave = 0;
myBarDlg->setUnitsVisible(aResourceMgr->booleanValue("VISU", propertyName + "display_units", true));
// signals and slots connections ===========================================
- // connect( RangeGroup, SIGNAL( buttonClicked( int ) ), this, SLOT( changeRange( int ) ) );
connect( RBFrange, SIGNAL( toggled( bool ) ), this, SLOT( onFieldRange( bool ) ) );
connect( RBIrange, SIGNAL( toggled( bool ) ), this, SLOT( onImposedRange( bool ) ) );
myScalarMap->IsItalicLabel(),
myScalarMap->IsShadowLabel());
+ myHideBar->setChecked(!myScalarMap->IsBarVisible());
+
// Draw Preview
if (myPreviewCheck->isChecked()) {
createScalarBar();
VISU_ScalarBarActor* aScalarBarActor = myPreviewActor->GetScalarBar();
myPreviewActor->GetScalarBar()->VisibilityOn();
myPreviewActor->PickableOff();
+ //myPreviewActor->SetBarVisibility(!myHideBar->isChecked());
myScalarMapPL->SetScalarMode(myModeCombo->currentIndex());
if(isLogarithmic())
myScalarMap->SetLabels(LabelSpin->value());
myScalarMap->SetIsDistributionVisible(isShowDistribution()); // RKV
+ myScalarMap->SetBarVisible(!myHideBar->isChecked());
+
if (isToSave()) storeToResources();
if (myIsStoreTextProp) {