Elaztek Developer Hub
Blamite Game Engine - Keystone  00386.06.16.23.0646.blamite
A library that enables the use of Qt in Blamite's editing tools.
alert_widget.h
Go to the documentation of this file.
1 #pragma once
2 
3 #include <QWidget>
4 #include <qgraphicsscene.h>
5 #include <qpixmap.h>
6 #include <qgraphicsitem.h>
7 
9 #include "ui_alert_widget.h"
10 
11 class alert_widget : public QWidget
12 {
13  Q_OBJECT
14 
15 private:
16  Ui::alert_widget ui;
17 
19  QGraphicsScene* scene = nullptr;
20  QGraphicsPixmapItem* pixmap_item = nullptr;
21 
22  void RefreshIcon();
23 
24 public:
25  alert_widget(KeystoneMessageBoxType _type, std::string message, QWidget *parent = Q_NULLPTR);
26  ~alert_widget();
27 
31  void resizeEvent(QResizeEvent* event);
32 
36  void showEvent(QShowEvent* event);
37 };
themes.h
KeystoneMessageBoxType::Error
@ Error
Dialog icon will be a red circle with an X.
alert_widget::showEvent
void showEvent(QShowEvent *event)
Called when the dialog is fully shown.
Definition: alert_widget.cpp:64
KeystoneMessageBoxType
KeystoneMessageBoxType
Enumerator containing different possible message box types, primarily used to control the icon that i...
Definition: qt_message_box.h:10
alert_widget.h
KeystoneMessageBoxType::Warning
@ Warning
Dialog icon will be a yellow triangle with an exclamation mark.
BlamKeystone::Themes::GetActiveTheme
KEYSTONE BlamEditorTheme * GetActiveTheme()
Retrieves the currently selected theme.
Definition: themes.cpp:335
qt_message_box.h
alert_widget
Definition: alert_widget.h:11
alert_widget::~alert_widget
~alert_widget()
Definition: alert_widget.cpp:27
KeystoneMessageBoxType::None
@ None
The dialog will not contain an icon.
alert_widget::alert_widget
alert_widget(KeystoneMessageBoxType _type, std::string message, QWidget *parent=Q_NULLPTR)
Definition: alert_widget.cpp:5
alert_widget::resizeEvent
void resizeEvent(QResizeEvent *event)
Called when the dialog is resized.
Definition: alert_widget.cpp:59