supertux
|
The tilebox allows selection of tiles or objects from a specified tilegroup/objectgroup. More...
#include <tilebox.hpp>
Public Types | |
enum | HoveredItem { NONE, TILE, SCROLLBAR } |
enum | TileScrolling { NONE, UP, DOWN } |
enum | InputType { NONE, TILE, OBJECT } |
Public Member Functions | |
EditorTilebox (Editor &editor, const Rectf &rect) | |
virtual void | draw (DrawingContext &context) override |
virtual bool | on_mouse_button_up (const SDL_MouseButtonEvent &button) override |
virtual bool | on_mouse_button_down (const SDL_MouseButtonEvent &button) override |
virtual bool | on_mouse_motion (const SDL_MouseMotionEvent &motion) override |
virtual bool | on_mouse_wheel (const SDL_MouseWheelEvent &wheel) override |
virtual void | setup () override |
virtual void | resize () override |
void | set_rect (const Rectf &rect) |
Rectf | get_rect () const |
void | on_select (const std::function< void(EditorTilebox &)> &callback) |
void | select_tilegroup (int id) |
void | set_tilegroup (std::unique_ptr< Tilegroup > tilegroup) |
void | select_objectgroup (int id) |
bool | select_layers_objectgroup () |
const ObjectInfo & | get_object_info () const |
InputType | get_input_type () const |
void | set_input_type (InputType input_type) |
TileSelection * | get_tiles () const |
const std::string & | get_object () const |
void | set_object (const std::string &object) |
float | get_tiles_height () const |
bool | has_active_object_tip () const |
![]() | |
virtual bool | event (const SDL_Event &ev) |
virtual void | update (float dt_sec) |
virtual bool | on_key_up (const SDL_KeyboardEvent &key) |
virtual bool | on_key_down (const SDL_KeyboardEvent &key) |
The tilebox allows selection of tiles or objects from a specified tilegroup/objectgroup.
NOTE: Not to be confused with EditorToolboxWidget, which also includes tilegroup/objectgroup selection and tools.