home *** CD-ROM | disk | FTP | other *** search
/ Fresh Fish 8 / FreshFishVol8-CD1.bin / gnu / os-include / intuition / screens.i < prev    next >
Text File  |  1993-10-15  |  20KB  |  566 lines

  1.     IFND  INTUITION_SCREENS_I
  2. INTUITION_SCREENS_I    SET  1
  3. **
  4. **    $VER: screens.i 38.25 (15.2.93)
  5. **    Includes Release 40.15
  6. **
  7. **    The Screen and NewScreen structures and attributes
  8. **
  9. **    (C) Copyright 1985-1993 Commodore-Amiga, Inc.
  10. **        All Rights Reserved
  11. **
  12.     IFND EXEC_TYPES_I
  13.     INCLUDE "exec/types.i"
  14.     ENDC
  15.  
  16.     IFND GRAPHICS_GFX_I
  17.     INCLUDE "graphics/gfx.i"
  18.     ENDC
  19.  
  20.     IFND GRAPHICS_CLIP_I
  21.     INCLUDE "graphics/clip.i"
  22.     ENDC
  23.  
  24.     IFND GRAPHICS_VIEW_I
  25.     INCLUDE "graphics/view.i"
  26.     ENDC
  27.  
  28.     IFND GRAPHICS_RASTPORT_I
  29.     INCLUDE "graphics/rastport.i"
  30.     ENDC
  31.  
  32.     IFND GRAPHICS_LAYERS_I
  33.     INCLUDE "graphics/layers.i"
  34.     ENDC
  35.  
  36.     IFND UTILITY_TAGITEM_I
  37.     INCLUDE "utility/tagitem.i"
  38.     ENDC
  39.  
  40. *
  41. * NOTE:  intuition/iobsolete.i is included at the END of this file!
  42. *
  43.  
  44. ; ========================================================================
  45. ; === DrawInfo =========================================================
  46. ; ========================================================================
  47.  
  48. * This is a packet of information for graphics rendering.  It originates
  49. * with a Screen, and is gotten using GetScreenDrawInfo( screen );
  50.  
  51. * You can use the Intuition version number to tell which fields are
  52. * present in this structure.
  53. *
  54. * DRI_VERSION of 1 corresponds to V37 release.
  55. * DRI_VERSION of 2 corresponds to V39, and includes three new pens
  56. *    and the dri_CheckMark and dri_AmigaKey fields.
  57. *
  58. * Note that sometimes applications need to create their own DrawInfo
  59. * structures, in which case the DRI_VERSION won't correspond exactly
  60. * to the OS version!!!
  61.  
  62. DRI_VERSION    EQU    2
  63.  
  64.  STRUCTURE DrawInfo,0
  65.     UWORD    dri_Version     ; will be  DRI_VERSION
  66.     UWORD    dri_NumPens     ; guaranteed to be >= 9
  67.     APTR    dri_Pens     ; pointer to pen array
  68.     APTR    dri_Font     ; screen default font
  69.     UWORD    dri_Depth     ; (initial) depth of screen bitmap
  70.     ; from DisplayInfo database for initial display mode
  71.     UWORD    dri_ResolutionX
  72.     UWORD    dri_ResolutionY
  73.     ULONG    dri_Flags
  74.     ; New for V39: dri_CheckMark, dri_AmigaKey
  75.     APTR    dri_CheckMark    ; pointer to scaled checkmark image
  76.                  ; Will be NULL if DRI_VERSION < 2
  77.     APTR    dri_AmigaKey     ; pointer to scaled Amiga-key image
  78.                  ; Will be NULL if DRI_VERSION < 2
  79.    STRUCT       dri_longreserved,20
  80.  
  81. DRIF_NEWLOOK    EQU    $00000001 ; specified SA_Pens, full treatment
  82. DRIB_NEWLOOK    EQU    0
  83.  
  84.     ; rendering pen number indexes into DrawInfo.dri_Pens[]
  85.     ENUM
  86.     EITEM    DETAILPEN    ; compatible Intuition rendering pens
  87.     EITEM    BLOCKPEN,
  88.     EITEM    TEXTPEN        ; text on background (pen = 0)
  89.     EITEM    SHINEPEN    ; bright edge on bas-relief
  90.     EITEM    SHADOWPEN    ; dark edge
  91.     EITEM    FILLPEN        ; active window fill
  92.     EITEM    FILLTEXTPEN    ; text over FILLPEN
  93.     EITEM    BACKGROUNDPEN    ; always color 0
  94.     EITEM    HIGHLIGHTTEXTPEN  ; highlighted text, against BACKGROUNDPEN
  95. ; New for V39, only present if DRI_VERSION >= 2:
  96.     EITEM    BARDETAILPEN    ; text/detail in screen-bar/menus
  97.     EITEM    BARBLOCKPEN    ; screen-bar/menus fill
  98.     EITEM    BARTRIMPEN    ; trim under menu-bar
  99.  
  100.     EITEM    NUMDRIPENS
  101.  
  102. * New for V39:  It is sometimes useful to specify that a pen value
  103. * is to be the complement of color zero to three.  The "magic" numbers
  104. * serve that purpose:
  105.  
  106. PEN_C3        EQU    $FEFC        ; Complement of color 3
  107. PEN_C2        EQU    $FEFD        ; Complement of color 2
  108. PEN_C1        EQU    $FEFE        ; Complement of color 1
  109. PEN_C0        EQU    $FEFF        ; Complement of color 0
  110.  
  111. ; ======================================================================== 
  112. ; === Screen ============================================================= 
  113. ; ======================================================================== 
  114.  
  115. * VERY IMPORTANT NOTE ABOUT Screen->BitMap.  In the future, bitmaps
  116. * will need to grow.  The embedded instance of a bitmap in the screen
  117. * will no longer be large enough to hold the whole description of
  118. * the bitmap.
  119. *
  120. * YOU ARE STRONGLY URGED to use Screen->RastPort.BitMap in place of
  121. * &Screen->BitMap whenever and whereever possible.
  122.  
  123.  STRUCTURE Screen,0
  124.  
  125.     APTR sc_NextScreen        ; linked list of screens
  126.     APTR sc_FirstWindow        ; linked list Screen's Windows
  127.  
  128.     WORD sc_LeftEdge        ; parameters of the screen
  129.     WORD sc_TopEdge        ; parameters of the screen
  130.  
  131.     WORD sc_Width
  132.     WORD sc_Height
  133.  
  134.     WORD sc_MouseY        ; position relative to upper-left
  135.     WORD sc_MouseX        ; position relative to upper-left
  136.  
  137.     WORD sc_Flags        ; see definitions below
  138.  
  139.     APTR sc_Title        ; null-terminated Title text
  140.     APTR sc_DefaultTitle    ; for Windows without ScreenTitle
  141.  
  142.     ; Bar sizes for this Screen and all Window's in this Screen
  143.     BYTE sc_BarHeight
  144.     BYTE sc_BarVBorder
  145.     BYTE sc_BarHBorder
  146.     BYTE sc_MenuVBorder
  147.     BYTE sc_MenuHBorder
  148.     BYTE sc_WBorTop
  149.     BYTE sc_WBorLeft
  150.     BYTE sc_WBorRight
  151.     BYTE sc_WBorBottom
  152.  
  153.     BYTE sc_KludgeFill00    ; This is strictly for word-alignment 
  154.  
  155.     ; the display data structures for this Screen
  156.     APTR sc_Font            ; this screen's default font
  157.     STRUCT sc_ViewPort,vp_SIZEOF    ; describing the Screen's display
  158.     STRUCT sc_RastPort,rp_SIZEOF    ; describing Screen rendering
  159.     STRUCT sc_BitMap,bm_SIZEOF        ; SEE WARNING ABOVE!
  160.     STRUCT sc_LayerInfo,li_SIZEOF    ; each screen gets a LayerInfo
  161.  
  162.     APTR sc_FirstGadget
  163.  
  164.     BYTE sc_DetailPen        ; for bar/border/gadget rendering
  165.     BYTE sc_BlockPen        ; for bar/border/gadget rendering
  166.  
  167.     ; the following variable(s) are maintained by Intuition to support the
  168.     ; DisplayBeep() color flashing technique
  169.     WORD sc_SaveColor0
  170.  
  171.     ; This layer is for the Screen and Menu bars
  172.     APTR sc_BarLayer         ; was "BarLayer"
  173.  
  174.     APTR sc_ExtData
  175.  
  176.     APTR sc_UserData        ; general-purpose pointer to User data 
  177.  
  178.     LABEL sc_SIZEOF    ; actually, you have no business talking about
  179.             ; or relying on the size of a screen structure
  180.  
  181.  
  182. ; --- FLAGS SET BY INTUITION -------------------------------------------------
  183. ; The SCREENTYPE bits are reserved for describing various Screen types
  184. ; available under Intuition.  
  185. SCREENTYPE    EQU    $000F    ; all the screens types available 
  186. ; --- the definitions for the Screen Type ------------------------------------
  187. WBENCHSCREEN    EQU    $0001    ; identifies the Workbench screen
  188. PUBLICSCREEN    EQU    $0002    ; public shared (custom) screen
  189. CUSTOMSCREEN    EQU    $000F    ; for that special look
  190.  
  191. SHOWTITLE    EQU    $0010    ; this gets set by a call to ShowTitle() 
  192.  
  193. BEEPING        EQU    $0020    ; set when Screen is beeping 
  194.  
  195. CUSTOMBITMAP    EQU    $0040    ; if you are supplying your own BitMap
  196.  
  197. SCREENBEHIND    EQU    $0080    ; if you want your screen to open behind
  198.                 ; already open screens
  199.  
  200. SCREENQUIET    EQU    $0100    ; if you do not want Intuition to render
  201.                 ; into your screen (gadgets, title)
  202.  
  203. SCREENHIRES    EQU    $0200    ; do not use lowres gadgets (set by intuition)
  204.  
  205. STDSCREENHEIGHT    EQU    -1    ; supply in NewScreen.Height
  206. STDSCREENWIDTH    EQU    -1    ; supply in NewScreen.Width
  207.  
  208. NS_EXTENDED    EQU    $1000    ; means ns_Extenion is valid
  209. AUTOSCROLL    EQU    $4000    ; automatic scrolling of large raster
  210.  
  211. * New for V39:
  212. PENSHARED    EQU    $0400    ; Screen opener set {SA_SharePens,TRUE}
  213.  
  214. * Screen attribute tag ID's.  These are used in the ti_Tag field of
  215. * TagItem arrays passed to OpenScreenTagList() (or in the
  216. * ExtNewScreen.Extension field).
  217.  
  218. * Screen attribute tags.  Please use these versions, not those in
  219. * iobsolete.h.
  220.  
  221.  ENUM TAG_USER+33
  222. *
  223. *   these items specify items equivalent to fields in NewScreen
  224.     EITEM SA_Left    ; traditional screen positions    and dimensions
  225.     EITEM SA_Top
  226.     EITEM SA_Width
  227.     EITEM SA_Height
  228.     EITEM SA_Depth    ; screen bitmap depth
  229.     EITEM SA_DetailPen    ; serves as default for windows, too
  230.     EITEM SA_BlockPen
  231.     EITEM SA_Title    ; default screen title
  232.  
  233.     EITEM SA_Colors    ; ti_Data is an array of struct ColorSpec,
  234.             ; terminated by ColorIndex = -1.  Specifies
  235.             ; initial screen palette colors.
  236.             ; Also see SA_Colors32 for use under V39.
  237.  
  238.     EITEM SA_ErrorCode    ; ti_Data points to LONG error code (values below)
  239.     EITEM SA_Font    ; equiv. to NewScreen.Font
  240.     EITEM SA_SysFont    ; Selects one of the preferences system fonts:
  241.             ;    0 - old DefaultFont, fixed-width
  242.             ;    1 - WB Screen preferred font
  243.  
  244.  
  245.     EITEM SA_Type    ; ti_Data is PUBLICSCREEN or CUSTOMSCREEN.  For other
  246.             ; fields of NewScreen.Type, see individual tags,
  247.             ; eg. SA_Behind, SA_Quiet.
  248.  
  249.     EITEM SA_BitMap    ; ti_Data is pointer to custom BitMap.    This
  250.             ; implies type of CUSTOMBITMAP
  251.  
  252.     E