Allow disabling anti-aliasing via a setting (#241)

Fixes https://github.com/daveallie/crosspoint-reader/issues/233

By disabling the Text Anti-Aliasing in the settings, you can get faster
black-and-white page turns that work exactly like the stock firmware,
instead of having an additional flash after rendering (see issue linked
above for example).

Tested on the X4 and confirmed working.

---------

Co-authored-by: Dave Allie <dave@daveallie.com>
This commit is contained in:
Stanislav Khromov
2026-01-07 10:14:35 +01:00
committed by Irene Ying
parent 63e976b875
commit b60568a91a
4 changed files with 7 additions and 3 deletions

View File

@@ -388,7 +388,7 @@ void EpubReaderActivity::renderContents(std::unique_ptr<Page> page, const int or
// grayscale rendering
// TODO: Only do this if font supports it
{
if (SETTINGS.textAntiAliasing) {
renderer.clearScreen(0x00);
renderer.setRenderMode(GfxRenderer::GRAYSCALE_LSB);
page->render(renderer, SETTINGS.getReaderFontId(), orientedMarginLeft, orientedMarginTop);

View File

@@ -13,7 +13,7 @@
// Define the static settings list
namespace {
constexpr int settingsCount = 17;
constexpr int settingsCount = 18;
const SettingInfo settingsList[settingsCount] = {
// Should match with SLEEP_SCREEN_MODE
{"Sleep Screen", SettingType::ENUM, &CrossPointSettings::sleepScreen, {"Dark", "Light", "Custom", "Cover", "None"}},