Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
503 views
in Technique[技术] by (71.8m points)

python - 删除笔记本电脑标签上的虚线(Remove dotted line around notebook tab tkinter)

I have recently being trying to make pokedex using tkinter python and I was going well with it but a problem occurred, which made the whole interface ugly!

(我最近正在尝试使用tkinter python制作pokedex,但效果很好,但是出现了问题,这使整个界面很难看!)

There is a dotted border which is coming in every active button and notebook tab which is spoiling look of the whole program.

(每个活动按钮和笔记本选项卡上都有一个虚线边框,破坏了整个程序的外观。)

NOTE: I tried using focuscolor but it didn't help...

(注意:我尝试使用focuscolor,但没有帮助...)

import tkinter as tk
from tkinter.ttk import *

root = tk.Tk()
root.geometry('700x500')

Style().configure('lefttab.TNotebook', tabposition='wn')
Style().configure('TNotebook.Tab', font='Courier 16')

notebook = Notebook(root, style='lefttab.TNotebook')
f1 = tk.Frame(notebook, width=500, height=400)
f2 = tk.Frame(notebook, width=500, height=400)

notebook.add(f1, text='Kantodex Vx')
notebook.add(f2, text='  Attacks  ')

notebook.pack(anchor=tk.NW)

root.mainloop()
  ask by Hardik Jain translate from so

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Answer

0 votes
by (71.8m points)
等待大神答复

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...