Tkinter - Make status bar longer than window
<p>I was working on a Tkinter GUI with a status bar at the bottom to display instructions or the file paths on hover over a specific widget, especially if the file path was too long to write in the given section. Is there any way that the status bar could extends past the window in the case of a long name? (Like maybe a window without the top bar?)</p>

<p>The status bar is cut off at the end: 
<a href="http://i.stack.imgur.com/hzAt2.png" rel="nofollow"><img src="http://i.stack.imgur.com/hzAt2.png" alt="Status bar is cut off"></a></p>

<p>What I want the status bar to look like:
<a href="http://i.stack.imgur.com/d9IU3.jpg" rel="nofollow"><img src="http://i.stack.imgur.com/d9IU3.jpg" alt="enter image description here"></a></p>

<p>I've seen other applications where the status bar can extend past the window but I was wondering if that was possible in Tkinter. Any help would be appreciated!</p>

<p>Yes, it's possible:</p>

<pre><code>from tkinter import *
root = Tk()
root.geometry("800x500-500+50")
root.config(bg="lightblue")

stslabel = Label(root, anchor=W, 
              text="Process another input file to get citations. blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah"
              )
stslabel.pack(fill=X, side=BOTTOM)
</code></pre>

<p>All you need to do is using the most proper geometry manager (<code>pack</code> in this case) for the <code>label</code> widget that is intended to show a status (<code>ststlabel</code>); then adding some options to the geometry manager: <code>fill</code> makes it extended as you stretch the window horizontally; and <code>side</code> puts it at the very bottom of the screen which means it will always stay there (until you make the geometry of any of preceding widgets to bottom. Otherwise, it'll be replaced with that).</p>

<p>Now we got it! But there is a problem that it doesn't show the beginning of the status text. To solve this add an <code>anchor</code> option to the status label and change its value to <code>W</code> since we want to see the beginning (the most left side) of the text. And <code>W</code> which stands for "West", <i>does</i> it.</p>

python tkinter