home *** CD-ROM | disk | FTP | other *** search
/ The Fred Fish Collection 1.5 / ffcollection-1-5-1992-11.iso / ff_disks / 200-299 / ff253.lzh / Elements / Source / elements.h < prev    next >
C/C++ Source or Header  |  1989-10-19  |  3KB  |  95 lines

  1. /***************************************************************************
  2.  * elements.h - CAMM v2.0 Periodic Table of the Elements header file.      *
  3.  * ----------------------------------------------------------------------- *
  4.  * Modification History:                                                   *
  5.  * 11-10-88    Created: constants and structures defined                   *
  6.  * 10-02-89    Fixed for Lattice "C" v5.02, element select bug fixed
  7.  ***************************************************************************/
  8.  
  9. #include <exec/types.h>
  10. #include <graphics/text.h>
  11. #include <graphics/rastport.h>
  12. #include <graphics/layers.h>
  13. #include <graphics/gfxbase.h>
  14. #include <exec/ports.h>
  15. #include <exec/execbase.h>
  16. #include <intuition/intuition.h>
  17. #include <graphics/text.h>
  18. #include <exec/memory.h>
  19. #include <fcntl.h>
  20. #include <stdio.h>
  21.  
  22. #define DEPTH           2     /* two bitplanes (4 colors) */
  23. #define SCREEN_WIDTH    640
  24. #define SCREEN_HEIGHT   400
  25. #define EWIN_TOP        11
  26. #define EWIN_WIDTH      640   /* elements window */
  27. #define EWIN_HEIGHT     400-EWIN_TOP
  28. #define IWIN_TOP        100
  29. #define IWIN_LEFT       150
  30. #define IWIN_WIDTH      394   /* information window */
  31. #define IWIN_HEIGHT     174
  32. #define INFOTEXTX       5L
  33. #define INFOTEXT        16L
  34. #define EOFF_X          20L
  35. #define EOFF_Y          25L
  36. #define BOX_W           33L    /* element box */
  37. #define BOX_H           36L
  38. #define E_TITLE         "Periodic Table of the Elements"
  39. #define SCREEN_TITLE    "Elements - v1.2a (c)1989 Paul T. Miller"
  40. #define BOX_COLOR       1L
  41. #define ENUM_X          3L
  42. #define ENUM_Y          2L
  43. #define ESYM_X          14L
  44. #define ESYM_Y          17L
  45. #define SHADOWDEPTH     3L
  46. #define EOFF_SHADX      30L
  47. #define EOFF_SHADY      32L
  48. #define SHADOWBLACK     4L
  49. #define BACKGROUND      0L
  50. #define GREENTEXT       1L
  51. #define BLUETEXT        2L
  52. #define REDTEXT         3L
  53. #define ROWNUM_Y        (BOX_H - 5)/2
  54.  
  55. #define ELEMENTS        106      /* number of elements supported */
  56. #define ELEMENTS_FILE   "DAT:Elements.DAT"
  57. #define INFO_FILE       "DAT:Info.DAT"
  58. #define ISOTOPES_FILE   "DAT:Isotopes.DAT"
  59.  
  60. struct Window *get_window();
  61.  
  62. #define SOLID_E         1
  63. #define LIQUID_E        2
  64. #define GAS_E           3
  65. #define SYNTHETIC_E     4
  66.  
  67. struct Element {
  68.    USHORT   number;        /* atomic number */
  69.    USHORT   column;        /* column on periodic table */
  70.    USHORT   row;           /* row on periodic table */
  71.    char     symbol[4];     /* atomic symbol */
  72.    char     name[13];      /* element's name */
  73.    USHORT   type;          /* stable form */
  74. };
  75.  
  76. struct Info {
  77.    USHORT   Structure;
  78.    FLOAT    AWeight;
  79.    FLOAT    BoilingP;
  80.    FLOAT    MeltingP;
  81.    FLOAT    Density;
  82.    FLOAT    CRadius;
  83.    FLOAT    ARadius;
  84.    FLOAT    AVolume;
  85.    FLOAT    IonPot;
  86.    FLOAT    SpecHeat;
  87.    FLOAT    Electroneg;
  88.    FLOAT    HeatVap;
  89.    FLOAT    HeatFus;
  90.    char     ElecCond[13];
  91.    FLOAT    ThermalCond;
  92.    char     Config[25];
  93.    char     OxiStates[11];
  94. };
  95.