Added test.py file
This commit is contained in:
5
main.py
5
main.py
@@ -66,6 +66,7 @@ class Menu(object):
|
||||
class MyApp(object):
|
||||
|
||||
def __init__(self, screen):
|
||||
screen = curses.initscr()
|
||||
curses.curs_set(0)
|
||||
curses.start_color()
|
||||
curses.init_color(0,0,0,0)
|
||||
@@ -77,7 +78,7 @@ class MyApp(object):
|
||||
cols56 = (curses.COLS - 2) * 0.56 # Take 2 characters out from the boarders and then calculate 56%
|
||||
cols56 = int(cols56) + 1 # Ditch the fractional part and add 1
|
||||
|
||||
lines = (curses.LINES - 2) * 0.95 # Take 2 characters out from the boarders and then calculate 56%
|
||||
lines = (curses.LINES - 2) * 0.95 # Take 2 characters out from the boarders and then calculate 95%
|
||||
lines = int(lines) # Ditch the fractional part
|
||||
|
||||
|
||||
@@ -109,7 +110,7 @@ class MyApp(object):
|
||||
# resistors_items = [("10R", curses.beep), ("10K", curses.beep), ("330R", curses.flash), ("57K", curses.flash)]
|
||||
# resistorsMenu = Menu(resistors_items, parts)
|
||||
|
||||
components_items = [("Resistors", (r = 1)), ("Capacitors", curses.beep), ("Coils", curses.flash), ("IC\'s", curses.flash)]
|
||||
components_items = [("Resistors", curses.beep), ("Capacitors", curses.beep), ("Coils", curses.flash), ("IC\'s", curses.flash)]
|
||||
componentsMenu = Menu(components_items, components)
|
||||
componentsMenu.display()
|
||||
|
||||
|
Reference in New Issue
Block a user