Skip to content

Commit 6d80d59

Browse files
committed
.
1 parent 76f6c5a commit 6d80d59

File tree

10 files changed

+16
-46
lines changed

10 files changed

+16
-46
lines changed
26 Bytes
Binary file not shown.

carinfo.txt

Lines changed: 3 additions & 32 deletions
Original file line numberDiff line numberDiff line change
@@ -1,32 +1,3 @@
1-
BMW-5957,2019-06-07 21:25:27
2-
ANB 8888,2019-06-07 21:26:01
3-
None,2019-06-09 17:04:13
4-
None,2019-06-09 17:04:20
5-
BMW-5957,2019-06-09 17:04:26
6-
ml12-jQ,2019-06-09 17:04:51
7-
9C-9508,2019-06-09 17:04:58
8-
None,2019-06-09 17:05:08
9-
None,2019-06-09 17:05:59
10-
None,2019-06-09 17:06:53
11-
None,2019-06-09 17:08:24
12-
None,2019-06-09 17:08:53
13-
None,2019-06-09 17:09:24
14-
5978YA,2019-06-09 17:09:52
15-
9276MG,2019-06-09 17:09:58
16-
AFS3269,2019-06-09 17:10:04
17-
RATZ182,2019-06-09 17:10:09
18-
1051K7,2019-06-09 17:13:30
19-
J88W12,2019-06-09 17:14:18
20-
9276MG,2019-06-09 17:17:57
21-
BMW5957,2019-06-09 17:23:52
22-
5978YA,2019-06-09 17:25:00
23-
5978YA,2019-06-09 17:59:09
24-
None,2019-06-09 18:23:43
25-
AND8888,2019-06-09 19:15:16
26-
BMW5957,2019-06-09 19:15:21
27-
1051K7,2019-06-09 19:15:34
28-
1051K7,2019-06-09 19:25:36
29-
1051K7,2019-06-09 19:27:54
30-
5978YA,2019-06-09 19:28:00
31-
AFS3269,2019-06-11 00:09:32
32-
AFS3269,2019-06-11 16:12:47
1+
1051K7,2019-06-08 21:14:06
2+
9C9508,2019-06-11 21:27:02
3+
5978YA,2019-06-11 21:28:20

gui.py

Lines changed: 5 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ def __init__(self, window=tkinter.Tk(), window_title="ALPR", video_source=OBS):
2727
# create a top-window
2828
self.window = window
2929
self.window.title(window_title)
30-
self.window.geometry("1366x768")
30+
self.window.geometry("1300x680")
3131
self.video_source = video_source
3232

3333

@@ -101,10 +101,10 @@ def initwidgets(self):
101101
self.makeimageslist()
102102

103103
# layout
104-
self.canvas.grid(column=0, row=0, ipadx=0, padx=50)
105-
self.preview_canvas.grid(column=1, row=0)
106-
self.cb.grid(column=0, row=1)
107-
self.panel.grid(column=1, row=1)
104+
self.canvas.grid(column=0, row=0, sticky='w')
105+
self.preview_canvas.grid(column=1, row=0, sticky='e')
106+
self.cb.grid(column=0, row=1, sticky='ne')
107+
self.panel.grid(column=1, row=1, sticky='nw')
108108

109109
# panel
110110
self.lb.grid(column=0, row=0)
@@ -122,14 +122,10 @@ def makemenu(self):
122122
self.window.config(menu=self.main_menu)
123123
self.file_menu = tkinter.Menu(tearoff=False)
124124
self.main_menu.add("cascade", label="File", menu=self.file_menu)
125-
self.file_menu.add("command", label='Save File', command=self.savefile)
126125
self.file_menu.add("command", label='Open Image', command=self.opentheimage)
127126
self.file_menu.add("command", label='Quit', command=self.window.destroy)
128127
self.main_menu.add("command", label="About", command=self.about)
129128

130-
def savefile(self): # under construction
131-
pass
132-
133129
def opentheimage(self):
134130
askfilename = filedialog.askopenfilename(
135131
filetypes=(("all files", "*.*"), ("png files", "*.png"), ("jpg files", "*.jpg")))

imageManagement.py

Lines changed: 8 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -14,22 +14,25 @@ def __init__(self):
1414
self.windowWidth = 1600 # 視窗寬
1515
self.windowHeight = 900 # 視窗高
1616
self.screenWidth, screenHeight = self.window.maxsize() # 獲得螢幕寬和高
17-
self.window.geometry("1366x768")
17+
self.window.geometry("1300x680")
1818
self.window.wm_attributes('-topmost', 1) # 視窗置頂
1919

20-
self.deletebtn = tkinter.Button(self.window, text="刪除", command=self.deleteImgage, width=20, height=10,
20+
self.panel = tkinter.Frame(self.window)
21+
self.deletebtn = tkinter.Button(self.panel, text="刪除", command=self.deleteImgage, width=20, height=10,
2122
bg="pink", fg="white", font="30")
22-
self.chosebtn = tkinter.Button(self.window, text="選擇", command=self.chose, width=20, height=10,
23+
self.chosebtn = tkinter.Button(self.panel, text="選擇", command=self.chose, width=20, height=10,
2324
bg="pink", fg="white", font="30")
2425

2526

26-
self.deletebtn.place(x=500, y=500)
27-
self.chosebtn.place(x=750, y=500)
2827

2928
self.name = StringVar(value='None')
3029
self.lab = tkinter.Label(self.window, textvariable=self.name)
3130

3231
self.lab.grid(column=1, row=2)
32+
self.panel.grid(column=1, row=3)
33+
34+
self.deletebtn.grid(column=0, row=0)
35+
self.chosebtn.grid(column=1, row=0)
3336

3437
self.show_canvas()
3538
self.x_place = 450

images/9C9508.jpg

-102 KB
Binary file not shown.

images/9C9508.png

426 KB
Loading

images/ANB8888.png

422 KB
Loading

images/AND8888.png

-425 KB
Binary file not shown.

images/None.png

312 KB
Loading

images/snapshot.png

422 KB
Loading

0 commit comments

Comments
 (0)