Heaven v0.1.0-1
C++ global-menu library for Wayland sessions
Loading...
Searching...
No Matches
Public Member Functions
HNWithTitle Class Reference

Mixin interface for client objects that expose a textual title. More...

#include "HNWithTitle.h"

Inheritance diagram for HNWithTitle:
Inheritance graph
[legend]

Public Member Functions

const std::string & title () const noexcept
 Returns the current title.
 
void setTitle (const std::string &title) noexcept
 Updates the title and notifies the bar.
 
virtual ~HNWithTitle () noexcept=default
 Virtual destructor (makes the mixin polymorphic for safe cross-casts).
 

Detailed Description

Mixin interface for client objects that expose a textual title.

Member Function Documentation

◆ setTitle()

void setTitle ( const std::string &  title)
noexcept

Updates the title and notifies the bar.

If the new title equals the current one, nothing is sent. Otherwise the change is queued and delivered to the bar on the next commit().

Parameters
titleNew title.

◆ title()

const std::string & title ( ) const
inlinenoexcept

Returns the current title.

Returns
Const reference to the title string (may be empty).

The documentation for this class was generated from the following file: