Commit Graph

58 Commits (14af83a3912c2c1d35faf06d82880f1d15f93f25)

Author SHA1 Message Date
Hleb Valoshka 14af83a391 Implement Logger to replace raw cerr/cout and DPRINTF usage 2021-12-20 17:54:50 +03:00
Hleb Valoshka 08b0cd0682 Use custom gettext file to translated object names 2021-12-14 13:16:18 +03:00
Hleb Valoshka 42790d9013 Replace deprecated fmt::fprintf calls 2021-10-19 19:35:23 +03:00
Andrew Tribick 11c0361324 Fixes for the Windows build
- Move the compatibility classes into the cel17 namespace
- Skip generating resource translations if Perl not present
- Use fmt/ostream.h instead of fmt/printf.h for string_view
2021-10-18 09:58:33 +03:00
Levin Li 04c6b40c50 Fix parsing URLs containing non ascii values 2021-06-05 15:57:06 +08:00
Levin Li fd2ba19d79 Add back support for URL version 4 2021-05-26 08:40:34 +08:00
Hleb Valoshka 332840fdd1 Refactor Url class
* Critical change:
   - Drop Url versions 1, 2 and 4. Versions 1 and 2 are
     too old and can't be handled properly. Version 4
     was added to handle 64 bit RenderFlags but we can
     encode them in backward compatible way by adding a
     new parameter "nrf" ignored by Celestia 1.6.

 * Use string_view to reduce memory allocation during Url
   parsing.

 * Use non-throwing functions to parse numbers.
2021-03-08 14:08:36 +03:00
Hleb Valoshka ddbe9ddd1d Refactor astro.*/url.* to remove extern global variables 2020-07-12 10:41:53 +03:00
Hleb Valoshka f67b331f02 Show error if an incorrect URL passed to CelestiaCore::goToUrl 2020-03-07 15:40:39 +03:00
Hleb Valoshka 154c06e0a7 Fix failure if an incorrect URL is pasted
Closes: #637

+ small code cleanup
2020-03-07 15:40:39 +03:00
Hleb Valoshka fb4bede3d1 Allow building without NLS 2020-02-15 00:20:13 +03:00
Li Linfeng 9c371c891c define macros for print levels and avoid direct use of fmt::printf 2019-08-31 13:32:44 +08:00
pirogronian c3567d820c Replace refcounted objects with std::shared_ptr 2019-08-16 12:45:57 +03:00
Hleb Valoshka f3a73dae71 Move math code into celmath namespace 2019-05-20 10:48:04 +03:00
Hleb Valoshka 78641736fd Replace sscanf with C++11 methods where appropriate 2019-05-02 22:58:37 +03:00
Hleb Valoshka 379a658dff Fix format specifier 2019-01-11 12:57:55 +03:00
Hleb Valoshka deeca96ddb Update URL to handle 64bit render flags, bump URL version to 4 2018-11-16 21:25:16 +01:00
Hleb Valoshka eab70c96cb Fix more coverity issues
Mostly uninitialized variables plus one memory leak
2018-10-30 23:52:19 +03:00
Hleb Valoshka 363abc40f3 Use libfmt instead of C-style & iostream workflow
TODO: check StarDatabase::getStarName
2018-10-17 22:19:03 +03:00
Hleb Valoshka b082d5f47f Automatically convert to c++11 using clan-tidy
+ manual cleanups
2018-09-22 23:42:02 +03:00
Hleb Valoshka 882e4ecf28 fix whitespaces and indents
trailing spaces are removed
tabs are replaced with 4 spaces

