sscasc@tumkur framea frame is similar to canvasbut it can hold components of forms to create framewe can create an object of frame class as fframe(rootheight= ,width= ,bg="yellow",cursor="crosshere'fis an object of class framethe options height and width reprsents the area of frame in pixels'bgrepresents the back ground color to be displayed and 'cursorindicates the type of the cursor to be displayed in the frame once the frame is createdit should be added to the root window using the pack(method widgetsform elementswidgets is gui component that is displayed on the screen and can perform task as designed by the user the widgets are button label text box message checkbox list box option button scroll bars menus steps to create widgets create widget object =button(ftext="submit" define the event performed by the widget def buttonclick(selfprint("you have clicked submit button" clicking event should be linked with the callback handler bind(''buttonclick call event loop root mainloop( buttona push button is component that performs some action when clicked these buttons are created as objects of button class asb=button(ftext="ok"width= ,height= bg="yellow"fg="blue"here'bis the object of button class'frepresents the frame for which the button is created as child the 'textoption represents the text to be display on the buttonwidth and height represents the size of the button'bgrepresents the background color and 'fgrepresents the fore ground color of the buttonb bind(""buttonclickwe link the mouse left button with the buttonclick)method using bind()method texta text widget is same as label but text widget has several options and can display multiple lines of text in different colors and fonts it is possible to insert text into text widgetmodify it or delete it we can also display images in the text widget text is created as an object of text class ast=text( ,width= height= font=('times', ,'italic')fg='blue'bg="yellow"wrap=wordhere'tis the object of text class'frepresents the frame for which the text is created as child the width and height represents the size of the text box'bgrepresents the background color and 'fgrepresents the fore ground color of the text'font represents tuple that contains font namesize and style the 'wraprepresents the text information can be align with in the text box labela label represents the constant text that is displayed in the frame or container label can display one or more lines of text that cannot be modified label is created as an object of label class asl=label(ftext=label fg='blue',bg='yellow'sp_python programming demo",width= ,height= font=('times', ,'bold')