ladybird/Userland/Applications/PixelPaint/EditGuideDialog.h
Linus Groh 6e19ab2bbc AK+Everywhere: Rename String to DeprecatedString
We have a new, improved string type coming up in AK (OOM aware, no null
state), and while it's going to use UTF-8, the name UTF8String is a
mouthful - so let's free up the String name by renaming the existing
class.
Making the old one have an annoying name will hopefully also help with
quick adoption :^)
2022-12-06 08:54:33 +01:00

34 lines
873 B
C++

/*
* Copyright (c) 2021, Tobias Christiansen <tobyase@serenityos.org>
*
* SPDX-License-Identifier: BSD-2-Clause
*/
#pragma once
#include "Guide.h"
#include "ImageEditor.h"
#include <LibGUI/Dialog.h>
namespace PixelPaint {
class EditGuideDialog final : public GUI::Dialog {
C_OBJECT(EditGuideDialog);
public:
DeprecatedString const offset() const { return m_offset; }
Guide::Orientation orientation() const { return m_orientation; }
Optional<float> offset_as_pixel(ImageEditor const&);
private:
EditGuideDialog(GUI::Window* parent_window, DeprecatedString const& offset = {}, Guide::Orientation orientation = Guide::Orientation::Unset);
DeprecatedString m_offset;
Guide::Orientation m_orientation;
RefPtr<GUI::TextBox> m_offset_text_box;
bool m_is_horizontal_checked { false };
bool m_is_vertical_checked { false };
};
}