home *** CD-ROM | disk | FTP | other *** search
/ Developer CD Series 1999 …ember: Reference Library / Apple Developer Reference Library (December 1999) (Disk 1).iso / pc / technical documentation / macintosh technotes and q&as / technotes / tn / samplecode.sit.hqx / Sample Code / StorageLibrary.h < prev    next >
Encoding:
C/C++ Source or Header  |  1997-07-22  |  2.2 KB  |  85 lines

  1. /*
  2.     File:        StorageLibrary.h
  3.  
  4.     Contains:    Graphics library for primitive flattening of QuickDraw GX data.
  5.  
  6.     Written by:    Cary Clark, Georgiann Delaney, Michael Fairman, Dave Good, Robert Johnson, Keith McGreggor, Oliver Steele, David Van Brink, Chris Yerga
  7.  
  8.     Copyright:    © 1995-1997 by Apple Computer, Inc., all rights reserved.
  9.  
  10.     Writers:
  11.  
  12.         (jtd)    John Daggett
  13.         (DH)    David Hayward
  14.         (IK)    Ingrid Kelly
  15.  
  16.     Change History (most recent first):
  17.  
  18.          <4>      6/1/97    IK        Modify printing routines for GXGraphics 1.1.6.
  19.          <3>      4/8/97    DH        Added ShapeToFSSpec and FSSpecToShape.
  20.          <2>      5/1/95    jtd        Bringing in final 1.1 source changes.
  21.          <1>      1/9/95    jtd        First checked in.
  22. */
  23.  
  24. #ifndef __STORAGELIBRARY__
  25. #define __STORAGELIBRARY__
  26.  
  27. #ifndef __FILES__
  28. #include <Files.h>
  29. #endif
  30.  
  31. #ifndef __GXTYPES__
  32. #include <GXTypes.h>
  33. #endif
  34.  
  35. #ifdef __cplusplus
  36. extern "C" {
  37. #endif
  38.  
  39. #if PRAGMA_ALIGN_SUPPORTED
  40. #pragma options align=mac68k
  41. #endif
  42.  
  43. #if PRAGMA_IMPORT_SUPPORTED
  44. #pragma import on
  45. #endif
  46.  
  47. /* For compatibility with old headers. */
  48. #define storageLibraryIncludes
  49.  
  50. struct userSpool {
  51.     gxSpoolBlock    spool;
  52.     long            reference;
  53.     long            position;
  54.     long            size;
  55.     void            *data;
  56.     void            *userField;
  57. };
  58. typedef struct userSpool userSpool;
  59.  
  60. extern Handle    GXStShapeToHandle(gxShape source);
  61. extern Handle    GXStShapeToHandleWithFlags(gxShape source, gxFlattenFlag flags);
  62. extern gxShape    GXStHandleToShape(Handle target, long count, const gxViewPort portList[]);
  63. extern void        GXStShapeToFRef(gxShape source, short fileRef);
  64. extern gxShape    GXStFRefToShape(short fileRef, long count, const gxViewPort portList[]);
  65. extern void        GXStShapeToFile(gxShape source, Str255 fileName, short vRefNum, OSType creator, OSType fileType);
  66. extern gxShape    GXStFileToShape(Str255 fileName, short vRefNum, long count, const gxViewPort portList[]);
  67. extern void        GXStShapeToFSSpec(gxShape source, FSSpec* spec, OSType creator, OSType fileType, ScriptCode script);
  68. extern gxShape    GXStFSSpecToShape(FSSpec* spec, long count, const gxViewPort portList[]);
  69. extern Handle    GXStFontToHandle(gxFont fontID, long glyphBits[]);
  70. extern gxFont    GXStHandleToFont(Handle source);
  71.  
  72. #if PRAGMA_IMPORT_SUPPORTED
  73. #pragma import off
  74. #endif
  75.  
  76. #if PRAGMA_ALIGN_SUPPORTED
  77. #pragma options align=reset
  78. #endif
  79.  
  80. #ifdef __cplusplus
  81. }
  82. #endif
  83.  
  84. #endif /* __STORAGELIBRARY__ */
  85.