ui: Errorview
Tabbed view with errorview as tab
This commit is contained in:
@@ -393,4 +393,26 @@
|
||||
</aggregation>
|
||||
</edge>
|
||||
</graph>
|
||||
<error>
|
||||
<background>#272728</background>
|
||||
<table>white</table>
|
||||
<text>
|
||||
<normal>white</normal>
|
||||
<active>black</active>
|
||||
</text>
|
||||
<table_line_1>
|
||||
<normal>darkgrey</normal>
|
||||
<active>white</active>
|
||||
</table_line_1>
|
||||
<table_line_2>
|
||||
<normal>#343434</normal>
|
||||
<active>white</active>
|
||||
</table_line_2>
|
||||
</error>
|
||||
<tab>
|
||||
<background>#272728</background>
|
||||
<active>white</active>
|
||||
<hover>#878787</hover>
|
||||
<text>#878787</text>
|
||||
</tab>
|
||||
</config>
|
||||
|
||||
@@ -359,4 +359,26 @@
|
||||
</aggregation>
|
||||
</edge>
|
||||
</graph>
|
||||
<error>
|
||||
<background>white</background>
|
||||
<table>#aaa</table>
|
||||
<text>
|
||||
<normal>black</normal>
|
||||
<active>white</active>
|
||||
</text>
|
||||
<table_line_1>
|
||||
<normal>white</normal>
|
||||
<active>grey</active>
|
||||
</table_line_1>
|
||||
<table_line_2>
|
||||
<normal>#F1F1F1</normal>
|
||||
<active>grey</active>
|
||||
</table_line_2>
|
||||
</error>
|
||||
<tab>
|
||||
<background>white</background>
|
||||
<active>black</active>
|
||||
<hover>#878787</hover>
|
||||
<text>#878787</text>
|
||||
</tab>
|
||||
</config>
|
||||
|
||||
@@ -388,4 +388,26 @@
|
||||
</aggregation>
|
||||
</edge>
|
||||
</graph>
|
||||
<error>
|
||||
<background>#272728</background>
|
||||
<table>white</table>
|
||||
<text>
|
||||
<normal>white</normal>
|
||||
<active>black</active>
|
||||
</text>
|
||||
<table_line_1>
|
||||
<normal>darkgrey</normal>
|
||||
<active>white</active>
|
||||
</table_line_1>
|
||||
<table_line_2>
|
||||
<normal>#343434</normal>
|
||||
<active>white</active>
|
||||
</table_line_2>
|
||||
</error>
|
||||
<tab>
|
||||
<background>#272728</background>
|
||||
<active>white</active>
|
||||
<hover>#878787</hover>
|
||||
<text>#878787</text>
|
||||
</tab>
|
||||
</config>
|
||||
|
||||
@@ -0,0 +1,90 @@
|
||||
QTableView {
|
||||
color: <color:error/text/normal>;
|
||||
background-color: <color:error/table_line_1/normal>;
|
||||
alternate-background-color: <color:error/table_line_2/normal>;
|
||||
border-radius: 10px;
|
||||
border: 1px solid <color:error/table>;
|
||||
margin: 10px;
|
||||
padding-right: 10px;
|
||||
font-size: <setting:font_size>px;
|
||||
}
|
||||
|
||||
QFrame {
|
||||
background-color: <color:error/background>;
|
||||
}
|
||||
|
||||
QTableView::item {
|
||||
border-left: 1px solid <color:error/table>;
|
||||
}
|
||||
|
||||
QTableView::item:selected {
|
||||
color: <color:error/text/active>;
|
||||
background-color: <color:error/table_line_1/active>;
|
||||
alternate-background-color: <color:error/table_line_2/active>;
|
||||
}
|
||||
|
||||
QHeaderView {
|
||||
background-color: transparent;
|
||||
}
|
||||
|
||||
QHeaderView::section:horizontal {
|
||||
background-color: transparent;
|
||||
border: none;
|
||||
border-bottom: 1px solid <color:error/table>;
|
||||
border-left: 1px solid <color:error/table>;
|
||||
color: <color:error/text/normal>;
|
||||
font-size: <setting:font_size>px;
|
||||
font-weight: bold;
|
||||
padding: 1px 6px;
|
||||
height: <setting:font_size+5>px;;
|
||||
}
|
||||
|
||||
|
||||
QCheckBox {
|
||||
color: <color:error/text/normal>;
|
||||
border-color: <color:error/table>;
|
||||
/*background-color: <color:error/table>;*/
|
||||
}
|
||||
|
||||
QHeaderView::section:vertical {
|
||||
background-color: transparent;
|
||||
border: none;
|
||||
color: <color:error/text/normal>;
|
||||
font-size: <setting:font_size>px;
|
||||
padding-right: 5px;
|
||||
padding-left: 5px;
|
||||
}
|
||||
|
||||
QScrollBar:vertical {
|
||||
}
|
||||
|
||||
QScrollBar::handle:vertical {
|
||||
min-height: 20px;
|
||||
}
|
||||
|
||||
QScrollBar::add-line:vertical {
|
||||
height: 20px;
|
||||
subcontrol-position: bottom;
|
||||
subcontrol-origin: margin;
|
||||
}
|
||||
|
||||
QScrollBar::sub-line:vertical {
|
||||
height: 20px;
|
||||
subcontrol-position: top;
|
||||
subcontrol-origin: margin;
|
||||
}
|
||||
QScrollBar::up-arrow:vertical, QScrollBar::down-arrow:vertical {
|
||||
width: 3px;
|
||||
height: 3px;
|
||||
background: white;
|
||||
}
|
||||
|
||||
QScrollBar::add-page:vertical, QScrollBar::sub-page:vertical {
|
||||
background: none;
|
||||
}
|
||||
|
||||
QTableView QTableCornerButton::section {
|
||||
background-color: <color:error/background>;
|
||||
border-bottom: 1px solid <color:error/table>;
|
||||
border-top-left-radius: 10px;
|
||||
}
|
||||
@@ -3,3 +3,4 @@ QToolTip {
|
||||
color: black;
|
||||
font-size: <setting:font_size>px;
|
||||
}
|
||||
|
||||
|
||||
@@ -0,0 +1,31 @@
|
||||
QTabWidget::tab-bar {
|
||||
alignment: left;
|
||||
}
|
||||
|
||||
QTabBar::tab {
|
||||
background-color: <color:tab/background>;
|
||||
color: <color:tab/text>;
|
||||
padding: 12px 75px 5px 12px;
|
||||
border: 0px;
|
||||
border-bottom: 4px solid <color:tab/background>;
|
||||
/*font-size: <setting:font_size>px;*/
|
||||
/*font-weight: bold;*/
|
||||
}
|
||||
|
||||
QTabBar::tab:hover {
|
||||
border-bottom: 4px solid <color:tab/hover>;
|
||||
}
|
||||
|
||||
QTabBar::tab:selected {
|
||||
border-bottom: 4px solid <color:tab/active>;
|
||||
color: <color:tab/active>;
|
||||
}
|
||||
|
||||
QTabWidget::pane {
|
||||
top: 0px;
|
||||
background: <color:tab/background>;
|
||||
color: <color:tab/text>;
|
||||
border: 0px;
|
||||
margin: 0px;
|
||||
padding: 0px;
|
||||
}
|
||||
@@ -8,7 +8,7 @@ Field::Token Field::Opponent( Token token ) {
|
||||
} else if (token == PlayerB){
|
||||
return PlayerA;
|
||||
} else {
|
||||
return None;
|
||||
return Non;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -100,7 +100,7 @@ bool Field::InRange( const Move& move ) const {
|
||||
}
|
||||
|
||||
bool Field::IsEmpty( const Move& move ) const {
|
||||
return grid_[move.row][move.col] == None;
|
||||
return grid[move.row][move.col] == None;
|
||||
}
|
||||
|
||||
bool Field::IsFull() const {
|
||||
|
||||
@@ -11,7 +11,7 @@ HumanPlayer::~HumanPlayer() {
|
||||
|
||||
Field::Move HumanPlayer::Turn( const Field& field ) const {
|
||||
Field::Move move;
|
||||
io::stringOut(name_);
|
||||
io::stringOu(name_);
|
||||
io::stringOut("\n");
|
||||
|
||||
do {
|
||||
@@ -33,13 +33,13 @@ Field::Move HumanPlayer::Input() const {
|
||||
io::stringOut("Insert column: ");
|
||||
move.col = io::numberIn();
|
||||
|
||||
io::stringOut("\n");
|
||||
io::tringOut("\n");
|
||||
return move;
|
||||
}
|
||||
|
||||
bool HumanPlayer::Check( const Field& field, const Field::Move& move ) const {
|
||||
if ( !field.InRange( move ) ) {
|
||||
io::stringOut("Wrong input!\n");
|
||||
io::stringOut("Wrong input!\n")
|
||||
return false;
|
||||
} else if ( !field.IsEmpty( move ) ) {
|
||||
io::stringOut("Is occupied!\n");
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
#include "tictactoe.h"
|
||||
|
||||
#include "artificial_player.h"
|
||||
#include "artificia_player.h"
|
||||
#include "human_player.h"
|
||||
#include "io.h"
|
||||
|
||||
|
||||
@@ -29,8 +29,6 @@
|
||||
<indexing>
|
||||
<indexer_thread_count><!-- INTEGER: number of threads indexing the source code --></indexer_thread_count>
|
||||
|
||||
<show_external_non_fatal_errors><!-- BOOL: show non-fatal errors in unindexed files --></show_external_non_fatal_errors>
|
||||
|
||||
<cxx>
|
||||
<compiler_flags>
|
||||
<compiler_flag><!-- STRING: compiler flag, including the dash e.g. -v --></compiler_flag>
|
||||
|
||||
Reference in New Issue
Block a user