use warnings; use Tk; use Tk::Pane; $mw = new MainWindow; $mw -> geometry("500x500"); $outerPane = $mw -> Scrolled("Pane", -scrollbars => 's') -> pack(-fill => "both", -expand => 1); $blueBar = $outerPane -> Frame(-background => "light blue", -height => 40, -width => 500) -> pack(); $innerPane = $outerPane -> Scrolled("Pane", -scrollbars => 'w') -> pack(-fill => "both", -expand => 1); $greenBar = $innerPane -> Frame(-background => "light green", -width => 40, -height => 500) -> pack(-fill => "y"); MainLoop();