I am trying to add the "Open File" tab in my user interface. It works fine, but the line --------- displayed at the top of the tab, and I want to delete it. I do not know why this line appears, and I cannot find the line in the code.

This is my code:
# -*- coding: utf-8 -*- from Tkinter import * import Image import ImageTk import tkFileDialog class Planificador(Frame): def __init__(self,master): Frame.__init__(self, master) self.master = master self.initUI() def initUI(self): self.master.title("test") menubar = Menu(self.master, tearoff=0) self.master.config(menu=menubar) fileMenu = Menu(menubar) fileMenu.add_command(label="Open config file", command=self.onOpen) menubar.add_cascade(label="File", menu=fileMenu) fileMenu.add_separator() fileMenu.add_command(label="Exit", command=root.quit) self.txt = Text(self) self.txt.pack(fill=BOTH, expand=1) def onOpen(self): ftypes = [('Python files', '*.py'), ('All files', '*')] dlg = tkFileDialog.Open(self, filetypes = ftypes) fl = dlg.show() if fl != '': text = self.readFile(fl) self.txt.insert(END, text) def readFile(self, filename): f = open(filename, "r") text = f.read() return text
I would like to know where I can remove this ------- from the code.
thanks in advance
source share