# HG changeset patch # User Neil Muller # Date 1378239560 -7200 # Node ID 05c2c592ce2eb817fe776f15ede6015ff3dc8e84 # Parent 34c11bb5c96ee9ab2372127a442baf9dcc91bb65 Add dummy check boxes diff -r 34c11bb5c96e -r 05c2c592ce2e tools/area_editor.py --- a/tools/area_editor.py Tue Sep 03 22:50:29 2013 +0200 +++ b/tools/area_editor.py Tue Sep 03 22:19:20 2013 +0200 @@ -23,7 +23,7 @@ from albow.root import RootWidget from albow.widget import Widget -from albow.controls import Button +from albow.controls import Button, Label, CheckBox from albow.dialogs import alert from nagslang.constants import SCREEN @@ -304,6 +304,9 @@ button_rect = pygame.rect.Rect(0, 0, MENU_WIDTH, MENU_BUTTON_HEIGHT) + check_rect = pygame.rect.Rect(0, 0, MENU_BUTTON_HEIGHT // 2, + MENU_BUTTON_HEIGHT // 2) + end_poly_but = PolyButton(None, self.level_widget) end_poly_but.rect = button_rect.copy() end_poly_but.rect.move_ip(MENU_LEFT, y) @@ -329,6 +332,25 @@ self.add(close_poly_but) y += MENU_BUTTON_HEIGHT + MENU_PAD + white = pygame.color.Color("white") + self.show_objs = CheckBox(fg_color=white) + self.show_objs.rect = check_rect.copy() + self.show_objs.rect.move_ip(MENU_LEFT, y) + label = Label("Show Objects", fg_color=white) + label.rect.move_ip(MENU_LEFT + MENU_BUTTON_HEIGHT // 2 + MENU_PAD, y) + self.add(self.show_objs) + self.add(label) + y += label.rect.height + MENU_PAD + + self.show_enemies = CheckBox(fg_color=white) + self.show_enemies.rect = check_rect.copy() + self.show_enemies.rect.move_ip(MENU_LEFT, y) + label = Label("Show enemy start pos", fg_color=white) + label.rect.move_ip(MENU_LEFT + MENU_BUTTON_HEIGHT // 2 + MENU_PAD, y) + self.add(self.show_enemies) + self.add(label) + y += label.rect.height + MENU_PAD + quit_but = Button('Quit', action=self.quit) quit_but.rect = button_rect.copy() quit_but.rect.move_ip(MENU_LEFT, y)