home *** CD-ROM | disk | FTP | other *** search
/ Tools / WinSN5.0Ver.iso / NETSCAP.50 / WIN1998.ZIP / ns / cmd / xfe / XfeWidgets / Xfe / BmButtonP.h < prev    next >
Encoding:
C/C++ Source or Header  |  1998-04-08  |  4.8 KB  |  133 lines

  1. /* -*- Mode: C; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*-
  2.  *
  3.  * The contents of this file are subject to the Netscape Public License
  4.  * Version 1.0 (the "NPL"); you may not use this file except in
  5.  * compliance with the NPL.  You may obtain a copy of the NPL at
  6.  * http://www.mozilla.org/NPL/
  7.  *
  8.  * Software distributed under the NPL is distributed on an "AS IS" basis,
  9.  * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the NPL
  10.  * for the specific language governing rights and limitations under the
  11.  * NPL.
  12.  *
  13.  * The Initial Developer of this code under the NPL is Netscape
  14.  * Communications Corporation.  Portions created by Netscape are
  15.  * Copyright (C) 1998 Netscape Communications Corporation.  All Rights
  16.  * Reserved.
  17.  */
  18. /*-----------------------------------------*/
  19. /*                                                                        */
  20. /* Name:        <Xfe/BmButtonP.h>                                        */
  21. /* Description:    XfeBmButton widget private header file.                    */
  22. /* Author:        Ramiro Estrugo <ramiro@netscape.com>                    */
  23. /*                                                                        */
  24. /*----------------------------------------------------------------------*/
  25.  
  26.  
  27. #ifndef _XfeBmButtonP_h_                        /* start BmButtonP.h    */
  28. #define _XfeBmButtonP_h_
  29.  
  30. #include <Xfe/PrimitiveP.h>
  31. #include <Xfe/BmButton.h>
  32. #include <Xm/PushBP.h>
  33.  
  34. #ifdef __cplusplus                                /* start C++            */
  35. extern "C" {
  36. #endif
  37.    
  38. /*----------------------------------------------------------------------*/
  39. /*                                                                        */
  40. /* XfeBmButtonClassRec                                                    */
  41. /*                                                                        */
  42. /*----------------------------------------------------------------------*/
  43. typedef struct
  44. {
  45.     XtPointer        extension;                    /* Extension            */
  46. } XfeBmButtonClassPart;
  47.  
  48. /*----------------------------------------------------------------------*/
  49. /*                                                                        */
  50. /* XfeBmButtonPart                                                        */
  51. /*                                                                        */
  52. /*----------------------------------------------------------------------*/
  53. typedef struct _XfeBmButtonClassRec
  54. {
  55.     CoreClassPart                core_class;            /* Core class        */
  56.     XmPrimitiveClassPart        primitive_class;    /* XmPrimitive        */
  57.     XmLabelClassPart            label_class;        /* XmLabel            */
  58.     XmPushButtonClassPart        pushbutton_class;    /* XmPushButton        */
  59.     XfeBmButtonClassPart        bm_button_class;    /* XfeBmButton        */
  60. } XfeBmButtonClassRec;
  61.  
  62. externalref XfeBmButtonClassRec xfeBmButtonClassRec;
  63.  
  64. /*----------------------------------------------------------------------*/
  65. /*                                                                        */
  66. /* XfeBmButtonRec                                                        */
  67. /*                                                                        */
  68. /*----------------------------------------------------------------------*/
  69. typedef struct _XfeBmButtonPart
  70. {
  71.     /* Pixmap resources */
  72.     Pixmap                arm_pixmap_mask;            /* Arm pixmap mask    */
  73.     Pixmap                label_pixmap_mask;            /* Label pixmap mask*/
  74.     unsigned char        accent_type;                /* Accent type        */
  75.  
  76.     /* Private Data Members */
  77.     GC                    pixmap_GC;                    /* Pixmap gc        */
  78.  
  79.     Dimension            pixmap_width;
  80.     Dimension            pixmap_height;
  81. } XfeBmButtonPart;
  82.  
  83. /*----------------------------------------------------------------------*/
  84. /*                                                                        */
  85. /* XfeBmButtonPart                                                        */
  86. /*                                                                        */
  87. /*----------------------------------------------------------------------*/
  88. typedef struct _XfeBmButtonRec
  89. {
  90.     CorePart                core;                /* Core Part            */
  91.     XmPrimitivePart            primitive;            /* XmPrimitive Part        */
  92.     XmLabelPart                label;                /* XmLabel Part            */
  93.     XmPushButtonPart        pushbutton;            /* XmPushButton Part    */
  94.     XfeBmButtonPart            bm_button;            /* XfeBmButton part        */
  95. } XfeBmButtonRec;
  96.  
  97. /*----------------------------------------------------------------------*/
  98. /*                                                                        */
  99. /* XfeBmButtonPart Access Macro                                            */
  100. /*                                                                        */
  101. /*----------------------------------------------------------------------*/
  102. #define _XfeBmButtonPart(w) &(((XfeBmButtonWidget) w) -> bm_button)
  103.  
  104. /*----------------------------------------------------------------------*/
  105. /*                                                                        */
  106. /* Private XfeBmButton/BmCascade functions                                */
  107. /*                                                                        */
  108. /*----------------------------------------------------------------------*/
  109. extern void
  110. _XfeBmActionWithoutDrawing        (Widget                w,
  111.                                  XtActionProc        proc,
  112.                                  XEvent *            event,
  113.                                  char **            params,
  114.                                  Cardinal *            nparams);
  115. /*----------------------------------------------------------------------*/
  116. extern void
  117. _XfeBmProcWithoutDrawing        (Widget                w,
  118.                                  XtWidgetProc        proc);
  119. /*----------------------------------------------------------------------*/
  120.  
  121. /*----------------------------------------------------------------------*/
  122. /*                                                                        */
  123. /* Means the cursor is outside the target accent button/cascade.        */
  124. /*                                                                        */
  125. /*----------------------------------------------------------------------*/
  126. #define XfeACCENT_OUTSIDE -1
  127.  
  128. #ifdef __cplusplus                                /* end C++                */
  129. }
  130. #endif
  131.  
  132. #endif                                            /* end BmButtonP.h        */
  133.