home *** CD-ROM | disk | FTP | other *** search
- #include <inline/stub.h>
- #ifndef BASE_EXT_DECL
- #define BASE_EXT_DECL extern struct Library * DiskfontBase;
- #endif
- #ifndef BASE_PAR_DECL
- #define BASE_PAR_DECL
- #define BASE_PAR_DECL0 void
- #endif
- #ifndef BASE_NAME
- #define BASE_NAME DiskfontBase
- #endif
- __inline static struct TextFont* OpenDiskFont(BASE_PAR_DECL struct TextAttr* textAttr)
- {
- BASE_EXT_DECL
- register struct TextFont* res __asm("d0");
- register void *a6 __asm ("a6");
- register struct TextAttr* a0 __asm("a0");
-
- a6 = BASE_NAME;
- a0 = textAttr;
- __asm volatile ("
- jsr a6@(-0x1e)"
- : "=g" (res)
- : "g" (a6), "g" (a0)
- : "d0", "d1", "a0", "a1");
- return res;
- }
- __inline static LONG AvailFonts(BASE_PAR_DECL STRPTR buffer, long int bufBytes, long int flags)
- {
- BASE_EXT_DECL
- register LONG res __asm("d0");
- register void *a6 __asm ("a6");
- register STRPTR a0 __asm("a0");
- register long int d0 __asm("d0");
- register long int d1 __asm("d1");
-
- a6 = BASE_NAME;
- a0 = buffer;
- d0 = bufBytes;
- d1 = flags;
- __asm volatile ("
- jsr a6@(-0x24)"
- : "=g" (res)
- : "g" (a6), "g" (a0), "g" (d0), "g" (d1)
- : "d0", "d1", "a0", "a1");
- return res;
- }
- __inline static struct FontContentsHeader* NewFontContents(BASE_PAR_DECL BPTR fontsLock, STRPTR fontName)
- {
- BASE_EXT_DECL
- register struct FontContentsHeader* res __asm("d0");
- register void *a6 __asm ("a6");
- register BPTR a0 __asm("a0");
- register STRPTR a1 __asm("a1");
-
- a6 = BASE_NAME;
- a0 = fontsLock;
- a1 = fontName;
- __asm volatile ("
- jsr a6@(-0x2a)"
- : "=g" (res)
- : "g" (a6), "g" (a0), "g" (a1)
- : "d0", "d1", "a0", "a1");
- return res;
- }
- __inline static void DisposeFontContents(BASE_PAR_DECL struct FontContentsHeader* fontContentsHeader)
- {
- BASE_EXT_DECL
- register void *a6 __asm ("a6");
- register struct FontContentsHeader* a1 __asm("a1");
-
- a6 = BASE_NAME;
- a1 = fontContentsHeader;
- __asm volatile ("
- jsr a6@(-0x30)"
- : /* no output */
- : "g" (a6), "g" (a1)
- : "d0", "d1", "a0", "a1");
- }
- __inline static struct DiskFontHeader* NewScaledDiskFont(BASE_PAR_DECL struct TextFont* sourceFont, struct TextAttr* destTextAttr)
- {
- BASE_EXT_DECL
- register struct DiskFontHeader* res __asm("d0");
- register void *a6 __asm ("a6");
- register struct TextFont* a0 __asm("a0");
- register struct TextAttr* a1 __asm("a1");
-
- a6 = BASE_NAME;
- a0 = sourceFont;
- a1 = destTextAttr;
- __asm volatile ("
- jsr a6@(-0x36)"
- : "=g" (res)
- : "g" (a6), "g" (a0), "g" (a1)
- : "d0", "d1", "a0", "a1");
- return res;
- }
- #undef BASE_EXT_DECL
- #undef BASE_PAR_DECL
- #undef BASE_PAR_DECL0
- #undef BASE_NAME
-