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

  1.  
  2. /*
  3.     (C) 1999 - 2000 AROS - The Amiga Research OS
  4.     $Id: rtpaletterequesta.c,v 1.3 2000/11/26 16:53:49 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(LONG, rtPaletteRequestA,
  25.  
  26. /*  SYNOPSIS */
  27.  
  28.     AROS_LHA(char *, title, A2),
  29.     AROS_LHA(struct rtReqInfo *, reqinfo, A3),
  30.     AROS_LHA(struct TagItem *, taglist, A0),
  31.  
  32. /*  LOCATION */
  33.  
  34.     struct ReqToolsBase *, ReqToolsBase, 17, ReqTools)
  35.  
  36. /*  FUNCTION
  37.     Put up a palette requester so the user can change the screen's
  38.     colors.
  39.  
  40.     The colors are changed in the viewport of the screen the requester
  41.     will appear on, so that is where you will find them after the
  42.     palette requester returns.
  43.  
  44.     The selected color is returned, so you can also use this requester
  45.     to let the user select a color.
  46.  
  47.     'reqinfo' can be used to customize the requester. For greater
  48.     control use the tags listed below. The advantage of the rtReqInfo
  49.     structure is that it is global, where tags have to be specified
  50.     each function call. See libraries/reqtools.[hi] for a description
  51.     of the rtReqInfo structure.
  52.    
  53.     INPUTS
  54.     title - pointer to requester window title (null terminated).
  55.     reqinfo - pointer to a rtReqInfo structure allocated with
  56.         rtAllocRequest() or NULL.
  57.     taglist - pointer to a TagItem array.
  58.  
  59.     TAGS
  60.     RT_Window - see rtEZRequestA()
  61.  
  62.     RT_ReqPos - see rtEZRequestA()
  63.  
  64.     RT_LeftOffset - see rtEZRequestA()
  65.  
  66.     RT_TopOffset - see rtEZRequestA()
  67.  
  68.     RT_PubScrName - see rtEZRequestA()
  69.  
  70.     RT_Screen - see rtEZRequestA()
  71.  
  72.     RT_ReqHandler - see rtEZRequestA()
  73.  
  74.     RT_WaitPointer - see rtEZRequestA()
  75.  
  76.     RT_LockWindow - [V38] see rtEZRequestA()
  77.  
  78.     RT_ScreenToFront - [V38] see rtEZRequestA()
  79.  
  80.     RT_ShareIDCMP - [V38] see rtEZRequestA()
  81.  
  82.     RT_Locale - [V38] see rtEZRequestA()
  83.  
  84.     RT_IntuiMsgFunc - [V38] see rtEZRequestA()
  85.  
  86.     RT_DefaultFont - (struct TextFont *) This tag allows you to specify
  87.         the font to be used in the requester when the screen font is
  88.         proportional. Default is GfxBase->DefaultFont. This tag is
  89.         obsolete in ReqTools 2.2 and higher, when running OS 3.0 or
  90.         higher!
  91.  
  92.     RT_TextAttr - [V38] see rtFileRequestA() If the font is
  93.         proportional on Kickstart 2.04 or below ReqTools will use the
  94.         system default font or the font supplied with RT_DefaultFont.
  95.         On Kickstart 3.0 or higher the proportional font is used.
  96.  
  97.     RTPA_Color - (ULONG) Initially selected color of palette. Default
  98.         is 1.
  99.  
  100.     RESULT
  101.     color - the color number of the selected color or -1 if the user
  102.         canceled the requester.
  103.  
  104.     NOTES
  105.     Automatically adjusts the requester to the screen font. On
  106.     Kickstart 2.04 or lower, if the screen font is proportional the
  107.     default font will be used.
  108.  
  109.     If the requester got too big for the screen because of a very large
  110.     font, the topaz.font will be used.
  111.  
  112.     rtPaletteRequestA() checks the pr_WindowPtr of your process to find
  113.     the screen to put the requester on.
  114.  
  115.     EXAMPLE
  116.  
  117.     BUGS
  118.     none known
  119.  
  120.     SEE ALSO
  121.  
  122.     INTERNALS
  123.  
  124.     HISTORY
  125.  
  126. ******************************************************************************/
  127. {
  128.     AROS_LIBFUNC_INIT
  129.  
  130.     return PaletteRequestA(title, reqinfo, taglist); /* in palettereq.c */
  131.     
  132.     AROS_LIBFUNC_EXIT
  133.     
  134. } /* rtPaletteRequestA */
  135.