4#ifndef INCLUDE_FIFECHAN_WIDGETS_PANEL_HPP_
5#define INCLUDE_FIFECHAN_WIDGETS_PANEL_HPP_
11#include "fifechan/platform.hpp"
14#include "fifechan/listeners/mouselistener.hpp"
15#include "fifechan/widgets/container.hpp"
104 void setTitle(std::string
const & title);
112 std::string
const &
getTitle()
const;
154 bool mClosable =
true;
159 int mCollapsedWidth = 10;
Abstract interface providing primitive drawing functions (lines, rectangles, etc.).
Represents a mouse event.
MouseListener(MouseListener const &)=default
Copy constructor.
virtual bool handleContentClick(MouseEvent &event)
Handles content area mouse clicks.
int getCollapsedWidth() const
Gets the collapsed width.
void setClosable(bool closable)
Sets whether the panel has a close button.
void draw(Graphics *graphics) override
Draws the panel content.
VisibilityState getVisibilityState() const
Gets the visibility state of the panel.
void setCollapsedWidth(int width)
Sets the width when the panel is collapsed.
void adjustSize() override
Adjusts the panel size based on its visibility state.
void setTitle(std::string const &title)
Sets the panel title.
void setVisibilityState(VisibilityState state)
Sets the visibility state of the panel.
bool isClosable() const
Checks if the panel has a close button.
void mousePressed(MouseEvent &event) override
std::string const & getTitle() const
Gets the panel title.
void setVisible(bool visible)
Sets whether the panel is visible.
Represents a rectangular area (X, Y, Width, Height).
Used replacement tokens by configure_file():
VisibilityState
Defines the visibility state of a Panel.