Пример #1
0
 def about_license_clicked(self):
     about = tix.Toplevel()  # bg="#0f0" does not work
     about.title("License")
     about.resizable(width=False, height=False)
     set_window_icon(about)
     about.bind('<Escape>', lambda e: about.destroy())
     ###
     msg1 = tix.Message(
         about,
         width=420,
         text=licenseText,
         font=("DejaVu Sans", 9, "bold"),
     )
     msg1.pack(fill="x", expand=True)
     ###########
     frame = tix.Frame(about)
     closeB = ttk.Button(
         frame,
         text="Close",
         command=about.destroy,
         # bg="#ff0000",
         # activebackground="#ff5050",
     )
     closeB.pack(side="right")
     frame.pack(fill="x")
Пример #2
0
 def about_credits_clicked(self):
     about = tix.Toplevel()  # bg="#0f0" does not work
     about.title("Credits")
     about.resizable(False, False)
     set_window_icon(about)
     ###
     msg1 = tix.Message(
         about,
         width=500,
         text="\n".join(authors),
         font=("DejaVu Sans", 9, "bold"),
     )
     msg1.pack(fill="x", expand=True)
     ###########
     frame = tix.Frame(about)
     closeB = tix.Button(
         frame,
         text="Close",
         command=about.destroy,
         # bg="#ff0000",
         # activebackground="#ff5050",
     )
     closeB.pack(side="right")
     frame.pack(fill="x")
Пример #3
0
 def about_license_clicked(self):
     about = tix.Toplevel()  ## bg='#0f0' does not work
     about.title('License')
     about.resizable(False, False)
     about.wm_iconbitmap('@%s' % xbmLogo)
     ###
     msg1 = tix.Message(
         about,
         width=420,
         text=licenseText,
         font=('DejaVu Sans', 9, 'bold'),
     )
     msg1.pack(fill='x', expand=True)
     ###########
     frame = tix.Frame(about)
     closeB = tix.Button(
         frame,
         text='Close',
         command=about.destroy,
         #bg='#ff0000',
         #activebackground='#ff5050',
     )
     closeB.pack(side='right')
     frame.pack(fill='x')
Пример #4
0
 def about_credits_clicked(self):
     about = tix.Toplevel()  ## bg='#0f0' does not work
     about.title('Credits')
     about.resizable(False, False)
     set_window_icon(about)
     ###
     msg1 = tix.Message(
         about,
         width=500,
         text='\n'.join(authors),
         font=('DejaVu Sans', 9, 'bold'),
     )
     msg1.pack(fill='x', expand=True)
     ###########
     frame = tix.Frame(about)
     closeB = tix.Button(
         frame,
         text='Close',
         command=about.destroy,
         #bg='#ff0000',
         #activebackground='#ff5050',
     )
     closeB.pack(side='right')
     frame.pack(fill='x')
Пример #5
0
 def about_clicked(self):
     about = tix.Toplevel(width=600)  # bg="#0f0" does not work
     about.title("About PyGlossary")
     about.resizable(False, False)
     set_window_icon(about)
     ###
     msg1 = tix.Message(
         about,
         width=350,
         text="PyGlossary %s (Tkinter)" % VERSION,
         font=("DejaVu Sans", 13, "bold"),
     )
     msg1.pack(fill="x", expand=True)
     ###
     msg2 = tix.Message(
         about,
         width=350,
         text=aboutText,
         font=("DejaVu Sans", 9, "bold"),
         justify=tix.CENTER,
     )
     msg2.pack(fill="x", expand=True)
     ###
     msg3 = tix.Message(
         about,
         width=350,
         text=homePage,
         font=("DejaVu Sans", 8, "bold"),
         fg="#3333ff",
     )
     msg3.pack(fill="x", expand=True)
     ###
     msg4 = tix.Message(
         about,
         width=350,
         text="Install PyGTK to have a better interface!",
         font=("DejaVu Sans", 8, "bold"),
         fg="#00aa00",
     )
     msg4.pack(fill="x", expand=True)
     ###########
     frame = tix.Frame(about)
     ###
     button = tix.Button(
         frame,
         text="Close",
         command=about.destroy,
         # bg="#ff0000",
         # activebackground="#ff5050",
     )
     button.pack(side="right")
     ###
     button = tix.Button(
         frame,
         text="License",
         command=self.about_license_clicked,
         # bg="#00e000",
         # activebackground="#22f022",
     )
     button.pack(side="right")
     ###
     button = tix.Button(
         frame,
         text="Credits",
         command=self.about_credits_clicked,
         # bg="#0000ff",
         # activebackground="#5050ff",
     )
     button.pack(side="right")
     ###
     frame.pack(fill="x")
Пример #6
0
 def about_clicked(self):
     about = tix.Toplevel(width=600)  ## bg='#0f0' does not work
     about.title('About PyGlossary')
     about.resizable(False, False)
     about.wm_iconbitmap('@%s' % xbmLogo)
     ###
     msg1 = tix.Message(
         about,
         width=350,
         text='PyGlossary %s (Tkinter)' % VERSION,
         font=('DejaVu Sans', 13, 'bold'),
     )
     msg1.pack(fill='x', expand=True)
     ###
     msg2 = tix.Message(
         about,
         width=350,
         text=aboutText,
         font=('DejaVu Sans', 9, 'bold'),
         justify=tix.CENTER,
     )
     msg2.pack(fill='x', expand=True)
     ###
     msg3 = tix.Message(
         about,
         width=350,
         text=homePage,
         font=('DejaVu Sans', 8, 'bold'),
         fg='#3333ff',
     )
     msg3.pack(fill='x', expand=True)
     ###
     msg4 = tix.Message(
         about,
         width=350,
         text='Install PyGTK to have a better interface!',
         font=('DejaVu Sans', 8, 'bold'),
         fg='#00aa00',
     )
     msg4.pack(fill='x', expand=True)
     ###########
     frame = tix.Frame(about)
     ###
     button = tix.Button(
         frame,
         text='Close',
         command=about.destroy,
         #bg='#ff0000',
         #activebackground='#ff5050',
     )
     button.pack(side='right')
     ###
     button = tix.Button(
         frame,
         text='License',
         command=self.about_license_clicked,
         #bg='#00e000',
         #activebackground='#22f022',
     )
     button.pack(side='right')
     ###
     button = tix.Button(
         frame,
         text='Credits',
         command=self.about_credits_clicked,
         #bg='#0000ff',
         #activebackground='#5050ff',
     )
     button.pack(side='right')
     ###
     frame.pack(fill='x')