ladybird/Userland/Libraries/LibGfx/Font/Emoji.h
Timothy Flynn fd1fbad1d2 LibGfx+LibUnicode: Support specifying the path to search for emoji
Similar to the FontDatabase, this will be needed for Ladybird to find
emoji images. We now generate just the file name of emoji image in
LibUnicode, and look for that file in the specified path (defaulting to
/res/emoji) at runtime.
2023-03-01 14:54:16 +00:00

30 lines
708 B
C++

/*
* Copyright (c) 2019-2020, Sergey Bugaev <bugaevc@serenityos.org>
* Copyright (c) 2022, Linus Groh <linusg@serenityos.org>
*
* SPDX-License-Identifier: BSD-2-Clause
*/
#pragma once
#include <AK/Forward.h>
#include <AK/Span.h>
#include <AK/String.h>
#include <AK/Types.h>
namespace Gfx {
class Bitmap;
class Emoji {
public:
static void set_emoji_lookup_path(String);
static Gfx::Bitmap const* emoji_for_code_point(u32 code_point);
static Gfx::Bitmap const* emoji_for_code_points(ReadonlySpan<u32> const&);
static Gfx::Bitmap const* emoji_for_code_point_iterator(Utf8CodePointIterator&);
static Gfx::Bitmap const* emoji_for_code_point_iterator(Utf32CodePointIterator&);
};
}