Create Xref-Html Frames                    Remove All Frames
file:c:/local/Cygwin/usr/X11R6/include/Xm/Xm.h        (Tue Mar 30 23:22:48 2004 )


   1: /**
   2:  *
   3:  * $Header: /cvsroot/lesstif/lesstif/include/Motif-2.1/Xm/Xm.h.in,v 1.33 2002/09/10 22:09:13 dannybackx Exp $
   4:  *
   5:  * Copyright  1995 Free Software Foundation, Inc.
   6:  * Copyright  1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002 LessTif Development Team
   7:  *
   8:  * This file is part of the GNU LessTif Library.
   9:  *
  10:  * This library is free software; you can redistribute it and/or
  11:  * modify it under the terms of the GNU Library General Public
  12:  * License as published by the Free Software Foundation; either
  13:  * version 2 of the License, or (at your option) any later version.
  14:  *
  15:  * This library is distributed in the hope that it will be useful,
  16:  * but WITHOUT ANY WARRANTY; without even the implied warranty of
  17:  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
  18:  * Library General Public License for more details.
  19:  *
  20:  * You should have received a copy of the GNU Library General Public
  21:  * License along with this library; if not, write to the Free
  22:  * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
  23:  *
  24:  **/
  25: 
  26: 
  27: #ifndef _XM_XM_H
  28: #define _XM_XM_H
  29: 
  30: #include <stddef.h>    /* for  wchar_t, etc. */
  31: 
  32: #include <X11/Intrinsic.h>
  33: #include <X11/Shell.h>
  34: #include <X11/Xatom.h>
  35: 
  36: /* handy little define */
  37: 
  38: #if NeedFunctionPrototypes
  39: #define _XmANSI_ARGS_(args) args
  40: #else
  41: #define _XmANSI_ARGS_(args) ()
  42: #endif
  43: 
  44: /* Version Information */
  45: #define LESSTIF_VERSION  0
  46: #define LESSTIF_REVISION 93
  47: 
  48: #define LesstifVersion (LESSTIF_VERSION * 1000 + LESSTIF_REVISION)
  49: #define LesstifVERSION_STRING "@(#)GNU/LessTif Version 2.1 Release 0.93.94"
  50: 
  51: /* since we're replacing Motif 2.1... */
  52: #define XmVERSION 2
  53: #define XmREVISION 1
  54: #define XmVersion (XmVERSION * 1000 + XmREVISION)
  55: #define XmVERSION_STRING LesstifVERSION_STRING
  56: #define XmUPDATE_LEVEL 0
  57: 
  58: /* Our headers may use the #defines made above! */
  59: #include <Xm/XmStrDefs.h>
  60: #include <Xm/VirtKeys.h>
  61: #include <Xm/Transfer.h>
  62: #include <Xm/Primitive.h>
  63: #include <Xm/Manager.h>
  64: #include <Xm/Gadget.h>
  65: 
  66: #ifdef __cplusplus
  67: extern "C" {
  68: #endif
  69: 
  70: extern int xmUseVersion;
  71: 
  72: /* pixmap stuff */
  73: 
  74: #define XmUNSPECIFIED_PIXMAP  2
  75: 
  76: /* define for easy checking for unset resources */
  77: 
  78: #define XmUNSPECIFIED (~0)
  79: 
  80: /*
  81:  * vendor defines (hey, GNU is a vendor)
  82:  */
  83: #define XmSTRING_OS_CHARSET             XmSTRING_ISO8859_1
  84: #ifndef XmFALLBACK_CHARSET
  85: #define XmFALLBACK_CHARSET              XmSTRING_ISO8859_1
  86: #endif
  87: 
  88: #define XmDEFAULT_FONT                  _XmSDEFAULT_FONT
  89: #define XmDEFAULT_BACKGROUND            _XmSDEFAULT_BACKGROUND
  90: #define XmDEFAULT_DARK_THRESHOLD        20
  91: #define XmDEFAULT_LIGHT_THRESHOLD       93
  92: #define XmDEFAULT_FOREGROUND_THRESHOLD  70
  93: 
  94: extern char    _XmSDEFAULT_FONT[];
  95: extern char    _XmSDEFAULT_BACKGROUND[];
  96: 
  97: typedef unsigned char XmDirection;
  98: 
  99: #define XmDIRECTION_IGNORED 0x30
 100: 
 101: #define XmRIGHT_TO_LEFT_MASK 0x01
 102: #define XmLEFT_TO_RIGHT_MASK 0x02
 103: #define XmHORIZONTAL_MASK 0x03
 104: #define XmTOP_TO_BOTTOM_MASK 0x04
 105: #define XmBOTTOM_TO_TOP_MASK 0x08
 106: #define XmVERTICAL_MASK 0x0c
 107: #define XmPRECEDENCE_HORIZ_MASK 0x40
 108: #define XmPRECEDENCE_VERT_MASK 0x80
 109: #define XmPRECEDENCE_MASK 0xc0
 110: 
 111: enum {
 112:     XmRIGHT_TO_LEFT_TOP_TO_BOTTOM =
 113:         XmRIGHT_TO_LEFT_MASK | XmTOP_TO_BOTTOM_MASK | XmPRECEDENCE_HORIZ_MASK,
 114:     XmLEFT_TO_RIGHT_TOP_TO_BOTTOM =
 115:         XmLEFT_TO_RIGHT_MASK | XmTOP_TO_BOTTOM_MASK | XmPRECEDENCE_HORIZ_MASK,
 116:     XmRIGHT_TO_LEFT_BOTTOM_TO_TOP =
 117:         XmRIGHT_TO_LEFT_MASK | XmBOTTOM_TO_TOP_MASK | XmPRECEDENCE_HORIZ_MASK,
 118:     XmLEFT_TO_RIGHT_BOTTOM_TO_TOP =
 119:         XmLEFT_TO_RIGHT_MASK | XmBOTTOM_TO_TOP_MASK | XmPRECEDENCE_HORIZ_MASK,
 120:     XmTOP_TO_BOTTOM_RIGHT_TO_LEFT =
 121:         XmRIGHT_TO_LEFT_MASK | XmTOP_TO_BOTTOM_MASK | XmPRECEDENCE_VERT_MASK,
 122:     XmTOP_TO_BOTTOM_LEFT_TO_RIGHT =
 123:         XmLEFT_TO_RIGHT_MASK | XmTOP_TO_BOTTOM_MASK | XmPRECEDENCE_VERT_MASK,
 124:     XmBOTTOM_TO_TOP_RIGHT_TO_LEFT =
 125:         XmRIGHT_TO_LEFT_MASK | XmBOTTOM_TO_TOP_MASK | XmPRECEDENCE_VERT_MASK,
 126:     XmBOTTOM_TO_TOP_LEFT_TO_RIGHT =
 127:         XmLEFT_TO_RIGHT_MASK | XmBOTTOM_TO_TOP_MASK | XmPRECEDENCE_VERT_MASK,
 128:     XmTOP_TO_BOTTOM =
 129:         XmTOP_TO_BOTTOM_MASK | XmHORIZONTAL_MASK | XmPRECEDENCE_MASK,
 130:     XmBOTTOM_TO_TOP =
 131:         XmBOTTOM_TO_TOP_MASK | XmHORIZONTAL_MASK | XmPRECEDENCE_MASK,
 132:     XmRIGHT_TO_LEFT =
 133:         XmRIGHT_TO_LEFT_MASK | XmVERTICAL_MASK | XmPRECEDENCE_MASK,
 134:     XmLEFT_TO_RIGHT =
 135:         XmLEFT_TO_RIGHT_MASK | XmVERTICAL_MASK | XmPRECEDENCE_MASK,
 136:     XmDEFAULT_DIRECTION = 0xff
 137: };
 138:   
 139: /*
 140:  * XmString stuff
 141:  */
 142: 
 143: typedef enum {
 144:     XmFONT_IS_FONT,
 145:     XmFONT_IS_FONTSET,
 146:     XmFONT_IS_XOC,  /* IBM's BiDi extension to Motif */
 147:     XmFONT_IS_XFT /* FontConfig */
 148: } XmFontType;
 149: 
 150: enum {
 151:     XmSTRING_DIRECTION_L_TO_R, 
 152:     XmSTRING_DIRECTION_R_TO_L,
 153:     XmSTRING_DIRECTION_UNSET = 3,
 154:     XmSTRING_DIRECTION_DEFAULT = XmDEFAULT_DIRECTION
 155: };
 156: 
 157: typedef unsigned char XmStringDirection;
 158: typedef unsigned char *XmString;
 159: typedef XmString *XmStringTable;
 160: typedef char *XmStringCharSet;
 161: typedef unsigned char XmStringComponentType;
 162: typedef char *XmStringTag;
 163: 
 164: typedef struct __XmStringContextRec *_XmStringContext;
 165: typedef struct __XmStringRec *_XmString;
 166: typedef struct _XmtStringContextRec *XmStringContext;
 167: typedef struct _XmFontListContextRec *XmFontContext;
 168: 
 169: /*
 170:  * Rendering stuff
 171:  *  The definitions for this replace some older XmFontList* stuff.
 172:  *  Here's the old stuff for reference :
 173:  *  typedef struct _XmFontListRec *XmFontListEntry, *XmFontList;
 174:  */
 175: typedef struct __XmRenditionRec   *XmFontListEntry;
 176: typedef struct __XmRenderTableRec *XmFontList;
 177: 
 178: typedef struct __XmRenditionRec   *XmRendition;
 179: typedef struct __XmRenderTableRec *XmRenderTable;
 180: 
 181: enum {
 182:     XmSTRING_COMPONENT_UNKNOWN,   /* 0 */
 183:     XmSTRING_COMPONENT_CHARSET,   /* 1 */
 184:     XmSTRING_COMPONENT_TEXT,    /* 2 */
 185:     XmSTRING_COMPONENT_DIRECTION, /* 3 */
 186:     XmSTRING_COMPONENT_SEPARATOR, /* 4 */
 187:     XmSTRING_COMPONENT_LOCALE_TEXT, /* 5 */
 188:     XmSTRING_COMPONENT_LOCALE,    /* 6 */
 189:     XmSTRING_COMPONENT_WIDECHAR_TEXT, /* 7 */
 190:     XmSTRING_COMPONENT_LAYOUT_PUSH, /* 8 */
 191:     XmSTRING_COMPONENT_LAYOUT_POP,  /* 9 */
 192:     XmSTRING_COMPONENT_RENDITION_BEGIN, /* 10 */
 193:     XmSTRING_COMPONENT_RENDITION_END, /* 11 */
 194:     XmSTRING_COMPONENT_TAB    /* 12 */
 195:     /* 13 - 125 is said to be reserved */
 196: };
 197: 
 198: #define XmSTRING_COMPONENT_FONTLIST_ELEMENT_TAG XmSTRING_COMPONENT_CHARSET
 199: 
 200: #define XmSTRING_COMPONENT_TAG          XmSTRING_COMPONENT_CHARSET
 201: 
 202: #define XmSTRING_COMPONENT_END          ((XmStringComponentType) 126)
 203: /* anybody know what 127 is? */
 204: #define XmSTRING_COMPONENT_USER_BEGIN   ((XmStringComponentType) 128)
 205: /* 128-255 are user tags */
 206: #define XmSTRING_COMPONENT_USER_END     ((XmStringComponentType) 255)
 207: 
 208: typedef enum {
 209:     XmCHARSET_TEXT,
 210:     XmMULTIBYTE_TEXT,
 211:     XmWIDECHAR_TEXT,
 212:     XmNO_TEXT
 213: } XmTextType;
 214: 
 215: typedef enum {
 216:     XmOUTPUT_ALL,
 217:     XmOUTPUT_BETWEEN,
 218:     XmOUTPUT_BEGINNING,
 219:     XmOUTPUT_END,
 220:     XmOUTPUT_BOTH
 221: } XmParseModel;
 222: 
 223: typedef struct __XmParseMappingRec *XmParseMapping;     /* Definition hidden in source */
 224: typedef XmParseMapping             *XmParseTable;
 225: typedef unsigned char XmIncludeStatus;
 226: 
 227: typedef XmIncludeStatus (*XmParseProc) (
 228:   XtPointer *text_in_out,
 229:   XtPointer text_end,
 230:   XmTextType  type,
 231:   XmStringTag tag,
 232:   XmParseMapping  entry,
 233:   int   pattern_length,
 234:   XmString  *str_include,
 235:   XtPointer call_data);
 236: 
 237: enum {
 238:     XmINSERT,
 239:     XmTERMINATE,
 240:     XmINVOKE
 241: };
 242: 
 243: typedef enum {
 244:     XmSTYLE_STRING = XStringStyle,
 245:     XmSTYLE_COMPOUND = XCompoundTextStyle,
 246:     XmSTYLE_TEXT = XTextStyle,
 247:     XmSTYLE_STANDARD_ICC_TEXT = XStdICCTextStyle,
 248:     XmSTYLE_LOCALE = 32,
 249:     XmSTYLE_COMPOUND_STRING
 250: } XmICCEncodingStyle;
 251: 
 252: /* tab list stuff */
 253: typedef enum {
 254:     XmABSOLUTE,
 255:     XmRELATIVE
 256: } XmOffsetModel;
 257: 
 258: typedef struct _XmTabRec *XmTab;
 259: typedef struct _XmTabListRec  *XmTabList;
 260: 
 261: /* render table stuff */
 262: 
 263: typedef enum {
 264:     XmSKIP,
 265:     XmMERGE_REPLACE,
 266:     XmMERGE_OLD,
 267:     XmMERGE_NEW,
 268:     XmDUPLICATE
 269: } XmMergeMode;
 270: 
 271: #define XmAS_IS 255
 272: #define XmFORCE_COLOR 1
 273: 
 274: #define XmUNSPECIFIED_PIXEL ((Pixel) (~0))
 275: #define XmDEFAULT_SELECT_COLOR XmUNSPECIFIED_PIXEL
 276: #define XmREVERSED_GROUND_COLORS (XmDEFAULT_SELECT_COLOR - 1)
 277: #define XmHIGHLIGHT_COLOR (XmREVERSED_GROUND_COLORS - 1)
 278: 
 279: enum {
 280:     XmUNSPECIFIED_LOAD_MODEL,
 281:     XmLOAD_DEFERRED,
 282:     XmLOAD_IMMEDIATE
 283: };
 284: 
 285: /* size policy stuff */
 286: 
 287: enum {
 288:     XmCHANGE_ALL,
 289:     XmCHANGE_NONE,
 290:     XmCHANGE_WIDTH,
 291:     XmCHANGE_HEIGHT
 292: };
 293: 
 294: /* unitType stuff */
 295: 
 296: enum {
 297:   XmPIXELS,
 298:   Xm100TH_MILLIMETERS,
 299:   Xm1000TH_INCHES,
 300:   Xm100TH_POINTS,
 301:   Xm100TH_FONT_UNITS,
 302:   XmINCHES,
 303:   XmCENTIMETERS,
 304:   XmMILLIMETERS,
 305:   XmPOINTS,
 306:   XmFONT_UNITS
 307: };
 308: 
 309: /* delete Responses for VendorShell */
 310: 
 311: enum {
 312:     XmDESTROY,
 313:     XmUNMAP,
 314:     XmDO_NOTHING
 315: };
 316: 
 317: /* keyboard focus policies for VendorShell */
 318: 
 319: enum {
 320:     XmEXPLICIT,
 321:     XmPOINTER
 322: };
 323: 
 324: /* Navigation stuff */
 325: 
 326: enum {
 327:     XmNONE,
 328:     XmTAB_GROUP,
 329:     XmSTICKY_TAB_GROUP,
 330:     XmEXCLUSIVE_TAB_GROUP
 331: };
 332: 
 333: /* Audible Warning types for VendorShell */
 334: 
 335: enum {
 336: /* implied
 337:  *  XmNONE
 338:  */
 339:     XmBELL = 1
 340: };
 341: 
 342: /* Input Manager types */
 343: enum {
 344:     XmPER_SHELL,
 345:     XmPER_WIDGET,
 346:     XmINHERIT_POLICY = 255
 347: };
 348: 
 349: /* Note: The define in XmI.h was changed to XmIMInputPolicy. */
 350: typedef unsigned char XmInputPolicy;
 351: 
 352: /* various widgets' orientation, menu definitions */
 353: 
 354: enum {
 355:     XmNO_ORIENTATION,
 356:     XmVERTICAL,
 357:     XmHORIZONTAL
 358: };
 359: 
 360: /* row column types */
 361: 
 362: enum {
 363:     XmWORK_AREA,
 364:     XmMENU_BAR,
 365:     XmMENU_PULLDOWN,
 366:     XmMENU_POPUP,
 367:     XmMENU_OPTION
 368: };
 369: 
 370: /* row column packing strategies */
 371: 
 372: enum {
 373:     XmNO_PACKING,
 374:     XmPACK_TIGHT,
 375:     XmPACK_COLUMN,
 376:     XmPACK_NONE
 377: };
 378: 
 379: enum {
 380: /* implied
 381:  *  XmALIGNMENT_BASELINE_TOP,
 382:  *  XmALIGNMENT_CENTER,
 383:  *  XmALIGNMENT_BASELINE_BOTTOM,
 384:  */
 385:     XmALIGNMENT_CONTENTS_TOP = 3,
 386:     XmALIGNMENT_CONTENTS_BOTTOM
 387: };
 388: 
 389: enum {
 390:     XmTEAR_OFF_ENABLED,
 391:     XmTEAR_OFF_DISABLED
 392: };
 393: 
 394: enum {
 395:     XmUNPOST,
 396:     XmUNPOST_AND_REPLAY
 397: };
 398: 
 399: /* XmPanedWindow positioning */
 400: enum {
 401:   XmLAST_POSITION = -1,
 402:   XmFIRST_POSITION
 403: };
 404: 
 405: /* XmComboBox types */
 406: enum {
 407:    XmCOMBO_BOX = 0,
 408:    XmDROP_DOWN_COMBO_BOX,
 409:    XmDROP_DOWN_LIST
 410: };
 411: 
 412: /* XmComboBox: XmNpositionMode resource */
 413: enum {
 414:   XmZERO_BASED,
 415:   XmONE_BASED
 416: };
 417: 
 418: enum {
 419:    XmQUICK_NAVIGATE = 1
 420: };
 421: 
 422: /* Label and Frame alignments */
 423: 
 424: enum {
 425:     XmALIGNMENT_BEGINNING,
 426:     XmALIGNMENT_CENTER,
 427:     XmALIGNMENT_END
 428: };
 429: 
 430: enum {
 431:     XmALIGNMENT_BASELINE_TOP,
 432: /* implied
 433:  *  XmALIGNMENT_CENTER
 434:  */
 435:     XmALIGNMENT_BASELINE_BOTTOM = 2,
 436:     XmALIGNMENT_WIDGET_TOP,
 437:     XmALIGNMENT_WIDGET_BOTTOM
 438: };
 439: 
 440: #define XmALIGNMENT_CHILD_TOP XmALIGNMENT_WIDGET_BOTTOM
 441: #define XmALIGNMENT_CHILD_BOTTOM XmALIGNMENT_WIDGET_TOP 
 442: 
 443: /* Frame Child Types */
 444: 
 445: enum {
 446:     XmFRAME_GENERIC_CHILD,
 447:     XmFRAME_WORKAREA_CHILD,
 448:     XmFRAME_TITLE_CHILD
 449: };
 450: 
 451: /* For toggle button stuff */
 452: enum {
 453:     XmN_OF_MANY = 1,
 454:     XmONE_OF_MANY,
 455:     XmONE_OF_MANY_ROUND,
 456:     XmONE_OF_MANY_DIAMOND
 457: };
 458: 
 459: enum { XmUNSET, XmSET, XmINDETERMINATE };
 460: enum { XmTOGGLE_BOOLEAN, XmTOGGLE_INDETERMINATE };
 461: 
 462: typedef unsigned char XmToggleButtonState;
 463: 
 464: /* Form attachments */
 465: 
 466: enum {
 467:     XmATTACH_NONE,
 468:     XmATTACH_FORM,
 469:     XmATTACH_OPPOSITE_FORM,
 470:     XmATTACH_WIDGET,
 471:     XmATTACH_OPPOSITE_WIDGET,
 472:     XmATTACH_POSITION,
 473:     XmATTACH_SELF
 474: };
 475: 
 476: /* resize policies for some manager widgets */
 477: 
 478: enum {
 479:     XmRESIZE_NONE,
 480:     XmRESIZE_GROW,
 481:     XmRESIZE_ANY
 482: };
 483: 
 484: /* callback reasons */
 485: 
 486: enum {
 487:     XmCR_NONE,        /* 0 */
 488:     XmCR_HELP,        /* 1 */
 489:     XmCR_VALUE_CHANGED,     /* 2 */
 490:     XmCR_INCREMENT,     /* 3 */
 491:     XmCR_DECREMENT,     /* 4 */
 492:     XmCR_PAGE_INCREMENT,    /* 5 */
 493:     XmCR_PAGE_DECREMENT,    /* 6 */
 494:     XmCR_TO_TOP,      /* 7 */
 495:     XmCR_TO_BOTTOM,     /* 8 */
 496:     XmCR_DRAG,        /* 9 */
 497:     XmCR_ACTIVATE,      /* 10 */
 498:     XmCR_ARM,       /* 11 */
 499:     XmCR_DISARM,      /* 12 */
 500:     XmCR_DUMMY13,     /* 13 */
 501:     XmCR_DUMMY14,     /* 14 */
 502:     XmCR_DUMMY15,     /* 15 */
 503:     XmCR_MAP,       /* 16 */
 504:     XmCR_UNMAP,       /* 17 */
 505:     XmCR_FOCUS,       /* 18 */
 506:     XmCR_LOSING_FOCUS,      /* 19 */
 507:     XmCR_MODIFYING_TEXT_VALUE,    /* 20 */
 508:     XmCR_MOVING_INSERT_CURSOR,    /* 21 */
 509:     XmCR_EXECUTE,     /* 22 */
 510:     XmCR_SINGLE_SELECT,     /* 23 */
 511:     XmCR_MULTIPLE_SELECT,   /* 24 */
 512:     XmCR_EXTENDED_SELECT,   /* 25 */
 513:     XmCR_BROWSE_SELECT,     /* 26 */
 514:     XmCR_DEFAULT_ACTION,    /* 27 */
 515:     XmCR_CLIPBOARD_DATA_REQUEST,  /* 28 */
 516:     XmCR_CLIPBOARD_DATA_DELETE,   /* 29 */
 517:     XmCR_CASCADING,     /* 30 */
 518:     XmCR_OK,        /* 31 */
 519:     XmCR_CANCEL,      /* 32 */
 520:     XmCR_DUMMY33,     /* 33 */
 521:     XmCR_APPLY,       /* 34 */
 522:     XmCR_NO_MATCH,      /* 35 */
 523:     XmCR_COMMAND_ENTERED,   /* 36 */
 524:     XmCR_COMMAND_CHANGED,   /* 37 */
 525:     XmCR_EXPOSE,      /* 38 */
 526:     XmCR_RESIZE,      /* 39 */
 527:     XmCR_INPUT,       /* 40 */
 528:     XmCR_GAIN_PRIMARY,      /* 41 */
 529:     XmCR_LOSE_PRIMARY,      /* 42 */
 530:     XmCR_CREATE,      /* 43 */
 531:     XmCR_TEAR_OFF_ACTIVATE,   /* 44 */
 532:     XmCR_TEAR_OFF_DEACTIVATE,   /* 45 */
 533:     XmCR_OBSCURED_TRAVERSAL,    /* 46 */
 534:     XmCR_FOCUS_MOVED,     /* 47 */
 535:     XmCR_DUMMY48,     /* 48 */
 536:     XmCR_DUMMY49,     /* 49 */
 537:     XmCR_DUMMY50,     /* 50 */
 538:     XmCR_DUMMY51,     /* 51 */
 539:     XmCR_DUMMY52,     /* 52 */
 540:     XmCR_DUMMY53,     /* 53 */
 541:     XmCR_REPOST,      /* 54 */
 542:     XmCR_COLLAPSED,     /* 55 */
 543:     XmCR_EXPANDED,      /* 56 */
 544:     XmCR_SELECT,      /* 57 */
 545:     XmCR_DRAG_START,      /* 58 */
 546:     XmCR_NO_FONT,     /* 59 */
 547:     XmCR_NO_RENDITION,      /* 60 */
 548:     XmCR_POST,        /* 61 */
 549:     XmCR_SPIN_NEXT,     /* 62 */
 550:     XmCR_SPIN_PRIOR,      /* 63 */
 551:     XmCR_SPIN_FIRST,      /* 64 */
 552:     XmCR_SPIN_LAST,     /* 65 */
 553:     XmCR_PAGE_SCROLLER_INCREMENT, /* 66 */
 554:     XmCR_PAGE_SCROLLER_DECREMENT, /* 67 */
 555:     XmCR_MAJOR_TAB,     /* 68 */
 556:     XmCR_MINOR_TAB,     /* 69 */
 557:   XmCR_START_JOB,
 558:   XmCR_END_JOB,
 559:   XmCR_PAGE_SETUP,
 560:     XmCR_PDM_NONE,                      /* ?? */
 561:     XmCR_PDM_START_VXAUTH,              /* ?? */
 562:     XmCR_PDM_START_PXAUTH,              /* ?? */
 563:     XmCR_PDM_UP,                        /* ?? */
 564:     XmCR_PDM_OK,                        /* ?? */
 565:     XmCR_PDM_CANCEL,                    /* ?? */
 566:     XmCR_PDM_START_ERROR,               /* ?? */
 567:     XmCR_PDM_EXIT_ERROR,                /* ?? */
 568:     XmCR_PROTOCOLS = 6666   /* Note: this was 47 in Motif 1.2x */
 569: };
 570: 
 571: /*
 572:  * callback structures
 573:  */
 574: 
 575: typedef struct {
 576:     int reason;
 577:     XEvent *event;
 578: } XmAnyCallbackStruct;
 579: 
 580: typedef struct {
 581:     int reason;
 582:     XEvent *event;
 583:     int click_count;
 584: } XmArrowButtonCallbackStruct;
 585: 
 586: typedef struct {
 587:     int reason;
 588:     XEvent *event;
 589:     XmString item_or_text;
 590:     int item_position;
 591: } XmComboBoxCallbackStruct;
 592: 
 593: typedef struct {
 594:     int reason;
 595:     XEvent *event;
 596:     XmString value;
 597:     int length;
 598: } XmCommandCallbackStruct;
 599: 
 600: typedef struct {
 601:     int reason;
 602:     XEvent *event;
 603:     Widget item;
 604:     unsigned char new_outline_state;
 605: } XmContainerOutlineCallbackStruct;
 606: 
 607: typedef struct {
 608:     int reason;
 609:     XEvent *event;
 610:     WidgetList selected_items;
 611:     int selected_item_count;
 612:     unsigned char auto_selection_type;
 613: } XmContainerSelectCallbackStruct;
 614: 
 615: typedef struct {
 616:     int reason;
 617:     XEvent *event;
 618:     XmRendition rendition;
 619:     char *font_name;
 620:     XmRenderTable render_table;
 621:     XmStringTag tag;
 622: } XmDisplayCallbackStruct;
 623: 
 624: typedef struct _XmDragStartCallbackStruct {
 625:     int reason;
 626:     XEvent *event;
 627:     Widget widget;
 628:     Boolean doit;
 629: } XmDragStartCallbackStruct, *XmDragStartCallback;
 630: 
 631: typedef struct {
 632:     int reason;
 633:     XEvent *event;
 634:     Window window;
 635: } XmDrawingAreaCallbackStruct;
 636: 
 637: typedef struct {
 638:     int reason;
 639:     XEvent *event;
 640:     Window window;
 641:     int click_count;
 642: } XmDrawnButtonCallbackStruct;
 643: 
 644: typedef struct {
 645:     int reason;
 646:     XEvent *event;
 647:     XmString value;
 648:     int length;
 649:     XmString mask;
 650:     int mask_length;
 651:     XmString dir;
 652:     int dir_length;
 653:     XmString pattern;
 654:     int pattern_length;
 655: } XmFileSelectionBoxCallbackStruct;
 656: 
 657: typedef struct {
 658:     int reason;                    /* reason callback was called */
 659:     XEvent *event;                 /* points to event structure */
 660:     XmString item;                 /* item most recently selected */
 661:     int item_length;               /* number of bytes in item member */
 662:     int item_position;             /* item's position in XmNitems */
 663:     XmString *selected_items;      /* list of items selected */
 664:     int selected_item_count;       /* number of items in selected_items */
 665:     int *selected_item_positions;  /* array of ints marking selected items */
 666:     char selection_type;           /* type of most recent selection */
 667:     unsigned char auto_selection_type;  /* type of automatic selection callback */
 668: } XmListCallbackStruct;
 669: 
 670: typedef struct {
 671:     int reason;
 672:     XEvent *event;
 673:     int page_number;
 674:     Widget page_widget;
 675:     int prev_page_number;
 676:     Widget prev_page_widget;
 677: } XmNotebookCallbackStruct;
 678: 
 679: typedef struct {
 680:     int reason;
 681:     XEvent *event;
 682:     Widget menuToPost;
 683:     Boolean postIt;
 684:     Widget target;
 685: } XmPopupHandlerCallbackStruct;
 686: 
 687: typedef struct {
 688:     int reason;                   /* reason callback was called */
 689:     XEvent *event;
 690:     int click_count;
 691: } XmPushButtonCallbackStruct;
 692: 
 693: typedef struct {
 694:     int reason;
 695:     XEvent *event;
 696:     Widget widget;
 697:     char *data;
 698:     char *callbackstruct;
 699: } XmRowColumnCallbackStruct;
 700: 
 701: 
 702: typedef struct {
 703:     int reason;                   /* reason callback was called */
 704:     XEvent *event;
 705:     int value;
 706: } XmScaleCallbackStruct;
 707: 
 708: typedef struct {
 709:     int reason;
 710:     XEvent *event;
 711:     int value;
 712:     int pixel;
 713: } XmScrollBarCallbackStruct;
 714: 
 715: typedef struct {
 716:     int reason;
 717:     XEvent *event;
 718:     XmString value;
 719:     int length;
 720: } XmSelectionBoxCallbackStruct;
 721: 
 722: typedef struct {
 723:     int reason;
 724:     XEvent *event;
 725:     Widget widget;
 726:     Boolean doit;
 727:     int position;
 728:     XmString value;
 729:     Boolean crossed_boundary;
 730: } XmSimpleSpinBoxCallbackStruct;
 731: 
 732: typedef struct {
 733:     int reason;
 734:     XEvent *event;
 735:     Widget widget;
 736:     Boolean doit;
 737:     int position;
 738:     XmString value;
 739:     Boolean crossed_boundary;
 740: } XmSpinBoxCallbackStruct;
 741: 
 742: typedef struct {
 743:     int reason;                   /* reason callback was called */
 744:     XEvent *event;
 745:     int set;
 746: } XmToggleButtonCallbackStruct;
 747: 
 748: /* multiclick */
 749: 
 750: enum {
 751:     XmMULTICLICK_DISCARD,
 752:     XmMULTICLICK_KEEP
 753: };
 754: 
 755: /* Drawn button overrides some of the ShadowTypes */
 756: enum {
 757:     XmSHADOW_IN = 7,
 758:     XmSHADOW_OUT
 759: };
 760: 
 761: /* Arrow button directions */
 762: enum {
 763:     XmARROW_UP,
 764:     XmARROW_DOWN,
 765:     XmARROW_LEFT,
 766:     XmARROW_RIGHT
 767: };
 768: 
 769: /* Shadow/Separator types */
 770: 
 771: enum {
 772:     XmNO_LINE,
 773:     XmSINGLE_LINE,
 774:     XmDOUBLE_LINE,
 775:     XmSINGLE_DASHED_LINE,
 776:     XmDOUBLE_DASHED_LINE,
 777:     XmSHADOW_ETCHED_IN,
 778:     XmSHADOW_ETCHED_OUT,
 779:     XmSHADOW_ETCHED_IN_DASH,
 780:     XmSHADOW_ETCHED_OUT_DASH,
 781:     XmINVALID_SEPARATOR_TYPE
 782: };
 783: 
 784: /* XmLabel types */
 785: 
 786: enum {
 787:     XmPIXMAP = 1,
 788:     XmSTRING
 789: };
 790: 
 791: /* DragDrop */
 792: enum {
 793:     XmWINDOW,
 794: /* implied
 795:  *  XmPIXMAP
 796:  */
 797:     XmCURSOR = 2
 798: };
 799: 
 800: /* maximum value resources */
 801: 
 802: enum {
 803:     XmMAX_ON_TOP,
 804:     XmMAX_ON_BOTTOM,
 805:     XmMAX_ON_LEFT,
 806:     XmMAX_ON_RIGHT
 807: };
 808: 
 809: /* list selection policies */
 810: 
 811: enum {
 812:     XmSINGLE_SELECT,
 813:     XmMULTIPLE_SELECT,
 814:     XmEXTENDED_SELECT,
 815:     XmBROWSE_SELECT
 816: };
 817: 
 818: enum {
 819:     XmSTATIC,
 820:     XmDYNAMIC
 821: };
 822: 
 823: enum {
 824:     XmNORMAL_MODE,
 825:     XmADD_MODE
 826: };
 827: 
 828: /* container stuff */
 829: 
 830: /* for XmRAutomaticSelection */
 831: enum {
 832:     XmNO_AUTO_SELECT,
 833:     XmAUTO_SELECT
 834: };
 835: 
 836: /* auto_selection_type */
 837: enum {
 838:    XmAUTO_UNSET,
 839:    XmAUTO_BEGIN,
 840:    XmAUTO_MOTION,
 841:    XmAUTO_CANCEL,
 842:    XmAUTO_NO_CHANGE,
 843:    XmAUTO_CHANGE
 844: };
 845: 
 846: /* for XmRLineStyle */
 847: enum { 
 848:  /* XmNO_LINE */
 849:     XmSINGLE = 1
 850: };
 851: 
 852: /* for XmREntryViewType */
 853: enum {
 854:  /* XmLARGE_ICON */
 855:  /* XmSMALL_ICON */
 856:     XmANY_ICON = 2
 857: };
 858: 
 859: /* for XmRSpatialIncludeModel */
 860: enum {
 861:     XmAPPEND,
 862:     XmCLOSEST,
 863:     XmFIRST_FIT
 864: };
 865: 
 866: /* for XmRLayoutType */
 867: enum {
 868:     XmOUTLINE,
 869:     XmSPATIAL,
 870:     XmDETAIL
 871: };
 872: 
 873: /* for XmNoutlineButtonPolicy */
 874: enum {
 875:     XmOUTLINE_BUTTON_PRESENT,
 876:     XmOUTLINE_BUTTON_ABSENT
 877: };
 878: 
 879: /* for XmRSpatialPlaceStyle */
 880: enum {
 881:  /* XmNONE */
 882:     XmGRID = 1,
 883:     XmCELLS
 884: };
 885: 
 886: /* for XmRPrimaryOwnership */
 887: enum {
 888:     XmOWN_NEVER,
 889:     XmOWN_ALWAYS,
 890:     XmOWN_MULTIPLE,
 891:     XmOWN_POSSIBLE_MULTIPLE
 892: };
 893: 
 894: /* for XmRSpatialResizeModel */
 895: enum {
 896:     XmGROW_MINOR,
 897:     XmGROW_MAJOR,
 898:     XmGROW_BALANCED
 899: };
 900: 
 901: /* for XmRSelectionTechnique */
 902: enum {
 903:     XmMARQUEE,
 904:     XmMARQUEE_EXTEND_START,
 905:     XmMARQUEE_EXTEND_BOTH,
 906:     XmTOUCH_ONLY,
 907:     XmTOUCH_OVER
 908: };
 909: 
 910: /* for XmRSpatialSnapModel */
 911: enum {
 912:  /* XmNONE */
 913:     XmSNAP_TO_GRID = 1,
 914:     XmCENTER
 915: };
 916: 
 917: /* for XmROutlineState */
 918: enum {
 919:     XmCOLLAPSED,
 920:     XmEXPANDED
 921: };
 922: 
 923: /* icon gadget stuff */
 924: 
 925: /* for XmRViewType */
 926: enum {
 927:     XmLARGE_ICON,
 928:     XmSMALL_ICON
 929: };
 930: 
 931: /* for XmRVisualEmphasis */
 932: enum {
 933:     XmSELECTED,
 934:     XmNOT_SELECTED
 935: };
 936: 
 937: /* notebook stuff */
 938: 
 939: #define XmUNSPECIFIED_PAGE_NUMBER       (-32768)
 940: 
 941: /* for XmRBindingType */
 942: enum {  
 943:  /* XmNONE */
 944:  /* XmPIXMAP */
 945:     XmSOLID = 2,
 946:     XmSPIRAL,
 947:     XmPIXMAP_OVERLAP_ONLY
 948: };
 949: 
 950: /* for XmRNBChildType */
 951: enum {
 952:  /* XmNONE */
 953:     XmPAGE = 1,
 954:     XmMAJOR_TAB,
 955:     XmMINOR_TAB,
 956:     XmSTATUS_AREA,
 957:     XmPAGE_SCROLLER
 958: };
 959: 
 960: /* spin box stuff */
 961: 
 962: /* for XmNarrowLayout */
 963: enum {
 964:     XmARROWS_END,
 965:     XmARROWS_BEGINNING,
 966:     XmARROWS_SPLIT,
 967:     XmARROWS_FLAT_END,
 968:     XmARROWS_FLAT_BEGINNING
 969: };
 970: 
 971: /* XmSpinBox XmNarrowOrientation */
 972: enum {
 973:   XmARROWS_HORIZONTAL,
 974:   XmARROWS_VERTICAL
 975: };
 976: 
 977: /* for XmNarrowSensitivity or XmNdefaultArrowSensitivity */
 978: enum {
 979:     XmARROWS_INSENSITIVE,
 980:     XmARROWS_INCREMENT_SENSITIVE,
 981:     XmARROWS_DECREMENT_SENSITIVE,
 982:     XmARROWS_SENSITIVE,
 983:     XmARROWS_DEFAULT_SENSITIVITY
 984: };
 985: 
 986: /* for XmNspinBoxChildType */
 987: enum {
 988:     XmNUMERIC = 3
 989: };
 990: 
 991: /* XmNpositionType for XmSpinBox */
 992: enum {
 993:   XmPOSITION_VALUE,
 994:   XmPOSITION_INDEX
 995: };
 996: 
 997: /* XmSpinBoxValidatePosition() return values */
 998: enum{
 999:    XmVALID_VALUE,
1000:    XmCURRENT_VALUE,
1001:    XmMINIMUM_VALUE,
1002:    XmMAXIMUM_VALUE,
1003:    XmINCREMENT_VALUE
1004: };
1005: 
1006: 
1007: /* scrolled window policy stuff */
1008: 
1009: enum {
1010:     XmVARIABLE,
1011:     XmCONSTANT,
1012:     XmRESIZE_IF_POSSIBLE 
1013: };
1014: 
1015: enum {
1016:     XmAUTOMATIC,
1017:     XmAPPLICATION_DEFINED
1018: };
1019: 
1020: enum {
1021: /* implied
1022:  *  XmSTATIC,
1023:  */
1024:     XmAS_NEEDED = 1
1025: };
1026: 
1027: enum {
1028:     XmBOTTOM_RIGHT,
1029:     XmTOP_RIGHT,
1030:     XmBOTTOM_LEFT,
1031:     XmTOP_LEFT
1032: };
1033: 
1034: /* main window command window locations */
1035: 
1036: enum {
1037:     XmCOMMAND_ABOVE_WORKSPACE,
1038:     XmCOMMAND_BELOW_WORKSPACE
1039: };
1040: 
1041: /* edit modes for text widgets */
1042: 
1043: enum {
1044:     XmMULTI_LINE_EDIT,
1045:     XmSINGLE_LINE_EDIT
1046: };
1047: 
1048: /* text directions */
1049: 
1050: typedef enum {
1051:     XmTEXT_FORWARD,
1052:     XmTEXT_BACKWARD
1053: } XmTextDirection;
1054: 
1055: typedef long XmTextPosition;
1056: typedef Atom XmTextFormat;
1057: 
1058: #define XmFMT_8_BIT ((XmTextFormat) XA_STRING)
1059: #define XmFMT_16_BIT  ((XmTextFormat) 2)  /* they _mean_ XA_SECONDARY ??? */
1060: 
1061: /*
1062:  * something about backwards compatibility... besides, xmcd needs these
1063:  */
1064: #define FMT8BIT  XmFMT_8_BIT
1065: #define FMT16BIT XmFMT_16_BIT
1066: 
1067: #define XmFMT_8_BIT ((XmTextFormat) XA_STRING)
1068: #define XmFMT_16_BIT  ((XmTextFormat) 2)  /* they _mean_ XA_SECONDARY ??? */
1069: 
1070: /* Stuff for Text Widgets */
1071: typedef enum {
1072:     XmSELECT_POSITION,
1073:     XmSELECT_WHITESPACE,
1074:     XmSELECT_WORD,
1075:     XmSELECT_LINE,
1076:     XmSELECT_ALL,
1077:     XmSELECT_PARAGRAPH,
1078:     XmSELECT_OUT_LINE
1079: } XmTextScanType;
1080: 
1081: /* highlight mode for text and textfield widgets */
1082: 
1083: typedef enum {
1084:     XmHIGHLIGHT_NORMAL,
1085:     XmHIGHLIGHT_SELECTED,
1086:     XmHIGHLIGHT_SECONDARY_SELECTED
1087: } XmHighlightMode;
1088: 
1089: typedef struct {
1090:     char *ptr;
1091:     int length;
1092:     XmTextFormat format;
1093: } XmTextBlockRec, *XmTextBlock;
1094: 
1095: /* keep the members comma separated, as that can be endian dependent */
1096: typedef struct {
1097:     int  reason;   
1098:     XEvent *event;
1099:     Boolean doit;
1100:     XmTextPosition currInsert, newInsert;
1101:     XmTextPosition startPos, endPos;
1102:     XmTextBlock text;
1103: } XmTextVerifyCallbackStruct, *XmTextVerifyPtr;
1104: 
1105: typedef struct {
1106:     wchar_t *wcsptr;
1107:     int length;
1108: } XmTextBlockRecWcs, *XmTextBlockWcs;
1109: 
1110: typedef struct {
1111:     int  reason;   
1112:     XEvent *event;
1113:     Boolean doit;
1114:     XmTextPosition currInsert, newInsert;
1115:     XmTextPosition startPos, endPos;
1116:     XmTextBlockWcs text;
1117: } XmTextVerifyCallbackStructWcs, *XmTextVerifyPtrWcs;
1118: 
1119: #define XmCOPY_FAILED           0
1120: #define XmCOPY_SUCCEEDED        1
1121: #define XmCOPY_TRUNCATED        2
1122: 
1123: /* dialog child types */
1124: 
1125: enum {
1126:     XmDIALOG_NONE,
1127:     XmDIALOG_APPLY_BUTTON,
1128:     XmDIALOG_CANCEL_BUTTON,
1129:     XmDIALOG_DEFAULT_BUTTON,
1130:     XmDIALOG_OK_BUTTON,
1131:     XmDIALOG_FILTER_LABEL,
1132:     XmDIALOG_FILTER_TEXT,
1133:     XmDIALOG_HELP_BUTTON,
1134:     XmDIALOG_LIST,
1135:     XmDIALOG_LIST_LABEL,
1136:     XmDIALOG_MESSAGE_LABEL,
1137:     XmDIALOG_SELECTION_LABEL,
1138:     XmDIALOG_SYMBOL_LABEL,
1139:     XmDIALOG_TEXT,
1140:     XmDIALOG_SEPARATOR,
1141:     XmDIALOG_DIR_LIST,
1142:     XmDIALOG_DIR_LIST_LABEL
1143: };
1144: 
1145: #define XmDIALOG_COMMAND_TEXT    XmDIALOG_TEXT
1146: #define XmDIALOG_FILE_LIST       XmDIALOG_LIST
1147: #define XmDIALOG_FILE_LIST_LABEL XmDIALOG_LIST_LABEL
1148: #define XmDIALOG_HISTORY_LIST    XmDIALOG_LIST
1149: #define XmDIALOG_PROMPT_LABEL    XmDIALOG_SELECTION_LABEL
1150: #define XmDIALOG_VALUE_TEXT      XmDIALOG_TEXT
1151: 
1152: /* dialog styles */
1153: enum {
1154:     XmDIALOG_MODELESS,
1155:     XmDIALOG_PRIMARY_APPLICATION_MODAL,
1156:     XmDIALOG_FULL_APPLICATION_MODAL,
1157:     XmDIALOG_SYSTEM_MODAL
1158: };
1159: 
1160: /* this is obsolete.  Use XmDIALOG_PRIMARY_APPLICATION_MODAL */
1161: #define XmDIALOG_APPLICATION_MODAL XmDIALOG_PRIMARY_APPLICATION_MODAL
1162: 
1163: /* child placements (for selection boxes) */
1164: 
1165: enum {
1166:     XmPLACE_TOP,
1167:     XmPLACE_ABOVE_SELECTION,
1168:     XmPLACE_BELOW_SELECTION
1169: };
1170: 
1171: /* file type masks for filesb */
1172: #define XmFILE_DIRECTORY    (1 << 0)
1173: #define XmFILE_REGULAR      (1 << 1)
1174: #define XmFILE_ANY_TYPE     (XmFILE_DIRECTORY | XmFILE_REGULAR)
1175: 
1176: /* defines for selection dialog type: */
1177: 
1178: enum {
1179:     XmDIALOG_WORK_AREA,
1180:     XmDIALOG_PROMPT,
1181:     XmDIALOG_SELECTION,
1182:     XmDIALOG_COMMAND,
1183:     XmDIALOG_FILE_SELECTION
1184: };
1185: 
1186: /* dialog types */
1187: enum {
1188:     XmDIALOG_TEMPLATE,
1189:     XmDIALOG_ERROR,
1190:     XmDIALOG_INFORMATION,
1191:     XmDIALOG_MESSAGE,
1192:     XmDIALOG_QUESTION,
1193:     XmDIALOG_WARNING,
1194:     XmDIALOG_WORKING
1195: };
1196: 
1197: /* traversal stuff */
1198: 
1199: typedef enum {
1200:     XmVISIBILITY_UNOBSCURED,
1201:     XmVISIBILITY_PARTIALLY_OBSCURED,
1202:     XmVISIBILITY_FULLY_OBSCURED
1203: } XmVisibility;
1204: 
1205: typedef enum {
1206:     XmTRAVERSE_CURRENT,
1207:     XmTRAVERSE_NEXT,
1208:     XmTRAVERSE_PREV,
1209:     XmTRAVERSE_HOME,
1210:     XmTRAVERSE_NEXT_TAB_GROUP,
1211:     XmTRAVERSE_PREV_TAB_GROUP,
1212:     XmTRAVERSE_UP,
1213:     XmTRAVERSE_DOWN,
1214:     XmTRAVERSE_LEFT,
1215:     XmTRAVERSE_RIGHT
1216: } XmTraversalDirection;
1217: 
1218: typedef struct {
1219:     int reason;
1220:     XEvent *event;
1221:     Widget traversal_destination;
1222:     XmTraversalDirection direction;
1223: } XmTraverseObscuredCallbackStruct;
1224: 
1225: typedef unsigned char XmNavigationType;
1226: 
1227: /* simple menu stuff */
1228: 
1229: typedef unsigned char XmButtonType;
1230: typedef XmButtonType * XmButtonTypeTable;
1231: typedef KeySym * XmKeySymTable;
1232: typedef XmStringCharSet * XmStringCharSetTable;
1233: 
1234: enum {
1235:     XmPUSHBUTTON = 1,
1236:     XmTOGGLEBUTTON,
1237:     XmRADIOBUTTON,
1238:     XmCASCADEBUTTON,
1239:     XmSEPARATOR,
1240:     XmDOUBLE_SEPARATOR,
1241:     XmTITLE
1242: };
1243: 
1244: #define XmCHECKBUTTON XmTOGGLEBUTTON
1245: 
1246: /* Stuff needed by the base class stuff in BaseClass.c */
1247: 
1248: typedef XtPointer (*XmResourceBaseProc)(Widget w, XtPointer);
1249: 
1250: typedef struct _XmSecondaryResourceDataRec {
1251:     XmResourceBaseProc base_proc;
1252:     XtPointer client_data;
1253:     String name;
1254:     String res_class;
1255:     XtResourceList resources;
1256:     Cardinal num_resources;
1257: } XmSecondaryResourceDataRec, *XmSecondaryResourceData;
1258: 
1259: Cardinal XmGetSecondaryResourceData(WidgetClass wc,
1260:             XmSecondaryResourceData **resData);
1261: 
1262: /************************ Manager.c ***************************/
1263: Widget XmObjectAtPoint(Widget cw, Position x, Position y);
1264: 
1265: /************************ ImageCache.c ***************************/
1266: 
1267: Pixmap XmGetPixmap(Screen *screen, char *image_name,
1268:                    Pixel foreground, Pixel background);
1269: Pixmap XmGetPixmapByDepth(Screen *screen, char *image_name,
1270:                           Pixel foreground, Pixel background, int depth);
1271: Boolean XmDestroyPixmap(Screen *screen, Pixmap pixmap);
1272: Boolean XmInstallImage(XImage *image, char *image_name);
1273: Boolean XmUninstallImage(XImage *image);
1274: XtEnum XmGetScaledPixmap(Widget widget, String image_name,
1275:                          Pixel foreground, Pixel background,
1276:                          int depth, double scaling_ratio);
1277: 
1278: /************************** Manager.c *****************************/
1279: 
1280: void XmUpdateDisplay(Widget w);
1281: 
1282: /************************* Primitive.c ****************************/
1283: 
1284: typedef long XmOffset;
1285: typedef XmOffset *XmOffsetPtr;
1286: 
1287: void XmResolvePartOffsets(WidgetClass w_class, XmOffsetPtr *offset);
1288: void XmResolveAllPartOffsets(WidgetClass w_class, XmOffsetPtr *offset,
1289:            XmOffsetPtr *constraint_offset);
1290: Boolean XmWidgetGetBaselines(Widget wid, Dimension **baselines,
1291:            int *line_count);
1292: Boolean XmWidgetGetDisplayRect(Widget wid, XRectangle *displayrect);
1293: 
1294: /************************** RenderTable.c ****************************/
1295: 
1296: XmRenderTable XmRenderTableAddRenditions(XmRenderTable        oldtable,
1297:            XmRendition    *renditions,
1298:            Cardinal       rendition_count,
1299:            XmMergeMode    merge_mode);
1300: 
1301: XmRenderTable XmRenderTableCopy(XmRenderTable table,
1302:         XmStringTag     *tags,
1303:         int             tag_count);
1304: 
1305: XmRenderTable XmRenderTableCvtFromProp(Widget         widget,
1306:                char             *property,
1307:                unsigned int     length);
1308: 
1309: unsigned int XmRenderTableCvtToProp(Widget            widget,
1310:             XmRenderTable       table,
1311:             char                **prop_return);
1312: 
1313: void XmRenderTableFree(XmRenderTable table);
1314: 
1315: XmRendition XmRenderTableGetRendition(XmRenderTable   table,
1316:               XmStringTag       tag);
1317: 
1318: XmRendition *XmRenderTableGetRenditions(XmRenderTable table,
1319:           XmStringTag     *tags,
1320:           Cardinal        tag_count);
1321: 
1322: int XmRenderTableGetTags(XmRenderTable        table,
1323:        XmStringTag    **tag_list);
1324: 
1325: XmRenderTable XmRenderTableRemoveRenditions(XmRenderTable     oldtable,
1326:               XmStringTag *tags,
1327:               int         tag_count);
1328: 
1329: Boolean XmeRenderTableGetDefaultFont(XmRenderTable    renderTable,
1330:              XFontStruct        **fontStruct);
1331: 
1332: XmString XmStringGenerate(XtPointer   text,
1333:         XmStringTag   tag,
1334:         XmTextType    type,
1335:         XmStringTag   rendition);
1336:   
1337: XmRendition XmRenditionCreate(Widget widget,
1338:             XmStringTag tag,
1339:             ArgList arglist,
1340:             Cardinal argcount);
1341:   
1342: void XmRenditionFree(XmRendition rendition);
1343: 
1344: void XmRenditionUpdate(XmRendition rendition, 
1345:            ArgList arglist, 
1346:            Cardinal argcount);
1347: 
1348: void XmRenditionRetrieve (XmRendition rendition,
1349:                           ArgList arglist,
1350:         Cardinal argcount);
1351: 
1352: /************************ ResConvert.c ****************************/
1353: 
1354: void XmRegisterConverters(void);
1355: void XmCvtStringToUnitType(XrmValuePtr args, Cardinal *num_args, XrmValue *from_val, XrmValue *to_val);
1356: char *XmRegisterSegmentEncoding(char *fontlist_tag, char *ct_encoding);
1357: char *XmMapSegmentEncoding(char *fontlist_tag);
1358: XmString XmCvtCTToXmString(char *text);
1359: Boolean XmCvtTextToXmString(Display *display, XrmValuePtr args,
1360:           Cardinal *num_args, XrmValue *from_val,
1361:           XrmValue *to_val, XtPointer *converter_data);
1362: char *XmCvtXmStringToCT(XmString string);
1363: Boolean XmCvtXmStringToText(Display *display, XrmValuePtr args,
1364:           Cardinal *num_args, XrmValue *from_val,
1365:           XrmValue *to_val, XtPointer *converter_data);
1366: int XmConvertStringToUnits(Screen *screen, String spec, int orientation,
1367:   int to_type, XtEnum *parse_error);
1368: unsigned int XmCvtXmStringToByteStream(XmString string,
1369:                                        unsigned char **prop_return);
1370: XmString XmCvtByteStreamToXmString(unsigned char *property);
1371: int XmCvtXmStringTableToTextProperty (Display *display,
1372:                                       XmStringTable string_table,
1373:                                       int count,
1374:                                       XmICCEncodingStyle style,
1375:                                       XTextProperty *text_prop_return);
1376: 
1377: /************************** ResInd.c ******************************/
1378: 
1379: int XmConvertUnits(Widget widget, int orientation,
1380:        int from_unit_type, int from_value, int to_unit_type);
1381: int  XmCvtToHorizontalPixels(Screen *screen, int from_val, int from_type);
1382: int  XmCvtToVerticalPixels(Screen *screen, int from_val, int from_type);
1383: int  XmCvtFromHorizontalPixels(Screen *screen, int from_val, int to_type);
1384: int  XmCvtFromVerticalPixels(Screen *screen, int from_val, int to_type);
1385: void XmSetFontUnits(Display *display, int h_value, int v_value);
1386: void XmSetFontUnit(Display *display, int value);
1387: 
1388: /************************* MenuUtil.c *****************************/
1389: 
1390: void XmSetMenuCursor(Display *display, Cursor cursorId);
1391: Cursor XmGetMenuCursor(Display *display);
1392: 
1393: /************************** Simple.c ******************************/
1394: 
1395: Widget XmCreateSimpleCheckBox(Widget parent, char *name,
1396:             Arg *arglist, Cardinal argcount);
1397: Widget XmCreateSimpleMenuBar(Widget parent, char *name,
1398:            Arg *arglist, Cardinal argcount);
1399: Widget XmCreateSimpleOptionMenu(Widget parent, char *name,
1400:         Arg *arglist, Cardinal argcount);
1401: Widget XmCreateSimplePopupMenu(Widget parent, char *name,
1402:              Arg *arglist, Cardinal argcount);
1403: Widget XmCreateSimplePulldownMenu(Widget parent, char *name,
1404:           Arg *arglist, Cardinal argcount);
1405: Widget XmCreateSimpleRadioBox(Widget parent, char *name,
1406:             Arg *arglist, Cardinal argcount);
1407: 
1408: /************************* VaSimple.c *****************************/
1409: 
1410: Widget XmVaCreateSimpleCheckBox(Widget parent, String name,
1411:         XtCallbackProc callback, ...);
1412: Widget XmVaCreateSimpleMenuBar(Widget parent, String name,
1413:              ...);
1414: Widget XmVaCreateSimpleOptionMenu(Widget parent, String name,
1415:           XmString option_label,
1416:           KeySym option_mnemonic,
1417:           int button_set,
1418:           XtCallbackProc callback, ...);
1419: Widget XmVaCreateSimplePopupMenu(Widget parent, String name,
1420:          XtCallbackProc callback, ...);
1421: Widget XmVaCreateSimplePulldownMenu(Widget parent, String name,
1422:             int post_from_button,
1423:             XtCallbackProc callback, ...);
1424: Widget XmVaCreateSimpleRadioBox(Widget parent, String name,
1425:         int button_set,
1426:         XtCallbackProc callback, ...);
1427: 
1428: /************************** TrackLoc.c *****************************/
1429: 
1430: Widget XmTrackingEvent(Widget widget, Cursor cursor, Boolean confine_to,
1431:            XEvent *event_return);
1432: Widget XmTrackingLocate(Widget widget, Cursor cursor, Boolean confine_to);
1433: 
1434: /**************************** Visual.c *****************************/
1435: 
1436: typedef void (*XmColorProc)(XColor *bg_color, XColor *fg_color,
1437:           XColor *sel_color, XColor *ts_color, XColor *bs_color);
1438: 
1439: 
1440: XmColorProc XmSetColorCalculation(XmColorProc proc);
1441: XmColorProc XmGetColorCalculation(void);
1442: void XmGetColors(Screen *screen, Colormap color_map,
1443:       Pixel background, Pixel *foreground_ret,
1444:       Pixel *top_shadow_ret, Pixel *bottom_shadow_ret,
1445:       Pixel *select_ret);
1446: void XmChangeColor(Widget widget, Pixel background);
1447: 
1448: /*************************** XmString.c ****************************/
1449: 
1450: Dimension XmStringBaseline(XmFontList fontlist, XmString string);
1451: Boolean XmStringByteCompare(XmString s1, XmString s2);
1452: Boolean XmStringCompare(XmString s1, XmString s2);
1453: XmString XmStringConcat(XmString s1, XmString s2);
1454: XmString XmStringConcatAndFree(XmString s1, XmString s2);
1455: XmString XmStringCreate(char *text, char *tag);
1456: XmString XmStringCreateLtoR(char *text, char *tag);
1457: XmString XmStringLtoRCreate(char *text, char *tag);
1458: XmString XmStringCreateLocalized(char *text);
1459: XmString XmStringCreateSimple(char *text);
1460: XmString XmStringDirectionCreate(XmStringDirection direction);
1461: void XmStringDraw(Display *d, 
1462:       Window w,
1463:       XmFontList fontlist,
1464:       XmString string,
1465:       GC gc,
1466:       Position x,
1467:       Position y,
1468:       Dimension width,
1469:       unsigned char alignment,
1470:       unsigned char layout_direction,
1471:       XRectangle *clip);
1472: void XmStringDrawImage(Display *d, Window w,
1473:            XmFontList fontlist,
1474:            XmString string,
1475:            GC gc,
1476:            Position x,
1477:            Position y,
1478:            Dimension width,
1479:            unsigned char alignment,
1480:            unsigned char layout_direction,
1481:            XRectangle *clip);
1482: void XmStringDrawUnderline(Display *d, Window w,
1483:          XmFontList fontlist, XmString string,
1484:          GC gc, Position x, Position y, Dimension width,
1485:          unsigned char alignment,
1486:          unsigned char layout_direction,
1487:          XRectangle *clip,
1488:          XmString underline);
1489: Boolean XmStringEmpty(XmString s1);
1490: void XmStringExtent(XmFontList fontlist, 
1491:         XmString string,
1492:         Dimension *width,
1493:         Dimension *height);
1494: void XmStringFree(XmString string);
1495: void XmStringFreeContext(XmStringContext context);
1496: Boolean XmStringGetLtoR(XmString string,
1497:       XmStringCharSet tag,
1498:       char **text);
1499: XmStringComponentType XmStringGetNextComponent(XmStringContext context,
1500:                  char **text,
1501:                  XmStringCharSet *tag,
1502:                  XmStringDirection *direction,
1503:                  XmStringComponentType *unknown_tag,
1504:                  unsigned short *unknown_length,
1505:                  unsigned char **unknown_value);
1506: Boolean XmStringGetNextSegment(XmStringContext context,
1507:              char **text,
1508:              XmStringCharSet *tag,
1509:              XmStringDirection *direction,
1510:              Boolean *separator);
1511: Boolean XmStringHasSubstring(XmString string,
1512:            XmString substring);
1513: Dimension XmStringHeight(XmFontList fontlist, XmString string);
1514: Boolean XmStringInitContext(XmStringContext *context,
1515:           XmString string);
1516: int XmStringLength(XmString s1);
1517: int XmStringLineCount(XmString string);
1518: XmString XmStringNConcat(XmString s1, XmString s2, int num_bytes);
1519: XmString XmStringCopy(XmString s);
1520: XmString XmStringNCopy(XmString s1, int num_bytes);
1521: XmStringComponentType XmStringPeekNextComponent(XmStringContext context);
1522: XmString XmStringSegmentCreate(char *text, char *tag, 
1523:              XmStringDirection direction,
1524:              Boolean separator);
1525: XmString XmStringSeparatorCreate(void);
1526: 
1527: Dimension XmStringWidth(XmFontList fontList, XmString string);
1528: 
1529: XtPointer XmStringUnparse(XmString string,
1530:                           XmStringTag tag,
1531:                           XmTextType tag_type,
1532:                           XmTextType output_type,
1533:                           XmParseTable parse_table,
1534:                           Cardinal parse_count,
1535:                           XmParseModel parse_model);
1536: 
1537: 
1538: Cardinal XmStringToXmStringTable(XmString string,
1539:                                  XmString break_comp,
1540:                                  XmStringTable *table);
1541: 
1542: XmString XmStringTableToXmString(XmStringTable table,
1543:                                  Cardinal count,
1544:                                  XmString break_component);
1545: 
1546: XtPointer *XmStringTableUnparse(XmStringTable table,
1547:                                 Cardinal count,
1548:                                 XmStringTag tag,
1549:                                 XmTextType tag_type,
1550:                                 XmTextType output_type,
1551:                                 XmParseTable parse,
1552:                                 Cardinal parse_count,
1553:                                 XmParseModel parse_model);
1554: 
1555: XmStringTable XmStringTableParseStringArray(XtPointer *strings,
1556:                                             Cardinal count,
1557:                                             XmStringTag tag,
1558:                                             XmTextType type,
1559:                                             XmParseTable parse,
1560:                                             Cardinal parse_count,
1561:                                             XtPointer call_data);
1562: 
1563: XmString XmStringPutRendition(XmString string,
1564:                               XmStringTag rendition);
1565: 
1566: XmParseMapping XmParseMappingCreate(ArgList arg_list,
1567:                                     Cardinal arg_count);
1568: 
1569: void XmParseMappingSetValues(XmParseMapping parse_mapping,
1570:                              ArgList arg_list,
1571:                              Cardinal arg_count);
1572: 
1573: void XmParseMappingGetValues(XmParseMapping parse_mapping,
1574:                              ArgList arg_list,
1575:                              Cardinal arg_count);
1576: 
1577: void XmParseMappingFree(XmParseMapping parse_mapping);
1578: 
1579: void XmParseTableFree(XmParseTable parse_table,
1580:                       Cardinal parse_count);
1581: 
1582: XmStringComponentType XmStringGetNextTriple(XmStringContext context,
1583:                                             unsigned int *length,
1584:                                             XtPointer *value);
1585: 
1586: XmStringComponentType XmStringPeekNextTriple(XmStringContext context);
1587: 
1588: XmString XmStringComponentCreate(XmStringComponentType ctype,
1589:                                  unsigned int length,
1590:                                  XtPointer value);
1591: 
1592: Boolean XmStringIsVoid(XmString s1);
1593: 
1594: XmString XmStringParseText(XtPointer text, XtPointer *text_end, XmStringTag tag,
1595:   XmTextType type, XmParseTable parse_table, Cardinal parse_count,
1596:   XtPointer call_data);
1597: 
1598: /*************************** FontList.c *****************************/
1599: 
1600: XmFontList XmFontListAppendEntry(XmFontList oldlist,
1601:          XmFontListEntry entry);
1602: XmFontList XmFontListCreate(XFontStruct *font,
1603:           XmStringCharSet charset);
1604: XmFontList XmFontListAdd(XmFontList old,
1605:        XFontStruct *font,
1606:        XmStringCharSet charset);
1607: XmFontList XmFontListCopy(XmFontList fontlist);
1608: XmFontListEntry XmFontListEntryCreate(char *tag,
1609:               XmFontType type,
1610:               XtPointer font);
1611: void XmFontListEntryFree(XmFontListEntry *entry);
1612: XtPointer XmFontListEntryGetFont(XmFontListEntry entry,
1613:          XmFontType *type_return);
1614: char *XmFontListEntryGetTag(XmFontListEntry entry);
1615: XmFontListEntry XmFontListEntryLoad(Display *display,
1616:             char *font_name,
1617:             XmFontType type,
1618:             char *tag);
1619: void XmFontListFree(XmFontList list);
1620: void XmFontListFreeFontContext(XmFontContext context);
1621: Boolean XmFontListInitFontContext(XmFontContext *context,
1622:           XmFontList fontlist);
1623: XmFontListEntry XmFontListNextEntry(XmFontContext context);
1624: Boolean XmFontListGetNextFont(XmFontContext context, XmStringCharSet *charset, XFontStruct **font);
1625: XmFontList XmFontListRemoveEntry(XmFontList oldlist,
1626:          XmFontListEntry entry);
1627: 
1628: XmFontList XmStringCreateFontList( XFontStruct *font, XmStringCharSet charset);
1629: 
1630: /************************** Dest.c ***********************************/
1631: 
1632: Widget XmGetDestination(Display *display);
1633: 
1634: /*************************** Traversal.c *****************************/
1635: 
1636: Boolean XmIsTraversable(Widget widget);
1637: XmVisibility XmGetVisibility(Widget widget);
1638: void XmAddTabGroup(Widget widget);
1639: void XmRemoveTabGroup(Widget widget);
1640: Widget XmGetTabGroup(Widget widget);
1641: Boolean XmProcessTraversal(Widget widget, XmTraversalDirection direction);
1642: Widget XmGetFocusWidget(Widget widget);
1643: 
1644: /**************************** Direction.c *********************************/
1645: 
1646: Boolean XmDirectionMatch(XmDirection dir1, XmDirection dir2);
1647: Boolean XmDirectionMatchPartial(XmDirection dir1, XmDirection dir2, XmDirection dir_mask);
1648: XmStringDirection XmDirectionToStringDirection(XmDirection dir);
1649: XmDirection XmStringDirectionToDirection(XmStringDirection sdir);
1650: 
1651: /******************************* Xme.c ************************************/
1652: 
1653: void XmeConvertMerge(XtPointer data, Atom type,
1654:                      int format, unsigned long length,
1655:                      XmConvertCallbackStruct *call_data);
1656: 
1657: #ifdef __cplusplus
1658: }
1659: #endif
1660: 
1661: 
1662: #include <Xm/VendorS.h>
1663: #include <Xm/XmIm.h>
1664: 
1665: 
1666: #ifdef __cplusplus
1667: extern "C" {
1668: #endif
1669: 
1670: /* The following is for backwards compability (bc) */
1671: #define XmINDICATOR_3D_BOX 0x01
1672: #define XmINDICATOR_FLAT_BOX 0x02
1673: #define XmINDICATOR_CHECK_GLYPH 0x10
1674: #define XmINDICATOR_CROSS_GLYPH 0x20
1675: 
1676: enum {
1677:     XmINDICATOR_NONE = 0,
1678:     XmINDICATOR_FILL = XmINDICATOR_3D_BOX,
1679:     XmINDICATOR_CHECK = XmINDICATOR_CHECK_GLYPH,
1680:     XmINDICATOR_CHECK_BOX = XmINDICATOR_CHECK_GLYPH + XmINDICATOR_3D_BOX,
1681:     XmINDICATOR_CROSS = XmINDICATOR_CROSS_GLYPH,
1682:     XmINDICATOR_CROSS_BOX = XmINDICATOR_CROSS_GLYPH + XmINDICATOR_3D_BOX
1683: };
1684: 
1685: /* A slider can either be a slider or a thermometer */
1686: enum { XmSLIDER, XmTHERMOMETER };
1687: 
1688: #define XmTextSetTopPosition    XmTextSetTopCharacter 
1689: 
1690: enum {
1691:   XmPOPUP_DISABLED = 0,
1692:   XmPOPUP_KEYBOARD,
1693:   XmPOPUP_AUTOMATIC,
1694:   XmPOPUP_AUTOMATIC_RECURSIVE
1695: };
1696: 
1697: /* sliderVisual */
1698: enum {
1699:   XmBACKGROUND_COLOR,
1700:   XmFOREGROUND_COLOR,
1701:   XmTROUGH_COLOR,
1702:   XmSHADOWED_BACKGROUND,
1703:   XmFLAT_FOREGROUND
1704: };
1705: 
1706: /* showValue */
1707: enum {
1708:   XmNEAR_SLIDER = 1,
1709:         XmNEAR_BORDER
1710: };
1711: 
1712: /* sliderMark */
1713: enum {
1714:   /* XmNONE */
1715:   XmETCHED_LINE = 1,
1716:   XmTHUMB_MARK,
1717:   XmROUND_MARK
1718: };
1719: 
1720: /* showArrows */
1721: enum {
1722:   /* XmNONE */
1723:   XmEACH_SIDE = 1,
1724:   XmMAX_SIDE,
1725:   XmMIN_SIDE
1726: };
1727: 
1728: /* XmString */
1729: XmString XmStringGenerate(XtPointer   text, XmStringTag tag,
1730:                           XmTextType  type, XmStringTag rendition);
1731: 
1732: /* XmFileSelectionBox */
1733: enum {
1734:   XmPATH_MODE_FULL,
1735:   XmPATH_MODE_RELATIVE
1736: };
1737: 
1738: enum {
1739:   XmFILTER_NONE,
1740:   XmFILTER_HIDDEN_FILES
1741: };
1742: 
1743: /* RowColumn */
1744: #define XmInheritMenuTraversalProc ((XmMenuTraversalProc) _XtInherit)
1745: 
1746: /* XmTabList */
1747: XmTabList XmTabListCopy(XmTabList tablist,
1748:                         int offset,
1749:                         Cardinal count);
1750: 
1751: void XmTabListFree(XmTabList tablist);
1752: 
1753: XmTab XmTabListGetTab(XmTabList tablist,
1754:                       Cardinal position);
1755: 
1756: XmTabList XmTabListInsertTabs(XmTabList oldlist,
1757:                               XmTab *tabs,
1758:                               Cardinal tab_count,
1759:                               int position);
1760: 
1761: XmTabList XmTabListRemoveTabs(XmTabList oldlist,
1762:                               Cardinal *position_list,
1763:                               Cardinal position_count);
1764: 
1765: XmTabList XmTabListReplacePositions(XmTabList oldlist,
1766:                                     Cardinal *position_list,
1767:                                     XmTab *tabs,
1768:                                     Cardinal tab_count);
1769: 
1770: Cardinal XmTabListTabCount(XmTabList tablist);
1771: 
1772: void XmTabSetValue(XmTab tab,
1773:                    float value);
1774: 
1775: XmTab XmTabCreate(float value,
1776:                   unsigned char units,
1777:                   XmOffsetModel offset_model,
1778:                   unsigned char alignment,
1779:                   char *decimal);
1780: 
1781: void XmTabFree(XmTab tab);
1782: 
1783: float XmTabGetValues(XmTab tab,
1784:                      unsigned char *units,
1785:                      XmOffsetModel *offset,
1786:                      unsigned char *alignment,
1787:                      char **decimal);
1788: 
1789: XmTabList XmStringTableProposeTablist(XmStringTable strings,
1790:                                       Cardinal num_strings,
1791:                                       Widget widget,
1792:                                       float pad_value,
1793:                                       XmOffsetModel offset_model);
1794: 
1795: /*
1796:  * XmPrint API
1797:  */
1798: enum {
1799:         XmPDM_NOTIFY_FAIL,
1800:         XmPDM_NOTIFY_SUCCESS
1801: };
1802: 
1803: void XmRedisplayWidget(Widget w);
1804: 
1805: #ifdef __cplusplus
1806: }
1807: #endif
1808: 
1809: #endif /* _XM_XM_H */
1810: 








































Html form generated by Xrefactory version 1.6.7 on Fri Sep 03 17:18:59 2004