FEM: Typos

This commit is contained in:
luz.paz
2018-10-11 11:10:31 +02:00
committed by wmayer
parent 73fd1b5063
commit 892c64823f
6 changed files with 21 additions and 19 deletions

View File

@@ -330,8 +330,9 @@ void TaskPostBox::updateEnumerationList(App::PropertyEnumeration& prop, QComboBo
list.push_back(QString::fromStdString(*it));
}
int index = prop.getValue();
// be aware the QComboxBox might be connected to the Property, thus clear the box wil set back the proberty enumeration index too.
int index = prop.getValue();
// be aware the QComboxBox might be connected to the Property,
// thus clearing the box will set back the property enumeration index too.
// https://forum.freecadweb.org/viewtopic.php?f=10&t=30944
box->clear();
box->insertItems(0, list);
@@ -396,7 +397,7 @@ void TaskPostDisplay::applyPythonCode() {
}
//############################################################################################
// ?
// ?
// the icon fem-post-geo-plane might be wrong but I do not know any better since the plane is one of the implicit functions
TaskPostFunction::TaskPostFunction(ViewProviderDocumentObject* view, QWidget* parent): TaskPostBox(view, Gui::BitmapFactory().pixmap("fem-post-geo-plane"), tr("Implicit function"), parent) {
@@ -1119,14 +1120,14 @@ void TaskPostWarpVector::on_Max_valueChanged(double) {
ui->Slider->setValue((ui->Value->value() - ui->Min->value()) / (ui->Max->value() - ui->Min->value()) * 100.);
ui->Slider->blockSignals(false);
/*
/*
* problem, if warp_factor is 2000 one would like to input 4000 as max, one starts to input 4
* immediately the warp_factor is changed to 4 because 4 < 2000, but one has just input one character of his 4000
* I do not know how to solve this, but the code to set slider and spinbox is fine thus I leave it ...
*
* I do not know how to solve this, but the code to set slider and spinbox is fine thus I leave it ...
*
* mhh it works if "apply changes to pipeline directly" button is deactivated, still it really confuses if
* the button is active. More investigation is needed.
*
*
// set warp factor to max, if warp factor > max
if (ui->Value->value() > ui->Max->value()) {
double warp_factor = ui->Max->value();
@@ -1150,7 +1151,7 @@ void TaskPostWarpVector::on_Max_valueChanged(double) {
void TaskPostWarpVector::on_Min_valueChanged(double) {
// TODO min should be smaller than max
// TODO if warp factor is smaller than min, warp factor should be min, don't forget to sync
// TODO if warp factor is smaller than min, warp factor should be min, don't forget to sync
ui->Slider->blockSignals(true);
ui->Slider->setValue((ui->Value->value() - ui->Min->value()) / (ui->Max->value() - ui->Min->value()) * 100.);
ui->Slider->blockSignals(false);

View File

@@ -415,7 +415,7 @@ std::string ViewProviderFemMesh::getElement(const SoDetail* detail) const
str << "Elem" << (edx>>3) << "F"<< (edx&7)+1;
}
// trigger on edges only if edge only mesh, otherwise you only hit edges an never faces....
// trigger on edges only if edge only mesh, otherwise you only hit edges and never faces....
else if (onlyEdges && detail->getTypeId() == SoLineDetail::getClassTypeId()) {
const SoLineDetail* line_detail = static_cast<const SoLineDetail*>(detail);
int edge = line_detail->getLineIndex() + 1;

View File

@@ -252,7 +252,7 @@ class GeometryElementsSelection(QtGui.QWidget):
self._helpTextLbl.setText(self.tr(
"Click on \"Add\" and select geometric elements to add them to the list."
" If no geometry is added to the list, all remaining ones are used."
" The following geometry elemets are allowed to select: ") + self.sel_elem_text)
" The following geometry elements are allowed to select: ") + self.sel_elem_text)
# list
self.list_References = QtGui.QListWidget()
# radiobutton down the list
@@ -324,8 +324,8 @@ class GeometryElementsSelection(QtGui.QWidget):
FreeCADGui.Selection.clearSelection()
if ref[1].startswith('Solid') and (ref[0].Shape.ShapeType == 'Compound' or ref[0].Shape.ShapeType == 'CompSolid'):
# selection of Solids of Compounds or CompSolids is not possible, because a Solid is no Subelement
# since only Subelements can be selected, we gone select all Faces of such an Solids
solid = FemMeshTools.get_element(ref[0], ref[1]) # the method getElement(element) does not return Solid elements
# since only Subelements can be selected, we're going to select all Faces of said Solids
solid = FemMeshTools.get_element(ref[0], ref[1]) # the method getElement(element) doesn't return Solid elements
if not solid:
return
faces = []
@@ -437,7 +437,7 @@ class GeometryElementsSelection(QtGui.QWidget):
if solid_to_add:
selection = (selection[0], 'Solid' + solid_to_add)
ele_ShapeType = 'Solid'
FreeCAD.Console.PrintMessage('selection variable adaped to hold the Solid: ' + selection[0].Shape.ShapeType + ' ' + selection[0].Name + ' ' + selection[1] + ' \n')
FreeCAD.Console.PrintMessage('selection variable adapted to hold the Solid: ' + selection[0].Shape.ShapeType + ' ' + selection[0].Name + ' ' + selection[1] + ' \n')
else:
return
if ele_ShapeType in self.sel_elem_types:

View File

@@ -153,7 +153,8 @@ class _TaskPanelFemMaterial:
self.card_path = self.get_material_card(self.material)
print('card_path: ' + self.card_path)
if not self.card_path:
# we have not found our material in self.materials dict :-(, we gone add a user defined temporary material, a document material
# we have not found our material in self.materials dict :-(
# we're going to add a user-defined temporary material: a document material
FreeCAD.Console.PrintMessage("Previously used material card cannot be found in material directories. Add document material.\n")
self.card_path = '_document_material'
self.materials[self.card_path] = self.material
@@ -228,7 +229,7 @@ class _TaskPanelFemMaterial:
def set_transient_material(self):
self.card_path = '_transient_material'
self.materials[self.card_path] = self.material # = the crurrent input fields data
self.materials[self.card_path] = self.material # = the current input fields data
index = self.parameterWidget.cb_materials.findData(self.card_path)
self.choose_material(index)

View File

@@ -397,7 +397,7 @@ class FemInputWriterCcx(FemInputWriter.FemInputWriter):
elif len(self.fluidsection_objects) > 1:
self.get_ccx_elsets_multiple_mat_multiple_fluid()
# TODO: some elemetIDs are collected for 1D-Flow calculation,
# TODO: some elementIDs are collected for 1D-Flow calculation,
# this should be a def somewhere else, preferable inside the get_ccx_elsets_... methods
for ccx_elset in self.ccx_elsets:
if ccx_elset['ccx_elset'] and not isinstance(ccx_elset['ccx_elset'], six.string_types): # use six to be sure to be Python 2.7 and 3.x compatible

View File

@@ -129,7 +129,7 @@ class MaterialEditor:
self.outputResources()
def outputResources(self):
print('locations we gone look for material cards:')
print('locations to look for material cards:')
for path in self.resources:
print(' ' + path)
print('\n')
@@ -160,7 +160,7 @@ class MaterialEditor:
def updateContents(self, data):
'''updates the contents of the editor with the given data, can be:
- the name of a card, if material is changed in editors combo box
- a dictionary, if the editor was called with data'''
- a dictionary, if the editor was called with data'''
# print type(data)
if isinstance(data, dict):
self.clearEditor()
@@ -287,7 +287,7 @@ class MaterialEditor:
w = self.widget.Editor.topLevelItem(i1)
for i2 in range(w.childCount()):
c = w.child(i2)
# TODO the following should be translated back to english,since text(0) could be translated
# TODO the following should be translated back to english, since text(0) could be translated
matkey = self.collapseKey(str(c.text(0)))
matvalue = unicode(c.text(1))
if matvalue or (matkey == 'Name'):