31#include "../View/view.h"
32#include "../../Core/Math/size.h"
33#include "../../Core/Math/vec2.h"
34#include "label_view.h"
86 std::unique_ptr<TextViewImpl> impl;
2D Graphics Canvas
Definition: canvas.h:72
Keyboard key event.
Definition: key_event.h:48
2D (width,height) size structure - Integer
Definition: size.h:171
Definition: text_view.h:41
Signal< void(KeyEvent &)> & sig_before_edit_changed()
void set_selection(Vec2i head, Vec2i tail)
void set_cursor_pos(Vec2i pos)
Signal< void(KeyEvent &)> & sig_after_edit_changed()
std::string selection() const
float calculate_last_baseline_offset(Canvas &canvas, float width) override
Calculates the offset to the last baseline.
Vec2i selection_start() const
std::string placeholder() const
float calculate_first_baseline_offset(Canvas &canvas, float width) override
Calculates the offset to the first baseline.
Signal< void(KeyEvent &)> & sig_enter_pressed()
void render_content(Canvas &canvas) override
Renders the content of a view.
void set_placeholder(const std::string &value)
bool is_read_only() const
Signal< void()> & sig_selection_changed()
void delete_selected_text()
void set_preferred_size(Size num_characters)
TextAlignment text_alignment() const
void set_cursor_drawing_enabled(bool value)
void set_text_alignment(TextAlignment value)
float calculate_preferred_height(Canvas &canvas, float width) override
Calculates the preferred height of this view.
float calculate_preferred_width(Canvas &canvas) override
Calculates the preferred width of this view.
Vec2i selection_end() const
Size preferred_size() const
void set_text(const std::string &value)
void set_read_only(bool value=true)
View for an area of the user interface.
Definition: view.h:66
TextAlignment
Definition: label_view.h:39