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

## form-package-name

Arguments: form

Returns either a keyword symbol naming the package that is used for source code that is auto-generated for the specified form, or `nil` to default to the project-package-name of the form's project. If all of the forms of a project should be in a single package, then it is better to use project-package-name than this function. The setf of this function may be called to set this value programmatically.

The package that is named either by form-package-name or project-package-name is used at the time that source code for a form is auto-generated. There are two cases of this: (1) Whenever a form is saved, the .bil file is generated in its entirety, and contains the finder-function and maker-function that an application may call to create the running window of a form. The names of these functions will be in the package that's in effect for the form when it was last saved. (2) The first time that you click in the inspector on the small button at the right side of an event-handler property for a widget that's on a form, a new .cl source code file for the form will be created to hold auto-generated skeleton code for a new event-handler function. This file will have an in-package expression at the top that uses the package that's currently in effect for the form. If this happens before you have set the form's package as you want, you can simply edit this in-package expression later.

A package mismatch may occur when changing a form's package if event-handler functions have already been defined for widgets on the form. The reason is that the references to the functions in the form's auto-generated .bil file will now be in the new package, though the definitions of the functions in the associated .cl file will still be in the old package. So it is generally a good idea when changing a form's package to also edit the .cl file so that it is in the same package. The .cl is loaded into an Editor buffer when you click the View Selected Code button on the Project Manager Dialog. (The change to the .cl is not done automatically because this file is not auto-generated as a whole, and so it may not be appropriate for any in-package forms in the file to automatically be modified.)

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