mirror of
https://github.com/RGBCube/serenity
synced 2025-05-31 07:38:10 +00:00

This will represent a complex, region-based selection in the future. For now though, it's just a simple rectangle. :^)
18 lines
388 B
C++
18 lines
388 B
C++
/*
|
|
* Copyright (c) 2021, Andreas Kling <kling@serenityos.org>
|
|
*
|
|
* SPDX-License-Identifier: BSD-2-Clause
|
|
*/
|
|
|
|
#include "Selection.h"
|
|
#include "ImageEditor.h"
|
|
#include <LibGfx/Painter.h>
|
|
|
|
namespace PixelPaint {
|
|
|
|
void Selection::paint(Gfx::Painter& painter, ImageEditor const& editor)
|
|
{
|
|
painter.draw_rect(editor.image_rect_to_editor_rect(m_rect).to_type<int>(), Color::Magenta);
|
|
}
|
|
|
|
}
|