Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Library layout clean ups #883

Merged
merged 10 commits into from
Feb 13, 2016
26 changes: 25 additions & 1 deletion res/skins/Deere/style.qss
Original file line number Diff line number Diff line change
Expand Up @@ -338,7 +338,7 @@ WLibrary QSpinBox:editable {
WLibrary QLabel, WLibrary QRadioButton {
/* same as QTreeview */
color: #d2d2d2;
margin: 0px 10px 0px 0px;
margin: 9px 10px 6px 0px;
}

WLibrary QRadioButton::indicator {
Expand All @@ -347,6 +347,11 @@ WLibrary QRadioButton::indicator {
height: 18px;
}

/* Additional space for the first QRadionButton in the row */
WLibrary QRadioButton#radioButtonRecentlyAdded {
margin: 9px 10px 6px 14px;
}

WLibrary QRadioButton::indicator:checked {
background: url(skin:/icon/ic_radio_button_on_18px.svg);
}
Expand All @@ -361,6 +366,7 @@ WLibrary QRadioButton::indicator:unchecked {
#DlgAutoDJ > QPushButton,
#DlgRecording > QPushButton,
#DlgAnalysis > QPushButton {
margin: 9px 3px 6px 3px;
padding: 4px;
color: #D2D2D2;
background-color: qlineargradient(x1: 0, y1: 1, x2: 0, y2: 0,
Expand All @@ -377,6 +383,7 @@ WLibrary QRadioButton::indicator:unchecked {
#DlgAnalysis > QPushButton:!enabled {
/* buttons in "disabled" (not click-able) state. They are nearly invisible
by default QT palette, so style accordingly */
margin: 9px 3px 6px 3px;
padding: 4px;
color: #808080; /* Default #A3A3A3 -90L HSL*/
background-color: qlineargradient(spread:pad,
Expand All @@ -394,6 +401,7 @@ WLibrary QRadioButton::indicator:unchecked {
#DlgAutoDJ > QPushButton:hover,
#DlgRecording > QPushButton:hover,
#DlgAnalysis > QPushButton:hover {
margin: 9px 3px 6px 3px;
padding: 4px;
color: #D2D2D2;
background-color: qlineargradient(x1: 0, y1: 1, x2: 0, y2: 0,
Expand All @@ -408,6 +416,7 @@ WLibrary QRadioButton::indicator:unchecked {
#DlgRecording > QPushButton:checked,
#DlgAnalysis > QPushButton:checked {
/* checkbuttons in active state */
margin: 9px 3px 6px 3px;
padding: 4px;
color: #FDFDFD;
background-color: qlineargradient(x1: 0, y1: 1, x2: 0, y2: 0,
Expand All @@ -422,6 +431,7 @@ WLibrary QRadioButton::indicator:unchecked {
#DlgRecording > QPushButton:checked:hover,
#DlgAnalysis > QPushButton:checked:hover {
/* checkbuttons hovered over in "active" state */
margin: 9px 3px 6px 3px;
padding: 4px;
color: #FDFDFD;
background-color: qlineargradient(x1: 0, y1: 1, x2: 0, y2: 0,
Expand All @@ -437,6 +447,7 @@ WLibrary QRadioButton::indicator:unchecked {
#DlgAutoDJ > QPushButton:pressed,
#DlgAnalysis > QPushButton:pressed {
/* pushbuttons in "down" state */
margin: 9px 3px 6px 3px;
padding: 4px;
color: #FDFDFD;
background-color: qlineargradient(x1: 0, y1: 1, x2: 0, y2: 0,
Expand All @@ -447,6 +458,19 @@ WLibrary QRadioButton::indicator:unchecked {
outline: none;
}

/* Additional space for the first and the last QPushButton in the row */
#DlgMissing > QPushButton#btnPurge,
#DlgHidden > QPushButton#btnUnhide,
#DlgAutoDJ > QPushButton#pushButtonAutoDJ,
#DlgRecording > QPushButton#pushButtonRecording,
#DlgAnalysis > QPushButton#pushButtonAnalyze {
margin: 9px 12px 6px 3px;
}

#DlgAutoDJ > QPushButton#pushButtonShuffle {
margin: 9px 3px 6px 12px;
}


/* Scroll bars */
QScrollBar:horizontal {
Expand Down
25 changes: 24 additions & 1 deletion res/skins/LateNight/style.qss
Original file line number Diff line number Diff line change
Expand Up @@ -1277,7 +1277,30 @@ QSplitter::handle:horizontal { width: 10px; background-color: #0e0e0e;}
QSplitter::handle:vertical { height: 10px; background-color: #0e0e0e;}

/* Extra declaration for QRadioButton otherwise it shows up with wrong colors in Linux with Gnome */
QLabel, QRadioButton { background: transparent; color: #cfb32c;}
QLabel, QRadioButton { background: transparent; color: #cfb32c; }

/* Additional space for QRadionButtons and QLabels */
WLibrary QRadioButton, WLibrary QLabel { margin: 9px 3px 6px 3px; }

/* Additional space for the first QRadionButton in the row */
WLibrary QRadioButton#radioButtonRecentlyAdded { margin: 9px 3px 6px 12px; }

/* Additional space for the QPushButtons */
#DlgMissing > QPushButton,
#DlgHidden > QPushButton,
#DlgAutoDJ > QPushButton,
#DlgRecording > QPushButton,
#DlgAnalysis > QPushButton { margin: 9px 3px 6px 3px; padding: 3px 8px; min-width: 65px; }

/* Additional space for the first QPushButton in the row */
#DlgMissing > QPushButton#btnPurge,
#DlgHidden > QPushButton#btnUnhide,
#DlgAutoDJ > QPushButton#pushButtonAutoDJ,
#DlgRecording > QPushButton#pushButtonRecording,
#DlgAnalysis > QPushButton#pushButtonAnalyze { margin: 9px 12px 6px 3px; }

/* Additional space for the last QPushButton in the row */
#DlgAutoDJ > QPushButton#pushButtonShuffle { margin: 9px 3px 6px 12px; }

/* Spacing between treeview and searchbar */
QTreeView { margin: 10px 0px 0px 0px; }
Expand Down
27 changes: 27 additions & 0 deletions res/skins/Shade/skin.xml
Original file line number Diff line number Diff line change
Expand Up @@ -460,6 +460,33 @@
background: transparent;
color: #C1C1C1;}

<!--Additional space for QRadionButtons and QLabels-->
WLibrary QRadioButton, WLibrary QLabel { margin: 9px 3px 6px 3px; }

<!--Additional space for the first QRadionButton in the row-->
WLibrary QRadioButton#radioButtonRecentlyAdded { margin: 9px 3px 6px 12px; }

<!--Additional space for the QPushButtons-->
#DlgMissing > QPushButton,
#DlgHidden > QPushButton,
#DlgAutoDJ > QPushButton,
#DlgRecording > QPushButton,
#DlgAnalysis > QPushButton {
margin: 9px 3px 6px 3px;
padding: 3px 8px;
min-width: 65px;
}

<!--Additional space for the first QPushButton in the row-->
#DlgMissing > QPushButton#btnPurge,
#DlgHidden > QPushButton#btnUnhide,
#DlgAutoDJ > QPushButton#pushButtonAutoDJ,
#DlgRecording > QPushButton#pushButtonRecording,
#DlgAnalysis > QPushButton#pushButtonAnalyze { margin: 9px 12px 6px 3px; }

<!--Additional space for the last QPushButton in the row-->
#DlgAutoDJ > QPushButton#pushButtonShuffle { margin: 9px 3px 6px 12px; }

<!--Spacing between treeview and searchbar-->
QTreeView { margin: 0px 0px 0px 5px; }

Expand Down
7 changes: 5 additions & 2 deletions src/library/autodj/dlgautodj.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -221,7 +221,10 @@ void DlgAutoDJ::updateSelectionInfo() {
if (!indices.isEmpty()) {
label.append(Time::formatSeconds(duration));
label.append(QString(" (%1)").arg(indices.size()));
labelSelectionInfo->setText(label);
labelSelectionInfo->setEnabled(true);
} else {
labelSelectionInfo->setText("");
labelSelectionInfo->setEnabled(false);
}

labelSelectionInfo->setText(label);
}
26 changes: 13 additions & 13 deletions src/library/autodj/dlgautodj.ui
Original file line number Diff line number Diff line change
Expand Up @@ -13,13 +13,16 @@
<property name="windowTitle">
<string>Auto DJ</string>
</property>
<property name="styleSheet">
<string notr="true"/>
</property>
<layout class="QVBoxLayout" name="verticalLayout">
<property name="spacing">
<number>0</number>
</property>
<property name="leftMargin">
<number>0</number>
</property>
<property name="topMargin">
<number>0</number>
</property>
<property name="rightMargin">
<number>0</number>
</property>
Expand All @@ -28,14 +31,17 @@
</property>
<item>
<layout class="QHBoxLayout" name="horizontalLayout">
<property name="sizeConstraint">
<enum>QLayout::SetMinimumSize</enum>
<property name="spacing">
<number>0</number>
</property>
<property name="leftMargin">
<number>12</number>
<number>0</number>
</property>
<property name="topMargin">
<number>0</number>
</property>
<property name="rightMargin">
<number>12</number>
<number>0</number>
</property>
<property name="bottomMargin">
<number>0</number>
Expand Down Expand Up @@ -155,12 +161,6 @@
</item>
<item>
<widget class="QTableView" name="m_pTrackTablePlaceholder">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="Expanding">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="showGrid">
<bool>true</bool>
</property>
Expand Down
2 changes: 2 additions & 0 deletions src/library/dlganalysis.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -134,9 +134,11 @@ void DlgAnalysis::analysisActive(bool bActive) {
if (bActive) {
pushButtonAnalyze->setEnabled(true);
pushButtonAnalyze->setText(tr("Stop Analysis"));
labelProgress->setEnabled(true);
} else {
pushButtonAnalyze->setText(tr("Analyze"));
labelProgress->setText("");
labelProgress->setEnabled(false);
}
}

Expand Down
53 changes: 21 additions & 32 deletions src/library/dlganalysis.ui
Original file line number Diff line number Diff line change
Expand Up @@ -14,9 +14,15 @@
<string>Analyze</string>
</property>
<layout class="QVBoxLayout" name="verticalLayout">
<property name="spacing">
<number>0</number>
</property>
<property name="leftMargin">
<number>0</number>
</property>
<property name="topMargin">
<number>0</number>
</property>
<property name="rightMargin">
<number>0</number>
</property>
Expand All @@ -25,22 +31,21 @@
</property>
<item>
<layout class="QHBoxLayout" name="horizontalLayout">
<item>
<spacer name="horizontalSpacer_3">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeType">
<enum>QSizePolicy::Fixed</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>12</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
<property name="spacing">
<number>0</number>
</property>
<property name="leftMargin">
<number>0</number>
</property>
<property name="topMargin">
<number>0</number>
</property>
<property name="rightMargin">
<number>0</number>
</property>
<property name="bottomMargin">
<number>0</number>
</property>
<item>
<widget class="QRadioButton" name="radioButtonRecentlyAdded">
<property name="toolTip">
Expand Down Expand Up @@ -101,22 +106,6 @@
</property>
</widget>
</item>
<item>
<spacer name="horizontalSpacer_2">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeType">
<enum>QSizePolicy::Fixed</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>12</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
</layout>
</item>
<item>
Expand Down
26 changes: 13 additions & 13 deletions src/library/dlghidden.ui
Original file line number Diff line number Diff line change
Expand Up @@ -13,13 +13,16 @@
<property name="windowTitle">
<string>Hidden Tracks</string>
</property>
<property name="styleSheet">
<string notr="true"/>
</property>
<layout class="QVBoxLayout" name="verticalLayout">
<property name="spacing">
<number>0</number>
</property>
<property name="leftMargin">
<number>0</number>
</property>
<property name="topMargin">
<number>0</number>
</property>
<property name="rightMargin">
<number>0</number>
</property>
Expand All @@ -28,14 +31,17 @@
</property>
<item>
<layout class="QHBoxLayout" name="horizontalLayout">
<property name="sizeConstraint">
<enum>QLayout::SetMinimumSize</enum>
<property name="spacing">
<number>0</number>
</property>
<property name="leftMargin">
<number>12</number>
<number>0</number>
</property>
<property name="topMargin">
<number>0</number>
</property>
<property name="rightMargin">
<number>12</number>
<number>0</number>
</property>
<property name="bottomMargin">
<number>0</number>
Expand Down Expand Up @@ -96,12 +102,6 @@
</item>
<item>
<widget class="QTableView" name="m_pTrackTablePlaceholder">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="Expanding">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="showGrid">
<bool>true</bool>
</property>
Expand Down
Loading