31 #include "../View/view.h"
32 #include "../../Core/Math/size.h"
33 #include "../../Core/Math/vec2.h"
34 #include "label_view.h"
38 class TextAreaBaseViewImpl;
86 std::unique_ptr<TextAreaBaseViewImpl> impl;
2D (width,height) size structure - Integer
Definition: size.h:167
void set_cursor_pos(Vec2i pos)
Signal< void()> & sig_selection_changed()
void set_placeholder(const std::string &value)
void set_text(const std::string &value)
Signal< void(KeyEvent *)> & sig_enter_pressed()
void set_cursor_drawing_enabled(bool value)
void set_text_alignment(TextAlignment value)
std::string placeholder() const
Signal< void(KeyEvent *)> & sig_before_edit_changed()
Vec2i selection_start() const
float calculate_preferred_height(const CanvasPtr &canvas, float width) override
Calculates the preferred height of this view.
TextAlignment
Definition: label_view.h:37
float calculate_first_baseline_offset(const CanvasPtr &canvas, float width) override
Calculates the offset to the first baseline.
TextAlignment text_alignment() const
bool is_read_only() const
void render_content(const CanvasPtr &canvas) override
Renders the content of a view.
std::string selection() const
void set_preferred_size(Size num_characters)
Vec2i selection_end() const
Size preferred_size() const
View for an area of the user interface.
Definition: view.h:68
void delete_selected_text()
float calculate_last_baseline_offset(const CanvasPtr &canvas, float width) override
Calculates the offset to the last baseline.
Signal< void(KeyEvent *)> & sig_after_edit_changed()
std::shared_ptr< Canvas > CanvasPtr
Definition: canvas.h:126
float calculate_preferred_width(const CanvasPtr &canvas) override
Calculates the preferred width of this view.
Definition: Application/application.h:35
void set_selection(Vec2i head, Vec2i tail)
Definition: text_area_view.h:40
void set_read_only(bool value=true)