def __init__(self, window, **kwargs): Labelframe.__init__(self, window, **kwargs) self.name_of_applicant_n_lab = Label(self, text="Wnioskodawcy (m)") self.name_of_applicant_n_lab.grid(row=0, column=0, padx=5, pady=5, sticky='e') self.name_of_applicant_n = Entry(self, width = 40) self.name_of_applicant_n.grid(row=0, column=1, columnspan=3, padx=5, pady=5, sticky='w') self.name_of_applicant_g_lab = Label(self, text="Wnioskodawcy (d)") self.name_of_applicant_g_lab.grid(row=1, column=0, padx=5, pady=5, sticky='e') self.name_of_applicant_g = Entry(self, width = 40) self.name_of_applicant_g.grid(row=1, column=1, columnspan=3, padx=5, pady=5, sticky='w') self.city_lab = Label(self, text="Miejscowość") self.city_lab.grid(row=3, column=0, padx=5, pady=5, sticky='e') self.city = Entry(self, width=20) self.city.grid(row=3, column=1, columnspan=2, padx=5, pady=5, sticky='w') self.zip_code_lab = Label(self, text="Kod") self.zip_code_lab.grid(row=3, column=2, padx=5, pady=5, sticky='e') self.zip_code = Entry(self, width=7) self.zip_code.grid(row=3, column=3, padx=5, pady=5, sticky='w') self.address_lab = Label(self,text="Adres") self.address_lab.grid(row=4, column=0, padx=5, pady=5, sticky='e') self.address = Entry(self) self.address.grid(row=4, column=1, columnspan=2, padx=5, pady=5, sticky='w') self.same = Button(self, text="Adres jak wyżej") self.same.grid(row=4, column=2, columnspan=2) self.application_subject_lab = Label(self, text=" Wniosek o") self.application_subject_lab.grid(row=6, column=0, padx=5, pady=5, sticky='e') self.application_subject = Combobox(self, width=40, values=application) self.application_subject.grid(row=6, column=1, columnspan=3, padx=5, pady=5) self.application_subject.bind('<<ComboboxSelected>>', self.choosed_subject) self.application_reason_lab = Label(self, text="Z uwagi na") self.application_reason_lab.grid(row=7, column=0, padx=5, pady=5, sticky='e') self.application_reason = Combobox(self, width=40, postcommand=self.get_reason, exportselection=False) self.application_reason.bind('<<ComboboxSelected>>', self.clear_all_selection) self.application_reason.grid(row=7, column=1, columnspan=3, padx=5, pady=5) self.application_reason2_lab = Label(self, text="Z uwagi na") self.application_reason2_lab.grid(row=8, column=0, padx=5, pady=5, sticky='e') self.application_reason2 = Combobox(self, width=40, values=reasons) self.application_reason2.bind('<<ComboboxSelected>>', self.clear_all_selection) self.application_reason2.grid(row=8, column=1, columnspan=3, padx=5, pady=5) self.timespan_lab = Label(self, text="Na okres") self.timespan_lab.grid(row=9, column=0, padx=5, pady=5, sticky='e') self.timespan = Combobox(self, values=timespan) self.timespan.bind('<<ComboboxSelected>>', self.clear_all_selection) self.timespan.grid(row=9, column=1, pady=5, padx=5, sticky='w') self.timespan_ind = Entry(self, width=18) self.timespan_ind.grid(row=9, column=2, columnspan=2, padx=5, pady=5, sticky='w')
def __init__(self, master, tp=None, name='Load TP -> Select Pinref'): ''' Constructor ''' Labelframe.__init__(self, master) self.name = name self.tp = tp self.tree = Treeview(self) self.tree.pack(fill=BOTH, expand=True) self.config(width=400, height=300, relief=RIDGE, text='Pin Definitions', padding=10) # self.tree.bind('<<TreeviewSelect>>', self.show_pinss) # self.pin_view = Labelframe(self) self.pins = {} self.pingroups = {} self.load()
def __init__(self, master, tp=None, name='No TP Loaded'): ''' Constructor ''' Labelframe.__init__(self, master) self.name = name self.tp = tp self.tree = Treeview(self) self.tree.pack(fill=BOTH, expand=True) self.config(width=200, height=200, relief=RIDGE, text='Test Program', padding=10) self.tree.bind('<<TreeviewSelect>>', self.show_params) self.param_view = Labelframe(self) self.pins_view = Labelframe(self) self.params = {} self.pins = {} self.load()
def __init__(self, window, base, **kwargs): Labelframe.__init__(self, window, **kwargs) self.base = base self.notebook = Notebook(self) self.notebook.grid(row=0, column=0, padx=5, pady=5) self.student = Frame(self.notebook) self.student.grid(row=0, column=0) self.student_list = Treeview(self.student, height=24, columns=("name", "pesel"), displaycolumns="name") self.student_list.heading('name', text="Nazwisko i imię", anchor='w') self.student_list.column('name', width=240) self.student_list['show'] = 'headings' self.student_list.grid(row=0, column=0) self.button = Button(self.student, text="Usuń", command=self.delete_from_student_list) self.button.grid(row=1, column=0) self.staff_meeting = Frame(self.notebook) self.staff_meeting.grid(row=0, column=0) self.table = Treeview(self.staff_meeting, height=24, columns=("name", "id", "student_id"), displaycolumns="name") self.table.heading('name', text='Zespoły', anchor='w') self.table.column('name', width=235) self.table.column('#0', stretch=0, width=10) self.table.grid(row=0, column=0) self.delete_staffmeeting = Button( self.staff_meeting, text="Usuń wpis", command=self.delete_from_staffmeeting) self.delete_staffmeeting.grid(row=1, column=0) self.notebook.add(self.student, text="Dzieci") self.notebook.add(self.staff_meeting, text="Zespoły")
def __init__(self, window, base, **kwargs): Labelframe.__init__(self, window, **kwargs) self.base = base self.pesel_string = StringVar() self.pesel_string.set('') self.pesel_string.trace('w', lambda *args: self.pesel_validation()) self.birth_date = "" self.name_of_student_n_lab = Label(self, text="Imię i nazwisko (m)") self.name_of_student_n_lab.grid(row=0, column=0, sticky='e', padx=5, pady=5) self.name_of_student_n_entry = Entry(self, width=41) self.name_of_student_n_entry.grid(row=0, column=1, columnspan=3, padx=5, pady=5, sticky='w') self.name_of_student_g_lab = Label(self, text="Imię i nazwisko (d)") self.name_of_student_g_lab.grid(row=1, column=0, sticky='e', padx=5, pady=5) self.name_of_student_g_entry = Entry(self, width=41) self.name_of_student_g_entry.grid(row=1, column=1, columnspan=3, padx=5, pady=5, sticky='w') self.pesel_lab = Label(self, text="PESEL") self.pesel_lab.grid(row=2, column=0, sticky='e', padx=5, pady=5) self.pesel_entry = Entry(self, textvariable=self.pesel_string, width=12) self.pesel_entry.grid(row=2, column=1, sticky='w', padx=5, pady=5) self.id_of_student = Label(self, text="Teczka") self.id_of_student.grid(row=2, column=2, padx=5, pady=5, sticky='e') self.id_of_student_entry = Entry(self, width=7) self.id_of_student_entry.grid(row=2, column=3, padx=5, pady=5) self.birth_place_lab = Label(self, text="Miejsce urodzenia") self.birth_place_lab.grid(row=3, column=0, sticky='e', padx=5, pady=5) self.birth_place_entry = Entry(self, width=25) self.birth_place_entry.grid(row=3, column=1, sticky='w', padx=5, pady=5) self.city_of_student_lab = Label(self, text="Miejscowość") self.city_of_student_lab.grid(row=4, column=0, sticky='e', padx=5, pady=5) self.city_of_student_entry = Entry(self, width=25) self.city_of_student_entry.grid(row=4, column=1, sticky='w', padx=5, pady=5) self.zip_code_of_student_lab = Label(self, text="Kod") self.zip_code_of_student_lab.grid(row=4, column=2, padx=5, pady=5, sticky='e') self.zip_code_of_student_entry = Entry(self, width=7) self.zip_code_of_student_entry.grid(row=4, column=3, padx=5, pady=5) self.address_of_student_lab = Label(self, text="Adres dziecka") self.address_of_student_lab.grid(row=5, column=0, sticky='e', padx=5, pady=5) self.address_of_student_entry = Entry(self, width=25) self.address_of_student_entry.grid(row=5, column=1, sticky='w', padx=5, pady=5) self.sort_of_school_lab = Label(self, text="Rodzaj szkoły") self.sort_of_school_lab.grid(row=6, column=0, sticky='e', padx=5, pady=5) self.sort_of_school_box = Combobox(self, postcommand=self.list_of_sorts, exportselection=False) self.sort_of_school_box.bind("<<ComboboxSelected>>", self.clear_all_selection) self.sort_of_school_box.grid(row=6, column=1, sticky='w', padx=5, pady=5) self.school_lab = Label(self, text="Szkoła:") self.school_lab.grid(row=7, column=0, sticky='e', padx=5, pady=5) self.school = Combobox(self, width=40, postcommand=self.list_of_schools, exportselection=False) self.school.grid(row=7, column=1, columnspan=4, sticky='w', padx=5, pady=5) self.school.bind("<<ComboboxSelected>>", self.list_of_schools()) self.profession_lab = Label(self, text="Zawód") self.profession_lab.grid(row=8, column=0, sticky='e', padx=5, pady=5) self.profession_entry = Entry(self, width=25) self.profession_entry.grid(row=8, column=1, sticky='w', padx=5, pady=5) self.class_lab = Label(self, text="Klasa") self.class_lab.grid(row=8, column=2, padx=5, pady=5, sticky='e') self.class_entry = Entry(self, width=7) self.class_entry.grid(row=8, column=3)