QtPass 2.0.0
Developer documentation
Loading...
Searching...
No Matches
SecretPlainTextEdit Class Reference

A QPlainTextEdit for decrypted entry text being edited: whatever is copied or cut out of it is marked as a secret and reported for autoclear. More...

#include <secretplaintextedit.h>

Inheritance diagram for SecretPlainTextEdit:
Collaboration diagram for SecretPlainTextEdit:

Signals

void copied (const QString &text)
 Selected text was copied or cut out of the editor.

Public Member Functions

 SecretPlainTextEdit (QWidget *parent=nullptr)
 Constructs the editor.

Protected Member Functions

auto createMimeDataFromSelection () const -> QMimeData *override
 The selection as secret-marked plain text.

Detailed Description

A QPlainTextEdit for decrypted entry text being edited: whatever is copied or cut out of it is marked as a secret and reported for autoclear.

As in SecretTextBrowser, every way text leaves the editor (Ctrl+C, Ctrl+X, the context menu, a drag, and the X11 primary selection a mouse selection fills) goes through createMimeDataFromSelection().

Definition at line 23 of file secretplaintextedit.h.

Constructor & Destructor Documentation

◆ SecretPlainTextEdit()

SecretPlainTextEdit::SecretPlainTextEdit ( QWidget * parent = nullptr)
explicit

Constructs the editor.

Parameters
parentOwner.

Definition at line 13 of file secretplaintextedit.cpp.

Here is the caller graph for this function:

Member Function Documentation

◆ copied

void SecretPlainTextEdit::copied ( const QString & text)
signal

Selected text was copied or cut out of the editor.

Parameters
textThe text, as put on the clipboard, in the selection or in the drag.
Here is the call graph for this function:
Here is the caller graph for this function:

◆ createMimeDataFromSelection()

auto SecretPlainTextEdit::createMimeDataFromSelection ( ) const -> QMimeData *
nodiscardoverrideprotected

The selection as secret-marked plain text.

Returns
MIME data from buildClipboardMimeData(); the caller owns it.

Definition at line 16 of file secretplaintextedit.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

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