Пример #1
0
 def _layout_buttons_(self):
     box = QHBoxLayout()
     box.addWidget(self.delete_button)
     box.addStretch(20)
     box.addWidget(self.add_folder)
     box.addWidget(self.add_page)
     box.setContentsMargins(5, 5, 5, 5)
     self.buttons_bar.setLayout(box)
     self.buttons_bar.setSizePolicy(
         QSizePolicy(QSizePolicy.Expanding, QSizePolicy.Fixed))
     self.buttons_bar.setObjectName('buttons')
     self.buttons_bar.setStyleSheet(
         'QFrame#buttons{background:transparent; border-top:1px solid gray; '
         'border-left:1px solid gray; border-right:1px solid gray; '
         'border-top-left-radius:3px; border-top-right-radius:3px}')
Пример #2
0
    def _layout_buttons_(self):
        box = QHBoxLayout()
        box.setContentsMargins(5, 5, 5, 5)
        box.addWidget(self.add_files_button)
        box.addWidget(self.screenshot_button)
        box.addWidget(self.edit_image)
        box.addWidget(self.delete_button)
        box.addStretch(20)
        box.addWidget(self.insert_button)
        self.buttons_bar.setSizePolicy(
            QSizePolicy(QSizePolicy.Expanding, QSizePolicy.Fixed))
        self.buttons_bar.setLayout(box)

        # self.buttons_bar.setObjectName('buttons_bar')
        self.buttons_bar.setObjectName('buttons')
        self.buttons_bar.setStyleSheet("""
        QFrame#buttons{
            border-top:1px solid gray;
            border-left:1px solid gray; border-right:1px solid gray;
            border-top-left-radius:3px; border-top-right-radius:3px
        }
        """)