# Conflicts:
#	src/celengine/cmdparser.cpp
#	src/celengine/command.cpp
#	src/celestia/celestiacore.cpp
#	src/celestia/celestiacore.h
#	src/celestia/qt/qtappwin.cpp
#	src/celestia/qt/qtglwidget.cpp
#	src/celestia/win32/winmain.cpp
2018-09-22 23:41:57 +03:00
Andrew Tribick 94d590e67f Fix for Unicode cel URLs from v1.6.1 branch.
Fix for Unicode URLs in KDE bookmarks menu.
2011-03-13 00:58:23 +00:00
Chris Laurel 9cf68b5169 Eigenized parser and app core code. 2009-07-25 22:18:51 +00:00
Chris Laurel 9cca6b8c27 Eigenized Observer and Simulation classes. Fixed star picking bug. 2009-07-22 04:53:15 +00:00
Chris Laurel c9e60db060 Removed debugging code from url.cpp. 2009-03-20 18:07:24 +00:00
Chris Laurel ac85ac92d2 Added encoding of special characters in cel URLs. 2009-03-17 21:57:23 +00:00
Chris Laurel de41ec3813 Fixes to make Celestia build with gcc4.3 2008-11-16 10:19:38 +00:00
Chris Laurel d1139852b7 Added support for a new cel URL version that stores frame coordinates instead
of absolute coordinates and adds the time source option. Modified Qt4 front
end to create version 3 cel URLs. Added a time source option to the Qt4
Add Bookmark dialog.
2008-05-05 19:09:31 +00:00
Chris Laurel eba1b9940c - Implemented framework for Orbit and RotationModel subclasses to implement their own velocity and angular velocity methods to use instead of numerical differentation. Actual implementation of velocity methods will wait until further discussion on the developers list.
- Implemented Timelines for solar system bodies. A timeline allows a body to have different reference frames, orbits, and rotation models over time.
2008-02-21 02:25:48 +00:00
Chris Laurel a6cc486542 Rewrote observer class to use 1.5.0 reference frames. The FrameOfReference
class is replaced by the new ObserverFrame class, which is a wrapper for
ReferenceFrame. Small changes to a lot of file were necessary, in many cases
simply because the CoordinateSystem enum was moved from astro to
ObserverFrame. This change was primarily a refactoring to make future
development easier and improve performance be eliminating redundant
frame -> universal conversions of the observer position. The one change that
will be apparent to users is the redefinition of the chase and phase lock
frames. Previously, these used the spin axis of the reference object to define
the secondary frame axis. Now, the secondary axis is the position vector in
chase mode, and the velocity vector in phase lock mode.
2008-02-08 21:46:02 +00:00
Christophe Teyssier 281176ec53 Fixed bug 1738359 Barycenter not included in URL Path 2007-11-03 14:54:42 +00:00
Christophe Teyssier c60504c07a Moved pauseState from CelestiaCore to Simulation
Removed timeScale from CelestiaCore
Fixed pause behaviour with urls [bug 1819753]
Fixed track handling in urls when body with empty name exists [bug 1824833]
Fixed timeScale display in overlay
Added localization to numbers in flash messages
2007-11-03 09:49:29 +00:00
Chris Laurel 83c24983a6 Fixes for selection name in cel: URLs:
- Star name was being omitted for objects that directly orbited a star (i.e. moons of planets were fine, but not the planets themselves)
- No name was stored when the current selection was a location
2007-10-23 03:52:03 +00:00
Chris Laurel 78ff681c20 Added version stamp for cel URLs. 2007-01-11 19:30:04 +00:00
Christophe Teyssier 8bb9a79ad7 Fixed crash for improbably large dates. 2006-10-11 20:44:17 +00:00
Chris Laurel 974213f905 Integrated changes from Fridger and Toti's Celestia FT 1.2 2005-11-18 09:00:39 +00:00
Christophe Teyssier 2318e423a3 Adding support for i18n with gettext. 2005-07-19 21:31:04 +00:00
Christophe Teyssier e8aa62898d Replaced strcasecmp (BSD only) with compareIgnoringCase. 2004-02-11 22:25:42 +00:00
Christophe Teyssier 314af3350f Fix to make the 'mode' part case insensitive.
This is required because KDE 3.2 converts to lower case the server name in
URLs.
2004-02-09 21:06:41 +00:00
Christophe Teyssier cd1bcf78e0 Removed duplicate rf and lm variables in url. 2003-07-22 19:29:39 +00:00
Chris Laurel d7b3afc866 Redo the selection class to use a single pointer and a type field. 2003-06-25 17:40:24 +00:00
Christophe Teyssier eda0d8df99 New FoV handling 2003-06-03 21:49:54 +00:00
Christophe Teyssier 54dd8a9d78 Bug fix. 2003-05-31 17:52:31 +00:00
Christophe Teyssier 39cfe46350 Added Settings URL type. 2003-05-31 17:40:19 +00:00
Christophe Teyssier 67f6ed472f Compitability fix for old urls without light time delay information. 2003-05-17 09:55:05 +00:00
Christophe Teyssier 7ed945a8ef Added Light Time Delay 2003-05-06 22:13:33 +00:00
Chris Laurel 1efce138ac Removed dead code; modified position parsing to take advantage of BigFix(string) constructor. 2003-03-30 23:59:00 +00:00
Chris Laurel 70c2fa609d Fix bugs when reading time from cel:// URLs: real all fractional digits of seconds, and handle > 4 digit years 2003-03-29 22:30:02 +00:00
Chris Laurel 66487efd26 Store the time with additional precision. 2003-03-28 18:40:23 +00:00
Chris Laurel b8f1c84c3f Added field of view member to Observer. 2003-02-12 10:35:50 +00:00