Files
MuditaOS/module-gui/gui/core/renderers/PixelRenderer.hpp
Maciej Janicki bb59805a8e [EGD-4822] Add color test window to settings app
Add new window to allow convenient display and globally
change used color intensities  for design and testing purposes.
Changes were introduced to Renderer as well as GUI service
to allow global change of used color scheme.
When using list, screen is deep refreshed each
time the color is changed.
Known issues:
Item focus borders (top,bottom) with changed black intensity
may not render properly, however it doesn't obscure the
target functionality.
2021-02-04 13:34:04 +01:00

29 lines
639 B
C++

// Copyright (c) 2017-2020, Mudita Sp. z.o.o. All rights reserved.
// For licensing, see https://github.com/mudita/MuditaOS/LICENSE.md
#pragma once
#include "Color.hpp"
#include "Common.hpp"
#include <memory>
namespace gui
{
class Context;
} // namespace gui
namespace gui::renderer
{
class PixelRenderer
{
public:
PixelRenderer() = delete;
static void draw(Context *ctx, Point point, Color color);
static void updateColorScheme(const std::unique_ptr<ColorScheme> &scheme);
[[nodiscard]] static auto getColor(const uint8_t intensity) -> uint8_t;
};
} // namespace gui::renderer