10#ifndef COLLAPSIBLE_SECTION_H
11#define COLLAPSIBLE_SECTION_H
41 QWidget *parent =
nullptr);
103 void onToggle(
bool checked);
106 QToolButton *toggleButton;
108 QHBoxLayout *headerLayout_ =
nullptr;
111 QWidget *headerContainer_ =
nullptr;
112 QWidget *contentArea;
113 QVBoxLayout *mainLayout;
115 QWidget *headerTrailingWidget_ =
nullptr;
A collapsible section widget for use in a QSplitter.
Definition collapsible_section.h:31
void toggled(bool expanded)
Emitted when the section is toggled.
void setHeaderTrailingWidget(QWidget *widget)
Set an optional widget in the header row after the horizontal rule (order: title, rule,...
Definition collapsible_section.cpp:110
void setContentWidget(QWidget *contentWidget)
Set the content widget for this section.
Definition collapsible_section.cpp:90
void setExpanded(bool expanded)
Set the expanded state of the section.
Definition collapsible_section.cpp:130
void setTitle(const QString &title)
Set the title text.
Definition collapsible_section.cpp:141
int headerHeight() const
Get the header height (for splitter sizing when collapsed).
Definition collapsible_section.cpp:146
int titleButtonHeight() const
Height of the title / toggle control (single header line).
Definition collapsible_section.cpp:153
bool isExpanded() const
Check if the section is currently expanded.
Definition collapsible_section.cpp:136
QFont titleButtonFont() const
Font used for the section title (bold application font).
Definition collapsible_section.cpp:158