1
0
mirror of synced 2026-01-12 00:42:56 +00:00

MODERNIZE SKETCH WINDOWS

Fix MODERNIZE, SKETCH, and GRAPHER so that modernization happens whether MODERNIZE is loaded before or after the other packages
This commit is contained in:
rmkaplan 2021-03-15 13:04:02 -07:00
parent 9156590679
commit a297686908
7 changed files with 10 additions and 18 deletions

File diff suppressed because one or more lines are too long

Binary file not shown.

File diff suppressed because one or more lines are too long

Binary file not shown.

File diff suppressed because one or more lines are too long

Binary file not shown.

View File

@ -17,17 +17,6 @@ For top corners, "near" means within the title bar and within the margin from th
(Windows that don't have a title-bar, like Snap windows, can be set up so that moving can happen by clicking anywhere, and shaping at the top is determined by the margin inside the window region.)
When the package is loaded, this behavior is installed for the following kinds of windows:
Tedit
Debugger/break
Sedit
Inspector
Snap
Exec
File Browser
Grapher
The function MODERNWINDOW.SETUP establishes the new behavior for classes of windows:
(MODERNWINDOW.SETUP ORIGFN MODERNWINDOWFN ANYWHERE)
@ -44,7 +33,7 @@ If the flag ANYWHERE is non-NIL, especially for windows without a title bar, the
Because this works by redefining existing functions, it is important that the MODERNIZE package be loaded AFTER Tedit and Sedit, if those are not already in the sysout. And it should be called to upgrade the proper functions for other window classes that might later be added.
Provided these capabilities are already loaded, the following window classes are "modernized" when MODERNIZE is loaded are:
The following window classes are modernized if they are already in the sysout when MODERNIZE is loaded:
TEDIT
SEDIT
@ -57,6 +46,9 @@ Provided these capabilities are already loaded, the following window classes are
FREEMENU
GRAPHER
PROMPTWINDOW
SKETCH
MODERNIZE by itself can take no action for packages that are not already present. Packages that may be loaded after MODERNIZE are responsible for their own set up. This can be done simply by adding a P command to such a package that executes the proper call to MODERNWINDOW.SETUP when MODERNWINDOW.SETUP is defined.
If it is not known or it is inconvenient to systematically upgrade a button function or a window-creation function, the new behavior can be provided after a particular window has been created, by invoking