mutterkey
KDE-first push-to-talk transcription tool for KDE Plasma
Loading...
Searching...
No Matches
ClipboardWriter Class Referencefinal

Copies transcription text to the clipboard. More...

#include <clipboardwriter.h>

Public Member Functions

 ClipboardWriter (QClipboard *clipboard, QObject *parent=nullptr)
 Creates a clipboard writer bound to the application's clipboard.
 
bool copy (const QString &text)
 Copies text to the best available clipboard backend.
 
QString backendName () const
 Reports the active backend name for diagnostics.
 

Detailed Description

Copies transcription text to the clipboard.

The writer prefers KDE's system clipboard integration when available and falls back to the standard Qt clipboard API otherwise.

Definition at line 36 of file clipboardwriter.h.

Constructor & Destructor Documentation

◆ ClipboardWriter()

ClipboardWriter::ClipboardWriter ( QClipboard *  clipboard,
QObject *  parent = nullptr 
)
explicit

Creates a clipboard writer bound to the application's clipboard.

Parameters
clipboardNon-owning pointer to the process clipboard instance.
parentOptional QObject parent.

Member Function Documentation

◆ backendName()

QString ClipboardWriter::backendName ( ) const

Reports the active backend name for diagnostics.

Returns
Human-readable backend identifier.

◆ copy()

bool ClipboardWriter::copy ( const QString &  text)

Copies text to the best available clipboard backend.

Parameters
textText to copy.
Returns
true when a backend accepted the copy request.

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