Skip to content

Commit 492fc73

Browse files
author
mary
committed
Add a picture with the calculator.
1 parent 70e263c commit 492fc73

File tree

3 files changed

+11
-21
lines changed

3 files changed

+11
-21
lines changed

Moder_Calculator_IOS/configuration.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@
4040
'percent': {'row': 2, 'column': 2, 'span': 1, 'text': '%', }
4141
}
4242

43-
GAP_SIZE: int = 0.5
43+
GAP_SIZE: int = 1
4444
TITLE_BAR_COLOR: dict[str, int] = {
4545
'dark' : 0x00000000,
4646
'light': 0xFFEEEE

Moder_Calculator_IOS/main.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -200,7 +200,6 @@ def num_press(self, number: str) -> None:
200200
:param number:
201201
"""
202202
self.display_nums.append(number)
203-
print(self.display_nums)
204203
full_number = ''.join(self.display_nums)
205204
self.result_string.set(full_number)
206205

Moder_Calculator_IOS/widgets.py

Lines changed: 10 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -36,25 +36,16 @@ def __init__(self, parent, text: str, func, row: int, column: int, span: int, st
3636
style = style,
3737
command = func
3838
)
39-
try:
40-
self.grid(
41-
row = row,
42-
column = column,
43-
columnspan = span,
44-
sticky = 'news',
45-
padx = GAP_SIZE, # is a problem on debian with padx and pady. I am not sure if is on my machine
46-
# or not.
47-
pady = GAP_SIZE
48-
49-
)
50-
except Exception:
51-
self.grid(
52-
row = row,
53-
column = column,
54-
columnspan = span,
55-
sticky = 'news',
56-
57-
)
39+
self.grid(
40+
row = row,
41+
column = column,
42+
columnspan = span,
43+
sticky = 'news',
44+
padx = GAP_SIZE, # is a problem on debian with padx and pady. I am not sure if is on my machine
45+
# or not.
46+
pady = GAP_SIZE
47+
48+
)
5849

5950

6051
class NumberButtons(Button):

0 commit comments

Comments
 (0)