Commit Graph

16 Commits

Author SHA1 Message Date
Dalton Messmer
2c6d88f799 Add GUARD_H closing comments 2023-01-05 17:58:49 -05:00
Dalton Messmer
fe6df8dbaf Add namespace prefix to include guards 2023-01-02 19:51:32 -05:00
Johannes Lorenz
3cc5ec7282 Add check-namespace script (#6438)
This also fixes a lot of code files to be conforming to the script.

Co-authored-by: allejok96 <allejok96@gmail.com>
2022-08-30 02:19:07 +02:00
Levin Oehlmann
f742710758 Macro cleanup (#6095)
Summary:

* `NULL` -> `nullptr`
* `gui` -> Function `getGUI()`
* `pluginFactory` -> Function `getPluginFactory()`
* `assert` (redefinition) -> using `NDEBUG` instead, which standard `assert` respects.
* `powf` (C stdlib symbol clash) -> removed and all expansions replaced with calls to `std::pow`.
* `exp10` (nonstandard function symbol clash) -> removed and all expansions replaced with calls to `std::pow`.
* `PATH_DEV_DSP` -> File-scope QString of identical name and value.
* `VST_SNC_SHM_KEY_FILE` -> constexpr char* with identical name and value.
* `MM_ALLOC` and `MM_FREE` -> Functions with identical name and implementation.
* `INVAL`, `OUTVAL`, etc. for automation nodes -> Functions with identical names and implementations.
* BandLimitedWave.h: All integer constant macros replaced with constexpr ints of same name and value.
* `FAST_RAND_MAX` -> constexpr int of same name and value.
* `QSTR_TO_STDSTR` -> Function with identical name and equivalent implementation.
* `CCONST` -> constexpr function template with identical name and implementation.
* `F_OPEN_UTF8` -> Function with identical name and equivalent implementation.
* `LADSPA_PATH_SEPARATOR` -> constexpr char with identical name and value.
* `UI_CTRL_KEY` -> constexpr char* with identical name and value.
* `ALIGN_SIZE` -> Renamed to `LMMS_ALIGN_SIZE` and converted from a macro to a constexpr size_t.
* `JACK_MIDI_BUFFER_MAX` -> constexpr size_t with identical name and value.
* versioninfo.h: `PLATFORM`, `MACHINE` and `COMPILER_VERSION` -> prefixed with `LMMS_BUILDCONF_` and converted from macros to constexpr char* literals.
* Header guard _OSCILLOSCOPE -> renamed to OSCILLOSCOPE_H
* Header guard _TIME_DISPLAY_WIDGET -> renamed to TIME_DISPLAY_WIDGET_H
* C-style typecasts in DrumSynth.cpp have been replaced with `static_cast`.
* constexpr numerical constants are initialized with assignment notation instead of curly brace intializers.
* In portsmf, `Alg_seq::operator[]` will throw an exception instead of returning null if the operator index is out of range.

Additionally, in many places, global constants that were declared as `const T foo = bar;` were changed from const to constexpr, leaving them const and making them potentially evaluable at compile time.

Some macros that only appeared in single source files and were unused in those files have been removed entirely.
2021-09-30 18:01:27 +02:00
tresf
5174bdaa0d Spaces to tabs 2017-12-11 10:46:19 -05:00
David Carlier
a653d01ac8 Few code fixes since we re dealing with C++11 2017-12-09 07:55:30 +00:00
grejppi
9e85d7c66e update all copyright headers to the proper url (#3326) 2017-02-06 02:41:15 +02:00
Lukas W
e935cb046e Fix header guards
Closes #177
2014-11-25 11:25:30 +01:00
Umcaruje
6fb923cba2 Correct the program name and site in the descriptions. 2014-11-04 22:56:50 +01:00
Lukas W
ac54fcdac2 Fix some warnings 2014-01-24 22:04:37 +01:00
Tobias Doerffel
d6262bb556 use lmmsconfig.h rather than config.h and use prefixed macro-names
git-svn-id: https://lmms.svn.sf.net/svnroot/lmms/trunk/lmms@1097 0778d3d1-df1d-0410-868b-ea421aaaa00d
2008-06-08 11:30:47 +00:00
Javier Serrano Polo
1a94835907 updated FSF address
git-svn-id: https://lmms.svn.sf.net/svnroot/lmms/trunk/lmms@381 0778d3d1-df1d-0410-868b-ea421aaaa00d
2006-08-27 23:31:03 +00:00
Tobias Doerffel
3992e5c954 improved FLP-filter a lot
git-svn-id: https://lmms.svn.sf.net/svnroot/lmms/trunk/lmms@118 0778d3d1-df1d-0410-868b-ea421aaaa00d
2006-04-05 13:24:13 +00:00
Tobias Doerffel
ab719618f7 new audio-mixing system and new VST-support-framework
git-svn-id: https://lmms.svn.sf.net/svnroot/lmms/trunk/lmms@25 0778d3d1-df1d-0410-868b-ea421aaaa00d
2005-11-30 10:19:11 +00:00
Tobias Doerffel
22de18909a added ALSA-sequencer support
git-svn-id: https://lmms.svn.sf.net/svnroot/lmms/trunk/lmms@23 0778d3d1-df1d-0410-868b-ea421aaaa00d
2005-11-07 13:44:52 +00:00
Tobias Doerffel
4c7832a975 Initial revision
git-svn-id: https://lmms.svn.sf.net/svnroot/lmms/trunk/lmms@3 0778d3d1-df1d-0410-868b-ea421aaaa00d
2005-09-22 13:49:52 +00:00