getFont ?-prompt str? ?-sample str? ?-title str? ?-defaut font?
Prompt the user to select a font and a size. The command also displays the system font panel: fonts are selected in the font panel and echoed in the dialog. Press the OK button to end up the selection and validate the choice. The returned value is a font specification (i-e a Tcl dictionary with name and size keys), or an error if the Cancel button was pressed.
The
-prompt option specifies a text to display at the top of the dialog. If it is not specified, a default string is used.
The
-title option specifies a title for the dialog. By default, there is no title.
The
-sample option specifies a string to use as sample text. This sample text is displayed using the currently selected font: each time the user changes the font in the font panel, the sample field is updated.
The
-default option specifies a default font to display as a suggestion in the dialog. If it is not specified, the default font preference is used.