Skip to content

Commit

Permalink
fix the doxygen documentation by moving comments at the right place (#…
Browse files Browse the repository at this point in the history
  • Loading branch information
benoitdudu authored Oct 19, 2023
1 parent d4c9c5e commit f499d34
Showing 1 changed file with 32 additions and 32 deletions.
64 changes: 32 additions & 32 deletions include/ftxui/component/component_options.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -22,10 +22,10 @@ namespace ftxui {
/// |Radiobox::transform|, |MenuEntryOption::transform|,
/// |MenuOption::transform|.
struct EntryState {
std::string label; /// < The label to display.
bool state; /// < The state of the button/checkbox/radiobox
bool active; /// < Whether the entry is the active one.
bool focused; /// < Whether the entry is one focused by the user.
std::string label; ///< The label to display.
bool state; ///< The state of the button/checkbox/radiobox
bool active; ///< Whether the entry is the active one.
bool focused; ///< Whether the entry is one focused by the user.
};

struct UnderlineOption {
Expand Down Expand Up @@ -151,10 +151,10 @@ struct CheckboxOption {
/// @brief Used to define style for the Input component.
struct InputState {
Element element;
bool hovered; /// < Whether the input is hovered by the mouse.
bool focused; /// < Whether the input is focused by the user.
bool is_placeholder; /// < Whether the input is empty and displaying the
/// < placeholder.
bool hovered; ///< Whether the input is hovered by the mouse.
bool focused; ///< Whether the input is focused by the user.
bool is_placeholder; ///< Whether the input is empty and displaying the
///< placeholder.
};

/// @brief Option for the Input component.
Expand All @@ -175,9 +175,9 @@ struct InputOption {

// Style:
std::function<Element(InputState)> transform;
Ref<bool> password = false; /// < Obscure the input content using '*'.
Ref<bool> multiline = true; /// < Whether the input can be multiline.
Ref<bool> insert = true; /// < Insert or overtype character mode.
Ref<bool> password = false; ///< Obscure the input content using '*'.
Ref<bool> multiline = true; ///< Whether the input can be multiline.
Ref<bool> insert = true; ///< Insert or overtype character mode.

/// Called when the content changes.
std::function<void()> on_change = [] {};
Expand Down Expand Up @@ -232,32 +232,32 @@ struct SliderOption {

// Parameter pack used by `WindowOptions::render`.
struct WindowRenderState {
Element inner; /// < The element wrapped inside this window.
const std::string& title; /// < The title of the window.
bool active = false; /// < Whether the window is the active one.
bool drag = false; /// < Whether the window is being dragged.
bool resize = false; /// < Whether the window is being resized.
bool hover_left = false; /// < Whether the resizeable left side is hovered.
bool hover_right = false; /// < Whether the resizeable right side is hovered.
bool hover_top = false; /// < Whether the resizeable top side is hovered.
bool hover_down = false; /// < Whether the resizeable down side is hovered.
Element inner; ///< The element wrapped inside this window.
const std::string& title; ///< The title of the window.
bool active = false; ///< Whether the window is the active one.
bool drag = false; ///< Whether the window is being dragged.
bool resize = false; ///< Whether the window is being resized.
bool hover_left = false; ///< Whether the resizeable left side is hovered.
bool hover_right = false; ///< Whether the resizeable right side is hovered.
bool hover_top = false; ///< Whether the resizeable top side is hovered.
bool hover_down = false; ///< Whether the resizeable down side is hovered.
};

// @brief Option for the `Window` component.
// @ingroup component
struct WindowOptions {
Component inner; /// < The component wrapped by this window.
ConstStringRef title = ""; /// < The title displayed by this window.

Ref<int> left = 0; /// < The left side position of the window.
Ref<int> top = 0; /// < The top side position of the window.
Ref<int> width = 20; /// < The width of the window.
Ref<int> height = 10; /// < The height of the window.

Ref<bool> resize_left = true; /// < Can the left side be resized?
Ref<bool> resize_right = true; /// < Can the right side be resized?
Ref<bool> resize_top = true; /// < Can the top side be resized?
Ref<bool> resize_down = true; /// < Can the down side be resized?
Component inner; ///< The component wrapped by this window.
ConstStringRef title = ""; ///< The title displayed by this window.

Ref<int> left = 0; ///< The left side position of the window.
Ref<int> top = 0; ///< The top side position of the window.
Ref<int> width = 20; ///< The width of the window.
Ref<int> height = 10; ///< The height of the window.

Ref<bool> resize_left = true; ///< Can the left side be resized?
Ref<bool> resize_right = true; ///< Can the right side be resized?
Ref<bool> resize_top = true; ///< Can the top side be resized?
Ref<bool> resize_down = true; ///< Can the down side be resized?

/// An optional function to customize how the window looks like:
std::function<Element(const WindowRenderState&)> render;
Expand Down

0 comments on commit f499d34

Please sign in to comment.