diff --git a/EGUI/build-lab1-Desktop_Qt_6_2_4_GCC_64bit-Debug/blogentry.o b/EGUI/build-lab1-Desktop_Qt_6_2_4_GCC_64bit-Debug/blogentry.o index 2d83ceec..30ed380a 100644 Binary files a/EGUI/build-lab1-Desktop_Qt_6_2_4_GCC_64bit-Debug/blogentry.o and b/EGUI/build-lab1-Desktop_Qt_6_2_4_GCC_64bit-Debug/blogentry.o differ diff --git a/EGUI/build-lab1-Desktop_Qt_6_2_4_GCC_64bit-Debug/blogsview.o b/EGUI/build-lab1-Desktop_Qt_6_2_4_GCC_64bit-Debug/blogsview.o index 377743af..397662b2 100644 Binary files a/EGUI/build-lab1-Desktop_Qt_6_2_4_GCC_64bit-Debug/blogsview.o and b/EGUI/build-lab1-Desktop_Qt_6_2_4_GCC_64bit-Debug/blogsview.o differ diff --git a/EGUI/build-lab1-Desktop_Qt_6_2_4_GCC_64bit-Debug/lab1 b/EGUI/build-lab1-Desktop_Qt_6_2_4_GCC_64bit-Debug/lab1 index b7e4253a..f8926c38 100755 Binary files a/EGUI/build-lab1-Desktop_Qt_6_2_4_GCC_64bit-Debug/lab1 and b/EGUI/build-lab1-Desktop_Qt_6_2_4_GCC_64bit-Debug/lab1 differ diff --git a/EGUI/build-lab1-Desktop_Qt_6_2_4_GCC_64bit-Debug/ui_blogsview.h b/EGUI/build-lab1-Desktop_Qt_6_2_4_GCC_64bit-Debug/ui_blogsview.h index 9d6d8790..97e8979c 100644 --- a/EGUI/build-lab1-Desktop_Qt_6_2_4_GCC_64bit-Debug/ui_blogsview.h +++ b/EGUI/build-lab1-Desktop_Qt_6_2_4_GCC_64bit-Debug/ui_blogsview.h @@ -12,10 +12,12 @@ #include #include #include +#include #include #include #include #include +#include #include QT_BEGIN_NAMESPACE @@ -27,6 +29,8 @@ public: QAction *actionDelete_blog_entry; QAction *actionEdit_blog_entry; QWidget *centralwidget; + QGridLayout *gridLayout; + QVBoxLayout *blogsLayout; QMenuBar *menubar; QMenu *menuManageBlogEntires; QStatusBar *statusbar; @@ -44,6 +48,13 @@ public: actionEdit_blog_entry->setObjectName(QString::fromUtf8("actionEdit_blog_entry")); centralwidget = new QWidget(blogsView); centralwidget->setObjectName(QString::fromUtf8("centralwidget")); + gridLayout = new QGridLayout(centralwidget); + gridLayout->setObjectName(QString::fromUtf8("gridLayout")); + blogsLayout = new QVBoxLayout(); + blogsLayout->setObjectName(QString::fromUtf8("blogsLayout")); + + gridLayout->addLayout(blogsLayout, 0, 0, 1, 1); + blogsView->setCentralWidget(centralwidget); menubar = new QMenuBar(blogsView); menubar->setObjectName(QString::fromUtf8("menubar")); diff --git a/EGUI/lab1/blogentry.cpp b/EGUI/lab1/blogentry.cpp index 3e6d3163..5f733903 100644 --- a/EGUI/lab1/blogentry.cpp +++ b/EGUI/lab1/blogentry.cpp @@ -1,11 +1,16 @@ #include "blogentry.h" #include "ui_blogentry.h" +#include blogEntry::blogEntry(QWidget *parent) : QWidget(parent), ui(new Ui::blogEntry) { ui->setupUi(this); + QString Time = QTime::currentTime().toString(); + QString Date = QDate::currentDate().toString(); + ui -> dateTime -> setText(Date + " " + Time); + qDebug() << Time; } blogEntry::~blogEntry() diff --git a/EGUI/lab1/blogsview.cpp b/EGUI/lab1/blogsview.cpp index 2261beb9..c6ae2950 100644 --- a/EGUI/lab1/blogsview.cpp +++ b/EGUI/lab1/blogsview.cpp @@ -18,8 +18,7 @@ blogsView::~blogsView() void blogsView::createNewBlogEntry() { blogEntry *e = new blogEntry(); - e -> show(); - + ui -> blogsLayout -> addWidget(e); } void blogsView::on_actionCreate_new_Blog_entry_triggered() diff --git a/EGUI/lab1/blogsview.ui b/EGUI/lab1/blogsview.ui index 660574f5..b86cd297 100644 --- a/EGUI/lab1/blogsview.ui +++ b/EGUI/lab1/blogsview.ui @@ -13,7 +13,13 @@ MainWindow - + + + + + + +