Gui: Add rotation center indicator color, transparency and size preferences
This commit is contained in:
@@ -58,6 +58,7 @@ DlgSettingsNavigation::DlgSettingsNavigation(QWidget* parent)
|
||||
{
|
||||
ui->setupUi(this);
|
||||
ui->naviCubeBaseColor->setAllowTransparency(true);
|
||||
ui->rotationCenterColor->setAllowTransparency(true);
|
||||
retranslate();
|
||||
}
|
||||
|
||||
@@ -84,7 +85,8 @@ void DlgSettingsNavigation::saveSettings()
|
||||
ui->checkBoxZoomAtCursor->onSave();
|
||||
ui->checkBoxInvertZoom->onSave();
|
||||
ui->checkBoxDisableTilt->onSave();
|
||||
ui->checkBoxShowRotationCenter->onSave();
|
||||
ui->rotationCenterSize->onSave();
|
||||
ui->rotationCenterColor->onSave();
|
||||
ui->spinBoxZoomStep->onSave();
|
||||
ui->checkBoxUseAutoRotation->onSave();
|
||||
ui->qspinNewDocScale->onSave();
|
||||
@@ -97,6 +99,9 @@ void DlgSettingsNavigation::saveSettings()
|
||||
bool showNaviCube = ui->groupBoxNaviCube->isChecked();
|
||||
hGrp->SetBool("ShowNaviCube", showNaviCube);
|
||||
|
||||
bool showRotationCenter = ui->groupBoxRotationCenter->isChecked();
|
||||
hGrp->SetBool("ShowRotationCenter", showRotationCenter);
|
||||
|
||||
QVariant camera = ui->comboNewDocView->itemData(ui->comboNewDocView->currentIndex(),
|
||||
Qt::UserRole);
|
||||
hGrp->SetASCII("NewDocumentCameraOrientation", (const char*)camera.toByteArray());
|
||||
@@ -110,7 +115,7 @@ void DlgSettingsNavigation::saveSettings()
|
||||
hGrp = App::GetApplication().GetParameterGroupByPath(
|
||||
"User parameter:BaseApp/Preferences/NaviCube");
|
||||
if (ui->naviCubeFontName->currentIndex()) {
|
||||
hGrp->SetASCII("FontString", ui->naviCubeFontName->currentText().toLatin1());
|
||||
hGrp->SetASCII("FontString", ui->naviCubeFontName->currentText().toLatin1());
|
||||
} else {
|
||||
hGrp->RemoveASCII("FontString");
|
||||
}
|
||||
@@ -121,7 +126,8 @@ void DlgSettingsNavigation::loadSettings()
|
||||
ui->checkBoxZoomAtCursor->onRestore();
|
||||
ui->checkBoxInvertZoom->onRestore();
|
||||
ui->checkBoxDisableTilt->onRestore();
|
||||
ui->checkBoxShowRotationCenter->onRestore();
|
||||
ui->rotationCenterSize->onRestore();
|
||||
ui->rotationCenterColor->onRestore();
|
||||
ui->spinBoxZoomStep->onRestore();
|
||||
ui->checkBoxUseAutoRotation->onRestore();
|
||||
ui->qspinNewDocScale->onRestore();
|
||||
@@ -147,6 +153,9 @@ void DlgSettingsNavigation::loadSettings()
|
||||
bool showNaviCube = hGrp->GetBool("ShowNaviCube", true);
|
||||
ui->groupBoxNaviCube->setChecked(showNaviCube);
|
||||
|
||||
bool showRotationCenter = hGrp->GetBool("ShowRotationCenter", true);
|
||||
ui->groupBoxRotationCenter->setChecked(showRotationCenter);
|
||||
|
||||
ui->comboNewDocView->addItem(tr("Isometric"), QByteArray("Isometric"));
|
||||
ui->comboNewDocView->addItem(tr("Dimetric"), QByteArray("Dimetric"));
|
||||
ui->comboNewDocView->addItem(tr("Trimetric"), QByteArray("Trimetric"));
|
||||
@@ -182,7 +191,7 @@ void DlgSettingsNavigation::loadSettings()
|
||||
QStringList familyNames = QFontDatabase::families(QFontDatabase::Any);
|
||||
#endif
|
||||
ui->naviCubeFontName->addItems(familyNames);
|
||||
|
||||
|
||||
hGrp = App::GetApplication().GetParameterGroupByPath(
|
||||
"User parameter:BaseApp/Preferences/NaviCube");
|
||||
int indexFamilyNames = familyNames.indexOf(
|
||||
|
||||
Reference in New Issue
Block a user