XKBgeom.h revision 5afda2e6
15afda2e6Smrg/************************************************************ 25afda2e6SmrgCopyright (c) 1993 by Silicon Graphics Computer Systems, Inc. 35afda2e6Smrg 45afda2e6SmrgPermission to use, copy, modify, and distribute this 55afda2e6Smrgsoftware and its documentation for any purpose and without 65afda2e6Smrgfee is hereby granted, provided that the above copyright 75afda2e6Smrgnotice appear in all copies and that both that copyright 85afda2e6Smrgnotice and this permission notice appear in supporting 95afda2e6Smrgdocumentation, and that the name of Silicon Graphics not be 105afda2e6Smrgused in advertising or publicity pertaining to distribution 115afda2e6Smrgof the software without specific prior written permission. 125afda2e6SmrgSilicon Graphics makes no representation about the suitability 135afda2e6Smrgof this software for any purpose. It is provided "as is" 145afda2e6Smrgwithout any express or implied warranty. 155afda2e6Smrg 165afda2e6SmrgSILICON GRAPHICS DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS 175afda2e6SmrgSOFTWARE, INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY 185afda2e6SmrgAND FITNESS FOR A PARTICULAR PURPOSE. IN NO EVENT SHALL SILICON 195afda2e6SmrgGRAPHICS BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL 205afda2e6SmrgDAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, 215afda2e6SmrgDATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE 225afda2e6SmrgOR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH 235afda2e6SmrgTHE USE OR PERFORMANCE OF THIS SOFTWARE. 245afda2e6Smrg 255afda2e6Smrg********************************************************/ 265afda2e6Smrg 275afda2e6Smrg#ifndef _XKBGEOM_H_ 285afda2e6Smrg#define _XKBGEOM_H_ 295afda2e6Smrg 305afda2e6Smrg#include <X11/extensions/XKBstr.h> 315afda2e6Smrg 325afda2e6Smrg#ifdef XKB_IN_SERVER 335afda2e6Smrg#define XkbAddGeomKeyAlias SrvXkbAddGeomKeyAlias 345afda2e6Smrg#define XkbAddGeomColor SrvXkbAddGeomColor 355afda2e6Smrg#define XkbAddGeomDoodad SrvXkbAddGeomDoodad 365afda2e6Smrg#define XkbAddGeomKey SrvXkbAddGeomKey 375afda2e6Smrg#define XkbAddGeomOutline SrvXkbAddGeomOutline 385afda2e6Smrg#define XkbAddGeomOverlay SrvXkbAddGeomOverlay 395afda2e6Smrg#define XkbAddGeomOverlayRow SrvXkbAddGeomOverlayRow 405afda2e6Smrg#define XkbAddGeomOverlayKey SrvXkbAddGeomOverlayKey 415afda2e6Smrg#define XkbAddGeomProperty SrvXkbAddGeomProperty 425afda2e6Smrg#define XkbAddGeomRow SrvXkbAddGeomRow 435afda2e6Smrg#define XkbAddGeomSection SrvXkbAddGeomSection 445afda2e6Smrg#define XkbAddGeomShape SrvXkbAddGeomShape 455afda2e6Smrg#define XkbAllocGeomKeyAliases SrvXkbAllocGeomKeyAliases 465afda2e6Smrg#define XkbAllocGeomColors SrvXkbAllocGeomColors 475afda2e6Smrg#define XkbAllocGeomDoodads SrvXkbAllocGeomDoodads 485afda2e6Smrg#define XkbAllocGeomKeys SrvXkbAllocGeomKeys 495afda2e6Smrg#define XkbAllocGeomOutlines SrvXkbAllocGeomOutlines 505afda2e6Smrg#define XkbAllocGeomPoints SrvXkbAllocGeomPoints 515afda2e6Smrg#define XkbAllocGeomProps SrvXkbAllocGeomProps 525afda2e6Smrg#define XkbAllocGeomRows SrvXkbAllocGeomRows 535afda2e6Smrg#define XkbAllocGeomSectionDoodads SrvXkbAllocGeomSectionDoodads 545afda2e6Smrg#define XkbAllocGeomSections SrvXkbAllocGeomSections 555afda2e6Smrg#define XkbAllocGeomOverlays SrvXkbAllocGeomOverlays 565afda2e6Smrg#define XkbAllocGeomOverlayRows SrvXkbAllocGeomOverlayRows 575afda2e6Smrg#define XkbAllocGeomOverlayKeys SrvXkbAllocGeomOverlayKeys 585afda2e6Smrg#define XkbAllocGeomShapes SrvXkbAllocGeomShapes 595afda2e6Smrg#define XkbAllocGeometry SrvXkbAllocGeometry 605afda2e6Smrg#define XkbFreeGeomKeyAliases SrvXkbFreeGeomKeyAliases 615afda2e6Smrg#define XkbFreeGeomColors SrvXkbFreeGeomColors 625afda2e6Smrg#define XkbFreeGeomDoodads SrvXkbFreeGeomDoodads 635afda2e6Smrg#define XkbFreeGeomProperties SrvXkbFreeGeomProperties 645afda2e6Smrg#define XkbFreeGeomOverlayKeys SrvXkbFreeGeomOverlayKeys 655afda2e6Smrg#define XkbFreeGeomOverlayRows SrvXkbFreeGeomOverlayRows 665afda2e6Smrg#define XkbFreeGeomOverlays SrvXkbFreeGeomOverlays 675afda2e6Smrg#define XkbFreeGeomKeys SrvXkbFreeGeomKeys 685afda2e6Smrg#define XkbFreeGeomRows SrvXkbFreeGeomRows 695afda2e6Smrg#define XkbFreeGeomSections SrvXkbFreeGeomSections 705afda2e6Smrg#define XkbFreeGeomPoints SrvXkbFreeGeomPoints 715afda2e6Smrg#define XkbFreeGeomOutlines SrvXkbFreeGeomOutlines 725afda2e6Smrg#define XkbFreeGeomShapes SrvXkbFreeGeomShapes 735afda2e6Smrg#define XkbFreeGeometry SrvXkbFreeGeometry 745afda2e6Smrg#endif 755afda2e6Smrg 765afda2e6Smrgtypedef struct _XkbProperty { 775afda2e6Smrg char *name; 785afda2e6Smrg char *value; 795afda2e6Smrg} XkbPropertyRec,*XkbPropertyPtr; 805afda2e6Smrg 815afda2e6Smrgtypedef struct _XkbColor { 825afda2e6Smrg unsigned int pixel; 835afda2e6Smrg char * spec; 845afda2e6Smrg} XkbColorRec,*XkbColorPtr; 855afda2e6Smrg 865afda2e6Smrgtypedef struct _XkbPoint { 875afda2e6Smrg short x; 885afda2e6Smrg short y; 895afda2e6Smrg} XkbPointRec, *XkbPointPtr; 905afda2e6Smrg 915afda2e6Smrgtypedef struct _XkbBounds { 925afda2e6Smrg short x1,y1; 935afda2e6Smrg short x2,y2; 945afda2e6Smrg} XkbBoundsRec, *XkbBoundsPtr; 955afda2e6Smrg#define XkbBoundsWidth(b) (((b)->x2)-((b)->x1)) 965afda2e6Smrg#define XkbBoundsHeight(b) (((b)->y2)-((b)->y1)) 975afda2e6Smrg 985afda2e6Smrg/* 995afda2e6Smrg * In the following structs, this pattern is used for dynamically sized arrays: 1005afda2e6Smrg * foo is an array for which sz_foo entries are allocated & num_foo are used 1015afda2e6Smrg */ 1025afda2e6Smrg 1035afda2e6Smrgtypedef struct _XkbOutline { 1045afda2e6Smrg unsigned short num_points; 1055afda2e6Smrg unsigned short sz_points; 1065afda2e6Smrg unsigned short corner_radius; 1075afda2e6Smrg XkbPointPtr points; 1085afda2e6Smrg} XkbOutlineRec, *XkbOutlinePtr; 1095afda2e6Smrg 1105afda2e6Smrgtypedef struct _XkbShape { 1115afda2e6Smrg Atom name; 1125afda2e6Smrg unsigned short num_outlines; 1135afda2e6Smrg unsigned short sz_outlines; 1145afda2e6Smrg XkbOutlinePtr outlines; 1155afda2e6Smrg XkbOutlinePtr approx; 1165afda2e6Smrg XkbOutlinePtr primary; 1175afda2e6Smrg XkbBoundsRec bounds; 1185afda2e6Smrg} XkbShapeRec, *XkbShapePtr; 1195afda2e6Smrg#define XkbOutlineIndex(s,o) ((int)((o)-&(s)->outlines[0])) 1205afda2e6Smrg 1215afda2e6Smrgtypedef struct _XkbShapeDoodad { 1225afda2e6Smrg Atom name; 1235afda2e6Smrg unsigned char type; 1245afda2e6Smrg unsigned char priority; 1255afda2e6Smrg short top; 1265afda2e6Smrg short left; 1275afda2e6Smrg short angle; 1285afda2e6Smrg unsigned short color_ndx; 1295afda2e6Smrg unsigned short shape_ndx; 1305afda2e6Smrg} XkbShapeDoodadRec, *XkbShapeDoodadPtr; 1315afda2e6Smrg#define XkbShapeDoodadColor(g,d) (&(g)->colors[(d)->color_ndx]) 1325afda2e6Smrg#define XkbShapeDoodadShape(g,d) (&(g)->shapes[(d)->shape_ndx]) 1335afda2e6Smrg#define XkbSetShapeDoodadColor(g,d,c) ((d)->color_ndx= (c)-&(g)->colors[0]) 1345afda2e6Smrg#define XkbSetShapeDoodadShape(g,d,s) ((d)->shape_ndx= (s)-&(g)->shapes[0]) 1355afda2e6Smrg 1365afda2e6Smrgtypedef struct _XkbTextDoodad { 1375afda2e6Smrg Atom name; 1385afda2e6Smrg unsigned char type; 1395afda2e6Smrg unsigned char priority; 1405afda2e6Smrg short top; 1415afda2e6Smrg short left; 1425afda2e6Smrg short angle; 1435afda2e6Smrg short width; 1445afda2e6Smrg short height; 1455afda2e6Smrg unsigned short color_ndx; 1465afda2e6Smrg char * text; 1475afda2e6Smrg char * font; 1485afda2e6Smrg} XkbTextDoodadRec, *XkbTextDoodadPtr; 1495afda2e6Smrg#define XkbTextDoodadColor(g,d) (&(g)->colors[(d)->color_ndx]) 1505afda2e6Smrg#define XkbSetTextDoodadColor(g,d,c) ((d)->color_ndx= (c)-&(g)->colors[0]) 1515afda2e6Smrg 1525afda2e6Smrgtypedef struct _XkbIndicatorDoodad { 1535afda2e6Smrg Atom name; 1545afda2e6Smrg unsigned char type; 1555afda2e6Smrg unsigned char priority; 1565afda2e6Smrg short top; 1575afda2e6Smrg short left; 1585afda2e6Smrg short angle; 1595afda2e6Smrg unsigned short shape_ndx; 1605afda2e6Smrg unsigned short on_color_ndx; 1615afda2e6Smrg unsigned short off_color_ndx; 1625afda2e6Smrg} XkbIndicatorDoodadRec, *XkbIndicatorDoodadPtr; 1635afda2e6Smrg#define XkbIndicatorDoodadShape(g,d) (&(g)->shapes[(d)->shape_ndx]) 1645afda2e6Smrg#define XkbIndicatorDoodadOnColor(g,d) (&(g)->colors[(d)->on_color_ndx]) 1655afda2e6Smrg#define XkbIndicatorDoodadOffColor(g,d) (&(g)->colors[(d)->off_color_ndx]) 1665afda2e6Smrg#define XkbSetIndicatorDoodadOnColor(g,d,c) \ 1675afda2e6Smrg ((d)->on_color_ndx= (c)-&(g)->colors[0]) 1685afda2e6Smrg#define XkbSetIndicatorDoodadOffColor(g,d,c) \ 1695afda2e6Smrg ((d)->off_color_ndx= (c)-&(g)->colors[0]) 1705afda2e6Smrg#define XkbSetIndicatorDoodadShape(g,d,s) \ 1715afda2e6Smrg ((d)->shape_ndx= (s)-&(g)->shapes[0]) 1725afda2e6Smrg 1735afda2e6Smrgtypedef struct _XkbLogoDoodad { 1745afda2e6Smrg Atom name; 1755afda2e6Smrg unsigned char type; 1765afda2e6Smrg unsigned char priority; 1775afda2e6Smrg short top; 1785afda2e6Smrg short left; 1795afda2e6Smrg short angle; 1805afda2e6Smrg unsigned short color_ndx; 1815afda2e6Smrg unsigned short shape_ndx; 1825afda2e6Smrg char * logo_name; 1835afda2e6Smrg} XkbLogoDoodadRec, *XkbLogoDoodadPtr; 1845afda2e6Smrg#define XkbLogoDoodadColor(g,d) (&(g)->colors[(d)->color_ndx]) 1855afda2e6Smrg#define XkbLogoDoodadShape(g,d) (&(g)->shapes[(d)->shape_ndx]) 1865afda2e6Smrg#define XkbSetLogoDoodadColor(g,d,c) ((d)->color_ndx= (c)-&(g)->colors[0]) 1875afda2e6Smrg#define XkbSetLogoDoodadShape(g,d,s) ((d)->shape_ndx= (s)-&(g)->shapes[0]) 1885afda2e6Smrg 1895afda2e6Smrgtypedef struct _XkbAnyDoodad { 1905afda2e6Smrg Atom name; 1915afda2e6Smrg unsigned char type; 1925afda2e6Smrg unsigned char priority; 1935afda2e6Smrg short top; 1945afda2e6Smrg short left; 1955afda2e6Smrg short angle; 1965afda2e6Smrg} XkbAnyDoodadRec, *XkbAnyDoodadPtr; 1975afda2e6Smrg 1985afda2e6Smrgtypedef union _XkbDoodad { 1995afda2e6Smrg XkbAnyDoodadRec any; 2005afda2e6Smrg XkbShapeDoodadRec shape; 2015afda2e6Smrg XkbTextDoodadRec text; 2025afda2e6Smrg XkbIndicatorDoodadRec indicator; 2035afda2e6Smrg XkbLogoDoodadRec logo; 2045afda2e6Smrg} XkbDoodadRec, *XkbDoodadPtr; 2055afda2e6Smrg 2065afda2e6Smrg#define XkbUnknownDoodad 0 2075afda2e6Smrg#define XkbOutlineDoodad 1 2085afda2e6Smrg#define XkbSolidDoodad 2 2095afda2e6Smrg#define XkbTextDoodad 3 2105afda2e6Smrg#define XkbIndicatorDoodad 4 2115afda2e6Smrg#define XkbLogoDoodad 5 2125afda2e6Smrg 2135afda2e6Smrgtypedef struct _XkbKey { 2145afda2e6Smrg XkbKeyNameRec name; 2155afda2e6Smrg short gap; 2165afda2e6Smrg unsigned char shape_ndx; 2175afda2e6Smrg unsigned char color_ndx; 2185afda2e6Smrg} XkbKeyRec, *XkbKeyPtr; 2195afda2e6Smrg#define XkbKeyShape(g,k) (&(g)->shapes[(k)->shape_ndx]) 2205afda2e6Smrg#define XkbKeyColor(g,k) (&(g)->colors[(k)->color_ndx]) 2215afda2e6Smrg#define XkbSetKeyShape(g,k,s) ((k)->shape_ndx= (s)-&(g)->shapes[0]) 2225afda2e6Smrg#define XkbSetKeyColor(g,k,c) ((k)->color_ndx= (c)-&(g)->colors[0]) 2235afda2e6Smrg 2245afda2e6Smrgtypedef struct _XkbRow { 2255afda2e6Smrg short top; 2265afda2e6Smrg short left; 2275afda2e6Smrg unsigned short num_keys; 2285afda2e6Smrg unsigned short sz_keys; 2295afda2e6Smrg int vertical; 2305afda2e6Smrg XkbKeyPtr keys; 2315afda2e6Smrg XkbBoundsRec bounds; 2325afda2e6Smrg} XkbRowRec, *XkbRowPtr; 2335afda2e6Smrg 2345afda2e6Smrgtypedef struct _XkbSection { 2355afda2e6Smrg Atom name; 2365afda2e6Smrg unsigned char priority; 2375afda2e6Smrg short top; 2385afda2e6Smrg short left; 2395afda2e6Smrg unsigned short width; 2405afda2e6Smrg unsigned short height; 2415afda2e6Smrg short angle; 2425afda2e6Smrg unsigned short num_rows; 2435afda2e6Smrg unsigned short num_doodads; 2445afda2e6Smrg unsigned short num_overlays; 2455afda2e6Smrg unsigned short sz_rows; 2465afda2e6Smrg unsigned short sz_doodads; 2475afda2e6Smrg unsigned short sz_overlays; 2485afda2e6Smrg XkbRowPtr rows; 2495afda2e6Smrg XkbDoodadPtr doodads; 2505afda2e6Smrg XkbBoundsRec bounds; 2515afda2e6Smrg struct _XkbOverlay *overlays; 2525afda2e6Smrg} XkbSectionRec, *XkbSectionPtr; 2535afda2e6Smrg 2545afda2e6Smrgtypedef struct _XkbOverlayKey { 2555afda2e6Smrg XkbKeyNameRec over; 2565afda2e6Smrg XkbKeyNameRec under; 2575afda2e6Smrg} XkbOverlayKeyRec,*XkbOverlayKeyPtr; 2585afda2e6Smrg 2595afda2e6Smrgtypedef struct _XkbOverlayRow { 2605afda2e6Smrg unsigned short row_under; 2615afda2e6Smrg unsigned short num_keys; 2625afda2e6Smrg unsigned short sz_keys; 2635afda2e6Smrg XkbOverlayKeyPtr keys; 2645afda2e6Smrg} XkbOverlayRowRec,*XkbOverlayRowPtr; 2655afda2e6Smrg 2665afda2e6Smrgtypedef struct _XkbOverlay { 2675afda2e6Smrg Atom name; 2685afda2e6Smrg XkbSectionPtr section_under; 2695afda2e6Smrg unsigned short num_rows; 2705afda2e6Smrg unsigned short sz_rows; 2715afda2e6Smrg XkbOverlayRowPtr rows; 2725afda2e6Smrg XkbBoundsPtr bounds; 2735afda2e6Smrg} XkbOverlayRec,*XkbOverlayPtr; 2745afda2e6Smrg 2755afda2e6Smrgtypedef struct _XkbGeometry { 2765afda2e6Smrg Atom name; 2775afda2e6Smrg unsigned short width_mm; 2785afda2e6Smrg unsigned short height_mm; 2795afda2e6Smrg char * label_font; 2805afda2e6Smrg XkbColorPtr label_color; 2815afda2e6Smrg XkbColorPtr base_color; 2825afda2e6Smrg unsigned short sz_properties; 2835afda2e6Smrg unsigned short sz_colors; 2845afda2e6Smrg unsigned short sz_shapes; 2855afda2e6Smrg unsigned short sz_sections; 2865afda2e6Smrg unsigned short sz_doodads; 2875afda2e6Smrg unsigned short sz_key_aliases; 2885afda2e6Smrg unsigned short num_properties; 2895afda2e6Smrg unsigned short num_colors; 2905afda2e6Smrg unsigned short num_shapes; 2915afda2e6Smrg unsigned short num_sections; 2925afda2e6Smrg unsigned short num_doodads; 2935afda2e6Smrg unsigned short num_key_aliases; 2945afda2e6Smrg XkbPropertyPtr properties; 2955afda2e6Smrg XkbColorPtr colors; 2965afda2e6Smrg XkbShapePtr shapes; 2975afda2e6Smrg XkbSectionPtr sections; 2985afda2e6Smrg XkbDoodadPtr doodads; 2995afda2e6Smrg XkbKeyAliasPtr key_aliases; 3005afda2e6Smrg} XkbGeometryRec; 3015afda2e6Smrg#define XkbGeomColorIndex(g,c) ((int)((c)-&(g)->colors[0])) 3025afda2e6Smrg 3035afda2e6Smrg#define XkbGeomPropertiesMask (1<<0) 3045afda2e6Smrg#define XkbGeomColorsMask (1<<1) 3055afda2e6Smrg#define XkbGeomShapesMask (1<<2) 3065afda2e6Smrg#define XkbGeomSectionsMask (1<<3) 3075afda2e6Smrg#define XkbGeomDoodadsMask (1<<4) 3085afda2e6Smrg#define XkbGeomKeyAliasesMask (1<<5) 3095afda2e6Smrg#define XkbGeomAllMask (0x3f) 3105afda2e6Smrg 3115afda2e6Smrgtypedef struct _XkbGeometrySizes { 3125afda2e6Smrg unsigned int which; 3135afda2e6Smrg unsigned short num_properties; 3145afda2e6Smrg unsigned short num_colors; 3155afda2e6Smrg unsigned short num_shapes; 3165afda2e6Smrg unsigned short num_sections; 3175afda2e6Smrg unsigned short num_doodads; 3185afda2e6Smrg unsigned short num_key_aliases; 3195afda2e6Smrg} XkbGeometrySizesRec,*XkbGeometrySizesPtr; 3205afda2e6Smrg 3215afda2e6Smrg_XFUNCPROTOBEGIN 3225afda2e6Smrg 3235afda2e6Smrgextern XkbPropertyPtr 3245afda2e6SmrgXkbAddGeomProperty( 3255afda2e6Smrg XkbGeometryPtr /* geom */, 3265afda2e6Smrg char * /* name */, 3275afda2e6Smrg char * /* value */ 3285afda2e6Smrg); 3295afda2e6Smrg 3305afda2e6Smrgextern XkbKeyAliasPtr 3315afda2e6SmrgXkbAddGeomKeyAlias( 3325afda2e6Smrg XkbGeometryPtr /* geom */, 3335afda2e6Smrg char * /* alias */, 3345afda2e6Smrg char * /* real */ 3355afda2e6Smrg); 3365afda2e6Smrg 3375afda2e6Smrgextern XkbColorPtr 3385afda2e6SmrgXkbAddGeomColor( 3395afda2e6Smrg XkbGeometryPtr /* geom */, 3405afda2e6Smrg char * /* spec */, 3415afda2e6Smrg unsigned int /* pixel */ 3425afda2e6Smrg); 3435afda2e6Smrg 3445afda2e6Smrgextern XkbOutlinePtr 3455afda2e6SmrgXkbAddGeomOutline( 3465afda2e6Smrg XkbShapePtr /* shape */, 3475afda2e6Smrg int /* sz_points */ 3485afda2e6Smrg); 3495afda2e6Smrg 3505afda2e6Smrgextern XkbShapePtr 3515afda2e6SmrgXkbAddGeomShape( 3525afda2e6Smrg XkbGeometryPtr /* geom */, 3535afda2e6Smrg Atom /* name */, 3545afda2e6Smrg int /* sz_outlines */ 3555afda2e6Smrg); 3565afda2e6Smrg 3575afda2e6Smrgextern XkbKeyPtr 3585afda2e6SmrgXkbAddGeomKey( 3595afda2e6Smrg XkbRowPtr /* row */ 3605afda2e6Smrg); 3615afda2e6Smrg 3625afda2e6Smrgextern XkbRowPtr 3635afda2e6SmrgXkbAddGeomRow( 3645afda2e6Smrg XkbSectionPtr /* section */, 3655afda2e6Smrg int /* sz_keys */ 3665afda2e6Smrg); 3675afda2e6Smrg 3685afda2e6Smrgextern XkbSectionPtr 3695afda2e6SmrgXkbAddGeomSection( 3705afda2e6Smrg XkbGeometryPtr /* geom */, 3715afda2e6Smrg Atom /* name */, 3725afda2e6Smrg int /* sz_rows */, 3735afda2e6Smrg int /* sz_doodads */, 3745afda2e6Smrg int /* sz_overlays */ 3755afda2e6Smrg); 3765afda2e6Smrg 3775afda2e6Smrgextern XkbOverlayPtr 3785afda2e6SmrgXkbAddGeomOverlay( 3795afda2e6Smrg XkbSectionPtr /* section */, 3805afda2e6Smrg Atom /* name */, 3815afda2e6Smrg int /* sz_rows */ 3825afda2e6Smrg); 3835afda2e6Smrg 3845afda2e6Smrgextern XkbOverlayRowPtr 3855afda2e6SmrgXkbAddGeomOverlayRow( 3865afda2e6Smrg XkbOverlayPtr /* overlay */, 3875afda2e6Smrg int /* row_under */, 3885afda2e6Smrg int /* sz_keys */ 3895afda2e6Smrg); 3905afda2e6Smrg 3915afda2e6Smrgextern XkbOverlayKeyPtr 3925afda2e6SmrgXkbAddGeomOverlayKey( 3935afda2e6Smrg XkbOverlayPtr /* overlay */, 3945afda2e6Smrg XkbOverlayRowPtr /* row */, 3955afda2e6Smrg char * /* over */, 3965afda2e6Smrg char * /* under */ 3975afda2e6Smrg); 3985afda2e6Smrg 3995afda2e6Smrgextern XkbDoodadPtr 4005afda2e6SmrgXkbAddGeomDoodad( 4015afda2e6Smrg XkbGeometryPtr /* geom */, 4025afda2e6Smrg XkbSectionPtr /* section */, 4035afda2e6Smrg Atom /* name */ 4045afda2e6Smrg); 4055afda2e6Smrg 4065afda2e6Smrg 4075afda2e6Smrgextern void 4085afda2e6SmrgXkbFreeGeomKeyAliases( 4095afda2e6Smrg XkbGeometryPtr /* geom */, 4105afda2e6Smrg int /* first */, 4115afda2e6Smrg int /* count */, 4125afda2e6Smrg Bool /* freeAll */ 4135afda2e6Smrg); 4145afda2e6Smrg 4155afda2e6Smrgextern void 4165afda2e6SmrgXkbFreeGeomColors( 4175afda2e6Smrg XkbGeometryPtr /* geom */, 4185afda2e6Smrg int /* first */, 4195afda2e6Smrg int /* count */, 4205afda2e6Smrg Bool /* freeAll */ 4215afda2e6Smrg); 4225afda2e6Smrg 4235afda2e6Smrgextern void 4245afda2e6SmrgXkbFreeGeomDoodads( 4255afda2e6Smrg XkbDoodadPtr /* doodads */, 4265afda2e6Smrg int /* nDoodads */, 4275afda2e6Smrg Bool /* freeAll */ 4285afda2e6Smrg); 4295afda2e6Smrg 4305afda2e6Smrg 4315afda2e6Smrgextern void 4325afda2e6SmrgXkbFreeGeomProperties( 4335afda2e6Smrg XkbGeometryPtr /* geom */, 4345afda2e6Smrg int /* first */, 4355afda2e6Smrg int /* count */, 4365afda2e6Smrg Bool /* freeAll */ 4375afda2e6Smrg); 4385afda2e6Smrg 4395afda2e6Smrgextern void 4405afda2e6SmrgXkbFreeGeomOverlayKeys( 4415afda2e6Smrg XkbOverlayRowPtr /* row */, 4425afda2e6Smrg int /* first */, 4435afda2e6Smrg int /* count */, 4445afda2e6Smrg Bool /* freeAll */ 4455afda2e6Smrg); 4465afda2e6Smrg 4475afda2e6Smrgextern void 4485afda2e6SmrgXkbFreeGeomOverlayRows( 4495afda2e6Smrg XkbOverlayPtr /* overlay */, 4505afda2e6Smrg int /* first */, 4515afda2e6Smrg int /* count */, 4525afda2e6Smrg Bool /* freeAll */ 4535afda2e6Smrg); 4545afda2e6Smrg 4555afda2e6Smrgextern void 4565afda2e6SmrgXkbFreeGeomOverlays( 4575afda2e6Smrg XkbSectionPtr /* section */, 4585afda2e6Smrg int /* first */, 4595afda2e6Smrg int /* count */, 4605afda2e6Smrg Bool /* freeAll */ 4615afda2e6Smrg); 4625afda2e6Smrg 4635afda2e6Smrgextern void 4645afda2e6SmrgXkbFreeGeomKeys( 4655afda2e6Smrg XkbRowPtr /* row */, 4665afda2e6Smrg int /* first */, 4675afda2e6Smrg int /* count */, 4685afda2e6Smrg Bool /* freeAll */ 4695afda2e6Smrg); 4705afda2e6Smrg 4715afda2e6Smrgextern void 4725afda2e6SmrgXkbFreeGeomRows( 4735afda2e6Smrg XkbSectionPtr /* section */, 4745afda2e6Smrg int /* first */, 4755afda2e6Smrg int /* count */, 4765afda2e6Smrg Bool /* freeAll */ 4775afda2e6Smrg); 4785afda2e6Smrg 4795afda2e6Smrgextern void 4805afda2e6SmrgXkbFreeGeomSections( 4815afda2e6Smrg XkbGeometryPtr /* geom */, 4825afda2e6Smrg int /* first */, 4835afda2e6Smrg int /* count */, 4845afda2e6Smrg Bool /* freeAll */ 4855afda2e6Smrg); 4865afda2e6Smrg 4875afda2e6Smrg 4885afda2e6Smrgextern void 4895afda2e6SmrgXkbFreeGeomPoints( 4905afda2e6Smrg XkbOutlinePtr /* outline */, 4915afda2e6Smrg int /* first */, 4925afda2e6Smrg int /* count */, 4935afda2e6Smrg Bool /* freeAll */ 4945afda2e6Smrg); 4955afda2e6Smrg 4965afda2e6Smrgextern void 4975afda2e6SmrgXkbFreeGeomOutlines( 4985afda2e6Smrg XkbShapePtr /* shape */, 4995afda2e6Smrg int /* first */, 5005afda2e6Smrg int /* count */, 5015afda2e6Smrg Bool /* freeAll */ 5025afda2e6Smrg); 5035afda2e6Smrg 5045afda2e6Smrgextern void 5055afda2e6SmrgXkbFreeGeomShapes( 5065afda2e6Smrg XkbGeometryPtr /* geom */, 5075afda2e6Smrg int /* first */, 5085afda2e6Smrg int /* count */, 5095afda2e6Smrg Bool /* freeAll */ 5105afda2e6Smrg); 5115afda2e6Smrg 5125afda2e6Smrgextern void 5135afda2e6SmrgXkbFreeGeometry( 5145afda2e6Smrg XkbGeometryPtr /* geom */, 5155afda2e6Smrg unsigned int /* which */, 5165afda2e6Smrg Bool /* freeMap */ 5175afda2e6Smrg); 5185afda2e6Smrg 5195afda2e6Smrgextern Status 5205afda2e6SmrgXkbAllocGeomProps( 5215afda2e6Smrg XkbGeometryPtr /* geom */, 5225afda2e6Smrg int /* nProps */ 5235afda2e6Smrg); 5245afda2e6Smrg 5255afda2e6Smrgextern Status 5265afda2e6SmrgXkbAllocGeomKeyAliases( 5275afda2e6Smrg XkbGeometryPtr /* geom */, 5285afda2e6Smrg int /* nAliases */ 5295afda2e6Smrg); 5305afda2e6Smrg 5315afda2e6Smrgextern Status 5325afda2e6SmrgXkbAllocGeomColors( 5335afda2e6Smrg XkbGeometryPtr /* geom */, 5345afda2e6Smrg int /* nColors */ 5355afda2e6Smrg); 5365afda2e6Smrg 5375afda2e6Smrgextern Status 5385afda2e6SmrgXkbAllocGeomShapes( 5395afda2e6Smrg XkbGeometryPtr /* geom */, 5405afda2e6Smrg int /* nShapes */ 5415afda2e6Smrg); 5425afda2e6Smrg 5435afda2e6Smrgextern Status 5445afda2e6SmrgXkbAllocGeomSections( 5455afda2e6Smrg XkbGeometryPtr /* geom */, 5465afda2e6Smrg int /* nSections */ 5475afda2e6Smrg); 5485afda2e6Smrg 5495afda2e6Smrgextern Status 5505afda2e6SmrgXkbAllocGeomOverlays( 5515afda2e6Smrg XkbSectionPtr /* section */, 5525afda2e6Smrg int /* num_needed */ 5535afda2e6Smrg); 5545afda2e6Smrg 5555afda2e6Smrgextern Status 5565afda2e6SmrgXkbAllocGeomOverlayRows( 5575afda2e6Smrg XkbOverlayPtr /* overlay */, 5585afda2e6Smrg int /* num_needed */ 5595afda2e6Smrg); 5605afda2e6Smrg 5615afda2e6Smrgextern Status 5625afda2e6SmrgXkbAllocGeomOverlayKeys( 5635afda2e6Smrg XkbOverlayRowPtr /* row */, 5645afda2e6Smrg int /* num_needed */ 5655afda2e6Smrg); 5665afda2e6Smrg 5675afda2e6Smrgextern Status 5685afda2e6SmrgXkbAllocGeomDoodads( 5695afda2e6Smrg XkbGeometryPtr /* geom */, 5705afda2e6Smrg int /* nDoodads */ 5715afda2e6Smrg); 5725afda2e6Smrg 5735afda2e6Smrgextern Status 5745afda2e6SmrgXkbAllocGeomSectionDoodads( 5755afda2e6Smrg XkbSectionPtr /* section */, 5765afda2e6Smrg int /* nDoodads */ 5775afda2e6Smrg); 5785afda2e6Smrg 5795afda2e6Smrgextern Status 5805afda2e6SmrgXkbAllocGeomOutlines( 5815afda2e6Smrg XkbShapePtr /* shape */, 5825afda2e6Smrg int /* nOL */ 5835afda2e6Smrg); 5845afda2e6Smrg 5855afda2e6Smrgextern Status 5865afda2e6SmrgXkbAllocGeomRows( 5875afda2e6Smrg XkbSectionPtr /* section */, 5885afda2e6Smrg int /* nRows */ 5895afda2e6Smrg); 5905afda2e6Smrg 5915afda2e6Smrgextern Status 5925afda2e6SmrgXkbAllocGeomPoints( 5935afda2e6Smrg XkbOutlinePtr /* ol */, 5945afda2e6Smrg int /* nPts */ 5955afda2e6Smrg); 5965afda2e6Smrg 5975afda2e6Smrgextern Status 5985afda2e6SmrgXkbAllocGeomKeys( 5995afda2e6Smrg XkbRowPtr /* row */, 6005afda2e6Smrg int /* nKeys */ 6015afda2e6Smrg); 6025afda2e6Smrg 6035afda2e6Smrgextern Status 6045afda2e6SmrgXkbAllocGeometry( 6055afda2e6Smrg XkbDescPtr /* xkb */, 6065afda2e6Smrg XkbGeometrySizesPtr /* sizes */ 6075afda2e6Smrg); 6085afda2e6Smrg 6095afda2e6Smrgextern Status 6105afda2e6SmrgXkbSetGeometry( 6115afda2e6Smrg Display * /* dpy */, 6125afda2e6Smrg unsigned /* deviceSpec */, 6135afda2e6Smrg XkbGeometryPtr /* geom */ 6145afda2e6Smrg); 6155afda2e6Smrg 6165afda2e6Smrgextern Bool 6175afda2e6SmrgXkbComputeShapeTop( 6185afda2e6Smrg XkbShapePtr /* shape */, 6195afda2e6Smrg XkbBoundsPtr /* bounds */ 6205afda2e6Smrg); 6215afda2e6Smrg 6225afda2e6Smrgextern Bool 6235afda2e6SmrgXkbComputeShapeBounds( 6245afda2e6Smrg XkbShapePtr /* shape */ 6255afda2e6Smrg); 6265afda2e6Smrg 6275afda2e6Smrgextern Bool 6285afda2e6SmrgXkbComputeRowBounds( 6295afda2e6Smrg XkbGeometryPtr /* geom */, 6305afda2e6Smrg XkbSectionPtr /* section */, 6315afda2e6Smrg XkbRowPtr /* row */ 6325afda2e6Smrg); 6335afda2e6Smrg 6345afda2e6Smrgextern Bool 6355afda2e6SmrgXkbComputeSectionBounds( 6365afda2e6Smrg XkbGeometryPtr /* geom */, 6375afda2e6Smrg XkbSectionPtr /* section */ 6385afda2e6Smrg); 6395afda2e6Smrg 6405afda2e6Smrgextern char * 6415afda2e6SmrgXkbFindOverlayForKey( 6425afda2e6Smrg XkbGeometryPtr /* geom */, 6435afda2e6Smrg XkbSectionPtr /* wanted */, 6445afda2e6Smrg char * /* under */ 6455afda2e6Smrg); 6465afda2e6Smrg 6475afda2e6Smrgextern Status 6485afda2e6SmrgXkbGetGeometry( 6495afda2e6Smrg Display * /* dpy */, 6505afda2e6Smrg XkbDescPtr /* xkb */ 6515afda2e6Smrg); 6525afda2e6Smrg 6535afda2e6Smrgextern Status 6545afda2e6SmrgXkbGetNamedGeometry( 6555afda2e6Smrg Display * /* dpy */, 6565afda2e6Smrg XkbDescPtr /* xkb */, 6575afda2e6Smrg Atom /* name */ 6585afda2e6Smrg); 6595afda2e6Smrg 6605afda2e6Smrg_XFUNCPROTOEND 6615afda2e6Smrg 6625afda2e6Smrg#endif /* _XKBSTR_H_ */ 663