Skip to content

Commit

Permalink
spelling fixes (FreeCAD#18688)
Browse files Browse the repository at this point in the history
* Fixes spelling of "Allow to" to "Allow one to"

and those variants:
Allows to -> Allows one to
allow to -> allow one to
allows to -> allows one to

* Fix "Let's -> Lets"

(and lower case variant.)

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Update src/3rdParty/salomesmesh/inc/MED_Wrapper.hxx

Co-authored-by: Chris Hennes <[email protected]>

* Update src/Base/PyObjectBase.cpp
Update src/App/ExtensionContainer.h
Update src/App/PropertyContainer.h

Co-authored-by: Chris Hennes <[email protected]>

* Use gerund in user-facing texts.

* Use gerund for two more user-facing strings.

Co-authored-by: Chris Hennes <[email protected]>

* Update src/Mod/Fem/App/FemMeshShapeNetgenObject.cpp

Co-authored-by: Chris Hennes <[email protected]>

* Update src/Mod/Fem/App/FemMeshShapeNetgenObject.cpp

Co-authored-by: Chris Hennes <[email protected]>

* Update src/Mod/Fem/App/FemMeshShapeNetgenObject.cpp

Co-authored-by: Chris Hennes <[email protected]>

---------

Co-authored-by: Tobias Frost <[email protected]>
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Chris Hennes <[email protected]>
  • Loading branch information
4 people authored Jan 13, 2025
1 parent f301393 commit 7a5a3d1
Show file tree
Hide file tree
Showing 104 changed files with 149 additions and 148 deletions.
2 changes: 1 addition & 1 deletion src/3rdParty/salomesmesh/inc/MED_Wrapper.hxx
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ namespace MED
struct MEDWRAPPER_EXPORT TWrapper
{
typedef boost::mutex TMutex;
//! This is a syncronization primitive which allow to support thread safety for the MED access
//! This is a synchronization primitive which allows one to support thread safety for the MED access
TMutex myMutex;

virtual
Expand Down
2 changes: 1 addition & 1 deletion src/3rdParty/salomesmesh/inc/SMESH_Array1.hxx
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@
* The range of the index is user defined.
* An array1 can be constructed with a "C array".
* This functionality is useful to call methods expecting
* an Array1. It allows to carry the bounds inside the arrays.
* an Array1. It allows one to carry the bounds inside the arrays.
*
* Examples: Item tab[100]; // An example with a C array
* Array1OfItem ttab (tab[0],1,100);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ bool SMDS_PolyhedralVolumeOfNodes::ChangeNodes (const vector<const SMDS_MeshNode
myNodesByFaces = nodes;
myQuantities = quantities;

// Init fields of parent class, it allows to get only unique nodes(?)
// Init fields of parent class, it allows one to get only unique nodes(?)

set<const SMDS_MeshNode *> aSet;
aSet.insert( nodes.begin(), nodes.end());
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3512,7 +3512,7 @@ bool StdMeshers_Cartesian_3D::Compute(SMESH_Mesh & theMesh,
// The algorithm generates the mesh in following steps:

// 1) Intersection of grid lines with the geometry boundary.
// This step allows to find out if a given node of the initial grid is
// This step allows one to find out if a given node of the initial grid is
// inside or outside the geometry.

// 2) For each cell of the grid, check how many of it's nodes are outside
Expand Down
2 changes: 1 addition & 1 deletion src/App/DocumentPyImp.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -353,7 +353,7 @@ PyObject* DocumentPy::addObject(PyObject* args, PyObject* kwd)
str << "No document object found of type '" << sType << "'" << std::ends;
throw Py::TypeError(str.str());
}
// Allows to hide the handling with Proxy in client python code
// Allows one to hide the handling with Proxy in client python code
if (obj) {
try {
// the python binding class to the document object
Expand Down
2 changes: 1 addition & 1 deletion src/App/ExtensionContainer.h
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ class Extension;
* impossible to handle multiple inheritance in the C-API for python extensions. Also using multiple
* parent classes in python is currently not possible with the default object approach.
*
* The concept of extensions allow to circumvent those problems. Extensions are FreeCAD objects
* The concept of extensions allows one to circumvent those problems. Extensions are FreeCAD objects
* which work like normal objects in the sense that they use properties and class methods to define
* their functionality. However, they are not exposed as individual usable entities but are used to
* extend other objects. A extended object gets all the properties and methods of the extension.
Expand Down
2 changes: 1 addition & 1 deletion src/App/FeaturePython.h
Original file line number Diff line number Diff line change
Expand Up @@ -162,7 +162,7 @@ class AppExport FeaturePythonImp
};

/**
* Generic Python feature class which allows to behave every DocumentObject
* Generic Python feature class which allows one to behave every DocumentObject
* derived class as Python feature -- simply by subclassing.
* @author Werner Mayer
*/
Expand Down
2 changes: 1 addition & 1 deletion src/App/FeaturePythonPyImp.inl
Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,7 @@ int FeaturePythonPyT<FeaturePyT>::__setattro(PyObject *obj, PyObject *attro, PyO
{
const char *attr;
attr = PyUnicode_AsUTF8(attro);
// This overwrites PyObjectBase::__setattr because this actively disallows to delete an attribute
// This overwrites PyObjectBase::__setattr because this actively disallows one to delete an attribute
//

if (!static_cast<Base::PyObjectBase*>(obj)->isValid()){
Expand Down
2 changes: 1 addition & 1 deletion src/App/PropertyContainer.h
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ struct AppExport PropertyData
};

//purpose of this struct is to be constructible from all acceptable container types and to
//be able to return the offset to a property from the accepted containers. This allows to use
//be able to return the offset to a property from the accepted containers. This allows you to use
//one function implementation for multiple container types without losing all type safety by
//accepting void*
struct OffsetBase
Expand Down
2 changes: 1 addition & 1 deletion src/Base/ConsoleObserver.h
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@ class BaseExport ConsoleObserverStd: public ILogger
};

/** The ILoggerBlocker class
* This class allows to temporary block then automatically restore arbitrary message types
* This class allows one to temporary block then automatically restore arbitrary message types
* on a particular console observer.
*/
class BaseExport ILoggerBlocker
Expand Down
4 changes: 2 additions & 2 deletions src/Base/PyObjectBase.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,7 @@ PyObjectBase::~PyObjectBase()
* To prevent subclasses of PyTypeObject to be subclassed in Python we should remove
* the Py_TPFLAGS_BASETYPE flag. For example, the classes App::VectorPy and App::MatrixPy
* have removed this flag and its Python proxies App.Vector and App.Matrix cannot be subclassed.
* In case we want to allow to derive from subclasses of PyTypeObject in Python
* In case we want to allow a new class to derive from subclasses of PyTypeObject in Python
* we must either reimplement tp_new, tp_dealloc, tp_getattr, tp_setattr, tp_repr or set them to
* 0 and define tp_base as 0.
*/
Expand Down Expand Up @@ -367,7 +367,7 @@ int PyObjectBase::__setattro(PyObject *obj, PyObject *attro, PyObject *value)
const char *attr{};
attr = PyUnicode_AsUTF8(attro);

//Hint: In general we don't allow to delete attributes (i.e. value=0). However, if we want to allow
//Hint: In general we don't allow one to delete attributes (i.e. value=0). However, if we want to allow
//we must check then in _setattr() of all subclasses whether value is 0.
if (!value) {
PyErr_Format(PyExc_AttributeError, "Cannot delete attribute: '%s'", attr);
Expand Down
2 changes: 1 addition & 1 deletion src/Base/Sequencer.h
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,7 @@ class SequencerLauncher;
* seq2.next ();
* }
*
* seq1.next ( true ); // allow to cancel
* seq1.next ( true ); // allow one to cancel
* }
* }
* catch(const Base::AbortException&){
Expand Down
2 changes: 1 addition & 1 deletion src/Base/VectorPyImp.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -733,7 +733,7 @@ int VectorPy::setCustomAttributes(const char* /*attr*/, PyObject* /*obj*/)
}

// TODO: for v0.18
// In generation script allow to more precisely define which slots
// In generation script allow one to more precisely define which slots
// of the number protocol should be supported instead of setting all.

PyObject* VectorPy::number_divide_handler(PyObject* self, PyObject* other)
Expand Down
2 changes: 1 addition & 1 deletion src/Gui/CallTips.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -168,7 +168,7 @@ void CallTipsList::validateCursor()
hide();
}
else if (!word.isEmpty()){
// If the word is empty we should not allow to do a search,
// If the word is empty we should not allow one to do a search,
// otherwise we may select the next item which is not okay in this
// context. This might happen if e.g. Shift is pressed.
keyboardSearch(word);
Expand Down
2 changes: 1 addition & 1 deletion src/Gui/CommandWindow.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -475,7 +475,7 @@ bool StdCmdWindowsMenu::isActive()

Action * StdCmdWindowsMenu::createAction()
{
// Allow to show 10 menu items in the 'Window' menu and one separator.
// Allow one to show 10 menu items in the 'Window' menu and one separator.
// If we have more windows then the user can use the 'Windows...' item.
WindowAction *pcAction;
pcAction = new WindowAction(this, getMainWindow());
Expand Down
2 changes: 1 addition & 1 deletion src/Gui/DlgOnlineHelpImp.h
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ namespace Dialog {
class Ui_DlgOnlineHelp;

/** This class implements the dialog for downloading the online documentation.
* Moreover it allows to specify location of the start page an an external browser.
* Moreover it allows one to specify location of the start page an an external browser.
* Here you can specify to use a proxy if necessary and some more stuff.
* \author Werner Mayer
*/
Expand Down
2 changes: 1 addition & 1 deletion src/Gui/DlgParameterImp.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -513,7 +513,7 @@ void ParameterGroup::contextMenuEvent(QContextMenuEvent* event)
QTreeWidgetItem* item = currentItem();
if (item && item->isSelected()) {
expandAct->setEnabled(item->childCount() > 0);
// do not allow to import parameters from a non-empty parameter group
// do not allow one to import parameters from a non-empty parameter group
importAct->setEnabled(item->childCount() == 0);

if (item->isExpanded()) {
Expand Down
2 changes: 1 addition & 1 deletion src/Gui/GestureNavigationStyle.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -207,7 +207,7 @@ class NS::Event : public sc::event<NS::Event>
bool propagated = false; //flag that the event had been passed to superclass
};
std::shared_ptr<Flags> flags;
//storing these values as a separate unit allows to effectively write to
//storing these values as a separate unit allows one to effectively write to
//const object. Statechart passes all events as const, unfortunately, so
//this is a workaround. I've considered casting away const instead, but
//the internet seems to have mixed opinion if it's undefined behavior or
Expand Down
2 changes: 1 addition & 1 deletion src/Gui/GraphicsViewZoom.h
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@
*
* Note that it becomes not possible when the scene's
* size is not large enough comparing to the viewport size. QGraphicsView centers the picture
* when it's smaller than the view. And QGraphicsView's scrolls boundaries don't allow to
* when it's smaller than the view. And QGraphicsView's scrolls boundaries don't allow one to
* put any picture point at any viewport position.
*
* When the user starts scrolling, this class remembers original scene position and
Expand Down
2 changes: 1 addition & 1 deletion src/Gui/InputField.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -737,7 +737,7 @@ QValidator::State InputField::validate(QString& input, int& pos) const
std::string unitStr;
res.getUserString(factor, unitStr);
double value = res.getValue()/factor;
// disallow to enter numbers out of range
// disallow one to enter numbers out of range
if (value > this->Maximum || value < this->Minimum)
return QValidator::Invalid;
}
Expand Down
2 changes: 1 addition & 1 deletion src/Gui/MainWindow.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2296,7 +2296,7 @@ void MainWindow::setWindowTitle(const QString& string)
appname = QString::fromLatin1(App::Application::Config()["ExeName"].c_str());
}

// allow to disable version number
// allow one to disable version number
ParameterGrp::handle hGen = App::GetApplication().GetParameterGroupByPath(
"User parameter:BaseApp/Preferences/General");
bool showVersion = hGen->GetBool("ShowVersionInTitle", true);
Expand Down
4 changes: 2 additions & 2 deletions src/Gui/MainWindow.h
Original file line number Diff line number Diff line change
Expand Up @@ -182,7 +182,7 @@ class GuiExport MainWindow : public QMainWindow
* one gets created automatically if needed.
*
* If a url handler is registered that supports its scheme it will be delegated
* to this handler. This mechanism allows to change the default behaviour.
* to this handler. This mechanism allows one to change the default behaviour.
*/
void loadUrls(App::Document*, const QList<QUrl>&);
/**
Expand Down Expand Up @@ -288,7 +288,7 @@ public Q_SLOTS:
void dragEnterEvent(QDragEnterEvent * e) override;
/**
* This method is called from the Qt framework automatically whenever a
* QTranslator object has been installed. This allows to translate all
* QTranslator object has been installed. This allows one to translate all
* relevant user visible text.
*/
void changeEvent(QEvent *e) override;
Expand Down
2 changes: 1 addition & 1 deletion src/Gui/ManualAlignment.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -958,7 +958,7 @@ void ManualAlignment::align()
.arg(myFixedGroup.countPoints()));
}
else {
// do not allow to pick further points
// do not allow one to pick further points
myAlignModel.activeGroup().removeFromViewer(myViewer->getViewer(0));
myAlignModel.activeGroup().setAlignable(false);
std::vector<App::DocumentObject*> pViews = myAlignModel.activeGroup().getViews();
Expand Down
2 changes: 1 addition & 1 deletion src/Gui/MayaGestureNavigationStyle.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -501,7 +501,7 @@ SbBool MayaGestureNavigationStyle::processSoEvent(const SoEvent * const ev)
switch(button){
case SoMouseButtonEvent::BUTTON1:
case SoMouseButtonEvent::BUTTON2:
case SoMouseButtonEvent::BUTTON3: // allows to release button3 into SELECTION mode
case SoMouseButtonEvent::BUTTON3: // allows one to release button3 into SELECTION mode
if(comboAfter & BUTTON1DOWN || comboAfter & BUTTON2DOWN) {
//don't leave navigation till all buttons have been released
if (comboAfter & BUTTON1DOWN && comboAfter & BUTTON2DOWN) {
Expand Down
2 changes: 1 addition & 1 deletion src/Gui/NotificationArea.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -552,7 +552,7 @@ class NotificationsAction: public QWidgetAction
}

/** pushes all Notification Items to the fast cache (this also prevents all unnecessary
* signaling from parents) and allows to accelerate insertions and deletions
* signaling from parents) and allows one to accelerate insertions and deletions
*/
void shiftToCache()
{
Expand Down
2 changes: 1 addition & 1 deletion src/Gui/OnlineDocumentation.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -364,7 +364,7 @@ void StdCmdPythonHelp::activated(int iMsg)

bool Gui::OpenURLInBrowser(const char* URL)
{
// The webbrowser Python module allows to start the system browser in an OS-independent way
// The webbrowser Python module allows one to start the system browser in an OS-independent way
Base::PyGILStateLocker lock;
try {
PyObject* module = PyImport_ImportModule("webbrowser");
Expand Down
4 changes: 2 additions & 2 deletions src/Gui/PythonConsole.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1110,7 +1110,7 @@ bool PythonConsole::canInsertFromMimeData (const QMimeData * source) const
}

/**
* Allow to paste plain text or urls of text files.
* Allow one to paste plain text or urls of text files.
*/
void PythonConsole::insertFromMimeData (const QMimeData * source)
{
Expand Down Expand Up @@ -1601,7 +1601,7 @@ bool ConsoleHistory::next()

/**
* prev switches the history pointer to the previous item.
* The optional parameter prefix allows to search the history selectively for commands that start
* The optional parameter prefix allows one to search the history selectively for commands that start
* with a certain character sequence.
* @param prefix - prefix string for searching backwards in history, empty string by default
* @return true if the pointer was switched to an earlier item, false otherwise.
Expand Down
8 changes: 4 additions & 4 deletions src/Gui/PythonConsolePy.h
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ class PythonConsole;

/**
* Python class for redirection of stdout to FreeCAD's Python
* console window. This allows to show all Python messages in
* console window. This allows one to show all Python messages in
* the same window where the commands are performed.
* @see PythonStderr
* @see PythonConsole
Expand All @@ -59,7 +59,7 @@ class PythonStdout : public Py::PythonExtension<PythonStdout>

/**
* Python class for redirection of stderr to FreeCAD's Python
* console window. This allows to show all Python messages in
* console window. This allows one to show all Python messages in
* the same window where the commands are performed.
* @see PythonStdout
* @see PythonConsole
Expand All @@ -85,7 +85,7 @@ class PythonStderr : public Py::PythonExtension<PythonStderr>

/**
* Python class for redirection of stdout to FreeCAD's output
* console window. This allows to report all Python output to
* console window. This allows one to report all Python output to
* the report view which simplifies debugging scripts.
* @see PythonStdout
* @see PythonStderr
Expand All @@ -108,7 +108,7 @@ class OutputStdout : public Py::PythonExtension<OutputStdout>

/**
* Python class for redirection of stderr to FreeCAD's output
* console window. This allows to report all Python errors to
* console window. This allows one to report all Python errors to
* the report view which simplifies error tracking.
* @see PythonStdout
* @see PythonStderr
Expand Down
4 changes: 2 additions & 2 deletions src/Gui/QSint/actionpanel/actionbox.h
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ namespace QSint
connect(action2, SIGNAL(clicked()), this, SLOT(action2clicked()));
\endcode

createItem() also allows to create an ActionLabel from already existing QAction:
createItem() also allows one to create an ActionLabel from already existing QAction:

\code
QAction myAction3(":/icons/action3icon.png", "Action3 Text");
Expand Down Expand Up @@ -195,7 +195,7 @@ class QSINT_EXPORT ActionBox : public QFrame
one below another.

You can add action to the specified layout passing it as \a l parameter.
This allows to do custom actions arrangements, i.e. horizontal etc.
This allows one to do custom actions arrangements, i.e. horizontal etc.

\since 0.2
*/
Expand Down
2 changes: 1 addition & 1 deletion src/Gui/QSint/actionpanel/actiongroup.h
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ class QSINT_EXPORT ActionGroup : public QWidget
one below another.

Set \a addToLayout to \a false if you want to add the action to the specified layout manually.
This allows to do custom actions arrangements, i.e. horizontal etc.
This allows one to do custom actions arrangements, i.e. horizontal etc.

If \a addStretch is set to \a true (default),
ActionLabel will be automatically aligned to the left side of the ActionGroup.
Expand Down
2 changes: 1 addition & 1 deletion src/Gui/SoFCOffscreenRenderer.h
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ class GuiExport SoFCOffscreenRenderer : public SoOffscreenRenderer
public:
/** The SoOffscreenRenderer base class seems to have a huge memory leak. Whenever
* an instance is created internal memory doesn't get freed when destroying it.
* Thus, SoFCOffscreenRenderer is implemented as singleton to allow to create only
* Thus, SoFCOffscreenRenderer is implemented as singleton to allow one to create only
* one global instance. So, the memory is leaking for this instance only.
*/
static SoFCOffscreenRenderer& instance();
Expand Down
2 changes: 1 addition & 1 deletion src/Gui/SpinBox.h
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,7 @@ class UIntSpinBoxPrivate;
/**
* The UIntSpinBox class does basically the same as Qt's QSpinBox unless
* that it works with unsigned int's instead.
* This allows to use numbers in the range of [0, UINT_MAX]
* This allows one to use numbers in the range of [0, UINT_MAX]
* @author Werner Mayer
*/
class GuiExport UIntSpinBox : public QSpinBox, public ExpressionSpinBox
Expand Down
4 changes: 2 additions & 2 deletions src/Gui/SplitView3DInventor.h
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ class View3DInventorViewer;
class AbstractSplitViewPy;
class View3DSettings;

/** The SplitView3DInventor class allows to create a window with two or more Inventor views.
/** The SplitView3DInventor class allows one to create a window with two or more Inventor views.
* \author Werner Mayer
*/
class GuiExport AbstractSplitView : public MDIView
Expand Down Expand Up @@ -106,7 +106,7 @@ class AbstractSplitViewPy : public Py::PythonExtension<AbstractSplitViewPy>
Gui::MDIViewPy base;
};

/** The SplitView3DInventor class allows to create a window with two or more Inventor views.
/** The SplitView3DInventor class allows one to create a window with two or more Inventor views.
* \author Werner Mayer
*/
class GuiExport SplitView3DInventor : public AbstractSplitView
Expand Down
2 changes: 1 addition & 1 deletion src/Gui/ToolBox.h
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ namespace DockWnd
*
* Items are added using addItem(), or inserted at particular positions using insertItem(). The total number of
* items is given by count(). Items can be deleted with delete, or removed from the toolbox with removeItem().
* Combining removeItem() and insertItem() allows to move items to different positions.
* Combining removeItem() and insertItem() allows one to move items to different positions.
*
* The current item widget is returned by currentItem() and set with setCurrentItem(). If you prefer you can
* work in terms of indexes using currentIndex(), setCurrentIndex(), indexOf() and item().
Expand Down
2 changes: 1 addition & 1 deletion src/Gui/View3DInventor.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -872,7 +872,7 @@ bool View3DInventor::eventFilter(QObject* watched, QEvent* e)
{
// As long as this widget is a top-level window (either in 'TopLevel' or 'FullScreen' mode) we
// need to be notified when an action is added to a widget. This action must also be added to
// this window to allow to make use of its shortcut (if defined).
// this window to allow one to make use of its shortcut (if defined).
// Note: We don't need to care about removing an action if its parent widget gets destroyed.
// This does the action itself for us.
if (watched != this && e->type() == QEvent::ActionAdded) {
Expand Down
2 changes: 1 addition & 1 deletion src/Gui/ViewProviderExtensionPython.h
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@
namespace Gui {

/**
* Generic Python extension class which allows to behave every extension
* Generic Python extension class which allows one to behave every extension
* derived class as Python extension -- simply by subclassing.
*/
template <class ExtensionT>
Expand Down
Loading

0 comments on commit 7a5a3d1

Please sign in to comment.