DUNE-DAQ
DUNE Trigger and Data Acquisition software
Loading...
Searching...
No Matches
dbse::SchemaNoteEditor Class Reference

#include <SchemaNoteEditor.hpp>

Inheritance diagram for dbse::SchemaNoteEditor:
[legend]
Collaboration diagram for dbse::SchemaNoteEditor:
[legend]

Signals

void note_accepted (SchemaGraphicNote *note)
void cancelled (SchemaGraphicNote *note)

Public Member Functions

 SchemaNoteEditor (SchemaGraphicNote *note, QWidget *parent=0)
 ~SchemaNoteEditor ()

Private Slots

void update_text ()
void cancel_note ()

Private Attributes

SchemaGraphicNote * m_note
Ui::SchemaNoteEditor * m_ui

Detailed Description

Definition at line 12 of file SchemaNoteEditor.hpp.

Constructor & Destructor Documentation

◆ SchemaNoteEditor()

dbse::SchemaNoteEditor::SchemaNoteEditor ( SchemaGraphicNote * note,
QWidget * parent = 0 )

Definition at line 9 of file SchemaNoteEditor.cpp.

10 : QDialog(parent)
11 , m_note(note)
12 , m_ui(new Ui::SchemaNoteEditor)
13{
14
15 m_ui->setupUi(this);
16 m_ui->text->setPlainText(m_note->text());
17 m_ui->text->setFocus();
18 connect(m_ui->buttons, SIGNAL(accepted()), this, SLOT(update_text()));
19 connect(m_ui->buttons, SIGNAL(rejected()), this, SLOT(cancel_note()));
20}
Ui::SchemaNoteEditor * m_ui
SchemaGraphicNote * m_note

◆ ~SchemaNoteEditor()

dbse::SchemaNoteEditor::~SchemaNoteEditor ( )

Definition at line 22 of file SchemaNoteEditor.cpp.

23{
24 delete m_ui;
25}

Member Function Documentation

◆ cancel_note

void dbse::SchemaNoteEditor::cancel_note ( )
privateslot

Definition at line 28 of file SchemaNoteEditor.cpp.

29{
30 emit cancelled(m_note);
31}
void cancelled(SchemaGraphicNote *note)

◆ cancelled

void dbse::SchemaNoteEditor::cancelled ( SchemaGraphicNote * note)
signal

◆ note_accepted

void dbse::SchemaNoteEditor::note_accepted ( SchemaGraphicNote * note)
signal

◆ update_text

void dbse::SchemaNoteEditor::update_text ( )
privateslot

Definition at line 34 of file SchemaNoteEditor.cpp.

35{
37 m_note->update_note(m_ui->text->toPlainText());
38}
void update_note(QString text)
void note_accepted(SchemaGraphicNote *note)

Member Data Documentation

◆ m_note

SchemaGraphicNote* dbse::SchemaNoteEditor::m_note
private

Definition at line 23 of file SchemaNoteEditor.hpp.

◆ m_ui

Ui::SchemaNoteEditor* dbse::SchemaNoteEditor::m_ui
private

Definition at line 24 of file SchemaNoteEditor.hpp.


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