本文整理匯總了Python中tk_tools.TK_ROOT.geometry方法的典型用法代碼示例。如果您正苦於以下問題:Python TK_ROOT.geometry方法的具體用法?Python TK_ROOT.geometry怎麽用?Python TK_ROOT.geometry使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類tk_tools.TK_ROOT
的用法示例。
在下文中一共展示了TK_ROOT.geometry方法的2個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Python代碼示例。
示例1: Item
# 需要導入模塊: from tk_tools import TK_ROOT [as 別名]
# 或者: from tk_tools.TK_ROOT import geometry [as 別名]
break
else: # Not found
self.suggested = None
if self.suggested is not None:
self.set_context_font(
self.suggested,
font=self.sugg_font,
)
self.set_disp() # Update the textbox if needed
self.flow_items() # Refresh
if __name__ == '__main__': # test the window if directly executing this file
lbl = ttk.Label(TK_ROOT, text="I am a demo window.")
lbl.grid()
TK_ROOT.geometry("+500+500")
test_list = [
Item(
"SKY_BLACK",
"Black",
long_name="Darkness",
icon="skies/black",
authors=["Valve"],
desc=[
('line', 'Pure black darkness. Nothing to see here.'),
],
),
Item(
"SKY_BTS",
"BTS",
示例2: str
# 需要導入模塊: from tk_tools import TK_ROOT [as 別名]
# 或者: from tk_tools.TK_ROOT import geometry [as 別名]
win.after(50, reset_sfx)
widgets['titleLabel'].configure(text='Settings for "' + item_name + '"')
win.title('BEE2 - ' + item_name)
win.transient(master=parent)
win.deiconify()
win.lift(parent)
win.grab_set()
win.geometry(
'+' + str(parent.winfo_rootx() - 30) +
'+' + str(parent.winfo_rooty() - win.winfo_reqheight() - 30)
)
# load the window if directly executing this file
if __name__ == '__main__':
TK_ROOT.geometry('+250+250')
def callback(vals):
for key, value in sorted(vals.items()):
print(key + ' = ' + repr(value))
init(callback)
all_vals = {
'startup': '1',
'toplevel': '4',
'bottomlevel': '3',
'angledpanelanimation': 'ramp_45_deg_open',
'startenabled': '1',
'startreversed': '0',
'startdeployed': '1',
'startactive': '1',