Generic Function | Package: cg | ToC | DocOverview | CGDoc | RelNotes | FAQ | Index | PermutedIndex
| Allegro CL version 10.1 Unrevised from 10.0 to 10.1. 10.0 version

## set-default-button

Arguments: button-widget

Changes which button on a dialog is invoked by pressing the ENTER key (i.e. the default button). button must be an instance of class `button` already on a dialog (and it is that dialog whose default button is changed). An error is signaled if button is not on a dialog. The new default button will be drawn with a thick black border.

If the specified button is already the acting default button of its parent window, then nothing is done and `nil` is returned. Otherwise the specified button becomes the acting default button and a non-`nil` value is returned.

If a button of class `default-button` exists on the dialog, it will be the initial default button. This function is used to change the default button dynamically.

Note: following Windows environment practice, if the user gives the keyboard focus to any push button (the keyboard focus is shown by a thin dotted line about the button), that button is invoked by pressing ENTER or the Space Bar. This is regardless of whether it is the default button or not. ENTER will again invoke the default button when the keyboard focus moves away from any button.

Copyright (c) 1998-2022, Franz Inc. Lafayette, CA., USA. All rights reserved.
This page was not revised from the 10.0 page.
Created 2019.8.20.

|  | ToC | DocOverview | CGDoc | RelNotes | FAQ | Index | PermutedIndex
| Allegro CL version 10.1 Unrevised from 10.0 to 10.1. 10.0 version