HikoGUI
A low latency retained GUI
Loading...
Searching...
No Matches
Public Member Functions
hi::v1::text_delegate Class Referenceabstract

#include <hikogui/widgets/text_delegate.hpp>

Inheritance diagram for hi::v1::text_delegate:
hi::v1::default_text_delegate< char const * > hi::v1::default_text_delegate< gstring > hi::v1::default_text_delegate< std::string > hi::v1::default_text_delegate< txt >

Public Member Functions

virtual void init (widget_intf const &sender) noexcept
 
virtual void deinit (widget_intf const &sender) noexcept
 
virtual gstring read (widget_intf const &sender) noexcept=0
 Read text as a string of graphemes.
 
virtual void write (widget_intf const &sender, gstring const &text) noexcept=0
 Write text from a string of graphemes.
 
template<forward_of< void()> Func>
callback< void()> subscribe (Func &&func, callback_flags flags=callback_flags::synchronous) noexcept
 Subscribe a callback for notifying the widget of a data change.
 

Detailed Description

A delegate that controls the state of a text_widget.

Member Function Documentation

◆ read()

virtual gstring hi::v1::text_delegate::read ( widget_intf const & sender)
pure virtualnoexcept

◆ subscribe()

template<forward_of< void()> Func>
callback< void()> hi::v1::text_delegate::subscribe ( Func && func,
callback_flags flags = callback_flags::synchronous )
inlinenoexcept

Subscribe a callback for notifying the widget of a data change.

◆ write()

virtual void hi::v1::text_delegate::write ( widget_intf const & sender,
gstring const & text )
pure virtualnoexcept

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