1
/***************************************************************************
2
* Copyright (c) 2015 FreeCAD Developers *
3
* Author: WandererFan <wandererfan@gmail.com> *
4
* Based on src/Mod/FEM/Gui/DlgSettingsFEMImp.cpp *
6
* This file is part of the FreeCAD CAx development system. *
8
* This library is free software; you can redistribute it and/or *
9
* modify it under the terms of the GNU Library General Public *
10
* License as published by the Free Software Foundation; either *
11
* version 2 of the License, or (at your option) any later version. *
13
* This library is distributed in the hope that it will be useful, *
14
* but WITHOUT ANY WARRANTY; without even the implied warranty of *
15
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
16
* GNU Library General Public License for more details. *
18
* You should have received a copy of the GNU Library General Public *
19
* License along with this library; see the file COPYING.LIB. If not, *
20
* write to the Free Software Foundation, Inc., 59 Temple Place, *
21
* Suite 330, Boston, MA 02111-1307, USA *
23
***************************************************************************/
25
#include "PreCompiled.h"
27
#include "DlgPrefsTechDrawHLRImp.h"
28
#include "ui_DlgPrefsTechDrawHLR.h"
31
using namespace TechDrawGui;
33
DlgPrefsTechDrawHLRImp::DlgPrefsTechDrawHLRImp( QWidget* parent )
34
: PreferencePage( parent )
35
, ui(new Ui_DlgPrefsTechDrawHLRImp)
40
DlgPrefsTechDrawHLRImp::~DlgPrefsTechDrawHLRImp()
42
// no need to delete child widgets, Qt does it all for us
45
void DlgPrefsTechDrawHLRImp::saveSettings()
47
ui->pcbSeamViz->onSave();
48
ui->pcbSmoothViz->onSave();
49
ui->pcbHardViz->onSave();
50
ui->pcbPolygon->onSave();
51
ui->pcbIsoViz->onSave();
52
ui->pcbSmoothHid->onSave();
53
ui->pcbSeamHid->onSave();
54
ui->pcbIsoHid->onSave();
55
ui->psbIsoCount->onSave();
56
ui->pcbHardHid->onSave();
59
void DlgPrefsTechDrawHLRImp::loadSettings()
61
// set defaults for HLR
62
ui->pcbSeamViz->onRestore();
64
ui->pcbSmoothViz->onRestore();
65
ui->pcbHardViz->onRestore();
66
ui->pcbPolygon->onRestore();
67
ui->pcbIsoViz->onRestore();
68
ui->pcbSmoothHid->onRestore();
69
ui->pcbSeamHid->onRestore();
70
ui->pcbIsoHid->onRestore();
71
ui->psbIsoCount->onRestore();
72
ui->pcbHardHid->onRestore();
76
* Sets the strings of the subwidgets using the current language.
78
void DlgPrefsTechDrawHLRImp::changeEvent(QEvent *e)
80
if (e->type() == QEvent::LanguageChange) {
82
ui->retranslateUi(this);
86
QWidget::changeEvent(e);
90
#include <Mod/TechDraw/Gui/moc_DlgPrefsTechDrawHLRImp.cpp>