example: Add an example about using stylesheets

This commit is contained in:
Sergio Martins
2021-09-08 23:14:47 +01:00
parent 83c8c22736
commit b5c11ce199
2 changed files with 82 additions and 1 deletions

View File

@@ -10,6 +10,7 @@
*/
#include "MyFrameworkWidgetFactory.h"
#include "MyTitleBar_CSS.h"
#include <kddockwidgets/FrameworkWidgetFactory.h>
@@ -89,11 +90,13 @@ MySeparator::~MySeparator() = default;
KDDockWidgets::TitleBar * CustomWidgetFactory::createTitleBar(KDDockWidgets::Frame *frame) const
{
// Feel free to return MyTitleBar_CSS here instead, but just for education purposes!
return new MyTitleBar(frame);
}
KDDockWidgets::TitleBar * CustomWidgetFactory::createTitleBar(KDDockWidgets::FloatingWindow *fw) const
{
// Feel free to return MyTitleBar_CSS here instead, but just for education purposes!
return new MyTitleBar(fw);
}
@@ -101,4 +104,3 @@ Layouting::Separator * CustomWidgetFactory::createSeparator(Layouting::Widget *p
{
return new MySeparator(parent);
}