Fix encoding / C++11 compliance
- convert text encoding to UTF-8 - C++11 requires a space between literal and identifier
This commit is contained in:
parent
211a4982c8
commit
1cffd2b8c0
1 changed files with 16 additions and 17 deletions
|
@ -42,8 +42,7 @@ using namespace std;
|
|||
using namespace simgear;
|
||||
|
||||
// text color
|
||||
#if defined(__linux__) || defined(__sun) || defined(__CYGWIN__) \
|
||||
|| defined( __FreeBSD__ ) || defined ( sgi )
|
||||
#if defined(__linux__) || defined(__sun) || defined(__CYGWIN__) || defined( __FreeBSD__ ) || defined ( sgi )
|
||||
# define R "\033[31;1m" // red
|
||||
# define G "\033[32;1m" // green
|
||||
# define Y "\033[33;1m" // yellow
|
||||
|
@ -188,7 +187,7 @@ void printReport(SGMetar *m)
|
|||
if ((i = m->getWindDir()) == -1)
|
||||
cout << "from variable directions";
|
||||
else
|
||||
cout << "from the " << azimuthName(i) << " (" << i << "°)";
|
||||
cout << "from the " << azimuthName(i) << " (" << i << "°)";
|
||||
cout << " at " << rnd(d, -1) << " km/h";
|
||||
|
||||
cout << "\t\t" << rnd(m->getWindSpeed_kt(), -1) << " kt";
|
||||
|
@ -209,19 +208,19 @@ void printReport(SGMetar *m)
|
|||
if (from != to) {
|
||||
cout << "\t\t\tvariable from " << azimuthName(from);
|
||||
cout << " to " << azimuthName(to);
|
||||
cout << " (" << from << "°--" << to << "°)" << endl;
|
||||
cout << " (" << from << "°--" << to << "°)" << endl;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
// temperature/humidity/air pressure
|
||||
if ((d = m->getTemperature_C()) != NaN) {
|
||||
cout << "Temperature:\t\t" << d << "°C\t\t\t\t\t";
|
||||
cout << rnd(m->getTemperature_F(), -1) << "°F" << endl;
|
||||
cout << "Temperature:\t\t" << d << "°C\t\t\t\t\t";
|
||||
cout << rnd(m->getTemperature_F(), -1) << "°F" << endl;
|
||||
|
||||
if ((d = m->getDewpoint_C()) != NaN) {
|
||||
cout << "Dewpoint:\t\t" << d << "°C\t\t\t\t\t";
|
||||
cout << rnd(m->getDewpoint_F(), -1) << "°F" << endl;
|
||||
cout << "Dewpoint:\t\t" << d << "°C\t\t\t\t\t";
|
||||
cout << rnd(m->getDewpoint_F(), -1) << "°F" << endl;
|
||||
cout << "Rel. Humidity:\t\t" << rnd(m->getRelHumidity()) << "%" << endl;
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue