Example #1
0
	def fillButton(self):
		yawTtk.Button(self.buttonframe, font=("tahoma", 8, "bold"), image=Dialog.cross16, compound="image",
		              background=self.background, style="Dialog.TButton", text="Cancel", width=-1,
		              command=self.destroy).pack(side="right")
		yawTtk.Button(self.buttonframe, font=("tahoma", 8, "bold"), image=Dialog.tick16, compound="left",
		              background=self.background, style="Dialog.TButton", default="active", text="Sign transaction", width=-1,
		              command=self.link).pack(side="right", padx=self.border)
		b = yawTtk.Button(self.buttonframe, image=Dialog.stop16, compound="left", text="Show",
		                  background=self.background, style="Dialog.Toolbutton", padding=(self.border, 0))
		b.pack(side="left", fill="y")
		b.bind("<ButtonPress>", lambda e,o=self: [o.secret.configure(show=""), o.secondsecret.configure(show="")])
		b.bind("<ButtonRelease>", lambda e,o=self: [o.secret.configure(show="-"), o.secondsecret.configure(show="-")])
Example #2
0
    def __init__(self, master=None, cnf={}, **kw):
        yawTtk.Frame.__init__(self, master, cnf={}, **kw)
        self.rowconfigure(6, weight=1)
        #
        yawTtk.Label(self,
                     padding=2,
                     text="recipientId",
                     background="lightgreen",
                     font=("tahoma", 8, "bold")).grid(row=0,
                                                      column=0,
                                                      columnspan=3,
                                                      padx=4,
                                                      pady=4,
                                                      sticky="nesw")
        self.recipientId = yawTtk.Combobox(self).grid(row=1,
                                                      column=0,
                                                      columnspan=3,
                                                      padx=4,
                                                      pady=4,
                                                      sticky="nesw")
        #
        yawTtk.Label(self,
                     padding=2,
                     text="vendorField",
                     background="lightgreen",
                     font=("tahoma", 8, "bold")).grid(row=2,
                                                      column=0,
                                                      columnspan=3,
                                                      padx=4,
                                                      pady=4,
                                                      sticky="nesw")
        self.vendorField = yawTtk.Entry(self).grid(row=3,
                                                   column=0,
                                                   columnspan=3,
                                                   padx=4,
                                                   pady=4,
                                                   sticky="nesw")
        #
        self.amount = AmountFrame(self,
                                  padding=(4, 0, 4, 4),
                                  address=AddressPanel.address).grid(
                                      row=5,
                                      column=0,
                                      columnspan=3,
                                      sticky="nesw")
        #
        frame = yawTtk.Frame(self, padding=4, text="Send").grid(row=6,
                                                                column=0,
                                                                columnspan=3,
                                                                sticky="esw")
        yawTtk.Separator(frame).pack(side="top", fill="x", pady=8)
        self.button = yawTtk.Button(frame, text="Send").pack(side="right")

        self.update()
        self.amount.value.trace("w", self.update)
Example #3
0
	def __init__(self, master=None, cnf={}, **kw):
		yawTtk.Frame.__init__(self, master, cnf={}, **kw)
		self.columnconfigure(0, weight=1)
		self.rowconfigure(6, weight=1)

		self.username = yawTtk.StringVar(self, "", "vote.username")
		#
		yawTtk.Label(self, padding=2, text="delegate", background="lightgreen", font=("tahoma", 8, "bold")).grid(row=0, column=0, columnspan=3, padx=4, pady=4, sticky="nesw")
		self.delegate = yawTtk.Combobox(self, values=tuple(d["username"] for d in AddressPanel.candidates), textvariable="vote.username").grid(row=1, column=0, columnspan=3, padx=4, pady=4, sticky="nesw")
		#
		frame = yawTtk.Frame(self, padding=4, text="Send").grid(row=6, column=0, sticky="esw")
		yawTtk.Separator(frame).pack(side="top", fill="x", pady=8)
		self.button = yawTtk.Button(frame, text="").pack(side="right")

		self.update()
		@setInterval(2)
		def _update(obj): obj.update()
		self.__stop_update = _update(self)