]> git.lyx.org Git - features.git/commitdiff
QWidget::setContentsMargins is supported in Qt5
authorJean-Marc Lasgouttes <lasgouttes@lyx.org>
Sun, 5 Mar 2023 20:37:01 +0000 (21:37 +0100)
committerJean-Marc Lasgouttes <lasgouttes@lyx.org>
Sun, 5 Mar 2023 20:37:01 +0000 (21:37 +0100)
src/frontends/qt/GuiCommandBuffer.cpp
src/frontends/qt/IconPalette.cpp

index ee68013e2f91aa4a546be8e302f5ca82904ce999..4f7a8b433a7c479398a3ba7e1fba6795a4bd4e34 100644 (file)
@@ -133,17 +133,9 @@ GuiCommandBuffer::GuiCommandBuffer(GuiView * view)
        layout->addWidget(upPB, 0);
        layout->addWidget(downPB, 0);
        layout->addWidget(edit_, 10);
-#if QT_VERSION < 0x060000
-       layout->setMargin(0);
-#else
        layout->setContentsMargins(0, 0, 0, 0);
-#endif
        top->addLayout(layout);
-#if QT_VERSION < 0x060000
-       top->setMargin(0);
-#else
        top->setContentsMargins(0, 0, 0, 0);
-#endif
        setFocusProxy(edit_);
 
        upPB->setEnabled(!history().empty());
index 45d774bf46609911fe1ba0e61b6bab5d68ee12c8..a3ed7b25007d4e781f6a1e3d53f61c0b9df650da 100644 (file)
@@ -103,11 +103,7 @@ IconPalette::IconPalette(QWidget * parent)
        : QWidget(parent, Qt::Popup), tornoff_(false)
 {
        QVBoxLayout * v = new QVBoxLayout(this);
-#if QT_VERSION < 0x060000
-       v->setMargin(0);
-#else
        v->setContentsMargins(0, 0, 0, 0);
-#endif
        v->setSpacing(0);
        layout_ = new QGridLayout;
        layout_->setSpacing(0);