home *** CD-ROM | disk | FTP | other *** search
/ Amiga ISO Collection / AmigaUtilCD2.iso / Programming / Misc / TRSICAT.LZX / CATS_CD2_TRSI / Inc&AD1.3 / Includes / intuition / screens.h < prev    next >
Encoding:
C/C++ Source or Header  |  1992-09-12  |  4.5 KB  |  143 lines

  1. #ifndef INTUITION_SCREENS_H
  2. #define INTUITION_SCREENS_H
  3. /*
  4. **    $Filename: intuition/screens.h $
  5. **    $Release: 1.3 $
  6. **
  7. **    
  8. **
  9. **    (C) Copyright 1987,1988 Commodore-Amiga, Inc.
  10. **        All Rights Reserved
  11. */
  12.  
  13. #ifndef EXEC_TYPES_H
  14. #include "exec/types.h"
  15. #endif
  16.  
  17. #ifndef GRAPHICS_GFX_H
  18. #include "graphics/gfx.h"
  19. #endif
  20.  
  21. #ifndef GRAPHICS_CLIP_H
  22. #include "graphics/clip.h"
  23. #endif
  24.  
  25. #ifndef GRAPHICS_VIEW_H
  26. #include "graphics/view.h"
  27. #endif
  28.  
  29. #ifndef GRAPHICS_RASTPORT_H
  30. #include "graphics/rastport.h"
  31. #endif
  32.  
  33. #ifndef GRAPHICS_LAYERS_H
  34. #include "graphics/layers.h"
  35. #endif
  36.  
  37. /* ======================================================================== */
  38. /* === Screen ============================================================= */
  39. /* ======================================================================== */
  40. struct Screen
  41. {
  42.     struct Screen *NextScreen;        /* linked list of screens */
  43.     struct Window *FirstWindow;        /* linked list Screen's Windows */
  44.  
  45.     SHORT LeftEdge, TopEdge;        /* parameters of the screen */
  46.     SHORT Width, Height;        /* parameters of the screen */
  47.  
  48.     SHORT MouseY, MouseX;        /* position relative to upper-left */
  49.  
  50.     USHORT Flags;            /* see definitions below */
  51.  
  52.     UBYTE *Title;            /* null-terminated Title text */
  53.     UBYTE *DefaultTitle;        /* for Windows without ScreenTitle */
  54.  
  55.     /* Bar sizes for this Screen and all Window's in this Screen */
  56.     BYTE BarHeight, BarVBorder, BarHBorder, MenuVBorder, MenuHBorder;
  57.     BYTE WBorTop, WBorLeft, WBorRight, WBorBottom;
  58.  
  59.     struct TextAttr *Font;        /* this screen's default font       */
  60.  
  61.     /* the display data structures for this Screen */
  62.     struct ViewPort ViewPort;        /* describing the Screen's display */
  63.     struct RastPort RastPort;        /* describing Screen rendering       */
  64.     struct BitMap BitMap;        /* extra copy of RastPort BitMap   */
  65.     struct Layer_Info LayerInfo;    /* each screen gets a LayerInfo       */
  66.  
  67.     /* You supply a linked-list of Gadgets for your Screen.
  68.      *    This list DOES NOT include system Gadgets.  You get the standard
  69.      *    system Screen Gadgets by default
  70.      */
  71.     struct Gadget *FirstGadget;
  72.  
  73.     UBYTE DetailPen, BlockPen;        /* for bar/border/gadget rendering */
  74.  
  75.     /* the following variable(s) are maintained by Intuition to support the
  76.      * DisplayBeep() color flashing technique
  77.      */
  78.     USHORT SaveColor0;
  79.  
  80.     /* This layer is for the Screen and Menu bars */
  81.     struct Layer *BarLayer;
  82.  
  83.     UBYTE *ExtData;
  84.  
  85.     UBYTE *UserData;    /* general-purpose pointer to User data extension */
  86. };
  87.  
  88.  
  89. /* --- FLAGS SET BY INTUITION --------------------------------------------- */
  90. /* The SCREENTYPE bits are reserved for describing various Screen types
  91.  * available under Intuition.  
  92.  */
  93. #define SCREENTYPE    0x000F    /* all the screens types available    */
  94. /* --- the definitions for the Screen Type ------------------------------- */
  95. #define WBENCHSCREEN    0x0001    /* Ta Da!  The Workbench        */
  96. #define CUSTOMSCREEN    0x000F    /* for that special look        */
  97.  
  98. #define SHOWTITLE    0x0010    /* this gets set by a call to ShowTitle() */
  99.  
  100. #define BEEPING        0x0020    /* set when Screen is beeping        */
  101.  
  102. #define CUSTOMBITMAP    0x0040    /* if you are supplying your own BitMap */
  103.  
  104. #define SCREENBEHIND    0x0080    /* if you want your screen to open behind
  105.                  * already open screens
  106.                  */
  107. #define SCREENQUIET    0x0100    /* if you do not want Intuition to render
  108.                  * into your screen (gadgets, title)
  109.                  */
  110.  
  111. #define STDSCREENHEIGHT -1    /* supply in NewScreen.Height        */
  112.  
  113.  
  114. /* ======================================================================== */
  115. /* === NewScreen ========================================================== */
  116. /* ======================================================================== */
  117. struct NewScreen
  118. {
  119.     SHORT LeftEdge, TopEdge, Width, Height, Depth;  /* screen dimensions */
  120.  
  121.     UBYTE DetailPen, BlockPen;         /* for bar/border/gadget rendering */
  122.  
  123.     USHORT ViewModes;        /* the Modes for the ViewPort (and View) */
  124.  
  125.     USHORT Type;        /* the Screen type (see defines above) */
  126.     
  127.     struct TextAttr *Font;    /* this Screen's default text attributes */
  128.     
  129.     UBYTE *DefaultTitle;    /* the default title for this Screen */
  130.     
  131.     struct Gadget *Gadgets;    /* your own Gadgets for this Screen */
  132.     
  133.     /* if you are opening a CUSTOMSCREEN and already have a BitMap 
  134.      * that you want used for your Screen, you set the flags CUSTOMBITMAP in
  135.      * the Type field and you set this variable to point to your BitMap
  136.      * structure.  The structure will be copied into your Screen structure,
  137.      * after which you may discard your own BitMap if you want
  138.      */
  139.     struct BitMap *CustomBitMap;
  140. };
  141.  
  142. #endif    /* INTUITION_SCREENS_H */
  143.