title: Python3: Class (or static) variable definition relative to another
body: <p>On Ubuntu MATE 17.04 
  Python: 3.5</p>
  
  <p>I'm sublassing a ttk Button:</p>
  
  <pre><code>import tkinter as tk
  import tkinter.ttk as ttk
  
  class ImgButton(ttk.Button):
      """
      Button for holding an image
      """
      IMG_NAME = 'filename{}.jpg'
      IMAGES_DIR = os.path.sep + os.path.sep.join(['home', 'user', 'MyProjects', 'myProject', 'resources', 'images'])
      UNKNOWN_IMG = os.path.sep.join([IMAGES_DIR, IMG_NAME.format(0)])
      IMAGES = [os.path.sep.join([IMAGES_DIR, IMG_NAME.format(i)]) for i in [1,2,3,4,5,6]]
  
      # ... more code... You can add an empty __init__() if you like so
  
  if __name__ == '__main__':
      root = tk.Tk()
      ImgButton(root).pack()
  </code></pre>
  
  <p>When using the button it gives me an error:</p>
  
  <pre><code>NameError: name 'IMAGES_DIR' is not defined
  </code></pre>
  
  <p>How is it possible that UNKNOWN_IMAGE has no problem using the IMAGES_DIR variable and IMAGES raises this error???</p>
  
  <p>I'm shocked with this. Do I need some static initializer? Do I need to refer to he variable in another way? In the former line it worked with nothing. And I tried ImgButton.IMAGES_DIR and it doesn't work. </p>
  
  <p>How should I solve this problem? And the most important thing, what am I doing wrong?</p>