use Tk; #================ Haupffenster =================== $HF = new MainWindow (-title => "Test"); $HF->geometry('200x200'); $HF->geometry('+10+10'); #================ Frames ======================= $Fr1 = $HF -> Frame ( -width => 200, -height => 100, ); $Fr1->place(-x=> 0, -y=> 0); #================ Labels ======================= $Lbl1 = $Fr1->Label ( -text => "Überschrift", -bg => white, -width => 32, ); $Lbl1->place(-x=> 0, -y=> 0); $Lbl2 = $Fr1->Label ( -bg => red, -width => 100, -height => 92, ); $Lbl2->place(-x=> 0, -y=> 20); #================ Button ======================= $Bttn1 = $Lbl2->Button ( -text=>"Testbutton", -bg => grey, -width => 32, -height => 2, ); $Bttn1->place(-x=> 0, -y=> 0); #================ Canvas ======================= $Can1 = $HF -> Canvas ( -bg => green, -width => 200, -height => 50, ); $Can1->place(-x=> 0, -y=> 90); #================ TK-Abschluss ================== MainLoop();