Bog'liq [Nichola Lacey] Python by Example Learning to Pro(1)
entry_box = Entry (text = 0) Creates a blank entry box. Entry boxes can be used by
the user to input data or used to display output.
output_box = Message(text = 0) Creates a message box which is used to display an
output.
list_box = Listbox() Creates a drop-down list box
which can only contain strings.
button1 = Button(text = “Click here”, command = click) Creates a button that will run the subprogram “click”.
output_box [“bg”] = “red” Specifies the background colour of the
object.
output_box [“fg”] = “white” Specifies the font colour of the object.
output_box [“relief”] = “sunken” Specifies the style of the box. This can be flat,
raised, sunken, grooved and ridged.
entry_box [“justify”] = “center” Specifies the justification of the text in an entry box,
but this does not work for message boxes.