- QAD_CONFIG->addSetting( "SMESH:ScalarBarLabelFont", "Times" );
- QAD_CONFIG->addSetting( "SMESH:ScalarBarLabelBold", myLabelsBoldCheck->isChecked() ? "true" : "false" );
- QAD_CONFIG->addSetting( "SMESH:ScalarBarLabelItalic", myLabelsItalicCheck->isChecked() ? "true" : "false" );
- QAD_CONFIG->addSetting( "SMESH:ScalarBarLabelShadow", myLabelsShadowCheck->isChecked() ? "true" : "false" );
-
- QAD_CONFIG->addSetting( "SMESH:ScalarBarNbOfColors", myColorsSpin->value() );
- QAD_CONFIG->addSetting( "SMESH:ScalarBarNbOfLabels", myLabelsSpin->value() );
-
- QAD_CONFIG->addSetting( "SMESH:ScalarBarOrientation", myHorizRadioBtn->isChecked() ? "Horizontal" : "Vertical" );
-
- QAD_CONFIG->addSetting( "SMESH:ScalarBarXPosition", myXSpin->value() );
- QAD_CONFIG->addSetting( "SMESH:ScalarBarYPosition", myYSpin->value() );
- QAD_CONFIG->addSetting( "SMESH:ScalarBarWidth", myWidthSpin->value() );
- QAD_CONFIG->addSetting( "SMESH:ScalarBarHeight", myHeightSpin->value() );
+ f.setFamily( "Times");
+
+ f.setBold( myLabelsBoldCheck ->isChecked() );
+ f.setItalic( myLabelsItalicCheck->isChecked() );
+ f.setUnderline( myLabelsShadowCheck->isChecked() );
+ mgr->setValue( "SMESH", "scalar_bar_label_font", f );
+
+ mgr->setValue("SMESH", "scalar_bar_num_colors", myColorsSpin->value());
+ mgr->setValue("SMESH", "scalar_bar_num_labels", myLabelsSpin->value());
+
+ mgr->setValue("SMESH", "scalar_bar_orientation", myHorizRadioBtn->isChecked() ? 1 : 0 );
+
+ QString name = myHorizRadioBtn->isChecked() ? "scalar_bar_horizontal_%1" : "scalar_bar_vertical_%1";
+ mgr->setValue("SMESH", name.arg( "x" ), myXSpin->value());
+ mgr->setValue("SMESH", name.arg( "y" ), myYSpin->value());
+ mgr->setValue("SMESH", name.arg( "width" ), myWidthSpin->value());
+ mgr->setValue("SMESH", name.arg( "height" ), myHeightSpin->value());