NAME

Games::Sudoku::Component::TkPlayer::Controller - controls Tk Widgets and Sudoku Components

SYNOPSIS

use Games::Sudoku::Component::TkPlayer::Controller;
my $ctrl = Games::Sudoku::Component::TkPlayer::Controller->new;

DESCRIPTION

This is an internal class but may show you how to use Games::Sudoku::Component.

METHODS

new

creates an instance

new_game

erases an existing puzzle if any and creates a new one.

load_game

erases an existing puzzle if any and loads a new one.

save_game

saves a puzzle to a file.

lock

locks a puzzle, so you can roll back the changes you make afterwards. Generated and loaded puzzles are locked by default.

unlock

unlocks a puzzle, so you can change an existing puzzle.

clear

clears an existing puzzle.

rewind_all

rolls back all the changes you made.

find_tmpvalue

finds values that are wrong and prohibited in fact.

find_next

would tell you what cell you should put an answer next.

solve

solves a puzzle.

do_next

puts an answer to a cell the solver thinks best.

configure_button, configure_button_color

configures button/cell appearance (used internally).

push_button

does everything required when you push a button/cell (used internally).

quit

quits an application.

AUTHOR

Kenichi Ishigaki, <ishigaki at cpan.org>

COPYRIGHT AND LICENSE

Copyright (C) 2006 by Kenichi Ishigaki, all rights reserved.

This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.