home *** CD-ROM | disk | FTP | other *** search
/ Amiga ISO Collection / AmigaUtilCD2.iso / Misc / CBMDevKit1.dms / CBMDevKit1.adf / tutorials.lha / tutorials / V39_Intuition < prev    next >
Encoding:
Text File  |  1993-11-04  |  49.9 KB  |  1,008 lines

  1.                 Intuition 3.0
  2.      (c) Copyright 1991-93 Commodore-Amiga, Inc.  All Rights Reserved
  3.  
  4.  
  5. Graphics and AA-Chipset Issues
  6.  
  7. Support for New Modes
  8.  
  9. Intuition now has direct support for the AA display modes, through
  10. extensions to old mechanisms and through new tags.  This includes the
  11. ability to select higher resolutions and to set colors in better than 4
  12. bits-per-gun.  The graphics database and the ASL screen-mode requester
  13. are the definitive places to get information about what modes and
  14. depths are available or desired.  You can specify higher depths using
  15. SA_Depth, and new display modes with SA_DisplayID. SA_Colors32
  16. supplants SA_Colors for specifying colors with a higher precision than
  17. 4 bits-per-gun.  For full details, see the section on new screen
  18. features.
  19.  
  20.  
  21. Mode Promotion
  22.  
  23. The AA chipset provides some flicker-free display modes that are
  24. roughly equivalent to NTSC or PAL when output through a
  25. display-enhancer or flicker-fixing product.  While the AA chipset
  26. provides these modes without the significant extra expense of a
  27. display-enhancer, some software help is required.  Conversely, the
  28. display-enhancer lives on the video output, and is completely
  29. transparent to software.
  30.  
  31. To use promotion, the user needs to have a multiscan monitor.  He needs
  32. to install the DblNTSC or DblPAL monitor into his devs:monitors drawer,
  33. and ensure that the "Mode Promotion" option in IControl Prefs is on
  34. (starting with 3.1, this setting will be on by default, eliminating
  35. this last step). When this is done, the graphics database entries for
  36. the "default" monitor will map to the most appropriate modes from the
  37. DblNTSC (or DblPAL) monitor, in place of the NTSC (or PAL) monitor.
  38.  
  39. Interlaced screens that are promoted are displayed using double-height
  40. non-interlaced modes.  For example, 640x400 NTSC interlaced appears as
  41. 640x400 double-NTSC non-interlaced.  Non-interlaced 15 kHz screens are
  42. promoted using a chipset feature called "scan-doubling," in which each
  43. scan-line is output twice, because the 200 or 256 lines of the original
  44. screen only fill half the screen when in 31 kHz modes.
  45.  
  46. Most applications which use the default monitor (either by explicitly
  47. using mode-IDs such as HIRES_KEY or by using V34-style 16-bit mode
  48. descriptions) and which go through Intuition and have relatively
  49. ordinary display requirements will be successfully and transparently
  50. promoted, and their screen will be displayed flicker-free. Applications
  51. which refer to modes of explicit monitors (e.g., SA_DisplayID of
  52. NTSC_MONITOR_ID|HIRES_KEY) are never promoted.  The preferred method
  53. for an application is to use the ASL screen-mode requester, which
  54. normally presents all explicit modes (including the modes of DblNTSC
  55. and DblPAL) and omits the modes of the "default" monitor.
  56.  
  57.  
  58. Promotion and Compatibility
  59.  
  60. De-interlacing in hardware is expensive but transparent, since the
  61. Amiga chipset's operation is unchanged by the presence of such
  62. hardware. However, promotion can change the behavior of the system in a
  63. manner which may be incompatible with certain applications.  These are:
  64.  
  65.    o  The overscan limits of DblNTSC (DblPAL) are a little less than
  66. the overscan limits of NTSC (PAL).  (For 3.1, the DblNTSC (DblPAL)
  67. limits have been extended and are now comparable to NTSC (PAL)).
  68.  
  69.    o  It may be harder to center a DblNTSC (DblPAL) screen on certain
  70. multiscan monitors than it was to center a de-interlaced NTSC (PAL)
  71. screen.  (3.1 provides additional centering flexibility which
  72. basically solves this problem).
  73.  
  74.    o  An interlaced screen is promoted to a non-interlaced screen,
  75. which has obvious implications on custom copper-lists.
  76.  
  77.    o  The higher resolutions/depths of the AA chipset require higher
  78. alignment restrictions on bitplanes.  Fortunately, most applications
  79. either let Intuition allocate their screen's BitMap or else they have a
  80. custom BitMap whose width is a multiple of 64 pixels (the highest
  81. alignment currently required by AA).  However, if the custom BitMap is
  82. an unusual width, it may not be sufficiently aligned for the hardware.
  83. Such a screen can come up skewed when promoted.
  84.  
  85. "1x" modes require 16-pixel (word boundary) alignment of each scan-line.
  86. "2x" modes require 32-pixel (longword boundary) alignment, while "4x"
  87. modes require 64-pixel (double-longword boundary) alignment.  Here is a
  88. short reference:
  89.  
  90.    o  140 ns pixels (lores in 15 kHz modes, extra-lores in 31 kHz modes)
  91.                 1-8 planes require 1X
  92.    o  70 ns pixels (hires in 15 kHz modes, lores in 31 kHz modes)
  93.                 1-4 planes require 1X
  94.                 5-8 planes require 2X
  95.    o  35 ns pixels (super-hires in 15 kHz modes, hires in 31 kHz modes)
  96.                 1-2 planes require 1X
  97.                 2-4 planes require 2X
  98.                 5-8 planes require 4X
  99.  
  100. As the graphics.library AllocBitMap() function takes care of allocating
  101. suitably-aligned BitMaps for you, you do not need to worry about alignment
  102. when using modern system calls.
  103.  
  104.    o  The AA hardware does not allow dual-playfield non-interlaced
  105. screens to be scan-doubled, so they will appear half as tall as their
  106. non-promoted counterparts.
  107.    o  Like earlier chipsets, the AA chipset still supports eight
  108. sprites. In much the same way as ECS and original chipsets lose sprites
  109. when overscan is increased, many of the new modes have insufficient
  110. spare cycles to fetch data for these sprites.  A promoted screen may
  111. have fewer sprites left than the corresponding 15 kHz mode, meaning
  112. that some sprites other than the pointer sprite may vanish.
  113.    o  There is no 31 kHz mode having 1280 pixels per line.  That would
  114. require 17.5 ns pixel speeds, which is twice what the AA chipset is
  115. capable of. Therefore, SuperHires screens are promoted to 640
  116. pixel-per-line screens, which generally can scroll.
  117.    o  Custom ViewPorts are not promoted, but a graphics-database aware
  118. application could open a ViewPort in DblNTSC or DblPAL.
  119.  
  120.  
  121. Pointer Sprite Features
  122.  
  123. New Pointer Features
  124.  
  125. Intuition's handling of the pointer sprite has undergone significant
  126. rework for V39, partly to add support for AA sprites (35/70/140 ns
  127. sprite pixels, 16/32/64 pixels per sprite, scan-doubling of sprites),
  128. and partly to make some general improvement to Intuition.
  129.  
  130. The Intuition pointer now supports the various new sprite modes of the
  131. AA chipset.  This includes 16, 32, and 64-bit wide sprites, as well as
  132. the sprite-pixel resolution control.
  133.  
  134. Intuition automatically positions the pointer sprite on screen pixel
  135. resolution boundaries, even if the pointer is in a lower resolution,
  136. with the exception that graphics.library only allows positioning the
  137. pointer on every second line of an interlaced screen.
  138.  
  139. For applications, there is a new boopsi class called "pointerclass,"
  140. which is used to create Intuition pointer objects.  The new
  141. <intuition/pointerclass.h|i> include file contains definitions for the
  142. attributes that pointerclass supports, including:
  143.  
  144.    o  POINTERA_BitMap - BitMap to use for sprite imagery
  145.    o  POINTERA_XOffset, POINTERA_YOffset - sprite hot-spot
  146.    o  POINTERA_WordWidth - intended width in words of this pointer
  147.    o  POINTERA_XResolution, POINTERA_YResolution - intended resolution of
  148. this pointer
  149.  
  150. The resolution can be any of the hardware resolutions (ECS-compatible,
  151. 140 ns, 70 ns, or 35 ns), but Intuition also adds software-managed
  152. choices for
  153.  
  154.    o  sprite resolution to match screen pixel resolution
  155.    o  sprite resolution to be "always lores" (~320 pixels per line)
  156.    o  sprite resolution to be "always hires" (~640 pixels per line)
  157.  
  158. See <intuition/pointerclass.h|i> for full details.
  159.  
  160. There is a new pointer-control function called SetWindowPointerA(),
  161. which takes a window and a taglist.  The tag values are as follows:
  162.  
  163.    o  WA_Pointer (APTR) - used to specify an application custom
  164. pointer, ti_Data points to an instance of "pointerclass" you typically
  165. obtain using NewObject().  If NULL, you are requesting the Preferences
  166. default pointer.
  167.    o  WA_BusyPointer (BOOL) - if ti_Data is TRUE, this tag requests the
  168. Preferences default busy pointer.
  169.    o  WA_PointerDelay (BOOL) - if ti_Data is TRUE, this tag requests
  170. that the change of pointer imagery be deferred for a short duration.
  171. This is very useful for an application which is about to be busy for an
  172. unknown but possibly very short duration.  Such an application should
  173. request both the Preferences default busy pointer and the pointer-delay
  174. feature.  If the application clears the pointer or sets another pointer
  175. before the delay expires, the pending pointer change is cancelled. This
  176. reduces short flashes of the busy pointer caused by the application
  177. having brief intervals of busy-ness.
  178.  
  179. The same three tags are now recognized by OpenWindowTagList(), so you
  180. can now arrange for a window to open with a custom pointer (or standard
  181. busy pointer) already in place, and never see a brief flash of the
  182. default pointer.
  183.  
  184. The user can can now specify 32 pixel wide pointers in hires or lores
  185. using Pointer Preferences.  Pointer Preferences supports a user-defined
  186. default pointer image as well as a user-defined busy pointer image.
  187.  
  188. Intuition blanks the pointer around size or imagery changes, to reduce
  189. ugly flashing that might otherwise result.
  190.  
  191. On an upbeat note, the notorious off-by-one error in sprite hot-spot
  192. position was eliminated from all new Intuition and Graphics calls. When
  193. using the new mechanisms, always specify the correct hot-spot offset.
  194. (The truth is, we tried to leave the error in, but couldn't agree
  195. whether the error should be one lores pixel or one sprite-resolution
  196. pixel.)
  197.  
  198.  
  199. Sprite Compatibility
  200.  
  201. The old SetPointer() and ClearPointer() functions still work, giving
  202. compatible Intuition pointers.  Likewise, the pointer imagery in
  203. devs:system-configuration will be used until a pointer.prefs file is
  204. received.  However, due to growing complexity in the pointer subsystem,
  205. calling SetPointer() or ClearPointer() from within an input handler or
  206. inside Begin/EndRefresh() runs a risk of deadlocking.  This has been
  207. kludged around, however:
  208.  
  209. THIS IS WHY WE WARN PEOPLE TO STICK TO SIMPLE RENDERING FUNCTIONS ONLY!
  210. While inside LockLayerInfo(), LockLayer(), BeginRefresh(),
  211. BeginUpdate(), etc., and to not call Intuition or other high-level
  212. system functions inside of LockIBase(). As well, great care should be
  213. taken inside an input handler (it's generally best for the handler to
  214. signal a high-priority task which actually does the work).  Don't be
  215. the application that dies under the next release when an inappropriate
  216. function that happened to work now deadlocks because its handling has
  217. become more sophisticated.
  218.  
  219. See the Autodocs for these functions for more information on what other
  220. system calls are okay to use with these functions.
  221.  
  222. Intuition and Graphics are involved in a scheme to maximize
  223. compatibility with older sprite-using applications.  The AA chipset
  224. supports variable sprite resolution and width, but the setting affects
  225. all sprites.  If an application requests a specific sprite width
  226. (through the old graphics.library/GetSprite() call or the new
  227. graphics.library calls (GetExtSpriteA() and ChangeExtSpriteA()), and
  228. Intuition's sprite is not compatible with that request, then
  229. graphics.library will blank Intuition's sprite and notify Intuition.
  230. Intuition will rebound by generating the most suitable pointer sprite
  231. which is compatible.
  232.  
  233. Using an attached sprite for the Intuition pointer was quasi-supported
  234. under 2.0.  It no longer works.
  235.  
  236. The pointer information returned by GetPrefs() is no longer kept
  237. up-to-date, since the pointer data can exceed the storage space
  238. available in struct Preferences.  (The ROM default pointer will be
  239. returned in all cases).  (Like V37, V39 ignores the pointer data in
  240. calls to SetPointer() after the first one, for reasons such as this).
  241.  
  242.  
  243. Pen-Sharing Support
  244.  
  245. Under V39, graphics.library has functions that let multiple
  246. applications share the pens in a palette (ObtainBestPen(), etc.).
  247. Palette sharing allows an application to gain exclusive access to some
  248. palette entries, which that application may then use or change as it
  249. sees fit.  As well, an application may access a pen as shareable,
  250. meaning that other applications in need of a similar color may also be
  251. granted that pen value.  Because these pens are shared among several
  252. clients, applications may not alter their color.
  253.  
  254. Intuition now uses and supports this pen-sharing scheme.  For all types
  255. of screen, the sprite pens and pens found in the DrawInfo->dri_Pens are
  256. obtained as shareable.  By default, all other pens are allocated as
  257. exclusive on behalf of the screen opener (this provides compatibility
  258. when visitor windows aware of the pen-sharing functions open on unaware
  259. public screens).  Exclusive pens are for the screen owner's use only,
  260. and may be changed at the owner's will.
  261.  
  262. Screens that are aware of pen-sharing issues should set the
  263. {SA_SharePens,TRUE} tag, which instructs Intuition to leave all other
  264. pens unallocated.  The Workbench screen is so marked, but pens 0 to 3
  265. and ~0 to ~3 are also made shareable, for compatibility.  Screens with
  266. SA_SharePens set to TRUE will have the new PENSHARED bit set in the
  267. screen->Flags field.
  268.  
  269. The application may then allocate pens as needed.  A paint package, for
  270. example, would allocate all colors it uses as exclusive.  Other
  271. applications might allocate several colors as shared or exclusive.
  272. Since Intuition opens all public screens in private state, the
  273. application has a chance to allocate its colors before making the
  274. screen available to visitors (see SetPubScreenModes()).
  275.  
  276. Preferences now listens to only 8 colors for the BitMap, which
  277. Intuition will set as the first four and the last four colors of the
  278. Workbench or any "Workbench-like" screen (those having the
  279. SA_FullPalette or SA_LikeWorkbench attributes).  When the SA_Pens
  280. pen-array is evaluated, pens are masked to the number of available
  281. colors.  As well, special definitions of pen-number (PEN_C3, PEN_C2,
  282. PEN_C1, and PEN_C0) mean the complementary pen numbers of pens 0 to 3,
  283. regardless of depth.
  284.  
  285. The way the DrawInfo pens are determined is Intuition picks a default
  286. pen-array.  Then, any pens you supply with SA_Pens override the
  287. defaults, up until the ~0 in your array.  If the screen is monochrome
  288. or old-look, the default will be the standard two-color pens.  If the
  289. screen is two or more planes deep, the default will be the standard
  290. four-color pens.  If any explicit pens are specified, the default
  291. colors for NewLook menus and the titlebar match the V37 colors.  If the
  292. SA_Pens tag points at ~0, the NewLook menu colors will be used.
  293.  
  294. If the screen has the SA_LikeWorkbench property, the default will be
  295. the user's preferred pen-array, now changeable through Preferences.
  296. There is a preferred pen-array for four colors, and one for eight or
  297. more colors.
  298.  
  299.  
  300. Miscellaneous Graphics-Level Changes
  301.  
  302. Intuition places a blanking gap between sliding screens.  The time
  303. spent in this gap is used to load the hardware color registers,
  304. display-mode registers, and bitplane-pointers in a clean way.  Under
  305. ECS and prior, three non-interlaced lines were sufficient, and this
  306. amount was hard-coded. Under AA, this amount may increase, so logic was
  307. added to graphics.library (CalcIVG()) to determine this amount.
  308. Intuition now bases its inter-screen gap on the result of this call.
  309.  
  310. Under 2.0, when a screen was coerced, Intuition determined what display
  311. mode to use based on tables built into Intuition.  This was too
  312. limiting, so graphics.library now has a CoerceMode() function to
  313. fulfill this responsibility.  Intuition now uses this function.
  314. (Interested persons should see graphics.library/BestModeIDA(), which
  315. has wider application than CoerceMode()).
  316.  
  317.  
  318. Enhancements to Screens
  319.  
  320. Attached Screens
  321.  
  322. It is becoming increasingly popular for an application to have multiple
  323. screens open simultaneously.  A typical use is an application that has
  324. a full-sized screen (perhaps in HAM mode) as a canvas, and a short
  325. screen as a control panel or palette.  Since it is desirable that these
  326. screens slide and depth-arrange together, Intuition now provides the
  327. ability to attach screens together.  OpenScreenTagList() now supports
  328. the SA_Parent tag to attach a new child to an existing parent.  The
  329. SA_FrontChild and SA_BackChild tags can be used to attach an existing
  330. child in front of or behind a new parent.  When opening a parent screen
  331. you can specify multiple SA_xxxChild tags, in order to attach multiple
  332. children.  Draggable child screens can be dragged independently of each
  333. other and their parent, except that they can never go above their
  334. parent.  Pulling down the parent below its natural top causes the child
  335. screens to move as well.
  336.  
  337. Attached screens always remain adjacent to each other in the screen
  338. depth-ordering.  It is not possible to interpose some other screen
  339. between screens of the same family.  User depth-arrangement (via
  340. Amiga-M/N or the screen depth-gadget), as well as old programmatic
  341. depth-arrangement (ScreenToFront() and ScreenToBack()), depth-arrange a
  342. screen's family as a single unit, moving them to the front or to the
  343. back of the list of screens without altering the ordering of screens
  344. within the family.  The new ScreenDepth() function has an
  345. SDEPTH_INFAMILY option which allows the programmer to depth-arrange
  346. screens within their family.
  347.  
  348. There are times when it would be useful for a parent and child screen
  349. to masquerade as a single screen.  This can allow independent setting
  350. of screen mode, depth, resolution, etc.  Set the new SA_Draggable tag
  351. to FALSE to get a child screen which is non-draggable with respect to
  352. its parent. Trying to drag a child screen (through MoveScreen(), its
  353. drag-bar, or mouse-screen-drag) is equivalent to dragging the parent.
  354. The new ScreenPosition() function has an SPOS_FORCEDRAG option which
  355. allows the application to independently move such a child screen.
  356.  
  357. To complement attached screens, a feature called "menu lending" has
  358. been implemented.  This allows menu button presses in one window to
  359. activate the menus of a different window, and have the menus appear in
  360. the screen of that other window.  The idea is to allow unification of
  361. the menu strips of attached screens.  The LendMenus() function is used
  362. for this.
  363.  
  364. If OpenScreen() is unable to attach screens (due to illegal
  365. hierarchies, etc.), the screen will fail to open, with a secondary
  366. error of OSERR_ATTACHFAIL.  A parent screen may not itself have a
  367. parent, nor may a child screen have a child.  Also, a child screen may
  368. not be the child of more than one screen.  One parent may legally have
  369. several child screens.
  370.  
  371. Aside from the SA_Parent, SA_FrontChild, or SA_BackChild tags, and the
  372. drag and depth arrangement behavior described, attached screens are
  373. just like other screens, that is to say they live on the regular screen
  374. list (IntuitionBase->FirstScreen-> ...), and child screens don't
  375. inherit any properties from their parent.  In particular this means you
  376. can run the same code under Release 2 and all you will lose are the
  377. depth arrangement and dragging relationships.  That would yield the
  378. best situation under those versions, and no conditional code is
  379. required on your part.
  380.  
  381. Various combinations of DClips and over-sized scrolling screens are
  382. supported by attached screens, and they work in much the manner you
  383. would expect.  Note that there are problems when non-draggable child
  384. screens are attached to parent screens and their DClips or dimensions
  385. are not equivalent.  These problems are fixed in 3.1.
  386.  
  387. The attachdemo.c example on the DevCon disks shows usage of attached
  388. screens.
  389.  
  390.  
  391. Double-Buffering Support for Screens
  392.  
  393. Intuition now supports double (or multiple) buffering inside an
  394. Intuition screen, with full support for menus, and support for certain
  395. kinds of gadget.
  396.  
  397. The AllocScreenBuffer() call allows you to create other BitMap buffers
  398. for your screen.  the SB_SCREEN_BITMAP flag is used to get a buffer
  399. handle for the BitMap currently in use in the screen.  Subsequent
  400. buffers are allocated with the SB_COPY_BITMAP flag instead, which
  401. instructs Intuition to copy the current imagery (e.g., the screen
  402. title-bar and any of your rendering) into the alternate BitMap.
  403. Normally you let Intuition allocate these alternate BitMaps, but if
  404. your screen is CUSTOMBITMAP, you should allocate the alternate BitMaps
  405. yourself.
  406.  
  407. To swap buffers, call the ChangeScreenBuffer() function, which attempts
  408. to install the new buffer.  ChangeScreenBuffer() will fail if Intuition
  409. is temporarily unable to make the change (say while gadgets or menus
  410. are active).  Intuition builds these functions on top of the new
  411. graphics.library ChangeVPBitMap() function, so the signalling
  412. information that graphics provides is also available to the Intuition
  413. user.  To clean up, call FreeScreenBuffer() for each screen buffer. It
  414. is not necessary to restore the original buffer before freeing things.
  415. Consult the autodocs for full details.
  416.  
  417. When the user accesses the screen's menus, buffer-swapping will stop.
  418. The ChangeScreenBuffer()  call will return failure during this time.
  419. When the user finishes his menu selection, buffer-swapping will be
  420. possible again. Only a small subset of gadgets are supportable in
  421. double-buffered screens. These gadgets are those whose imagery returns
  422. to the initial state when you release them (e.g., action buttons or the
  423. screen's depth gadget).  To use other kinds of gadgets (such as sliders
  424. or string gadgets) you need to put them on a separate screen, which can
  425. be an attached screen.
  426.  
  427. Windows with borders are not supportable on double-buffered screens.
  428. Double-buffered screens are expected to consist nearly entirely of
  429. custom rendering.
  430.  
  431. An example program illustrating double-buffering under Intuition, with
  432. menu-lending and an attached screen to hold two slider gadgets is
  433. provided.
  434.  
  435. Miscellaneous Screen Features
  436.  
  437. The new {SA_Interleaved,TRUE} tag allows applications to request that
  438. their custom or public screen have an "interleaved" BitMap. Interleaved
  439. BitMaps are built out of a single allocation, instead of one per
  440. bitplane. Further, the data is laid out as follows:
  441.  
  442.         bitplane 0, scan-line 0
  443.         bitplane 1, scan-line 0
  444.         ...
  445.         bitplane n, scan-line 0
  446.         bitplane 0, scan-line 1
  447.         ...
  448.  
  449. (Contrast this to regular BitMaps, where each bitplane is contiguous.)
  450. The primary advantage of interleaved BitMaps is that blitting between
  451. them is cleaner, because color artifacting is eliminated.  As well,
  452. multiple small blits are replaced by fewer large blits, saving on
  453. blitter setup time and improving blitter/processor overlap.
  454.  
  455. The primary disadvantage of interleaved BitMaps is that
  456. BitMap->BytesPerRow no longer means "how many bytes are in one row of
  457. one bitplane."  This field continues to mean "how many bytes must be
  458. added to the current address to arrive at the same pixel one row down."
  459. See the notes for the compatibility talk for further details. (Screen
  460. grabbers and screen printers seem to be the primary victims of this
  461. change.)
  462.  
  463. For compatibility, the Workbench screen is non-interleaved if it opens
  464. before IPrefs has run.  If opened or reset after IPrefs has run, the
  465. Workbench screen will be interleaved. The new SA_LikeWorkbench tag
  466. gives you a screen having the same attributes as the Workbench screen,
  467. including depth, colors, pen-array, screen mode, etc.  Individual
  468. attributes can be overridden by using tags.  (SA_Workbench itself
  469. overrides things specified in the NewScreen structure).  Attention
  470. should be paid to hidden assumptions when doing this.  For example,
  471. setting the depth to two makes assumptions about the pen values in the
  472. DrawInfo pens.  Note that this tag requests that Intuition attempt to
  473. open the screen to match the Workbench.  There are fallbacks in case
  474. that fails, so it is not correct to make enquiries about the Workbench
  475. screen then make strong assumptions about what you're going to get.
  476.  
  477. OpenScreen() now allocates an appropriate-sized ColorMap for new modes.
  478. You can override this with the SA_ColorMapEntries tag to let the
  479. application increase the ColorMap size if needed.
  480.  
  481. The SA_Draggable and SA_Exclusive tags are designed to help implement
  482. "game screens" that coexist with Intuition.  {SA_Draggable,FALSE}
  483. allows the caller to make a screen non-draggable.  {SA_Exclusive,TRUE}
  484. allows the caller to make a screen exclusive, meaning it will never
  485. share the display with another screen.  Dragging down a screen that's
  486. in front of an exclusive screen won't reveal the exclusive screen.
  487. Although exclusive screens can autoscroll, but they can't be pulled
  488. down below their natural top (since nothing should be visible behind).
  489. Starting with 3.1, you can attach one or more exclusive screens with
  490. the SA_Parent and SA_xxxChild tags already described.  Such screens
  491. form an exclusive family, and only coexist on the display with each
  492. other, not with other screens (exclusive or not).
  493.  
  494. Intuition and graphics.library now support over-sized scrollable
  495. A2024/Moniterm screens.  While such screens can autoscroll and be
  496. dragged around, they can't be pulled down, since other screens would
  497. not be visible behind them (similar to the SA_Exclusive property, but
  498. dictated by the graphics database MonitorInfo.Compatibility field).
  499.  
  500. The new ScreenPosition() function extends the functionality of
  501. MoveScreen() to also include absolute screen positioning and optional
  502. movement of {SA_Draggable,FALSE} screens.  The hope is that only the
  503. screen's opener (and not any commodity-type programs) would forcibly
  504. move a non-draggable screen.  As well, ScreenPosition() allows you to
  505. specify a rectangle in screen coordinates which you wish to be made
  506. visible.  Over-sized screens will be scrolled such that the rectangle
  507. you supply will be on the visible part of the display.
  508.  
  509. The new ScreenDepth() function unifies ScreenToFront() and
  510. ScreenToBack() while adding a flag allowing optional in-family
  511. depth-arrangement of attached screens.  ScreenToFront(),
  512. ScreenToBack(), Amiga-M/N, screen depth-gadget action, and EasyRequest
  513. screen-popping all go through the ScreenDepth() LVO.  Due to a bug,
  514. WBenchToFront() and WBenchToBack() do not yet do so, but this is
  515. expected to be fixed for 3.1. OpenScreen() and the routines which open
  516. the Workbench now call OpenScreenTagList() through the LVO, which will
  517. allow some useful SetFunction()ing. OpenScreen() now supports the new
  518. SA_BackFill tag, to install a LayerInfo backfill hook for the screen.
  519.  
  520. Intuition now ensures that the Workbench screen is at least 640x200.
  521. This is needed in order to safely allow lores (and other odd
  522. resolution) Workbench screens.
  523.  
  524. The original Screen structure has an embedded instance of a BitMap
  525. structure, which is unfortunate.  When Intuition allocates a screen's
  526. BitMap (i.e., a non-CUSTOMBITMAP screen), it now uses AllocBitMap(),
  527. and copies the struct BitMap into &screen->BitMap.  This is the
  528. direction to head for RTG, and it is needed now for double-buffering.
  529. Intuition internally now references the real BitMap (obtainable as
  530. screen->RastPort.BitMap) instead of &screen->BitMap.  It is recommended
  531. that applications do the same.
  532.  
  533. The new SA_Colors32 tag can be used to provide 32-bit color information
  534. at OpenScreen() time.  ti_Data points to a longword-array that
  535. Intuition will pass to LoadRGB32().  See the autodoc for LoadRGB32()
  536. for details on how to format the data.
  537.  
  538. The new SA_VideoControl tag allows an application to provide a taglist
  539. which Intuition will pass to VideoControl() after opening the screen.
  540. This can be useful to turn on border-sprites, for example.
  541.  
  542. The requested screen depth is now validated.  Making a request for a
  543. screen too deep causes failure with a secondary error of OSERR_TOODEEP.
  544.  
  545.  
  546. Enhancements to Windows
  547.  
  548. The window depth-gadget now determines whether a click should send the
  549. window to front or to back based on whether the window is obscured or
  550. not, rather than on whether it's the top layer.
  551.  
  552. The new ScrollWindowRaster() function implements ScrollRasterBF() at
  553. the Intuition level.  You will receive an IDCMP_REFRESHWINDOW event if
  554. there is damage to your window.  Damage will appear if obscured parts
  555. of a simple refresh window are scrolled into view.  Note:  this area
  556. is not cleared!
  557.  
  558. When you supply the "alternate-size" rectangle for zooming using the
  559. WA_Zoom tag, you can now specify (-1,-1) for the upper-left corner.
  560. This instructs Intuition to perform size-only zooming.  Wherever the
  561. window is placed, zooming will toggle size but not affect position
  562. (unless moving the window would be required to keep it on-screen).
  563. Using (-1,-1) under V37 is safe, and equivalent to using (0,0).
  564.  
  565. The Window->WindowPort is now allocated at OpenWindow() time, even if
  566. IDCMPFlags of zero are requested.  This simplifies ModifyIDCMP()
  567. failure handling because failure can no longer happen when you set the
  568. window->UserPort to your shared port, then call ModifyIDCMP() to turn
  569. on messaging.  ModifyIDCMP() can now only fail if you ask it to create
  570. the UserPort.
  571.  
  572. The new OpenWindow() tag WA_NotifyDepth allows a window to request
  573. IDCMP_CHANGEWINDOW messages when that window is depth-arranged.  These
  574. messages arrive with an IntuiMessage->Code value of CWCODE_DEPTH to
  575. distinguish them from V37-style IDCMP_CHANGEWINDOW messages (sent in
  576. response to window movement or resizing), which have a Code value of
  577. CW_MOVESIZE.
  578.  
  579. When inactive, window borders are filled with BACKGROUNDPEN instead of
  580. pen zero.  There are presumably a few more places when pen zero is
  581. being used incorrectly, but they are hard to track down (ever try to
  582. search 1.5 megabytes of source code for all references to "0"?)
  583.  
  584. The WA_HelpGroup and WA_HelpGroupWindow tags allow the programmer to
  585. identify multiple windows of the same application, for purposes of
  586. gadget help processing.  See the section on gadget help for details.
  587.  
  588.  
  589. Enhancements to Gadgets and Imagery
  590.  
  591. Extended Gadget Structure
  592.  
  593. V39 introduces the ExtGadget structure as a compatible substitute that
  594. can be used wherever old Gadget structures can be found.  An arbitrary
  595. gadget can be identified as an ExtGadget if the GFLG_EXTENDED bit in
  596. its Flags field is set.  Never attempt to read any of the extended
  597. fields of a gadget if this flag is not set. Starting with V39, all
  598. instances of gadgetclass or its subclasses are ExtGadgets.  The
  599. extended fields include a new longword worth of flags, and a bounding
  600. box.
  601.  
  602.  
  603. Gadget Bounding Box and GM_LAYOUT
  604.  
  605. Until now, the only area that was defined for gadgets was the select
  606. box area.  However, the imagery of a gadget often extends outside its
  607. select box.  For example, the border of a string gadget is often
  608. outside, as is its label.  ExtGadgets have four new fields that
  609. describe the "bounding box."  The bounding box can be used to allow
  610. relative size or position gadgets to work even if they have imagery
  611. outside the select box.  The BoundsLeftEdge, BoundsTopEdge,
  612. BoundsWidth, and BoundsHeight fields of an ExtGadget are assumed valid
  613. if the GMORE_BOUNDS flag in the ExtGadget->MoreFlags field is set.
  614. Where Intuition wants to use a bounding box, but the gadget is not
  615. extended or does not have GMORE_BOUNDS set, the gadget select box will
  616. be used instead, which matches the V37 behavior. The routine that
  617. manages erasing and redrawing GRELxxx gadgets during window resizing
  618. now bases its work on the gadget bounding box (if one is specified),
  619. instead of the gadget select box.  This means that you can finally have
  620. GREL gadgets which have imagery (e.g., a gadget label) extending
  621. outside of the select box, and Intuition will correctly move or resize
  622. such a gadget.
  623.  
  624. As well, there is a new boopsi method for gadgets called GM_LAYOUT. If
  625. your gadget has any of the GREL properties, it will receive a GM_LAYOUT
  626. message when the gadget is first added (or the window containing the
  627. gadget is first opened), as well as whenever the window size changes.
  628. At GM_LAYOUT time, the gadget can change its gadget select box and/or
  629. bounding box.  It can re-allocate or change its image dimensions if it
  630. likes.  If it is a group-gadget, it can move its members around.  To
  631. round this all out, there is a new "special relativity" property,
  632. GFLG_RELSPECIAL or GA_RelSpecial. Unlike the older GREL properties,
  633. this property doesn't affect the interpretation of the gadget box.  It
  634. does allow your gadget to receive GM_LAYOUT messages, hence have
  635. arbitrary layout power.
  636.  
  637. The DevCon disks include a sample program called relspecial.c that
  638. implements a boopsi gadget whose size is kept at half the current size
  639. of the window, and which is centered in that window.  The example makes
  640. use of GFLG_RELSPECIAL and GM_LAYOUT.
  641.  
  642.  
  643. Gadget Help
  644.  
  645. Intuition now supports "gadget help".  If a window enables this feature
  646. and the user passes the mouse over the bounding box of a gadget which
  647. has the GMORE_GADGETHELP property, then an IDCMP_GADGETHELP event will
  648. be sent. There is a corresponding boopsi GM_HELPTEST method which
  649. boopsi gadgets can use to refine their help-sensitivity areas or to
  650. delegate help-testing to member gadgets. Boopsi gadgets can also return
  651. values for the IntuiMessage Code field of the IDCMP_GADGETHELP message.
  652.  
  653. The gadget help feature may be turned on or off through the
  654. HelpControl() function.
  655.  
  656. The gadget help checking is optimized for performance.  If the mouse is
  657. moving quickly, Intuition skips the check for gadget help.  If
  658. Intuition discovers that the mouse is still over the same gadget as the
  659. last one that sent gadget help, no new IntuiMessage is sent unless the
  660. gadget wants to report a different IntuiMessage->Code value.
  661.  
  662. When the mouse is over a GMORE_GADGETHELP gadget, the IDCMP_GADGETHELP
  663. message has an IntuiMessage->IAddress which points to the gadget. When
  664. the mouse is over the window but not over any help-aware gadget, the
  665. IAddress points to the window itself.  When the mouse is not over the
  666. window, the IntuiMessage IAddress will be zero.  Intuition will look
  667. "through" gadgets that do not have the GMORE_GADGETHELP property to see
  668. if some other gadget lies underneath.
  669.  
  670. Ordinarily, gadget help only applies to the active window.  However, a
  671. multi-window application can mark all its windows as being in a group
  672. (using the WA_HelpGroup or WA_HelpGroupWindow tags), which makes
  673. Intuition test gadget help in all windows of the group when any one of
  674. them is the active one.  There is a new utility.library function called
  675. GetUniqueID() which must be used to provide an ID for WA_HelpGroup.  If
  676. you have only one window, there is no need to pass WA_HelpGroup.
  677. HelpControl() sets the state of gadget help for all windows of a group,
  678. and Intuition ensures that all windows of the same group are
  679. consistently set.
  680.  
  681.         helpgroup = GetUniqueID();
  682.  
  683.         for ( each window )
  684.                 {
  685.                 win[x] = OpenWindowTags(...,
  686.                              WA_HelpGroup, helpgroup, TAG_DONE);
  687.                 }
  688.  
  689. Inactive windows whose WA_HelpGroup matches the active window's are
  690. also subject to gadget help testing.  IDCMP_GADGETHELP messages are
  691. sent to the window the mouse is over.  The IDCMP_GADGETHELP message
  692. with an IAddress of zero means the mouse is not over the active window
  693. or any other window of the same group.  This particular message is
  694. always sent to the active window (which is not necessarily the window
  695. in your group that last got a message).
  696.  
  697. All system gadgets (e.g., close, drag, size, depth) have
  698. GMORE_GADGETHELP set, so GadgetHelp-aware applications can (almost
  699. must) provide help on them too.  You can check the gadget->GadgetType &
  700. 0xF0 field for GTYP_CLOSE, etc.  Later include files define
  701. GTYP_SYSTYPEMASK to be this value (0xF0).
  702.  
  703. The gadgethelp.c example on the DevCon disks illustrates the correct
  704. handling of IDCMP_GADGETHELP messages.
  705.  
  706.  
  707. Gadget Support for ScrollRaster() Damage Handling
  708.  
  709. Intuition now notices and repairs damage when boopsi gadgets use
  710. ScrollRaster().  (Such damage occurs when the gadget is in a
  711. simple-refresh window and part of the scrolled area is obscured). Such
  712. gadgets must set GMORE_SCROLLRASTER in order to benefit from this magic
  713. repair feature.
  714.  
  715. Note that ScrollWindowRaster() is for applications.  Boopsi gadgets
  716. must not use ScrollWindowRaster(), but rather use ScrollRaster() or
  717. ScrollRasterBF(). Miscellaneous Gadget Features
  718.  
  719. There is an important new Boopsi function in Intuition called
  720. DoGadgetMethodA(), that invokes the specified method, but includes a
  721. valid GadgetInfo structure if possible.  SetGadgetAttrsA() has been
  722. re-implemented to go through DoGadgetMethodA().  Two SetGadgetAttrsA()
  723. bugs were fixed in the process.  First, if a requester is off-window,
  724. it has no layer.  SetGadgetAttrsA() of a gadget in such a requester
  725. wasn't being sent to the gadget, but now OM_SET is sent with a
  726. GadgetInfo of NULL.  Second, there was no locking around the call.
  727. DoGadgetMethodA() is preferable to a direct Boopsi invocation (namely
  728. DoMethod()) because it offers both a valid GadgetInfo structure and
  729. arbitration around other gadget activity.
  730.  
  731. The default string edit hook now ignores Return or Enter keystrokes
  732. that have the repeat-qualifier set.
  733.  
  734. PROPNEWLOOK proportional gadgets in the borders of an active window
  735. have their knobs rendered in FILLPEN instead of SHINEPEN.  When you
  736. click on the knob, they become SHINEPEN as before.  This looks a lot
  737. better, is more consistent with inactive windows, and finally restores
  738. that all-important feedback to these prop gadgets.
  739.  
  740.  
  741. Imagery Features
  742.  
  743. Under V37 and prior, Intuition handled ghosting a gadget by blasting a
  744. pattern of dots over its select area.  This did not allow boopsi images
  745. to manage their own disabled rendering.  For V39, Intuition has defined
  746. a new read-only attribute for image classes, called IA_SupportsDisable.
  747. If an image class returns TRUE in response to an OM_GET request of this
  748. attribute, it is asking to take responsibility for performing ghosting
  749. based on image state.  When a gadget is first added to a window,
  750. Intuition will check its image to determine if it has the
  751. IA_SupportsDisable attribute.  When such a gadget is disabled,
  752. Intuition skips its own disabled rendering, and draws the image using
  753. DrawImageState() using the IDS_DISABLED or the new IDS_SELECTEDDISABLED
  754. state.
  755.  
  756. The ROM boopsi image class for rendering frames, "frameiclass", now
  757. supports the standard frame types used by GadTools and recommended by
  758. the Amiga User Interface Style Guide, including the standard
  759. GadTools-style bevelled box, the GadTools string-gadget ridge, and the
  760. AppWindow icon drop-box specified by the Style Guide. The imagery for
  761. the standard system arrows has been improved.
  762.  
  763. The GadTools checkbox and GadTools radio-button images are now marked
  764. as scalable to allow GadTools to support scaled checkboxes and
  765. radio-buttons.
  766.  
  767. The basic gadget types (classic prop, bool, string) now support
  768. GFLG_LABELIMAGE.
  769.  
  770. Enhancements to Menus
  771.  
  772. NewLook Title Bar and Menus
  773.  
  774. On aware screens, the title-bar has a nicer appearance.
  775.  
  776. For V39, Intuition defines three additional pens in the DrawInfo, which
  777. are used to control the rendering of the screen title bar and menus.
  778. These pens are:
  779.  
  780.    o  BARDETAILPEN - pen used for details like text in the title bar
  781. and text or graphics in menus.
  782.    o  BARBLOCKPEN - pen used to fill the solid areas of the title bar
  783. and menus.
  784.    o  BARTRIMPEN - pen to use for the trim-line under the screen title
  785. bar.
  786.  
  787. It is intended that BARDETAILPEN and BARTRIMPEN should be black or
  788. dark, and that BARBLOCKPEN should be white or light-colored.
  789.  
  790. The handling of defaults is a bit involved because of compatibility
  791. issues. Applications that specify no SA_Pens array or ones who specify
  792. an SA_Pens array with at least one explicit pen provided get compatible
  793. defaults. Applications whose SA_Pens array consists solely of {~0} will
  794. get the new colors.  Finally, screens which specify SA_LikeWorkbench
  795. will get the user's preferred pen-array, which allows the user to
  796. control the menu and title bar colors.
  797.  
  798. Under V37 and earlier, the menus themselves are drawn using the
  799. window's DetailPen and BlockPen, while the colors of the MenuItems are
  800. determined by the imagery (IntuiTexts or Images) chosen.  For
  801. compatibility, old applications will have their menus rendered in
  802. V37-compatible colors. Applications will want to take advantage of
  803. NewLook menus when present, but they must request them through the
  804. {WA_NewLookMenus,TRUE} tag.  This instructs Intuition to use
  805. BARDETAILPEN and BARBLOCKPEN for rendering the elements of your menus,
  806. instead of relying on the window's DetailPen and BlockPen.  Note that
  807. the application (or any menu-building library) should ensure that the
  808. colors of struct IntuiText or struct Images used by MenuItems use
  809. matching pens.  You can instruct GadTools to use the new colors by
  810. passing {GTMN_NewLookMenus,TRUE} to LayoutMenusA().
  811.  
  812. Intuition also ensures that the Amiga-key and checkmark symbols are
  813. colored to match the menu and are scaled to match the screen's font. If
  814. you are using a font other than the screen's font for the menus, you
  815. must create custom Amiga-key and checkmark symbols using "sysiclass".
  816. This image class recognizes a new tag, SYSIA_ReferenceFont, which you
  817. can use to set the size of a checkmark or Amiga-key symbol
  818. appropriately for your chosen font.  You can then use the (V36)
  819. WA_CheckMark tag or the new WA_AmigaKey tag to override the imagery
  820. Intuition will use in the menus.
  821.  
  822. Per screen, the default Amiga-key and checkmark images used will be
  823. appropriately colored and scaled to the screen's font.  (You can find
  824. pointers to their imagery in the DrawInfo structure for that screen).
  825.  
  826. HIGHCOMP menu items in NewLook menus complement in such a way that
  827. pixels colored in BARDETAILPEN highlight into BARBLOCKPEN, and
  828. vice-versa.
  829.  
  830. The flag which indicates whether a window is using NewLook menus is
  831. publicly readable (WFLG_NEWLOOKMENUS).
  832.  
  833.  
  834. Other Enhancements
  835.  
  836. Drawing Tablet Support
  837.  
  838. As an input device, a drawing tablet poses special problems for
  839. Intuition and for the tablet driver writer.  Some of the problems
  840. include getting auxiliary information such as pressure through the
  841. IntuiMessage channel and providing suitable scaling.  As well, the
  842. absolute nature of tablet devices poses some interesting problems for
  843. features like autoscroll.  V37 added a simple tablet input event, but
  844. this was not enough.  There now is a new subclass of
  845. IECLASS_NEWPOINTERPOS called IESUBCLASS_NEWTABLET.  This subclass
  846. solves tablet handling quite nicely.  The tablet driver fills out a few
  847. tablet-oriented properties (like the current value and range in X and
  848. Y), and then submits the InputEvent to input.device.  Later, Intuition
  849. establishes the active screen and the rectangle to which the tablet
  850. should scale itself, then calls back the driver through a hook. This
  851. allows the tablet driver to handle screen resolution changes, oversized
  852. scrolling screens, pulled down screens, and attached screens.  The
  853. tablet driver can scale according to some tablet preferences settings
  854. it manages (for example, preserve aspect, center, best fit horizontal,
  855. best fit vertical). Intuition supplies reasonable default scaling for
  856. simple tablet drivers that leave the hook NULL.  See struct IENewTablet
  857. in <devices/inputevent.h>.
  858.  
  859. Windows that request the new WA_TabletMessages property receive
  860. extended IntuiMessages, which include a pointer to a TabletData
  861. structure.  If this IntuiMessage originated from a tablet event, the
  862. TabletData pointer will be non-NULL, and the structure will have some
  863. information such as sub-pixel position.  In addition, there is a
  864. pointer to a tag-list, and there are definitions for standard tags such
  865. as pressure, tilt, additional buttons, and a Z-coordinate.  The
  866. definition and important comments on the TabletData structure can be
  867. found in <intuition/intuition.h>. As an example, pressure is passed in
  868. with the TABLETA_Pressure tag. the pressure reading of the stylus.  The
  869. ti_Data member is the pressure, which should be normalized to fill a
  870. signed long integer.  Typical devices would not generate negative
  871. pressure, but the possibility is not precluded.  The Preferences
  872. program shipped with a tablet driver for a pressure-sensitive device
  873. might offer two pressure sensitivity settings. The "contact threshold"
  874. would be the pressure below which no contact should be reported by the
  875. driver.  This is the "zero point" for reported pressure.  The "click
  876. threshold" would the pressure at which a button transition should be
  877. reported (by setting the InputEvent ie_Code to indicate a downpress of
  878. the select button).  The tablet would send position/pressure events
  879. even when the pressure was below the click threshold (but above the
  880. contact threshold, of course).
  881.  
  882. When a tablet driver sends a new tablet event and the active window is
  883. tablet-aware, IDCMP_MOUSEMOVE events are sent to that window even if
  884. the pixel-level mouse-position is unchanged.  This is to allow
  885. applications to hear changes in sub-pixel position or other parameters
  886. such as pressure. This means that tablet drivers must be careful to
  887. only send events when something actually changed.
  888.  
  889. If an input event is a tablet event, boopsi gadgets can get a pointer
  890. to the TabletData structure in the gpInput structure they receive
  891. through the GM_GOACTIVE and GM_HANDLEINPUT messages.
  892.  
  893.  
  894. Miscellaneous Features
  895.  
  896. The new TimedDisplayAlert() function allows for alerts that time-out
  897. without user-intervention.  Exec uses this new function to aid
  898. unattended operation of the Amiga, particularly in kiosk and video
  899. applications.
  900.  
  901. In struct Preferences, the unused WorkName[] field is now split into
  902. PrtDevName[], DefaultSerUnit, and DefaultPrtUnit, for multi-serial
  903. preferences and more flexible printer-preferences.
  904.  
  905. OpenScreenTagList(), OpenScreen(), OpenWindowTagList(), OpenWindow(),
  906. and the internal BorderPatrol() routine now go through stack-swapping.
  907. This protects applications from increased stack usage in these calls.
  908. The Preferences LaceWB field (and whether the pretend screen mode from
  909. GetScreenData() is lace or not) now solely depends on the height of the
  910. text overscan rectangle of the true mode of the Workbench.  This helps
  911. older applications opening on modes such as double-NTSC 640x400.
  912.  
  913. Intuition now handles MakeVPort() failure.  Intuition will blank any
  914. failed ViewPort, and attempt to remake it at each opportunity.
  915. MakeScreen(), RethinkDisplay(), and RemakeDisplay() now have return
  916. codes that reflect MakeVPort() failure.
  917.  
  918.  
  919. Rendering Optimizations
  920.  
  921. Several important rendering optimizations make Intuition appear snappier
  922. and cleaner.  Here is a partial list:
  923.  
  924.    o  When a WFLG_ACTIVATE window is opened, Intuition now activates it
  925. synchronously.  The big benefit is that the window's border is no
  926. longer drawn inactive then activate.
  927.    o  EasyRequests and AutoRequests used to consist of a window with a
  928. requester inside, which meant two layers.  This consumed memory and
  929. slowed down requester and other window operations.  Now, the gadgets
  930. and imagery are brought up directly in the window, saving a layer.
  931.    o  The window sizing/dragging rubber-band box is now much faster.
  932.    o  The bar-layer of each screen no longer does any backfill
  933. processing, since Intuition fully re-renders the screen bar anyway.
  934.    o  Intuition now avoids spurious border and gadget refresh and
  935. sending a spurious IDCMP_REFRESHWINDOW event.  Formerly, if an
  936. application had not cleared its window's damage when another
  937. damage-causing operation (e.g., menus, window sizing/movement) occurred
  938. on the same screen, another round of refresh was performed.  Intuition
  939. now can tell if the window's layer had been damaged since the last
  940. IDCMP_REFRESHWINDOW message went out.
  941.    o  Menus are brought on-screen somewhat faster than before, and are
  942. removed very much faster than before.  (3.1 and up only)
  943.    o  A lot of work has been done to reduce window border and gadget
  944. flashing during window resize operations.  (3.1 and up only)
  945.  
  946. Bug Fixes
  947.  
  948.    o  NextPubScreen() could write a zero-byte one byte past the end of
  949. the buffer the caller supplies.  It no longer does this.
  950.    o  Clicking in the no-window area of a screen now makes that screen the
  951. active screen (for purposes of autoscrolling).
  952.    o  Fixed a long-standing bug where REQCLEAR messages weren't being
  953. sent when a requester having no layer is taken down while other
  954. requesters are still up in the window.
  955.    o  Setting a negative minimum width or height with WindowLimits() no
  956. longer allows you to crash the computer by turning a window inside out.
  957.    o  SetWindowTitles() now properly erases remnants of the previous
  958. title, even when odd extenders happen.
  959.    o  A ghosted string gadget no longer causes patterning in string
  960. gadgets precede it in the list and have a non-zero container
  961. background-pen.
  962.    o  NewModifyProp() of a disabled prop gadget no longer clears away
  963. part of the ghosting.
  964.    o  SetGadgetAttrs() to a proportional gadget no longer can cause the
  965. window's installed clip-region to be lost.
  966.    o  The mouse-pointer no longer blanks in the first gap when three
  967. interlaced screens up.
  968.    o  Several causes of sprite-pointer jumping have been fixed.
  969.    o  The ROM default sprite pointer now is the 2.0/3.0 one, not the
  970. 1.3 one.
  971.    o  DClips of coerced ViewPorts are finally scaled as correctly as
  972. possible.
  973.  
  974. If you used a boopsi string gadget as an integer gadget, with Intuition
  975. supplying the buffer, and you specified a STRINGA_MaxChars of > 15, you
  976. would get a mismatched FreeMem() when the gadget is disposed.  This is
  977. now fixed.
  978.  
  979. There is a bug in 3.0 (not in 2.0x and fixed in 3.1) where the
  980. autoscroll boundary was inadvertently switched to be the DClip of the
  981. active screen, where it used to be the "hull" of the DClips of all the
  982. screens.  If there are two screens in the system with different DClips,
  983. the mouse can be way outside the DClip of the smaller screen. If that
  984. screen is active, it will AutoScroll at a ridiculous rate. For example,
  985. if the mouse is seventeen pixels below its DClip, moving it down one
  986. pixel causes the screen to autoscroll by eighteen, instead of one.
  987. This is now fixed.
  988.  
  989. Starting with 3.1, Intuition now updates its internal time values
  990. based on (nearly) ANY InputEvent it receives, instead of just
  991. IECLASS_TIMER ones.  The problem was that outgoing IntuiMessages get
  992. their time from this internal time, which meant that IntuiMessage time
  993. was the time-stamp of the most recent timer tick, instead of the
  994. time-stamp of the event that actually triggered this IntuiMessage. This
  995. problem completely precludes correlating an IntuiMessage with the
  996. InputEvent that caused it, which is important for tablet people, for
  997. example.  A SetPatch for earlier ROM versions is being considered.
  998.  
  999. In 3.00, there is a bug where the part of a window obscuring the
  1000. title-bar area of a SCREENQUIET screen wasn't erased when the window
  1001. was closed or moved away.  Effectively, Intuition was relying on a
  1002. layers side-effect that was optimized out for V39.  Intuition fixes
  1003. this for 3.1. Starting with 3.1, when Intuition splits a single
  1004. InputEvent into button and movement components, the button event is now
  1005. sent first. This fixes some inconsistencies with extended input
  1006. information like pressure, as well as odd behavior of the qualifiers,
  1007. in particular IEQUALIFIER_MIDBUTTON.
  1008.