diff --git a/src/burner/qt/aboutdialog.cpp b/src/burner/qt/aboutdialog.cpp index 03cb19647..838c52796 100644 --- a/src/burner/qt/aboutdialog.cpp +++ b/src/burner/qt/aboutdialog.cpp @@ -14,7 +14,7 @@ AboutDialog::AboutDialog(QWidget *parent) : layout()->setContentsMargins(0, 0, 0, 0); layout()->setSizeConstraint(QLayout::SetFixedSize); - ui->teLicense->setText(util::loadText(tr(":/resource/license.txt"))); + ui->teLicense->setText(util::loadText(tr(":/license.txt"))); ui->lblVersion->setText(QString(" FBAlpha %1.%2.%3.%4") .arg(VER_MAJOR) diff --git a/src/burner/qt/aboutdialog.ui b/src/burner/qt/aboutdialog.ui index 8417d7615..c6279f825 100644 --- a/src/burner/qt/aboutdialog.ui +++ b/src/burner/qt/aboutdialog.ui @@ -32,6 +32,12 @@ + + 6 + + + 6 + diff --git a/src/burner/qt/main.cpp b/src/burner/qt/main.cpp index 9eb200ff9..663180248 100644 --- a/src/burner/qt/main.cpp +++ b/src/burner/qt/main.cpp @@ -58,10 +58,20 @@ char *TCHARToANSI(const TCHAR* pszInString, char* pszOutString, int nOutSize) } +QString loadAppStyle(const QString &name) +{ + QFile file(name); + file.open(QFile::ReadOnly); + + return QString(file.readAll()); +} + int main(int argc, char **argv) { QApplication app(argc, argv); + app.setStyleSheet(loadAppStyle(":/resource/dark-flat.css")); + MainWindow mw; mw.show(); diff --git a/src/burner/qt/resource/branch-closed.png b/src/burner/qt/resource/branch-closed.png new file mode 100644 index 000000000..45c40bf99 Binary files /dev/null and b/src/burner/qt/resource/branch-closed.png differ diff --git a/src/burner/qt/resource/branch-end.png b/src/burner/qt/resource/branch-end.png new file mode 100644 index 000000000..469d93ed2 Binary files /dev/null and b/src/burner/qt/resource/branch-end.png differ diff --git a/src/burner/qt/resource/branch-more.png b/src/burner/qt/resource/branch-more.png new file mode 100644 index 000000000..2ec5d376d Binary files /dev/null and b/src/burner/qt/resource/branch-more.png differ diff --git a/src/burner/qt/resource/branch-open.png b/src/burner/qt/resource/branch-open.png new file mode 100644 index 000000000..d62a0ae4c Binary files /dev/null and b/src/burner/qt/resource/branch-open.png differ diff --git a/src/burner/qt/resource/checked.png b/src/burner/qt/resource/checked.png new file mode 100644 index 000000000..a84840285 Binary files /dev/null and b/src/burner/qt/resource/checked.png differ diff --git a/src/burner/qt/resource/dark-flat-bg.png b/src/burner/qt/resource/dark-flat-bg.png new file mode 100644 index 000000000..c27562975 Binary files /dev/null and b/src/burner/qt/resource/dark-flat-bg.png differ diff --git a/src/burner/qt/resource/dark-flat.css b/src/burner/qt/resource/dark-flat.css new file mode 100644 index 000000000..82d1d4175 --- /dev/null +++ b/src/burner/qt/resource/dark-flat.css @@ -0,0 +1,501 @@ + +QWidget, QDialog +{ + background: url(:resource/dark-flat-bg.png); + color: #EFF0EF; +} + +QHeaderView::section +{ + border: none; + border-top: 0.5px solid #686868; + border-bottom: 0.5px solid #0f0f0f; + padding-left: 4px; + background: qlineargradient(x1: 0, y1: 0, x2: 0, y2: 1, + stop: 0 #4a4a4a, + stop: 1.0 #2b2b2b ); +} + +QPushButton +{ + border: 0.5px solid #0f0f0f; + border-top: 2px solid + qlineargradient( + x1: 0, y1: 0, x2: 0, y2: 1, + stop: 0.0 #0f0f0f, + stop: 1.0 #686868 ); + padding: 2px; + padding-left: 8px; + padding-right: 8px; + background: qlineargradient(x1: 0, y1: 0, x2: 0, y2: 1, + stop: 0 #4a4a4a, + stop: 1.0 #2b2b2b ); +} + +QPushButton:hover +{ + border: 0.5px solid #0f0f0f; + border-top: 2px solid + qlineargradient( + x1: 0, y1: 0, x2: 0, y2: 1, + stop: 0.0 #0f0f0f, + stop: 1.0 #686868 ); + padding: 2px; + padding-left: 8px; + padding-right: 8px; + background: qlineargradient(x1: 0, y1: 0, x2: 0, y2: 1, + stop: 0 #8c8c8c, + stop: 1.0 #515152 ); +} + +QPushButton:focus +{ + outline: 0; + border: 0.5px solid #0f0f0f; + border-top: 2px solid + qlineargradient( + x1: 0, y1: 0, x2: 0, y2: 1, + stop: 0.0 #0f0f0f, + stop: 1.0 #2e65a9 ); + padding: 2px; + padding-left: 8px; + padding-right: 8px; + background: qlineargradient(x1: 0, y1: 0, x2: 0, y2: 1, + stop: 0 #4282e5, + stop: 1.0 #142dd8 ); +} + +QPushButton#btnPlay +{ + outline: 0; + border: 0.5px solid #0f0f0f; + border-top: 2px solid + qlineargradient( + x1: 0, y1: 0, x2: 0, y2: 1, + stop: 0.0 #0f0f0f, + stop: 1.0 #652ea9 ); + padding: 2px; + padding-left: 8px; + padding-right: 8px; + background: qlineargradient(x1: 0, y1: 0, x2: 0, y2: 1, + stop: 0 #8242e5, + stop: 1.0 #2d14d8 ); +} + +QPushButton#btnPlay:hover +{ + border: 0.5px solid #0f0f0f; + border-top: 2px solid + qlineargradient( + x1: 0, y1: 0, x2: 0, y2: 1, + stop: 0.0 #0f0f0f, + stop: 1.0 #686868 ); + padding: 2px; + padding-left: 8px; + padding-right: 8px; + background: qlineargradient(x1: 0, y1: 0, x2: 0, y2: 1, + stop: 0 #8242e5, + stop: 1.0 #2da4d8 ); +} + +QLineEdit, QTextEdit, QSpinBox +{ + background: #1f1f1f; + border: 1px solid #0f0f0f; + border-top: 2px solid + qlineargradient( + x1: 0, y1: 0, x2: 0, y2: 1, + stop: 0.0 #0f0f0f, + stop: 1.0 #1f1f1f ); +} + +QTreeWidget +{ + background: #1f1f1f; + border: 1px solid #0f0f0f; + alternate-background-color: #1d1d1d; +} + + +QTreeWidget:item:selected, QTreeView::branch:selected +{ + outline: 0; + border: none; + background: qlineargradient(x1: 0, y1: 0, x2: 0, y2: 1, + stop: 0 #4282e5, + stop: 1.0 #142dd8 ); +} + +QTreeView::branch:has-siblings:!adjoins-item { + border-image: url(:resource/vline.png) 0; +} + +QTreeView::branch:has-siblings:adjoins-item { + border-image: url(:resource/branch-more.png) 0; +} + +QTreeView::branch:!has-children:!has-siblings:adjoins-item { + border-image: url(:resource/branch-end.png) 0; +} + +QTreeView::branch:has-children:!has-siblings:closed, +QTreeView::branch:closed:has-children:has-siblings { + border-image: none; + image: url(:resource/branch-closed.png); +} + +QTreeView::branch:open:has-children:!has-siblings, +QTreeView::branch:open:has-children:has-siblings { + border-image: none; + image: url(:resource/branch-open.png); +} + +QMenuBar +{ + background: url(:resource/dark-flat-bg.png); + border: 1px solid #0f0f0f; + color: white; +} + + +QMenuBar:item +{ + background: transparent; +} + +QMenuBar:item:pressed +{ + color: white; + + outline: 0; + border: 0.5px solid #0f0f0f; + border-top: 2px solid + qlineargradient( + x1: 0, y1: 0, x2: 0, y2: 1, + stop: 0.0 #0f0f0f, + stop: 1.0 #2e65a9 ); + background: qlineargradient(x1: 0, y1: 0, x2: 0, y2: 1, + stop: 0 #4282e5, + stop: 1.0 #142dd8 ); +} + +QMenu +{ + background: url(:resource/dark-flat-bg.png); + border: 1px solid #0f0f0f; + color: white; + /*padding: 2px; + padding-left: 8px; + padding-right: 8px;*/ +} + +QMenu::item::selected +{ + + background: qlineargradient(x1: 0, y1: 0, x2: 0, y2: 1, + stop: 0 #4282e5, + stop: 1.0 #142dd8 ); +} + +QMenu::separator +{ + width: 100%; + height: 1px; + margin-left: 5%; + margin-right: 5%; + border-top: 2px solid + qlineargradient( + x1: 0, y1: 0, x2: 0, y2: 1, + stop: 0.0 #0f0f0f, + stop: 1.0 #686868 ); +} + +QLabel#imgTitleScreen, QLabel#imgPreview +{ + border: 1px solid #0f0f0f; +} + +QToolTip +{ + border: 1px solid black; + background-color: #FFFF99; + border-radius: 2px; + padding: 0px; + color: black; +} + +QComboBox +{ + border: 0.5px solid #0f0f0f; + border-top: 2px solid + qlineargradient( + x1: 0, y1: 0, x2: 0, y2: 1, + stop: 0.0 #0f0f0f, + stop: 1.0 #686868 ); + + padding-left: 4px; + background: qlineargradient(x1: 0, y1: 0, x2: 0, y2: 1, + stop: 0 #4a4a4a, + stop: 1.0 #2b2b2b ); +} + +QComboBox::drop-down +{ + border: none; + padding: 3px; +} + +QComboBox QAbstractItemView +{ + background-color: #1f1f1f; + border: 1px solid #0f0f0f; +} + + +QComboBox::down-arrow +{ + image: url(:resource/down_arrow.png); +} + +QGroupBox +{ + spacing: 5px; + padding-top: 20px; + background: #1f1f1f; + border: 1px solid #0f0f0f; + border-top: 2px solid + qlineargradient( + x1: 0, y1: 0, x2: 0, y2: 1, + stop: 0.0 #0f0f0f, + stop: 1.0 #1f1f1f ); +} + +QCheckBox +{ + outline: 0; + background: none; + width: 13px; + height: 13px; +} + +QCheckBox::indicator +{ + width: 16px; + height: 16px; + background: #2f2f2f; + border: 1px solid #0f0f0f; + border-top: 2px solid + qlineargradient( + x1: 0, y1: 0, x2: 0, y2: 1, + stop: 0.0 #0f0f0f, + stop: 1.0 #1f1f1f ); +} + +QCheckBox::indicator:hover +{ + width: 16px; + height: 16px; + background: #3f3f3f; + border: 1px solid #0f0f0f; + border-top: 2px solid + qlineargradient( + x1: 0, y1: 0, x2: 0, y2: 1, + stop: 0.0 #0f0f0f, + stop: 1.0 #1f1f1f ); +} + +QCheckBox::indicator:checked +{ + width: 16px; + height: 16px; + background-image: url(:resource/checked.png); + background-position: center; + background-repeat: no-repeat; + + border: 1px solid #0f0f0f; + border-top: 2px solid + qlineargradient( + x1: 0, y1: 0, x2: 0, y2: 1, + stop: 0.0 #0f0f0f, + stop: 1.0 #1f1f1f ); +} + + +/*****************/ +QScrollBar:horizontal { + border: 1px solid #222222; + background: QLinearGradient( x1: 0, y1: 0, x2: 0, y2: 1, stop: 0.0 #121212, stop: 0.2 #282828, stop: 1 #484848); + height: 16px; + margin: 0px 20px 0 20px; +} + +QScrollBar::handle:horizontal +{ + background: QLinearGradient( x1:0 y1:1, x2:0 y2:0, stop:0 #676767, stop:0.5 #878787, stop:0.51 #979797, stop:1 #a7a7a7); + border-radius: 1px; + min-width: 16px; + border: 1px solid #202020; +} + +QScrollBar::add-line:horizontal { + border: 1px solid #1b1b19; + background: QLinearGradient( x1: 0, y1: 0, x2: 0, y2: 1, stop: 0.0 #121212, stop: 0.2 #282828, stop: 1 #484848); + width: 20px; + subcontrol-position: right; + subcontrol-origin: margin; +} + +QScrollBar::sub-line:horizontal { + border: 1px solid #1b1b19; + background: QLinearGradient( x1: 0, y1: 0, x2: 0, y2: 1, stop: 0.0 #121212, stop: 0.2 #282828, stop: 1 #484848); + width: 20px; + subcontrol-position: left; + subcontrol-origin: margin; +} + +QScrollBar::right-arrow:horizontal +{ + background-image: url(:resource/right_arrow.png); + background-position: center; + background-repeat: no-repeat; + border: none; +} + +QScrollBar::left-arrow:horizontal +{ + background-image: url(:resource/left_arrow.png); + background-position: center; + background-repeat: no-repeat; + border: none; +} + +QScrollBar::add-page:horizontal, QScrollBar::sub-page:horizontal +{ + background: none; +} + +/*****************************/ +QScrollBar:vertical +{ + background: QLinearGradient( x1: 0, y1: 0, x2: 1, y2: 0, stop: 0.0 #121212, stop: 0.2 #282828, stop: 1 #484848); + width: 16px; + margin: 20px 0 20px 0; + border: 1px solid #222222; +} + +QScrollBar::handle:vertical +{ + background: QLinearGradient( x1:1 y1:0, x2:0 y2:0, stop:0 #676767, stop:0.5 #878787, stop:0.51 #979797, stop:1 #a7a7a7); + border-radius: 1px; + min-height: 16px; + border: 1px solid #202020; +} + +QScrollBar::add-line:vertical +{ + border: 1px solid #1b1b19; + background: QLinearGradient( x1: 0, y1: 0, x2: 1, y2: 0, stop: 0.0 #121212, stop: 0.2 #282828, stop: 1 #484848); + height: 20px; + subcontrol-position: bottom; + subcontrol-origin: margin; +} + +QScrollBar::sub-line:vertical +{ + border: 1px solid #1b1b19; + background: QLinearGradient( x1: 0, y1: 0, x2: 1, y2: 0, stop: 0.0 #121212, stop: 0.2 #282828, stop: 1 #484848); + height: 20px; + subcontrol-position: top; + subcontrol-origin: margin; +} + +QScrollBar::up-arrow:vertical +{ + background-image: url(:resource/up_arrow.png); + background-position: center; + background-repeat: no-repeat; + border: none; +} + +QScrollBar::down-arrow:vertical +{ + background-image: url(:resource/down_arrow.png); + background-position: center; + background-repeat: no-repeat; + border: none; +} + +QScrollBar::add-page:vertical, QScrollBar::sub-page:vertical +{ + background: none; +} + +QTabWidget::pane +{ + outline: 0; + border-top: 2px solid + qlineargradient( + x1: 0, y1: 0, x2: 0, y2: 1, + stop: 0.0 #0f0f0f, + stop: 1.0 #686868 ); +} + +QTabBar +{ + outline: 0; +} + +QTabBar::tab +{ + border: 0.5px solid #0f0f0f; + border-top: 2px solid + qlineargradient( + x1: 0, y1: 0, x2: 0, y2: 1, + stop: 0.0 #0f0f0f, + stop: 1.0 #686868 ); + border-bottom: none; + padding-left: 3px; + padding-right: 3px; + background: qlineargradient(x1: 0, y1: 0, x2: 0, y2: 1, + stop: 0 #4a4a4a, + stop: 1.0 #2b2b2b ); + color: white; +} + +QTabBar::tab::selected +{ + border: 0.5px solid #0f0f0f; + border-top: 2px solid + qlineargradient( + x1: 0, y1: 0, x2: 0, y2: 1, + stop: 0.0 #0f0f0f, + stop: 1.0 #686868 ); + border-bottom: none; + padding-left: 3px; + padding-right: 3px; + background: qlineargradient(x1: 0, y1: 0, x2: 0, y2: 1, + stop: 0 #8c8c8c, + stop: 1.0 #515152 ); + color: white; +} + +QProgressBar +{ + background: #1f1f1f; + border: 1px solid #0f0f0f; + text-align: center; + color: white; +} + +QProgressBar::chunk +{ +border-top: 2px solid + qlineargradient( + x1: 0, y1: 0, x2: 0, y2: 1, + stop: 0.0 #0f0f0f, + stop: 1.0 #686868 ); +background: qlineargradient(x1: 0, y1: 0, x2: 0, y2: 1, + stop: 0 #8242e5, + stop: 1.0 #2da4d8 ); + width: 1px; +} diff --git a/src/burner/qt/resource/down_arrow.png b/src/burner/qt/resource/down_arrow.png new file mode 100644 index 000000000..db581cb78 Binary files /dev/null and b/src/burner/qt/resource/down_arrow.png differ diff --git a/src/burner/qt/resource/left_arrow.png b/src/burner/qt/resource/left_arrow.png new file mode 100644 index 000000000..3586ea471 Binary files /dev/null and b/src/burner/qt/resource/left_arrow.png differ diff --git a/src/burner/qt/resource/license.txt b/src/burner/qt/resource/license.txt deleted file mode 100644 index 2d75f81d2..000000000 --- a/src/burner/qt/resource/license.txt +++ /dev/null @@ -1,48 +0,0 @@ -You may freely use, modify, and distribute both the FB Alpha source code and binary, however the following restrictions apply to the FB Alpha original material (see below for a list of libraries with differing licenses, please consult their respective documentation for more information): - - - You may not sell, lease, rent or otherwise seek to gain monetary profit from FB Alpha; - - You must make public any changes you make to the source code; - - You must include, verbatim, the full text of this license; - - You may not distribute binaries which support games with copyright dates less then three years old; - - You may not distribute FB Alpha with ROM images unless you have the legal right to distribute them; - - You may use dynamic linked libraries (dlls) for network play only (all other use is prohibited); - - You may not ask for donations to support your work on any project that uses the FB Alpha source code. - -FB Alpha can currently be obtained from http://www.barryharris.me.uk/. - -FB Alpha would not exist without a lot of code from the MAME project. The MAME project is subject to it's own license, which can be found at http://mamedev.org/legal.html. Due to the use of MAME code in FB Alpha, FB Alpha is also subject to the terms of the MAME license. - -FB Alpha is based on Final Burn (formally at http://www.finalburn.com/), see additional text below. -Musashi MC68000/MC68010/MC68EC020 core by Karl Stenerud (http://www.mamedev.org/). -A68K MC68000 core by Mike Coates & Darren Olafson (http://www.mamedev.org/). -YM3812/YM3526/Y8950 core by Jarek Burczynski & Tatsuyuki Satoh (http://www.mamedev.org/). -YM2151 core by Jarek Burczynski (http://www.mamedev.org/). -YM2413 core by Jarek Burczynski (http://www.mamedev.org/). -YMF278B core by R. Belmont & O.Galibert (http://www.mamedev.org/). -YM2608/YM2610/YM2612/YM2203 cores by Jarek Burczynski & Tatsuyuki Satoh (http://www.mamedev.org/). -AY8910/YM2149 core by various authors (http://www.mamedev.org/). -M6502 emulation core by Marat (http://fms.komkon.org/EMUL8/). -I8039 emulation core by Mirko Buffoni (http://www.mamedev.org/). -ARM7 emulation core by Steve Ellenoff (http://www.mamedev.org/). -Z80 emulation core by Juergen Buchmueller (http://www.mamedev.org/). -PNG functionality provided by libpng (http://www.libpng.org/) and PNGlib (http://www.madwizard.org/). -Zip functionality provided by zlib (http://www.zlib.net/). -Ruby functionality provided by ruby (http://http://byuu.org/programming/ruby/) - -Some graphics effects provided by the Scale2x, 2xPM, Eagle Graphics, 2xSaI, hq2x/hq3x/hq4x, hq2xS/hq3xS/SuperEagle/2xSaI (VBA), hq2xS/hq3xS/hq2xBold/hq3xBold/EPXB/EPXC (SNES9X ReRecording) and SuperScale libraries (http://scale2x.sourceforge.net/, http://2xpm.freeservers.com/, http://retrofx.com/, http://elektron.its.tudelft.nl/~dalikifa/, http://www.hiend3d.com/, http://code.google.com/p/vba-rerecording/, http://code.google.com/p/snes9x151-rerecording/, http://nebula.emulatronia.com/). - -Miscellaneous other components from various sources. Copyright and license information are contained in the relevant parts of the source code. - -All material not covered above © 2004-2013 Team FB Alpha. - -DISCLAIMER: The authors of FB Alpha don't guarantee its fitness for any purpose, implied or otherwise, and do not accept responsibility for any damages whatsoever that might occur when using FB Alpha. All games emulated by FB Alpha, including any images and sounds therein, are copyrighted by their respective copyright holders. FB Alpha DOES NOT INCLUDE any ROM images of emulated games. - -The following information and license conditions accompanied the original Final Burn emulator. They also apply to FB Alpha: - -"Copyright (c)2001 Dave (formally of www.finalburn.com), all rights reserved. This refers to all code except where stated otherwise (e.g. unzip and zlib code)." - -"You can use, modify and redistribute this code freely as long as you don't do so commercially. This copyright notice must remain with the code. If your program uses this code, you must either distribute or link to the source code. If you modify or improve this code, you must distribute the source code improvements." - -"Dave" -"Former Homepage: www.finalburn.com" -"E-mail: dave@finalburn.com" diff --git a/src/burner/qt/resource/right_arrow.png b/src/burner/qt/resource/right_arrow.png new file mode 100644 index 000000000..0172f02c7 Binary files /dev/null and b/src/burner/qt/resource/right_arrow.png differ diff --git a/src/burner/qt/resource/up_arrow.png b/src/burner/qt/resource/up_arrow.png new file mode 100644 index 000000000..f28e1420d Binary files /dev/null and b/src/burner/qt/resource/up_arrow.png differ diff --git a/src/burner/qt/resource/vline.png b/src/burner/qt/resource/vline.png new file mode 100644 index 000000000..d633d8de8 Binary files /dev/null and b/src/burner/qt/resource/vline.png differ diff --git a/src/burner/qt/rscr.qrc b/src/burner/qt/rscr.qrc index 3f0dc0019..4ae6132d5 100644 --- a/src/burner/qt/rscr.qrc +++ b/src/burner/qt/rscr.qrc @@ -6,6 +6,18 @@ resource/tv-not-found-non-essential.ico resource/misc.bmp resource/about.bmp - resource/license.txt + resource/dark-flat.css + resource/down_arrow.png + resource/left_arrow.png + resource/right_arrow.png + resource/up_arrow.png + resource/dark-flat-bg.png + resource/checked.png + resource/branch-closed.png + resource/branch-end.png + resource/branch-more.png + resource/branch-open.png + resource/vline.png + ../../license.txt diff --git a/src/burner/qt/selectdialog.cpp b/src/burner/qt/selectdialog.cpp index 6a665d698..90105e183 100644 --- a/src/burner/qt/selectdialog.cpp +++ b/src/burner/qt/selectdialog.cpp @@ -316,8 +316,8 @@ void SelectDialog::buildDriverTree() ditem->setText(1, ditem->romName()); ditem->setDriverNo(i); ditem->setIsParent(false); - ditem->setBackgroundColor(0, QColor(200, 230, 255)); - ditem->setBackgroundColor(1, QColor(210, 240, 255)); + //ditem->setBackgroundColor(0, QColor(200, 230, 255)); + //ditem->setBackgroundColor(1, QColor(210, 240, 255)); itemParent->addChild(ditem); } } diff --git a/src/burner/qt/selectdialog.ui b/src/burner/qt/selectdialog.ui index 7a7b554c9..50f5e70d9 100644 --- a/src/burner/qt/selectdialog.ui +++ b/src/burner/qt/selectdialog.ui @@ -109,6 +109,9 @@ + + true + Title @@ -130,7 +133,7 @@ 0 - 0 + 3