# -Q2.F.10- find my invisible windows when using the packer?

    From: -II-  Tk Questions and Answers - How can I:

    A2.F.10.  The situation:
      A window is created, say .w1, followed by another window, say .w2.
      The command "pack .w1 -in -.w2" is used to pack .w1 inside of .w2.
      The pack command completes successfully, and "pack newinfo .w1"
      indicates that things are as expected.  However, .w1 isn't visible!
      Where is it?
                button .w1 -text button;   # create .w1
                frame .w2;                 # create .w2
                pack .w1 -in .w2;          # pack .w1 inside .w2
                pack .w2;                  # pack .w1 in main window
                                           # where's the button?

      The explanation:
      (based on a posting by js@aelfric.bu.edu (Jay Sekora))

      The short answer is "raise .w1".  In the example .w1 is positioned
      properly inside .w2, and all the sizing glue that lets .w1 and .w2
      adjust their sizes based on each other will work, but .w1 is
      _underneath_ .w2, because windows are stacked in the order they're
      created in, by default.  You can change the stacking order
      explicitly with the "raise" command, in this case "raise .w1".

Parent document is top of "FAQ: comp.lang.tcl Tk Toolkit Usage Questions And Answers (1/1)"
Previous document is "-Q2.F.9- change the default colors in Tk?"
Next document is "-Q2.F.11- destroy every window except '.'?"