This is the doxygen documentation for gtkboard.

.
Main Page   Data Structures   File List   Data Fields   Globals  

board.h File Reference

#include <glib.h>
#include <gdk/gdk.h>
#include <gtk/gtk.h>
#include "game.h"

Go to the source code of this file.

Functions

void board_set_game_params ()
void board_set_cell (int, int, byte)
void board_refresh_cell (int, int)
 A wrapper around board_refresh_cell_real() to take care of whether the board is flipped.

void board_show ()
 Called when the game is unpaused.

void board_hide ()
 Hide the board when the game is paused.

void board_init ()
 initialization of the board.

void board_free ()
 Free all malloc()d stuff.

gboolean board_redraw (GtkWidget *, GdkEventExpose *)
 Redraws the exposed area of the board.

void board_redraw_all ()
 Redraw the whole board.

gint board_signal_handler (GtkWidget *, GdkEventButton *, gpointer)
 handles mouse clicks as well as key presses.

void board_apply_refresh (byte *, int *)

Variables

gboolean board_suspended
 This is TRUE when the game is paused.

GtkWidget* board_area
GtkWidget* board_rowbox
GtkWidget * board_colbox
gboolean state_board_flipped
 Is the board flipped (rotated 180 deg).


Function Documentation

void board_apply_refresh ( byte * move,
int * rmove )
 

Definition at line 90 of file board.c.

Referenced by menu_back_forw(), ui_animate_cb(), ui_get_machine_move(), and ui_make_human_move().

void board_free ( )
 

Free all malloc()d stuff.

Definition at line 427 of file board.c.

void board_hide ( )
 

Hide the board when the game is paused.

Definition at line 306 of file board.c.

void board_init ( )
 

initialization of the board.

Definition at line 516 of file board.c.

gboolean board_redraw ( GtkWidget * widget,
GdkEventExpose * event )
 

Redraws the exposed area of the board.

Definition at line 267 of file board.c.

Referenced by board_redraw_all(), and menu_board_flip_cb().

void board_redraw_all ( )
 

Redraw the whole board.

Definition at line 292 of file board.c.

void board_refresh_cell ( int x,
int y )
 

A wrapper around board_refresh_cell_real() to take care of whether the board is flipped.

Definition at line 257 of file board.c.

Referenced by board_apply_refresh().

void board_set_cell ( int x,
int y,
byte val )
 

Definition at line 85 of file board.c.

void board_set_game_params ( )
 

Definition at line 79 of file board.c.

void board_show ( )
 

Called when the game is unpaused.

Definition at line 298 of file board.c.

gint board_signal_handler ( GtkWidget * widget,
GdkEventButton * event,
gpointer data )
 

handles mouse clicks as well as key presses.

Definition at line 334 of file board.c.


Variable Documentation

GtkWidget* board_area
 

Definition at line 30 of file board.h.

GtkWidget * board_colbox
 

Definition at line 31 of file board.h.

GtkWidget* board_rowbox
 

Definition at line 31 of file board.h.

gboolean board_suspended
 

This is TRUE when the game is paused.

Definition at line 29 of file board.h.

gboolean state_board_flipped
 

Is the board flipped (rotated 180 deg).

Definition at line 32 of file board.h.