Skip to content

Commit

Permalink
renderer/text_renderer: Prefer FreeType renderer for auto selection i…
Browse files Browse the repository at this point in the history
…f available
  • Loading branch information
xqq committed Sep 29, 2023
1 parent 360ac76 commit 8a1f3c5
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/renderer/text_renderer.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -53,12 +53,12 @@ std::unique_ptr<TextRenderer> TextRenderer::Create(TextRendererType type, Contex

case TextRendererType::kAuto:
default:
#if defined(_WIN32) && defined(ARIBCC_USE_DIRECTWRITE)
#if defined(ARIBCC_USE_FREETYPE)
return std::make_unique<TextRendererFreetype>(context, font_provider);
#elif defined(_WIN32) && defined(ARIBCC_USE_DIRECTWRITE)
return std::make_unique<TextRendererDirectWrite>(context, font_provider);
#elif defined(__APPLE__) && defined(ARIBCC_USE_CORETEXT)
return std::make_unique<TextRendererCoreText>(context, font_provider);
#elif defined(ARIBCC_USE_FREETYPE)
return std::make_unique<TextRendererFreetype>(context, font_provider);
#else
static_assert(false, "No available auto-select TextRenderer!");
#endif
Expand Down

0 comments on commit 8a1f3c5

Please sign in to comment.