mirror of
https://github.com/ankitects/anki.git
synced 2025-09-24 08:46:37 -04:00
Place sidebar tools right of search bar
This commit is contained in:
parent
f5981e94bf
commit
2c25645975
2 changed files with 8 additions and 7 deletions
|
@ -946,14 +946,14 @@ QTableView {{ gridline-color: {grid} }}
|
|||
self.form.actionSidebarFilter.triggered,
|
||||
self.focusSidebarSearchBar,
|
||||
)
|
||||
l = QVBoxLayout()
|
||||
l.addWidget(toolbar)
|
||||
l.addWidget(searchBar)
|
||||
l.addWidget(self.sidebar)
|
||||
l.setContentsMargins(0, 0, 0, 0)
|
||||
l.setSpacing(0)
|
||||
grid = QGridLayout()
|
||||
grid.addWidget(searchBar, 0, 0)
|
||||
grid.addWidget(toolbar, 0, 1)
|
||||
grid.addWidget(self.sidebar, 1, 0, 1, 2)
|
||||
grid.setContentsMargins(0, 0, 0, 0)
|
||||
grid.setSpacing(0)
|
||||
w = QWidget()
|
||||
w.setLayout(l)
|
||||
w.setLayout(grid)
|
||||
dw.setWidget(w)
|
||||
self.sidebarDockWidget.setFloating(False)
|
||||
|
||||
|
|
|
@ -259,6 +259,7 @@ class SidebarToolbar(QToolBar):
|
|||
self._action_group = QActionGroup(self)
|
||||
qconnect(self._action_group.triggered, self._on_action_group_triggered)
|
||||
self._setup_tools()
|
||||
self.setIconSize(QSize(18, 18))
|
||||
|
||||
def _setup_tools(self) -> None:
|
||||
for row in self._tools:
|
||||
|
|
Loading…
Reference in a new issue