:right-sidebar: True ExpanderRow =================================================================== .. currentmodule:: gi.repository.Adw .. class:: ExpanderRow(**properties: ~typing.Any) :no-contents-entry: Superclasses: :class:`~gi.repository.Adw.PreferencesRow`, :class:`~gi.repository.Gtk.ListBoxRow`, :class:`~gi.repository.Gtk.Widget`, :class:`~gi.repository.GObject.InitiallyUnowned`, :class:`~gi.repository.GObject.Object` Implemented Interfaces: :class:`~gi.repository.Gtk.Accessible`, :class:`~gi.repository.Gtk.Actionable`, :class:`~gi.repository.Gtk.Buildable`, :class:`~gi.repository.Gtk.ConstraintTarget` :Constructors: :: ExpanderRow(**properties) new() -> Gtk.Widget Constructors ------------ .. rst-class:: interim-class .. class:: ExpanderRow :no-index: .. classmethod:: new() -> ~gi.repository.Gtk.Widget Creates a new ``AdwExpanderRow``. Methods ------- .. rst-class:: interim-class .. class:: ExpanderRow :no-index: .. method:: add_action(widget: ~gi.repository.Gtk.Widget) -> None Adds an action widget to ``self``. .. deprecated:: 1.4 Use :obj:`~gi.repository.ExpanderRow.add_suffix` to add a suffix. :param widget: a widget .. method:: add_prefix(widget: ~gi.repository.Gtk.Widget) -> None Adds a prefix widget to ``self``. :param widget: a widget .. method:: add_row(child: ~gi.repository.Gtk.Widget) -> None Adds a widget to ``self``. The widget will appear in the expanding list below ``self``. :param child: a widget .. method:: add_suffix(widget: ~gi.repository.Gtk.Widget) -> None Adds an suffix widget to ``self``. .. versionadded:: 1.4 :param widget: a widget .. method:: get_enable_expansion() -> bool Gets whether the expansion of ``self`` is enabled. .. method:: get_expanded() -> bool Gets whether ``self`` is expanded. .. method:: get_icon_name() -> str | None Gets the icon name for ``self``. .. deprecated:: 1.3 Use :obj:`~gi.repository.ExpanderRow.add_prefix` to add an icon. .. method:: get_show_enable_switch() -> bool Gets whether the switch enabling the expansion of ``self`` is visible. .. method:: get_subtitle() -> str Gets the subtitle for ``self``. .. method:: get_subtitle_lines() -> int Gets the number of lines at the end of which the subtitle label will be ellipsized. .. versionadded:: 1.3 .. method:: get_title_lines() -> int Gets the number of lines at the end of which the title label will be ellipsized. .. versionadded:: 1.3 .. method:: remove(child: ~gi.repository.Gtk.Widget) -> None Removes a child from ``self``. :param child: the child to be removed .. method:: set_enable_expansion(enable_expansion: bool) -> None Sets whether the expansion of ``self`` is enabled. :param enable_expansion: whether to enable the expansion .. method:: set_expanded(expanded: bool) -> None Sets whether ``self`` is expanded. :param expanded: whether to expand the row .. method:: set_icon_name(icon_name: str | None = None) -> None Sets the icon name for ``self``. .. deprecated:: 1.3 Use :obj:`~gi.repository.ExpanderRow.add_prefix` to add an icon. :param icon_name: the icon name .. method:: set_show_enable_switch(show_enable_switch: bool) -> None Sets whether the switch enabling the expansion of ``self`` is visible. :param show_enable_switch: whether to show the switch enabling the expansion .. method:: set_subtitle(subtitle: str) -> None Sets the subtitle for ``self``. The subtitle is interpreted as Pango markup unless :obj:`~gi.repository.Adw.PreferencesRow.props.use_markup` is set to ``FALSE``. :param subtitle: the subtitle .. method:: set_subtitle_lines(subtitle_lines: int) -> None Sets the number of lines at the end of which the subtitle label will be ellipsized. If the value is 0, the number of lines won't be limited. .. versionadded:: 1.3 :param subtitle_lines: the number of lines at the end of which the subtitle label will be ellipsized .. method:: set_title_lines(title_lines: int) -> None Sets the number of lines at the end of which the title label will be ellipsized. If the value is 0, the number of lines won't be limited. .. versionadded:: 1.3 :param title_lines: the number of lines at the end of which the title label will be ellipsized Properties ---------- .. rst-class:: interim-class .. class:: ExpanderRow :no-index: .. attribute:: props.enable_expansion :type: bool Whether expansion is enabled. .. attribute:: props.expanded :type: bool Whether the row is expanded. .. attribute:: props.icon_name :type: str The icon name for this row. .. deprecated:: 1.3 Use :obj:`~gi.repository.ExpanderRow.add_prefix` to add an icon. .. attribute:: props.show_enable_switch :type: bool Whether the switch enabling the expansion is visible. .. attribute:: props.subtitle :type: str The subtitle for this row. The subtitle is interpreted as Pango markup unless :obj:`~gi.repository.Adw.PreferencesRow.props.use_markup` is set to ``FALSE``. .. attribute:: props.subtitle_lines :type: int The number of lines at the end of which the subtitle label will be ellipsized. If the value is 0, the number of lines won't be limited. .. versionadded:: 1.3 .. attribute:: props.title_lines :type: int The number of lines at the end of which the title label will be ellipsized. If the value is 0, the number of lines won't be limited. .. versionadded:: 1.3 Fields ------ .. rst-class:: interim-class .. class:: ExpanderRow :no-index: .. attribute:: parent_instance