1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-27 08:27:46 +00:00

LibGfx: Add abstraction to load BitmapFont from a FixedMemoryStream

We'll use this to load from a Core::Resource in a later commit.
This commit is contained in:
Andrew Kaster 2023-10-17 11:52:31 -06:00 committed by Andrew Kaster
parent a4c7d9a374
commit 897f4d05eb
2 changed files with 13 additions and 6 deletions

View file

@ -32,6 +32,7 @@ public:
static RefPtr<BitmapFont> load_from_file(DeprecatedString const& path);
static ErrorOr<NonnullRefPtr<BitmapFont>> try_load_from_file(DeprecatedString const& path);
static ErrorOr<NonnullRefPtr<BitmapFont>> try_load_from_mapped_file(NonnullOwnPtr<Core::MappedFile>);
static ErrorOr<NonnullRefPtr<BitmapFont>> try_load_from_stream(FixedMemoryStream&);
ErrorOr<void> write_to_file(DeprecatedString const& path);
ErrorOr<void> write_to_file(NonnullOwnPtr<Core::File> file);