Lukas Dürrenberger
68ce027b2e
Update Catch2 to v3.8.0
2025-01-14 14:34:19 +00:00
Lukas Dürrenberger
b56604c940
Use approximation when comparing floats in tests
2025-01-08 11:33:40 +00:00
Chris Thrasher
796592edae
Add non-const overload of sf::Event::getIf
2024-12-29 20:50:38 -06:00
Lukas Dürrenberger
328f38553e
Update SFML version to 3.1.0
2024-12-21 11:28:47 -06:00
James Cowgill
ccda2659d4
Store IpAddress::m_address in host byte order
...
This changes the ordering of `IpAddress` objects to be lexographical
which is more intuitive, and it fixes unit test failures on big-endian
systems.
2024-12-08 23:20:43 +01:00
binary1248
248fd6dda8
Build dependency libraries instead of bundling pre-built binaries.
2024-12-04 23:52:24 +01:00
Chris Thrasher
ae87def93e
Use char32_t
for UTF-32 characters
...
This is probably an oversight from https://github.com/SFML/SFML/pull/2480
2024-11-30 18:28:34 -05:00
Chris Thrasher
51e38f51d4
Add tests for sf::Utf
2024-11-28 17:57:05 -05:00
Chris Thrasher
97541c6244
Add more tests for sf::SoundStream
2024-11-25 11:50:43 -07:00
Chris Thrasher
eec0ece713
Add missing sf::SoundSource
tests
2024-11-24 15:21:33 -07:00
Chris Thrasher
e21ba4dc95
Add more robust tests for sf::Music::setLoopPoints
2024-11-12 00:43:59 -07:00
Chris Thrasher
8758649b5d
Add tests for sf::Listener
2024-11-01 13:51:06 -06:00
Chris Thrasher
18eb48b13e
Disallow C-style arrays
2024-10-17 21:40:41 -06:00
Lukas Dürrenberger
ecb945b341
Use explicit constructors when implicit construction isn't wanted
2024-10-03 22:43:57 -06:00
vittorioromeo
816855d13f
Remove sf::Vector2<T>::Unit[XY]
2024-10-03 20:51:09 -06:00
ZXShady
de9286c11f
Use explicit conversion operator instead of explicit constructor
...
I also added a type trait test to check whether the conversion operator is marked explicit.
this change has the advantage of being clearer imo as it is a conversion operator for conersions not a constructor.
and also it allows users to take the address of convesion operator which I don't know if someone might find that useful.
2024-10-02 00:15:54 +02:00
Chris Thrasher
c8cf84511d
Fix clang-tidy-19 errors
2024-09-24 18:42:31 -06:00
Lukas Dürrenberger
6591c59504
Add window create functions without style specifier
...
This brings the create() functions inline with the constructor overloads
for WindowBase, Window, and RenderWindow
2024-09-16 12:05:59 -04:00
Chris Thrasher
ab109cd3cd
Use ON
and OFF
for CMake booleans
...
CMake supports a number of strings for truthy and falsey values.
ON/OFF and TRUE/FALSE are the most popular but 1/0 is also supported.
This is mostly a style choice but I'm inclined to believe that ON/OFF
is the most popular option and I'm generally in favor of style
choices that better align with the community at large.
2024-09-11 14:36:13 -06:00
Lukas Dürrenberger
9f52cfec39
Change spelling of anti-aliasing
2024-09-09 18:37:00 -06:00
Lukas Dürrenberger
265a0cb03f
Rename Vector2 & Vector3 functions to better fit the naming convention
2024-09-08 12:09:32 -06:00
Chris Thrasher
74dfd76b25
Pass sf::Vector2<T>
by value in test code
2024-09-01 17:51:54 +01:00
Chris Thrasher
27943ea774
Disallow constructing sf::String
from std::nullptr_t
2024-08-30 09:55:55 -06:00
Chris Thrasher
4a463ec136
Throw custom sf::Exception
type
2024-08-25 12:17:49 -06:00
CosminPerRam
6a94997ac9
chore: update catch2 from 3.6.0 to 3.7.0
2024-08-15 08:54:23 +01:00
Michal Tabaszewski
8096ba24fc
Rename getLoop() to isLooping() and setLoop() to setLooping()
2024-08-08 15:01:28 -06:00
binary1248
e185f6d53e
Replace factory functions with throwing constructors
2024-08-08 09:19:32 -06:00
binary1248
698f265277
(Re-)Introduce default constructors and load/open member functions for resource objects that can be reused.
2024-08-08 09:19:32 -06:00
Chris Thrasher
dffdaa52a7
Pass sf::Color
s by value
2024-07-31 09:25:21 -06:00
Chris Thrasher
b50f62da43
Test constexpr construction of aggregates
2024-07-27 17:27:39 -06:00
ZXShady
8c895fd7e1
Pass sf::IpAddress
by value
...
`sf::IpAddress` is a wrapper around `std::uint32_t` and should be passed by value
2024-07-27 15:53:03 -06:00
Chris Thrasher
0831f055ce
Require that sf::WindowBase::handleEvents
receives at least one argument
2024-07-21 11:59:05 -06:00
Chris Thrasher
c8c8673259
Pass sf::Vector2<T>
s by value
...
As a rule of thumb, if the type is less than or equal to the CPU
register width times two then you ought to pass it by value. This
will lead to more efficient code generation.
2024-07-19 10:33:00 -06:00
Chris Thrasher
b4c7e4a890
Stop running tests that sometimes hang indefinitely
2024-07-17 17:12:58 -06:00
vittorioromeo
7ba672139c
Simplify sf::WindowBase::handleEvents
and add basic tests
2024-07-09 17:51:41 +02:00
binary1248
41c48a84bc
Added visitation support to Event and WindowBase via handleEvents.
2024-07-08 15:16:20 -06:00
Chris Thrasher
fbd8407a5f
Enable moving windows
2024-06-30 16:50:32 -06:00
Chris Thrasher
e1469aa8f2
Use [[nodiscard]]
in more places
2024-06-27 15:12:15 -06:00
kimci86
fca4fa1aa2
Rename Font::loadFromFile into Font::openFromFile
...
Similar renaming for Font::loadFromMemory and Font::loadFromStream.
The goal is to better express the need to keep the source available,
similar to Music::openFromFile for example.
2024-06-25 22:53:28 +02:00
Chris Thrasher
14cff7406f
Disallow construction from const T&&
2024-06-23 16:55:37 -06:00
vittorioromeo
86c1a71a93
Remove default empty state of sf::Event
2024-06-23 19:11:10 +02:00
Chris Thrasher
6f5711e799
Decrease test precision to reduce flakey failures
...
Sometimes this job fails. Perhaps it needs to be resructured or
removed if we can't figure out how to make it more reliable.
https://github.com/SFML/SFML/actions/runs/9569223439/job/26381302304?pr=3106#step:21:137
2024-06-18 14:02:57 -06:00
kimci86
65c0a8183c
Simplify Rect unit tests
2024-06-16 02:48:53 +02:00
kimci86
c371bc6816
Remove Rect getPosition and getSize methods
2024-06-16 02:48:53 +02:00
kimci86
7e5ed78219
Replace Rect members left, top, width, height by position and size
2024-06-16 02:48:53 +02:00
vittorioromeo
e7b23ffcd1
Add timeout
parameter to waitEvent
2024-06-14 15:00:46 +02:00
vittorioromeo
51efe50ec4
Simplify sf::Sprite
implementation and reduce branches
2024-06-13 00:31:49 +02:00
Chris Thrasher
2f54312481
Fix documentation bugs
2024-06-12 14:38:04 -05:00
Chris Thrasher
304a7c1d69
Remove default empty state of sf::FileInputStream
2024-06-11 07:31:09 -05:00
Chris Thrasher
366b119963
Remove default empty state of sf::MemoryInputStream
2024-06-10 08:11:28 -05:00