Members of the KDE Community are recommended to subscribe to the kde-community mailing list at https://mail.kde.org/mailman/listinfo/kde-community to allow them to participate in important discussions and receive other important announcements

Commit 003b411f authored by Yuri Chornoivan's avatar Yuri Chornoivan

Fix Clang issues and typos

parent a2997225
......@@ -35,7 +35,7 @@ class Isotope;
* In this class all information about an element are stored. This means that
* both the chemical date and the data about the position are stored
* in this class.
* @short This class is the represention of a chemical element
* @short This class is the representation of a chemical element
* @author Carsten Niehaus
*/
class SCIENCE_EXPORT Element
......
......@@ -30,7 +30,7 @@
/**
* @class pseTables
* Provides functions to easyli create pse tables with qGridLayouts or qGraphicsView.
* Provides functions to easily create pse tables with qGridLayouts or qGraphicsView.
*
* creating a table for the gridlayout
@code
......@@ -57,7 +57,7 @@
int itemAtPos = pseTables::instance()->getTabletype(j)->numerationAtPos(i);
}
@endcode
* @short Provides shape and elements of diferent peridic tables of elements
* @short Provides shape and elements of different periodic tables of elements
* @author Etienne Rebetez
*/
class pseTable;
......@@ -93,13 +93,13 @@ public:
private:
pseTables();
QList<pseTable*> m_tables;
int m_currentTable;
//int m_currentTable;
};
/**
* defines a Periodic Table.
* Holds the position (x,y) and all the displaed elements
* Holds the position (x,y) and all the displayed elements
*/
class pseTable
......@@ -167,7 +167,7 @@ public:
/**
* Returns the Numeration for the current Table according to the position in the Table.
* Coordinatates beginning wiht 0. Returns -1 if none is found.
* Coordinates beginning with 0. Returns -1 if none is found.
*/
virtual int numerationAtPos(int xPos) const;
......
......@@ -105,7 +105,7 @@ bool SpectrumParser::endElement(const QString&, const QString& localName, const
} else if (localName == "peakList") {
d->inSpectrumList_ = false;
} else if (localName == "peak") {
//X qDebug() << "in 'peak'" << " with this data: " << d->currentPeak->intensity << " (intesity)" ;
//X qDebug() << "in 'peak'" << " with this data: " << d->currentPeak->intensity << " (intensity)" ;
d->currentSpectrum->addPeak(d->currentPeak);
d->currentPeak = nullptr;
d->inPeak_ = false;
......
......@@ -494,7 +494,7 @@ void concentrationCalculator::calculateAmountSolute()
// We have the amount of solvent in some form (moles, equivalents, mass, volume etc)
// Now we have to present it in the UI
switch (type2) {
case 0: // amount should be specified interms of mass
case 0: // amount should be specified in terms of mass
switch (mode) {
case 1: // we should get mass from moles
massSolute = molesSolute * m_MolarMass;
......@@ -1156,7 +1156,7 @@ void concentrationCalculator::setMode (int mode)
return;
}
// set all to writeable
// set all to writable
m_amountSolute->nativeWidget()->setReadOnly(false);
m_molarMass->nativeWidget()->setReadOnly(false);
m_eqtMass->nativeWidget()->setReadOnly(false);
......
......@@ -495,7 +495,7 @@ void nuclearCalculator::calculate()
}
calculateInitAmount();
break;
case 1: // Calulate final Amount after time
case 1: // Calculate final Amount after time
if (m_InitAmount.number() == 0.0) {
error(INIT_AMT_ZERO);
return;
......
......@@ -79,7 +79,7 @@ Molmasscalculator::~Molmasscalculator()
void Molmasscalculator::init()
{
// checking if the Dataengine is availiable
// checking if the Dataengine is available
if (!dataEngine("kalzium")->isValid()) {
setFailedToLaunch(true, i18n("Dataengine \"kalzium\" not found"));
}
......
......@@ -52,7 +52,7 @@ public:
void init();
public slots:
/// Appens the given String to the lineedit text and let it parse by ParseMolecule.
/// Appends the given String to the lineedit text and let it parse by ParseMolecule.
void appendElement(QString ElementSymbol);
void configChanged();
......
......@@ -46,7 +46,7 @@ class calculator : public QDialog
public:
/*
* The clas constructor and destructor, takes in a Widget as parent
* The class constructor and destructor, takes in a Widget as parent
*/
calculator(QWidget *parent = nullptr); // constructor
~ calculator(); // destructor
......
......@@ -206,7 +206,7 @@ void concCalculator::calculateAmtSolute()
// We have the amount of solvent in some form (moles, equivalents, mass, volume etc)
// Now we have to present it in the UI
switch (type2) {
case 0: // amount should be specified interms of mass
case 0: // amount should be specified in terms of mass
switch (mode) {
case 1: // we should get mass from moles
massSolute = molesSolute * m_molarMass;
......@@ -873,7 +873,7 @@ void concCalculator::setMode(int mode)
return;
}
// set all to writeable
// set all to writable
ui.amtSolute->setReadOnly(false);
ui.molarMass->setReadOnly(false);
ui.eqtMass->setReadOnly(false);
......
......@@ -49,7 +49,7 @@ enum MODE_CALCULATION_GAS {
/**
* This class implements the gas calculator. It performs basic calculations like
* calculation of volume given pressure, temerature, amount etc. and so on.
* calculation of volume given pressure, temperature, amount etc. and so on.
*
* Van der Val's gas equation
* ( P + n^2 a / V^2) ( V - nb ) = nRT
......
......@@ -342,7 +342,7 @@ void nuclearCalculator::calculate()
}
calculateInitAmount();
break;
case 1: // calulate final amount after given time
case 1: // calculate final amount after given time
if (ui.initAmt->value() == 0.0) {
error(INIT_AMT_ZERO);
return;
......
......@@ -471,7 +471,7 @@ void titrationCalculator::on_actionRapid_Help_triggered()
// I think it's better if I don't give so much information here.
// This information could be included into kalzium help, but I don't know how to do
//QMessageBox::information(this, "IceeQt Rapid Help", "There are two ways to use IceeQt:\n\nTheoretical Equations\n Here you can fill the table with the equations you have previously obtained for the chemical equilibria. FOR EXAMPLE if you have this reaction A + B -> C + D then you will have the equation K=(C*D)/(A*B) so you must write 'K' in the Parameter column and '(C*D)/(A*B)' in the Value column. If you want to assign a known value to a parameter you can simply write the numeric value in the Value field. FOR EXAMPLE you can use the system \nA=(C*D)/(B*K) \nK=10^-3 \nC=OH \nOH=(10^-14)/H \nH=10^-4 \nB=6*(10^-2) \nThen you have to write D as X axis and A as Y axis: so you will find out how the concentration of A change in function of D concentration.\nPlease don't use parenthesis for exponents: 10^-3 is correct, while 10^(-3) is wrong. \n\nExperimental Values\n You can use this program to draw the plot of your experimental data obtained during a titration and find out the volume of equivalence. It's strongly recommended to insert a even number of points, because of the best fit algorithm, sorted by volume (the X axis value).\n\nPlot\n The plot shows in red the curve that cames from theorical equations, in blue the experimental points, and in green the aproximated curve for experimental points.");
//QMessageBox::information(this, "IceeQt Rapid Help", "There are two ways to use IceeQt:\n\nTheoretical Equations\n Here you can fill the table with the equations you have previously obtained for the chemical equilibria. FOR EXAMPLE if you have this reaction A + B -> C + D then you will have the equation K=(C*D)/(A*B) so you must write 'K' in the Parameter column and '(C*D)/(A*B)' in the Value column. If you want to assign a known value to a parameter you can simply write the numeric value in the Value field. FOR EXAMPLE you can use the system \nA=(C*D)/(B*K) \nK=10^-3 \nC=OH \nOH=(10^-14)/H \nH=10^-4 \nB=6*(10^-2) \nThen you have to write D as X axis and A as Y axis: so you will find out how the concentration of A change in function of D concentration.\nPlease don't use parenthesis for exponents: 10^-3 is correct, while 10^(-3) is wrong. \n\nExperimental Values\n You can use this program to draw the plot of your experimental data obtained during a titration and find out the volume of equivalence. It's strongly recommended to insert a even number of points, because of the best fit algorithm, sorted by volume (the X axis value).\n\nPlot\n The plot shows in red the curve that comes from theoretical equations, in blue the experimental points, and in green the approximated curve for experimental points.");
}
/*
......@@ -527,7 +527,7 @@ void titrationCalculator::on_actionSave_triggered()
// l|
// note|
// ewewewww|
// as you can see we don't save also the empty cells, this is obious.
// as you can see we don't save also the empty cells, this is obvious.
QString tempyval;
tempyval = "table1|";
......@@ -582,7 +582,7 @@ void titrationCalculator::on_actionSave_triggered()
void titrationCalculator::on_actionOpen_triggered()
{
//loads all the cells text from a file prevoiusly saved
//loads all the cells text from a file previously saved
QString file = QFileDialog::getOpenFileName(this,i18n("Open work"),"",i18n("Icee File (*.icee)"));
if (!file.isEmpty()) {
QByteArray bac = file.toLatin1();
......
......@@ -450,7 +450,7 @@ void DetailedInfoDlg::createContent()
{
KPageWidgetItem *item = nullptr;
// Removed the overview Tab, because its an Dockwidget and dosn't show much information.
// Removed the overview Tab, because its an Dockwidget and doesn't show much information.
// overview tab
// QWidget *m_pOverviewTab = new QWidget();
// item = addPage(m_pOverviewTab, i18n("Overview"));
......
......@@ -382,7 +382,7 @@ void ElementDataViewer::drawPlot()
double min_y = m_yData->value(from);
/*
* iterate for example from element 20 to 30 and contruct
* iterate for example from element 20 to 30 and construct
* the KPlotObjects
*/
dataPointGreen = new KPlotObject(
......@@ -518,7 +518,7 @@ void ElementDataViewer::drawPlot()
ui.plotwidget->addPlotObject(dataPointRed);
if (num > 0) {
//now set the values for the min, max and avarage value
//now set the values for the min, max and average value
ui.av_x->setText(QString::number(av_x / num).append(m_xData->unit));
ui.minimum_x->setText(QString::number(min_x).append(m_xData->unit));
ui.maximum_x->setText(QString::number(max_x).append(m_xData->unit));
......
......@@ -211,7 +211,7 @@ void GradientWidgetImpl::play(void)
if ((gradient_slider)->value() >= gradient_slider->maximum()) {
gradient_slider->setValue (gradient_slider->minimum ());
}
//start the timer at 200 milisecond time interval with single shot disabled
//start the timer at 200 millisecond time interval with single shot disabled
m_timer->start(200);
m_play = true; //start playing
......
......@@ -68,7 +68,7 @@ private slots:
void doubleToSlider(double var);
void intToSpinbox(int var);
/**
* is used to display custom text in the widget accrding tu the current value of the gradient
* is used to display custom text in the widget according to the current value of the gradient
*/
void setNewValue(double newValue);
......
......@@ -26,7 +26,7 @@
class Isotope;
/**
* The class represtens the items which is drawn on the QGraphicsScene. Each such item represents on
* The class represents the items which is drawn on the QGraphicsScene. Each such item represents on
* Isotope.
* @author Carsten Niehaus
*/
......
......@@ -130,11 +130,11 @@ void Kalzium::setupActions()
export_action->setText(i18n("&Export Data..."));
connect(export_action, SIGNAL(triggered(bool)), this, SLOT(slotShowExportDialog()));
// the action for swiching look: color schemes and gradients
// the action for switching look: color schemes and gradients
QStringList schemes = KalziumElementProperty::instance()->schemeList(); /*KalziumSchemeTypeFactory::instance()->schemes();*/
QStringList gradients = KalziumElementProperty::instance()->gradientList();
// the action for swiching look: schemes
// the action for switching look: schemes
look_action_schemes = actionCollection()->add<KSelectAction>("view_look_onlyschemes");
look_action_schemes->setText(i18n("&Scheme"));
look_action_schemes->setItems(schemes);
......@@ -142,7 +142,7 @@ void Kalzium::setupActions()
look_action_schemes->setToolButtonPopupMode(QToolButton::InstantPopup);
connect(look_action_schemes, SIGNAL(triggered(int)), this, SLOT(slotSwitchtoLookScheme(int)));
// the action for swiching look: gradients
// the action for switching look: gradients
look_action_gradients = actionCollection()->add<KSelectAction>("view_look_onlygradients");
look_action_gradients->setText(i18n("&Gradients"));
look_action_gradients->setItems(gradients);
......@@ -150,7 +150,7 @@ void Kalzium::setupActions()
look_action_gradients->setToolButtonPopupMode(QToolButton::InstantPopup);
connect(look_action_gradients, SIGNAL(triggered(int)), this, SLOT(slotSwitchtoLookGradient(int)));
// the action for swiching tables
// the action for switching tables
QStringList table_schemes = pseTables::instance()->tables();
table_action = actionCollection()->add<KSelectAction>("view_table");
table_action->setText(i18n("&Tables"));
......@@ -535,7 +535,7 @@ void Kalzium::slotUpdateSettings()
Prefs::self()->save();
/*This slot function calls change the color of pse elements immideately after prefs change*/
/*This slot function calls change the color of pse elements immediately after prefs change*/
slotSwitchtoLookGradient(Prefs::colorgradientbox());
slotSwitchtoLookScheme(Prefs::colorschemebox());
}
......
......@@ -130,7 +130,7 @@ private:
Search *m_search;
friend class StaticKalziumDataObject;
friend struct StaticKalziumDataObject;
};
#endif // KALZIUMDATAOBJECT_H
......@@ -27,10 +27,10 @@
/**
* The logic of the scheme and the gradients is merged in this class. It provides
* an api to set the gradient and scheme without worring about the real id's.
* Elements can then get their propertys with the element functions.
* an API to set the gradient and scheme without worrying about the real id's.
* Elements can then get their properties with the element functions.
* Here is also the place where the gradientslider is evaluated. (see gradientwidget)
* @short This class holds the logic of the appiriance from the periodic table
* @short This class holds the logic of the appearance from the periodic table
* @author Etienne Rebetez
*/
......@@ -71,7 +71,7 @@ public:
*/
int schemeId() const;
/**
* Returns the current gradient id as int. Equivalent to the gradent list.
* Returns the current gradient id as int. Equivalent to the gradient list.
*/
int gradientId() const;
......@@ -86,14 +86,14 @@ public:
/**
* This is an element function.
* It returns the Brush (Backround) for the given element.
* It returns the Brush (Background) for the given element.
* It uses the color form getElementColor.
* @param el Number of the element.
*/
QBrush getElementBrush(int el);
/**
* This is an element function.
* It returns the Color (Backround) for the given element.
* It returns the Color (Background) for the given element.
* @param el Number of the element.
*/
QColor getElementColor(int el);
......@@ -112,7 +112,7 @@ public:
/**
* This is an element function.
* It returns the value from the current gradent type for the given element.
* It returns the value from the current gradient type for the given element.
* @param el Number of the element.
*/
double getValue(int el) const;
......@@ -126,7 +126,7 @@ public:
Q_SIGNALS:
/**
* Is emitted every time a property (scheme, gradent, ...) is changed.
* Is emitted every time a property (scheme, gradient, ...) is changed.
* all elements will be redrawn.
*/
void propertyChanged();
......
......@@ -69,7 +69,7 @@ public:
static QString prettyUnit(const Element *el, ChemicalDataObject::BlueObelisk kind);
/**
* Populates a a combobox wiht the names of the units. @see KUnitConversion.
* Populates a combobox with the names of the units. @see KUnitConversion.
* @param combobox the pointer to the combobox
* @param unitList Unit list with enums of KUnitConversion
*/
......
......@@ -89,12 +89,12 @@ public:
/**
* defines which picture to use as the background
* of the htmlview. The dialog
* will use the file specifiec by the @p filename
* will use the file specific by the @p filename
*/
void setBackgroundPicture(const QString& filename);
/**
* @return the picuture used as the background in
* @return the picture used as the background in
* this background
*/
QString backgroundPicture()const;
......@@ -181,7 +181,7 @@ public:
QStringList pictures() const;
/**
* @return the formated HTML code for current item.
* @return the formatted HTML code for current item.
*/
QString toHtml() const;
......
......@@ -53,7 +53,7 @@ public:
/**
* Get the rectangle of the given periodic table.
* @param tableIndex Index of the table @see pseTables.
* @return Rectangle in floating point precission.
* @return Rectangle in floating point precision.
*/
QRectF pseRect(const int &tableIndex) const;
......
......@@ -39,7 +39,7 @@
/**
* @class PeriodicTableView
* In this class the periodic table of elements is created.
* It provides slots to change the tables and accessing the element propertys
* It provides slots to change the tables and accessing the element properties
* @short Base class and creation for the pse System
* @author Carsten Niehaus
* @author Marcus D. Hanwell
......@@ -61,12 +61,12 @@ public:
/**
* Returns the current id of the pse-table.
* The id is the same as the menü and the pse list from the pseTables class.
* The id is the same as the menu and the pse list from the pseTables class.
*/
int table() const;
/**
* Genarates and saves the pse as svg in the given filename.
* Generates and saves the pse as svg in the given filename.
* @param filename filename of the destination.
*/
void generateSvg(const QString& filename);
......@@ -129,7 +129,7 @@ protected:
bool event(QEvent *e) override;
/**
* is caled every time the view is resized.
* is called every time the view is resized.
*/
void resizeEvent(QResizeEvent * event) override;
};
......
/**********************************************************************
Statemachine
Copyrigth (C) 2010 by Etienne Rebetez, etienne.rebetez@oberwallis.ch
Copyright (C) 2010 by Etienne Rebetez, etienne.rebetez@oberwallis.ch
This is free software; you can redistribute it and/or modify
it under the terms of the GNU Lesser General Public License as published by
......
......@@ -84,12 +84,12 @@ public:
/**
* @return the adjusted value of the @p color. The
* correction depends on @p factor which has been
* figured out emperically
* figured out empirically
*/
int Adjust(double color, double factor);
/**
* @return the postion in the widget of a band
* @return the position in the widget of a band
* with the wavelength @p wavelength
*
* @param wavelength the wavelength for which the position is needed
......
......@@ -96,7 +96,7 @@ private slots:
private:
// workaround for broken copy-operator of QtGui::Molecule
// whould be removed after next Avogadro release greater 0.9
// would be removed after next Avogadro release greater 0.9
Avogadro::QtGui::Molecule m_molecule;
};
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment