home *** CD-ROM | disk | FTP | other *** search
/ AmigActive 24 / AACD 24.iso / AACD / System / ReqToolsLib / Source / reqtools / rtgetvscreensize.c < prev    next >
Encoding:
C/C++ Source or Header  |  2001-07-02  |  1.9 KB  |  86 lines

  1.  
  2. /*
  3.     (C) 1999 - 2000 AROS - The Amiga Research OS
  4.     $Id: rtgetvscreensize.c,v 1.3 2000/11/26 16:53:48 stegerg Exp $
  5.  
  6.     Desc:
  7.     Lang: English
  8. */
  9.  
  10. #include <exec/types.h>
  11. #include <proto/exec.h>
  12. #include <proto/reqtools.h>
  13. #include <proto/intuition.h>
  14. #include <exec/libraries.h>
  15. #include <exec/memory.h>
  16. #include <aros/libcall.h>
  17.  
  18. #include "reqtools_intern.h"
  19.  
  20. /*****************************************************************************
  21.  
  22.     NAME */
  23.  
  24.     AROS_LH3(ULONG, rtGetVScreenSize,
  25.  
  26. /*  SYNOPSIS */
  27.  
  28.     AROS_LHA(struct Screen *, screen, A0),
  29.     AROS_LHA(ULONG *, widthptr, A1),
  30.     AROS_LHA(ULONG *, heightptr, A2),
  31.  
  32. /*  LOCATION */
  33.  
  34.     struct ReqToolsBase *, ReqToolsBase, 20, ReqTools)
  35.  
  36. /*  FUNCTION
  37.     Use this function to get the size of the visible portion of a
  38.     screen.
  39.  
  40.     The value returned by rtGetVScreenSize() can be used for vertical
  41.     spacing. It will be larger for interlaced and productivity screens.
  42.     Using this number for spacing will assure your requester will look
  43.     good on an interlaced and a non-interlaced screen.
  44.  
  45.     Current return codes are 2 for non-interlaced and 4 for interlaced.
  46.     These values may change in the future, don't depend on them too
  47.     much. They will in any case remain of the same magnitude.
  48.    
  49.     INPUTS
  50.     screen - pointer to the screen.
  51.     widthptr - address of an ULONG variable to hold the width.
  52.     heightptr - address of an ULONG variable to hold the height.
  53.  
  54.     RESULT
  55.     spacing - vertical spacing for the screen.
  56.  
  57.     NOTES
  58.     This function is for the advanced ReqTools user.
  59.  
  60.     EXAMPLE
  61.  
  62.     BUGS
  63.  
  64.     SEE ALSO
  65.  
  66.     INTERNALS
  67.  
  68.     HISTORY
  69.  
  70. ******************************************************************************/
  71. {
  72.     AROS_LIBFUNC_INIT
  73.  
  74.     int width, height, retval;
  75.     
  76.     retval = GetVScreenSize(screen, &width, &height); /* general.c */
  77.     
  78.     *widthptr  = (ULONG)width;
  79.     *heightptr = (ULONG)height;
  80.     
  81.     return (ULONG)retval;
  82.     
  83.     AROS_LIBFUNC_EXIT
  84.     
  85. } /* rtGetVScreenSize */
  86.