mirror of
https://github.com/qelectrotech/qelectrotech-source-mirror.git
synced 2025-12-21 16:50:53 +01:00
Rewrite terminaleditor with ui file.
Write terminal editor with ui file. The terminalData::type of a terminal can be edited with the terminal editor.
This commit is contained in:
@@ -72,7 +72,7 @@ void PartTerminal::paint(
|
||||
const QStyleOptionGraphicsItem *options,
|
||||
QWidget *widget)
|
||||
{
|
||||
Q_UNUSED(widget);
|
||||
Q_UNUSED(widget)
|
||||
painter -> save();
|
||||
|
||||
// annulation des renderhints
|
||||
@@ -161,6 +161,20 @@ void PartTerminal::setName(QString& name) {
|
||||
emit nameChanged();
|
||||
}
|
||||
|
||||
/**
|
||||
* @brief PartTerminal::setTerminalType
|
||||
* Set the type of terminal to 'type'
|
||||
* @param type
|
||||
*/
|
||||
void PartTerminal::setTerminalType(TerminalData::Type type)
|
||||
{
|
||||
if (d->m_type == type) {
|
||||
return;
|
||||
}
|
||||
d->m_type = type;
|
||||
emit terminalTypeChanged();
|
||||
}
|
||||
|
||||
void PartTerminal::setNewUuid()
|
||||
{
|
||||
d -> m_uuid = QUuid::createUuid();
|
||||
|
||||
Reference in New Issue
Block a user