Commit Graph

36 Commits

Author SHA1 Message Date
Luke Street 9ca1a38171 Use UTF-8 exclusively internally
This removes SystemString, SystemChar, etc.
All filepaths and log strings are assumed to be UTF-8,
with conversions to UTF-16 for Windows APIs as appropriate.

Updates amuse, athena, boo, kabufua and nod
2021-06-30 14:20:45 -04:00
Phillip Stephens 201d5c5423
Don't show menubar by default, use to toggle it 2021-05-30 18:44:02 -07:00
Luke Street ca94f6974c Updates for fmtlib 7
Update submodules & tracking branches
2021-04-06 12:55:40 -04:00
Jack Andersen 6a8714c1f3 Update fmtlib 2020-04-11 12:48:11 -10:00
Phillip Stephens 02d4292179 Add missing brace (where the heck did it go?) 2019-10-24 22:49:41 -07:00
Phillip Stephens a9dee6e268 Minor string fix 2019-10-24 22:43:45 -07:00
Lioncash a0e6ec0de7 Console: Make State enum an enum class
Makes the enum strongly typed and impervious to implicit conversions.
2019-10-21 01:53:05 -04:00
Lioncash 78aa42032a Console: Make truncation explicit within proc()
Makes floating-point truncation explicit.
2019-10-21 01:40:34 -04:00
Lioncash 358acfe944 Console: Use std::move within vreport()
Avoids redundant copies when emplacing into the log container.
2019-10-21 01:37:07 -04:00
Lioncash c8eab43489 Console: Make commandExists() a const qualified member function
This doesn't modify internal console state, so it can be turned into a
const qualified member function.
2019-10-21 01:30:19 -04:00
Lioncash deb09550d3 Console: Eliminate redundant strlen call in commandExists()
By using the std::string_view constructor for std::string, we can avoid
the char* constructor, which would require a strlen call in order to
determine the string size. This also allows it to work with
non-null-terminated strings.
2019-10-21 01:28:22 -04:00
Lioncash 96721d96ae Console: Avoid unnecessary copies and lookups within executeCommand()
We can make use of the result of a find() call to avoid performing two
redundant lookups into the command map and also use std::move to avoid
performing potentially reallocating copies.
2019-10-21 01:26:21 -04:00
Lioncash 7fbdf384de Console: Reuse iterator in unregisterCommand()
We can use the result of the first lookup to avoid doing another
redundant lookup to perform the erasure.

While we're at it, we can use std::string's std::string_view constructor
in order to avoid an unnecessary strlen() call.
2019-10-21 01:07:41 -04:00
Lioncash 5d2987588b Console: Use emplace in registerCommand()
Allows avoiding a redundant initial element. We can also remove the
const from the std::function rvalue to allow a std::move to take effect.

We can also use the std::string_view constructor for std::string to
avoid an unnecessary strlen() call.
2019-10-21 01:03:30 -04:00
Lioncash cbd40382bf Console: Convert std::bind to lambda functions
Same behavior, but more efficient than wrapping the function.
2019-10-21 00:53:15 -04:00
Phillip Stephens 6b56f2e6a4 Minor fixes 2019-09-29 08:17:01 -07:00
Phillip Stephens 7fd54effc9 Various fixes and improvements to CVars 2019-09-29 05:44:01 -07:00
Lioncash 5e66bee28c General: Include necessary includes
Ensures all necessary includes are included and also removes headers
that aren't necessary
2019-09-04 19:23:55 -04:00
Lioncash 7088235bc4 hecl: Correct fmt formatting specifiers
These should be using {}-style formatting specifiers instead of printf
style. While we're at it, std::move the std::string instances where
applicable to potentially avoid reallocations.
2019-08-24 03:21:16 -04:00
Jack Andersen 6988f86672 Massive fmtlib refactor 2019-07-19 18:22:58 -10:00
Jack Andersen 2ab5c1436b Add True and False tests for bitwise enums 2019-04-02 18:29:04 -10:00
Phillip Stephens f776f89bee Minor Console fixes 2018-12-09 21:12:10 -08:00
Jack Andersen 72193079ae New code style refactor 2018-12-07 19:18:42 -10:00
Jack Andersen 0ee18025dd Huge shader infrastructure refactor 2018-10-06 16:53:57 -10:00
Phillip Stephens 801214d9a8 Add support for string literals in Console::executeString, add implicit get/set for CVars 2018-06-12 19:03:29 -07:00
Phillip Stephens 0aac384e60 Fix windows build 2018-05-01 17:41:51 -07:00
Phillip Stephens eae0dbd2bb Add ability to flag commands 2018-04-29 20:11:37 -07:00
Phillip Stephens 694bc0a888 Add ability to unregister command on the fly 2018-04-26 14:10:32 -07:00
Phillip Stephens 24abe43865 Restore old CVar system 2018-01-21 18:40:11 -08:00
Phillip Stephens 8cef2f5192 Add ability to enable developer mode in-code 2018-01-15 05:18:03 -08:00
Phillip Stephens 5c66ffc5df Refactor CVar class 2018-01-15 04:34:02 -08:00
Phillip Stephens 52c14848d9 Various minor fixes 2018-01-13 23:37:00 -08:00
Phillip Stephens f777d034f2 Implement core Console behavior and CVarManager commands 2018-01-13 18:39:32 -08:00
Phillip Stephens 7f6913e046 Fix linux build, initial logvisor integration into Console 2018-01-11 08:26:33 -08:00
Phillip Stephens 24ee3fa21e Windows build fix 2018-01-11 04:38:35 -08:00
Phillip Stephens e247733d04 Initial `Console` implementation 2018-01-11 01:36:00 -08:00