mirror of
https://github.com/YACReader/yacreader
synced 2025-07-21 06:24:39 -04:00
nuevo estilo para windows y linux de la sidebar
This commit is contained in:
@ -104,5 +104,9 @@
|
||||
<file>../images/libraryIcon.png</file>
|
||||
<file>../images/libraryIconSelected.png</file>
|
||||
<file>../images/libraryOptions.png</file>
|
||||
<file>../images/branch-open.png</file>
|
||||
<file>../images/branch-closed.png</file>
|
||||
<file>../images/expanded_branch_selected.png</file>
|
||||
<file>../images/collapsed_branch_selected.png</file>
|
||||
</qresource>
|
||||
</RCC>
|
||||
|
@ -190,6 +190,31 @@ void LibraryWindow::doLayout()
|
||||
"QTreeView::branch:selected {background-color:qlineargradient(x1: 0, y1: 0, x2: 0, y2: 1, stop: 0 #6BAFE4, stop: 1 #3984D2); border-top: 2px solid qlineargradient(x1: 0, y1: 0, x2: 0, y2: 1, stop: 0 #5EA3DF, stop: 1 #73B8EA); border-left:none;border-right:none;border-bottom:1px solid #3577C2;}"
|
||||
"QTreeView::branch:open:selected:has-children {image: url(':/images/expanded_branch_osx.png');}"
|
||||
"QTreeView::branch:closed:selected:has-children {image: url(':/images/collapsed_branch_osx.png');}");
|
||||
#else
|
||||
foldersView->setStyleSheet("QTreeView {background-color:transparent; border: none; color:#DDDFDF; outline:0;}"
|
||||
"QTreeView::item:selected {background-color: #2E2E2E; color:white; font:bold;}"
|
||||
"QTreeView::item:hover {background-color:#2E2E2E; color:white; font:bold;}"
|
||||
"QTreeView::branch:selected {background-color:#2E2E2E;}"
|
||||
|
||||
|
||||
"QScrollBar:vertical { border: none; background: #222222; width: 7px; margin: 0 3px 0 0; }"
|
||||
"QScrollBar::handle:vertical { background: #DDDDDD; width: 7px; min-height: 20px; }"
|
||||
"QScrollBar::add-line:vertical { border: none; background: #222222; height: 10px; subcontrol-position: bottom; subcontrol-origin: margin; margin: 0 3px 0 0;}"
|
||||
|
||||
"QScrollBar::sub-line:vertical { border: none; background: #222222; height: 10px; subcontrol-position: top; subcontrol-origin: margin; margin: 0 3px 0 0;}"
|
||||
"QScrollBar::up-arrow:vertical {border:none;width: 9px;height: 6px;background: url(':/images/folders_view/line-up.png') center top no-repeat;}"
|
||||
"QScrollBar::down-arrow:vertical {border:none;width: 9px;height: 6px;background: url(':/images/folders_view/line-down.png') center top no-repeat;}"
|
||||
|
||||
"QScrollBar::add-page:vertical, QScrollBar::sub-page:vertical {background: none; }"
|
||||
|
||||
"QTreeView::branch:has-children:!has-siblings:closed,QTreeView::branch:closed:has-children:has-siblings {border-image: none;image: url(':/images/branch-closed.png');}"
|
||||
"QTreeView::branch:has-children:selected:!has-siblings:closed,QTreeView::branch:closed:selected:has-children:has-siblings {border-image: none;image: url(':/images/collapsed_branch_selected.png');}"
|
||||
|
||||
"QTreeView::branch:open:has-children:!has-siblings,QTreeView::branch:open:has-children:has-siblings {border-image: none;image: url(':/images/branch-open.png');}"
|
||||
"QTreeView::branch:open:has-children:selected:!has-siblings,QTreeView::branch:open:has-children:selected:has-siblings {border-image: none;image: url(':/images/expanded_branch_selected.png');}"
|
||||
|
||||
|
||||
);
|
||||
#endif
|
||||
sideBar = new YACReaderSideBar;
|
||||
QVBoxLayout * l = new QVBoxLayout;
|
||||
@ -197,11 +222,8 @@ void LibraryWindow::doLayout()
|
||||
selectedLibrary->setContextMenuPolicy(Qt::ActionsContextMenu);
|
||||
selectedLibrary->setAttribute(Qt::WA_MacShowFocusRect,false);
|
||||
selectedLibrary->setFocusPolicy(Qt::NoFocus);
|
||||
#ifdef Q_OS_MAC
|
||||
|
||||
l->setContentsMargins(0,0,0,0);
|
||||
#else
|
||||
l->setContentsMargins(sHorizontal->handleWidth(),0,0,0);
|
||||
#endif
|
||||
|
||||
YACReaderTitledToolBar * librariesTitle = new YACReaderTitledToolBar(tr("LIBRARIES"));
|
||||
|
||||
@ -228,7 +250,7 @@ void LibraryWindow::doLayout()
|
||||
searchLayout->addLayout(filter);
|
||||
|
||||
l->addLayout(searchLayout);
|
||||
l->setSpacing(1);
|
||||
l->setSpacing(0);
|
||||
sideBar->setLayout(l);
|
||||
|
||||
//FINAL LAYOUT-------------------------------------------------------------
|
||||
|
Reference in New Issue
Block a user