00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020 #ifndef __GUI__
00021 #define __GUI__
00022
00023 #ifndef NO_GRAPHICS
00024
00025 #include <gtk/gtk.h>
00026
00027 class ArenaWindow;
00028 class MessageWindow;
00029 class ScoreWindow;
00030 class StatisticsWindow;
00031 class StartTournamentWindow;
00032 class Robot;
00033 class String;
00034
00035 class Gui
00036 {
00037 public:
00038 Gui();
00039 ~Gui() {}
00040
00041 void set_colours();
00042
00043 GdkColor* get_bg_gdk_colour_p () { return &bg_gdk_colour; }
00044 GdkColor* get_fg_gdk_colour_p () { return &fg_gdk_colour; }
00045 GdkColor* get_rtb_message_gdk_colour_p () { return &rtb_message_gdk_colour; }
00046
00047 long int get_bg_rgb_colour () { return bg_rgb_colour; }
00048 long int get_fg_rgb_colour () { return fg_rgb_colour; }
00049 long int get_rtb_message_rgb_colour () { return rtb_message_rgb_colour; }
00050
00051 bool is_arenawindow_up ()
00052 { return ( arenawindow_p != NULL ); }
00053 ArenaWindow* get_arenawindow_p ()
00054 { return arenawindow_p; }
00055 void open_arenawindow ();
00056 void close_arenawindow ();
00057
00058 bool is_messagewindow_up ()
00059 { return ( messagewindow_p != NULL ); }
00060 MessageWindow* get_messagewindow_p ()
00061 { return messagewindow_p; }
00062 void open_messagewindow ();
00063 void close_messagewindow ();
00064
00065 bool is_scorewindow_up ()
00066 { return ( scorewindow_p != NULL ); }
00067 ScoreWindow* get_scorewindow_p ()
00068 { return scorewindow_p; }
00069 void open_scorewindow ();
00070 void close_scorewindow ();
00071
00072 bool is_statisticswindow_up ()
00073 { return ( statisticswindow_p != NULL ); }
00074 StatisticsWindow* get_statisticswindow_p ()
00075 { return statisticswindow_p; }
00076 void open_statisticswindow ();
00077 void close_statisticswindow ();
00078
00079 bool is_starttournamentwindow_up ()
00080 { return ( starttournamentwindow_p != NULL ); }
00081 StartTournamentWindow* get_starttournament_p ()
00082 { return starttournamentwindow_p; }
00083 static void kill_and_start_new_tournament ( int result );
00084 void open_starttournamentwindow ();
00085 void close_starttournamentwindow ();
00086
00087 private:
00088
00089 long int bg_rgb_colour;
00090 long int fg_rgb_colour;
00091 long int rtb_message_rgb_colour;
00092
00093 GdkColor bg_gdk_colour;
00094 GdkColor fg_gdk_colour;
00095 GdkColor rtb_message_gdk_colour;
00096
00097 ArenaWindow* arenawindow_p;
00098 MessageWindow* messagewindow_p;
00099 ScoreWindow* scorewindow_p;
00100 StatisticsWindow* statisticswindow_p;
00101 StartTournamentWindow* starttournamentwindow_p;
00102 };
00103
00104 #endif
00105
00106 #endif