class SGP:
class SGG:
class SGHint:
def __init__(self):
def add(self,score, effects, causes, algorithm):
def list(self):
def delete(self):
def hint_on(self):
def hint_off(self):
def hint_is_on(self):
def restore_hint_mode(self):
def save_hint_mode(self):
def len_hint_effects(self):
def len_hint_causes(self):
def hint_effects(self):
def hint_causes(self):
def mode_ok(self, mode_in):
def mode_is_on(self, mode_in, query_mode):
class SGHistory:
def __init__(self,sg):
def empty(self):
def add(self,sg):
def delete(self):
def get_current(self):
def get_previous(self):
def replace(self,sg):
class SGSCell:
def __init__(self, sg, cell_index_in):
def get_next_candidate(self):
class SGCell:
def __init__(self, cell_index):
def get_solution(self):
def get_guess(self):
def get_candidates(self):
def candidate_is_set(self,candidate):
def guess_is_set(self):
def guess_is_a_given(self):
def guess_correct(self):
def candidates_consistent(self):
def check_range_0_8(self,value):
def check_range_0_9(self,value):
def check_range_1_9(self,value):
def check_range_cell_index(self,value):
def set_solution(self,solution):
def set_guess(self,guess):
def unset_guess(self):
def del_candidate(self,candidate_in):
def add_candidate(self,candidate):
def reset_all_candidates(self):
def get_cell_info(self):
def compare_candidates(self,other):
def available_candidates(self):
class SGSudoku:
def __init__(self):
def __len__(self):
def check_range(self,value):
def print_sg_sudoku(self):
def print_sg_sudoku1(self):
def get_info(self):
def set_solutions(self,job):
def check_guesses(self):
def is_ninemer_consistent(self, shape):
def is_consistent(self):
def load_sg_sudoku(self,solutions):
def zero_algorithm_usage(self):
def get_cell_list(self,my_shape_index,shape):
def get_set_cell_list(self):
def prepare_to_go_fishing(self):
def prepare_tables(self):
def algorithms_not_ready(self):
def prepare_to_get_naked_1(self, shape):
def prepare_to_get_naked(self):
def prepare_to_get_hidden_1(self, shape):
def prepare_to_get_hidden(self):
def lc1_cause(self, box, index_t, candidate, shape):
def locked_candidate_12(self, box, shape, hints):
def locked_candidate_1(self, hints):
def lc2_cause(self, row_col_in, box, candidate, shape):
def locked_candidate_22(self, row_col_in, shape, hints):
def locked_candidate_2(self, hints):
def hs3(self,cell_index, result):
def hs4(self, cell_list, candidate, hints):
def hs2(self, shape, hints):
def hidden_single(self, hints):
def get_effects_1(self, cell_index, candidate_list):
def get_cause_1(self, cell_index, candidate_list):
def hp3(self,cell_list,candidate):
def hp2(self, shape, hints):
def hidden_pairs(self,hints):
def ht2(self,shape,hints):
def hidden_triples(self,hints):
def naked_1(self, cell_list_1, cell_list_2, candidate_list):
def naked_2(self, cell_list, candidate_list):
def naked_pairs_1(self, cell_list_in, good_stuff, hints):
def naked_pairs(self,hints):
def naked_triples_1(self, cell_list_in, good_stuff, hints):
def naked_triples(self,hints):
def naked_quads_1(self, cell_list_in, good_stuff, hints):
def naked_quads(self,hints):
def indexes_with_candidate(self, cell_list, candidate, shape):
def row_col_to_index(self, index_1, index_2, shape):
def fish_1(self, index_list, ninemer_index, candidate, shape):
def get_effects_2(self, cell_list, candidate_in, ninemer_list):
def xwing_1(self, shape_in, hints):
def xwing(self, hints):
def check_cause(self, cause, shape):
def swordfish_1(self, shape_in, hints):
def swordfish(self, hints):
def jellyfish_1(self, shape_in, hints):
def jellyfish(self, hints):
def simple_filter_a_cell(self, cell_index_in, shape):
def apply_effects(self, hints):
def simple_filter_now_1(self):
def get_solved_candidates(self, cell_index_list):
def simple_filter_shape(self, shape, hints, do_it_now):
def simple_filter(self, hints):
def simple_filter_now(self, hints):
def simple_filter_exhaustively(self, hints):
def apply_an_algorithm(self, algorithm, skip):
def try_all_algorithms(self):
def apply_all_algorithms(self):
def simplest_first(self):
def new_cell_index(self):
def solve_puzzle(self, pv):
def solve_sg_sudoku(self):
def unique_solution(self):
class SGWidgetData:
def __init__(self):
class SGWG:
class SGHandleStatus:
def __init__(self):
def redraw_all(self):
def update_all(self):
def this_status(self, status_array_code):
def mode_ok(self, mode_in):
def add_mode_1(self, mode_in, new_mode):
def del_mode_1(self, mode_in, new_mode):
def mode_is_on_1(self, current_mode, mode):
def set_mode(self, mode, status_index, status_array_code):
def add_mode(self, mode, status_index, status_array_code):
def del_mode(self, mode, status_index, status_array_code):
def mode_is_on(self, mode, status_index, status_array_code):
def mode_is(self, mode, status_index, status_array_code):
def toggle_mode(self, mode, status_index, status_array_code):
class SGWidget(Frame):
def __init__(self, parent=None):
Frame.__init__(self, parent)
def init_fonts(self):
def load_preferences(self):
def SGWidget_sanity_check(self):
def editMenu(self):
def sync_sg_and_sgw(self, new_sg, old_sg):
def check_user_colourings(self, sg):
def serviceEditmenu_toolbar(self, button_index, mouse_button):
def check_toolbar_status(self):
def do_toolbar(self):
def undo_so_colours_off(self):
def hints_are_used_up(self):
def uncolour_hints_1(self, hints, mode_off):
def uncolour_hints(self):
def undo_1(self):
def undo(self):
def service_an_algorithm(self, button):
def service_a_hint_request(self):
def makeMenuBar(self):
def fileMenu(self):
def serviceFilemenu(self,menu_index):
def quit(self):
def do_get_puzzle_from_file(self):
def do_get_puzzle_from_widget(self):
def do_write_puzzle(self):
def do_show_solution(self):
def refresh_widgets(self):
def set_hint_level(self, hint_index):
def set_help_level(self, help_index):
def set_symbol_choice(self, symbol_index):
def service_help_status(self):
def set_candidate_colour(self, colour_index):
def set_cell_colour(self, colour_index):
def colour_candidates(self, candidate):
def candidate_colours_none(self):
def colour_cell(self,cell_index):
def cell_colours_none(self):
def do_select_puzzle(self):
def makeToolbar(self):
def toolbar_button_handler(event, self=self, button=toolbar_index):
def toolbar_button_handler(event, self=self, button=toolbar_index):
def updateToolbar(self):
def init_for_new_puzzle(self):
def makeCounterbar(self):
def updateCounter(self):
def use_hints(self,sg,hints):
def make_SGCellWidget(self,sg_cell):
def little_button_handler(event, self=self, button=button,\
def reset_button_handler(event, self=self, cell_index=cell_index):
def little_button_handler(event, self=self, button=button,\
def reset_button_handler(event, self=self, cell_index=cell_index):
def update_SGCellWidget(self,sg_cell):
def little_button_despatcher (self, event, button_index, cell_index):
def toggle_little_button (self, cell_index, button_index):
def set_guess_to_candidate (self, cell_index, button_index):
def reset_button_despatcher (self, event, cell_index):
def service_big_button(self, cell_index, menu_index):
def make_SGGridWidget(self,sg):
def update_SGGridWidget(self,sg):
def do_show_difficulty(self):
def do_configure(self):
class SelectPuzzle(Toplevel):
def __init__(self):
def handleList(event,self=self):
class ShowDifficulty(Toplevel):
def __init__(self):
def get_algorithm_usage(self):
def set_score(self, score, alg):
class ConfigureSG(Toplevel):
def __init__(self, sg_widget):
def button_handler(event, self=self):
def button_handlerd(event, self=self):
def button_handlers(event, self=self):
def set_value(self,value,button):
def set_relief_value(self,value,button):
def set_colour_object(self,button):
def configure_configure(self):
def load_defaults(self, sg):
def apply_configure(self, sg):
def load_widgets(self):
def unload_widgets(self):
def do_colours(self,colour_frame):
def handler(event,self=self,i=i):
def handler1(self,event,i):
def set_my_colours(self):
def save_settings(self):
class SGIO:
def __init__(self):
def check_puzzle_values(self):
def sg_open_file(self):
def get_17mer_puzzle(self, my_file):
def get_data_from_file(self, my_file):
def guess_data_format(self, lines):
def parse_data1(self, lines):
def parse_data2(self, lines):
def parse_data(self, lines):
def read_puzzle(self, my_file):
def write_puzzle(self):
class EnterPuzzle(Toplevel):
def __init__(self):
def get_data(self):
def make_lines(self, content):