diff options
Diffstat (limited to 'xts5/Xopen')
60 files changed, 49652 insertions, 0 deletions
diff --git a/xts5/Xopen/.gitignore b/xts5/Xopen/.gitignore new file mode 100644 index 00000000..7754bef0 --- /dev/null +++ b/xts5/Xopen/.gitignore @@ -0,0 +1,8 @@ +XAllocNamedColor/XAllocNamedColor +cursorfont/cursorfont +XCreateFontCursor/XCreateFontCursor +keysym/keysym +keysymdef/keysymdef +XKeysymToKeycode/XKeysymToKeycode +XLookupColor/XLookupColor +XStringToKeysym/XStringToKeysym diff --git a/xts5/Xopen/Makefile.am b/xts5/Xopen/Makefile.am new file mode 100644 index 00000000..45e22d40 --- /dev/null +++ b/xts5/Xopen/Makefile.am @@ -0,0 +1,81 @@ +include ../../common.mk +AUTOMAKE_OPTIONS = subdir-objects + +AM_CFLAGS = $(XTS_LCFLAGS) $(XTS_CFLAGS) +LDADD = $(TCM) $(XTS_LLIBS) $(XTS_LIBS) + +libexec_PROGRAMS = $(tprogs) +BUILT_SOURCES = $(tprogs:$(EXEEXT)=.c) +CLEANFILES = $(BUILT_SOURCES) + +tprogs = \ + XAllocNamedColor/XAllocNamedColor \ + cursorfont/cursorfont \ + XCreateFontCursor/XCreateFontCursor \ + keysym/keysym \ + keysymdef/keysymdef \ + XKeysymToKeycode/XKeysymToKeycode \ + XLookupColor/XLookupColor \ + XStringToKeysym/XStringToKeysym + +keysym_keysym_SOURCES = \ + keysym/keysym.c \ + keysym/Test0.c \ + keysym/Test1.c \ + keysym/Test2.c \ + keysym/Test3.c \ + keysym/Test4.c \ + keysym/TestG.c \ + keysym/TestM.c + +keysymdef_keysymdef_SOURCES = \ + keysymdef/keysymdef.c \ + keysymdef/Test0.c \ + keysymdef/Test1.c \ + keysymdef/Test2.c \ + keysymdef/Test3.c \ + keysymdef/Test4.c \ + keysymdef/TestA.c \ + keysymdef/TestC.c \ + keysymdef/TestG.c \ + keysymdef/TestH.c \ + keysymdef/TestK.c \ + keysymdef/TestL.c \ + keysymdef/TestM.c \ + keysymdef/TestP.c \ + keysymdef/TestS.c \ + keysymdef/TestT.c + +XKeysymToKeycode_XKeysymToKeycode_SOURCES = \ + XKeysymToKeycode/XKeysymToKeycode.c \ + XKeysymToKeycode/Test1.c \ + XKeysymToKeycode/Test2.c \ + XKeysymToKeycode/Test3.c \ + XKeysymToKeycode/Test4.c \ + XKeysymToKeycode/TestA.c \ + XKeysymToKeycode/TestC.c \ + XKeysymToKeycode/TestG.c \ + XKeysymToKeycode/TestH.c \ + XKeysymToKeycode/TestK.c \ + XKeysymToKeycode/TestL.c \ + XKeysymToKeycode/TestM.c \ + XKeysymToKeycode/TestP.c \ + XKeysymToKeycode/TestS.c \ + XKeysymToKeycode/TestT.c + +XStringToKeysym_XStringToKeysym_SOURCES = \ + XStringToKeysym/XStringToKeysym.c \ + XStringToKeysym/Test1.c \ + XStringToKeysym/Test2.c \ + XStringToKeysym/Test3.c \ + XStringToKeysym/Test4.c \ + XStringToKeysym/TestA.c \ + XStringToKeysym/TestC.c \ + XStringToKeysym/TestG.c \ + XStringToKeysym/TestH.c \ + XStringToKeysym/TestK.c \ + XStringToKeysym/TestL.c \ + XStringToKeysym/TestM.c \ + XStringToKeysym/TestP.c \ + XStringToKeysym/TestS.c \ + XStringToKeysym/TestT.c diff --git a/xts5/Xopen/XAllocNamedColor/XAllocNamedColor.m b/xts5/Xopen/XAllocNamedColor/XAllocNamedColor.m new file mode 100644 index 00000000..00f978ad --- /dev/null +++ b/xts5/Xopen/XAllocNamedColor/XAllocNamedColor.m @@ -0,0 +1,1008 @@ +Copyright (c) 2005 X.Org Foundation L.L.C. + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies +of the Software, and to permit persons to whom the Software is furnished to do +so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. +$Header: /cvs/xtest/xtest/xts5/tset/Xopen/XAllocNamedColor/XAllocNamedColor.m,v 1.2 2005-11-03 08:44:00 jmichael Exp $ + +>># Project: VSW5 +>># +>># File: xts5/tset/Xopen/XAllocNamedColor/XAllocNamedColor.m +>># +>># Description: +>># Tests for XAllocNamedColor() +>># +>># Modifications: +>># $Log: allcnmdclr.m,v $ +>># Revision 1.2 2005-11-03 08:44:00 jmichael +>># clean up all vsw5 paths to use xts5 instead. +>># +>># Revision 1.1.1.2 2005/04/15 14:05:39 anderson +>># Reimport of the base with the legal name in the copyright fixed. +>># +>># Revision 8.0 1998/12/23 23:36:01 mar +>># Branch point for Release 5.0.2 +>># +>># Revision 7.0 1998/10/30 22:58:47 mar +>># Branch point for Release 5.0.2b1 +>># +>># Revision 6.0 1998/03/02 05:27:14 tbr +>># Branch point for Release 5.0.1 +>># +>># Revision 5.0 1998/01/26 03:23:47 tbr +>># Branch point for Release 5.0.1b1 +>># +>># Revision 4.0 1995/12/15 09:14:55 tbr +>># Branch point for Release 5.0.0 +>># +>># Revision 3.1 1995/12/15 01:18:22 andy +>># Prepare for GA Release +>># + +/* + * SCCS: @(#) allcnmdclr.m Rel 1.10 (12/10/91) + * + * UniSoft Ltd., London, England + * + * (C) Copyright 1991 X/Open Company Limited + * + * All rights reserved. No part of this source code may be reproduced, + * stored in a retrieval system, or transmitted, in any form or by any + * means, electronic, mechanical, photocopying, recording or otherwise, + * except as stated in the end-user licence agreement, without the prior + * permission of the copyright owners. + * + * X/Open and the 'X' symbol are trademarks of X/Open Company Limited in + * the UK and other countries. + */ +>>TITLE XAllocNamedColor Xopen +Status +XAllocNamedColor(display, colormap, color_name, screen_def_return, exact_def_return) +Display *display = Dsp; +Colormap colormap = DefaultColormap(display, DefaultScreen(display)); +char *color_name = ""; +XColor *screen_def_return = &dummycol; +XColor *exact_def_return = &dummycol; +>>EXTERN + +XColor dummycol; + +static char *convertname(s) +char *s; +{ + char *res; + char *rp; + char *cp = s; + int len = strlen(s); + + if(s == (char *) NULL) + return((char *) NULL); + + if((res = rp = (char*) malloc(len + 1)) == (char *) NULL) { + delete("Malloc returned NULL."); + return((char *) NULL); + } + + while(*cp == ' ') + cp++; + + *rp++ = toupper(*cp++); + while(*cp) { + if(*cp == ' ') { + while(*cp == ' ') + cp++; + if(*cp) + *rp++ = toupper(*cp++); + } else + *rp++ = *cp++; + } + + *rp = '\0'; + return(res); +} + +>>ASSERTION Good A +When a colour name in the table is recognised on a call to xname, +then all other colour names on the same line of the table +are also recognised on another call to xname +using the same +.A display +and +.A colormap , +and the same values are returned by each call to xname in the +.M red , +.M green +and +.M blue +components of the +.S XColor +structures named by the +.A exact_def_return +argument and +.A screen_def_return +arguments. +.tL "Set" "Color name(s)" +.tL "M" "gray" "grey" +.tL "M" "dark gray" "dark grey" +.tL "X" "dark slate gray" "dark slate grey" +.tL "X" "dim gray" "dim grey" +.tL "X" "light gray" "light grey" +>>STRATEGY +For each supported visual type: + Create a colourmap of that type using XCreateColormap. + For each equivalent colour name: + Obtain the rgb values for the colour. + Verify that the exact rgb values are identical. + Verify that the supported rbg values are identical. + Free the allocated colourmap cell using XFreeColors. +>>CODE +int i; +int firstunsupported; +int secondunsupported; +XVisualInfo *vp; +Status status; +XColor exactcol, screencol; +XColor exactcol2, screencol2; +unsigned long vmask; +static char *p[5][2] = + {{ "gray", "grey"}, + { "dark gray", "dark grey"}, + { "dark slate gray", "dark slate grey"}, + { "dim gray", "dim grey"}, + { "light gray", "light grey"}}; + + if( (vmask = visualsupported(display, 0L)) == 0L) { + delete("No visuals reported as valid."); + return; + } else + CHECK; + + for(resetsupvis(vmask); nextsupvis(&vp); ) { + + colormap = makecolmap(display, vp->visual, AllocNone); + for(i=0; i< NELEM(p); i++) { + + firstunsupported = secondunsupported = 0; + trace("Compare \"%s\" against \"%s\".", p[i][0], p[i][1]); + + exact_def_return = &exactcol; + screen_def_return = &screencol; + color_name= p[i][0]; + + status = XCALL; + + + if( status == (Status) 0) { + trace("Colour \"%s\" is not supported.", color_name); + firstunsupported = 1; + } else + XFreeColors(display, colormap, &exactcol.pixel, 1, (unsigned long)0); + + exact_def_return = &exactcol2; + screen_def_return = &screencol2; + color_name= p[i][1]; + + status = XCALL; + + if( status == (Status) 0) { + trace("Colour \"%s\" is not supported.", color_name); + secondunsupported = 1; + } else + XFreeColors(display, colormap, &(exactcol2.pixel), 1, (unsigned long)0); + + if(firstunsupported && secondunsupported) { + CHECK; + CHECK; + CHECK; + continue; + } + + if(firstunsupported && !secondunsupported) { + report("Colour %s is unsupported.", p[i][0]); + report("Colour %s is supported.", p[i][1]); + FAIL; + } else if(!firstunsupported && secondunsupported) { + report("Colour %s is unsupported.", p[i][1]); + report("Colour %s is supported.", p[i][0]); + FAIL; + } else { + CHECK; + + if((exactcol2.red != exactcol.red) || + (exactcol2.green != exactcol.green) || + (exactcol2.blue != exactcol.blue) ) { + report("Colour names \"%s\" and \"%s\" do not yield the same exact rgb values.", + p[i][0], p[i][1]); + report("( r %u g %u b %u instead of r %u g %u b %u respectively.)", + exactcol.red, exactcol.green, exactcol.blue, + exactcol2.red, exactcol2.green, exactcol2.blue); + FAIL; + } else + CHECK; + + if((screencol2.red != screencol.red) || + (screencol2.green != screencol.green) || + (screencol2.blue != screencol.blue) ) { + report("Colour names \"%s\" and \"%s\" do not yield the same supported rgb values.", + p[i][0], p[i][1]); + report("( r %u g %u b %u instead of r %u g %u b %u respectively.)", + screencol.red, screencol.green, screencol.blue, + screencol2.red, screencol2.green, screencol2.blue); + FAIL; + } else + CHECK; + } + + } + } + + CHECKPASS(1 + 3 * nsupvis() * NELEM(p) ); + +>>ASSERTION Good A +When a colour name in the table is recognised on a call to xname, +and a colour name on a different line of the table +is also recognised on another call to xname +using the same +.A display +and +.A colormap , +then distinct values are returned by each call to xname in the +.M red , +.M green +and +.M blue +components of the +.S XColor +structures named by the +.A exact_def_return +argument and +.A screen_def_return +arguments. +.tL "Set" "Color name(s)" +.tL "A" "black" +.tL "A" "white" +.tL "C" "blue" +.tL "C" "cyan" +.tL "C" "green" +.tL "C" "magenta" +.tL "C" "red" +.tL "C" "yellow" +.tL "M" "gray" "grey" +.tL "M" "dark gray" "dark grey" +.tL "V" "dark blue" +.tL "V" "brown" +.tL "V" "dark cyan" +.tL "V" "dark green" +.tL "V" "dark magenta" +.tL "V" "dark red" +.tL "X" "medium blue" +.tL "X" "midnight blue" +.tL "X" "navy blue" +.tL "X" "sky blue" +.tL "X" "coral" +.tL "X" "gold" +.tL "X" "dark slate gray" "dark slate grey" +.tL "X" "dim gray" "dim grey" +.tL "X" "light gray" "light grey" +.tL "X" "light green" +.tL "X" "forest green" +.tL "X" "lime green" +.tL "X" "pale green" +.tL "X" "spring green" +.tL "X" "maroon" +.tL "X" "orange" +.tL "X" "pink" +.tL "X" "indian red" +.tL "X" "orange red" +.tL "X" "violet red" +.tL "X" "salmon" +.tL "X" "sienna" +.tL "X" "tan" +.tL "X" "turquoise" +.tL "X" "violet" +.tL "X" "blue violet" +.tL "X" "wheat" +>>STRATEGY +For each supported visual: + Create a colourmap of that type using XCreateColormap. + For each pair of colour names in the table: + Obtain the rgb values corresponding to the name using xname. + Verify that the rgb triples are different. + Free the allocated colourmap cell using XFreeColors. +>>EXTERN +static int +compare(col1, col2, name1, name2, eflag) +XColor *col1; +XColor *col2; +char *name1; +char *name2; +int eflag; +{ + + if((col2->red == col1->red) && + (col2->green == col1->green) && + (col2->blue == col1->blue) ) { + report("Colour names \"%s\" and \"%s\" yield the same %s rgb values.", + name1, name2, eflag ? "exact" : "supported"); + trace("%s = r %u g %u b %u, %s = r %u g %u b %u", + name1, col1->red, col1->green, col1->blue, + name2, col2->red, col2->green, col2->blue); + return(0); + } + return(1); +} +>>CODE +XColor scols[43]; +XColor ecols[43]; +XColor scols2[5]; +XColor ecols2[5]; +Status status; +int i, j; +unsigned long vmask; +XVisualInfo *vp; +static char *list[43] = { + "gray", + "dark gray", + "dark slate gray", + "dim gray", + "light gray", + "black", + "white", + "blue", + "cyan", + "green", + "magenta", + "red", + "yellow", + "dark blue", + "brown", + "dark cyan", + "dark green", + "dark magenta", + "dark red", + "medium blue", + "midnight blue", + "navy blue", + "sky blue", + "coral", + "gold", + "light green", + "forest green", + "lime green", + "pale green", + "spring green", + "maroon", + "orange", + "pink", + "indian red", + "orange red", + "violet red", + "salmon", + "sienna", + "tan", + "turquoise", + "violet", + "blue violet", + "wheat"}; +static char *list2[5] = { + "grey", + "dark grey", + "dark slate grey", + "dim grey", + "light grey"}; + + if( (vmask = visualsupported(display, 0L)) == 0L) { + delete("No visuals reported as valid."); + return; + } else + CHECK; + + for(resetsupvis(vmask); nextsupvis(&vp); ) { + + colormap = makecolmap(display, vp->visual, AllocNone); + for(i=0; i<NELEM(list); i++) { + + color_name = list[i]; + exact_def_return = &ecols[i]; + screen_def_return = &scols[i]; + + status = XCALL; + + if(status == 0) { + trace("Colour \"%s\" is not supported.", color_name); + ecols[i].flags = 0; + } else { + XFreeColors(display, colormap, &ecols[i].pixel, 1, (unsigned long)0); + ecols[i].flags = 1; + } + + if(i==0) + CHECK; + } + + /* + * test all pairs of colours - n! + * 2!(n-2)! + */ + for(i=0; i<NELEM(list)-1; i++) { + for(j=i+1; j<NELEM(list); j++) { + if((ecols[i].flags) && (ecols[j].flags)) { + if(compare(&ecols[i], &ecols[j], list[i], list[j], 1) == 0) + FAIL; + if(compare(&scols[i], &scols[j], list[i], list[j], 0) == 0) + FAIL; + } + } + + if(i==0) + CHECK; + } + + for(i=0; i<NELEM(list2); i++) { + + color_name = list2[i]; + exact_def_return = &ecols2[i]; + screen_def_return = &scols2[i]; + + status = XCALL; + + if(status == 0) { + trace("Colour \"%s\" is not supported.", color_name); + ecols2[i].flags = 0; + } else { + XFreeColors(display, colormap, &ecols[i].pixel, 1, (unsigned long)0); + ecols2[i].flags = 1; + } + + if(i==0) + CHECK; + } + + for(i=0; i<NELEM(list2)-1; i++) { + for(j=i+5; j<NELEM(list); j++) { + if((ecols2[i].flags) && (ecols[j].flags)) { + if(compare(&ecols2[i], &ecols[j], list2[i], list[j], 1) == 0) + FAIL; + if(compare(&scols2[i], &scols[j], list2[i], list[j], 0) == 0) + FAIL; + } + } + + if(i==0) + CHECK; + + } + } + + CHECKPASS(1 + nsupvis() * 4); + +>>ASSERTION Good A +When a colour name in the table is recognised on a call to xname, +then the colour name with the first letter of each word in upper-case +and with no spaces between words +is also recognised on another call to xname +using the same +.A display +and +.A colormap , +and the same values are returned by each call to xname in the +.M red , +.M green +and +.M blue +components of the +.S XColor +structures named by the +.A exact_def_return +argument and +.A screen_def_return +arguments. +.tL "Set" "Color name(s)" +.tL "A" "black" +.tL "A" "white" +.tL "C" "blue" +.tL "C" "cyan" +.tL "C" "green" +.tL "C" "magenta" +.tL "C" "red" +.tL "C" "yellow" +.tL "M" "gray" "grey" +.tL "M" "dark gray" "dark grey" +.tL "V" "dark blue" +.tL "V" "brown" +.tL "V" "dark cyan" +.tL "V" "dark green" +.tL "V" "dark magenta" +.tL "V" "dark red" +.tL "X" "medium blue" +.tL "X" "midnight blue" +.tL "X" "navy blue" +.tL "X" "sky blue" +.tL "X" "coral" +.tL "X" "gold" +.tL "X" "dark slate gray" "dark slate grey" +.tL "X" "dim gray" "dim grey" +.tL "X" "light gray" "light grey" +.tL "X" "light green" +.tL "X" "forest green" +.tL "X" "lime green" +.tL "X" "pale green" +.tL "X" "spring green" +.tL "X" "maroon" +.tL "X" "orange" +.tL "X" "pink" +.tL "X" "indian red" +.tL "X" "orange red" +.tL "X" "violet red" +.tL "X" "salmon" +.tL "X" "sienna" +.tL "X" "tan" +.tL "X" "turquoise" +.tL "X" "violet" +.tL "X" "blue violet" +.tL "X" "wheat" +>>STRATEGY +For each supported visual type: + Create a colourmap of that type using XCreateColormap. + For each equivalent colour name: + Obtain the rgb values for the colour. + Verify that the exact rgb values are identical. + Verify that the supported rbg values are identical. + Free the allocated colourmap cell using XFreeColors. +>>CODE +int i; +XVisualInfo *vp; +Status status; +XColor exactcol, screencol; +XColor exactcol2, screencol2; +unsigned long vmask; +static char *list[] = { + "black", + "white", + "blue", + "cyan", + "green", + "magenta", + "red", + "yellow", + "gray", + "grey", + "dark gray", + "dark grey", + "dark blue", + "brown", + "dark cyan", + "dark green", + "dark magenta", + "dark red", + "medium blue", + "midnight blue", + "navy blue", + "sky blue", + "coral", + "gold", + "dark slate gray", + "dark slate grey", + "dim gray", + "dim grey", + "light gray", + "light grey", + "light green", + "forest green", + "lime green", + "pale green", + "spring green", + "maroon", + "orange", + "pink", + "indian red", + "orange red", + "violet red", + "salmon", + "sienna", + "tan", + "turquoise", + "violet", + "blue violet", + "wheat" }; + + + if( (vmask = visualsupported(display, 0L)) == 0L) { + delete("No visuals reported as valid."); + return; + } + + for(resetsupvis(vmask); nextsupvis(&vp); ) { + + for(i=0; i< NELEM(list); i++) { + + color_name = list[i]; + colormap = makecolmap(display, vp->visual, AllocNone); + exact_def_return = &exactcol; + screen_def_return = &screencol; + status = XCALL; + + if(status == (Status) 0) { + trace("Colour name \"%s\" is not supported.", color_name); + CHECK; CHECK;CHECK; + } else { + XFreeColors(display, colormap, &exactcol.pixel, 1, (unsigned long)0); + + color_name = convertname(list[i]); + exact_def_return = &exactcol2; + screen_def_return = &screencol2; + status = XCALL; + + if(status == 0) { + report("Colour name \"%s\" is supported but \"%s\" is not.", list[i], color_name); + FAIL; + } else { + + XFreeColors(display, colormap, &exactcol.pixel, 1, (unsigned long)0); + CHECK; + + if((exactcol2.red != exactcol.red) || + (exactcol2.green != exactcol.green) || + (exactcol2.blue != exactcol.blue) ) { + report("Colour names \"%s\" and \"%s\" do not yield the same exact rgb values.", + list[i], color_name); + report("( r %u g %u b %u instead of r %u g %u b %u respectively.)", + exactcol.red, exactcol.green, exactcol.blue, + exactcol2.red, exactcol2.green, exactcol2.blue); + FAIL; + } else + CHECK; + + if((screencol2.red != screencol.red) || + (screencol2.green != screencol.green) || + (screencol2.blue != screencol.blue) ) { + report("Colour names \"%s\" and \"%s\" do not yield the same supported rgb values.", + list[i], color_name); + report("( r %u g %u b %u instead of r %u g %u b %u respectively.)", + screencol.red, screencol.green, screencol.blue, + screencol2.red, screencol2.green, screencol2.blue); + FAIL; + } else + CHECK; + + + } + + if(!isdeleted()) + free(color_name); + + } + } + + } + + CHECKPASS(nsupvis() * 3 * NELEM(list)); + +>>ASSERTION Good A +All colour names in the table which are in set A are recognised +on a call to xname. +.tL "Set" "Color name(s)" +.tL "A" "black" +.tL "A" "white" +>>STRATEGY +For each supported visual type: + Create a colourmap of that type using XCreateColormap. + For the colournames in the table: + Obtain the rgb values for the colour using xname. + Verify that the call did not return 0. + Free the allocated colourmap cell using XFreeColors. +>>CODE +int i; +Status status; +XVisualInfo *vp; +XColor exactcol; +unsigned long vmask; +static char *list[] = { "black", "white" }; + + if( (vmask = visualsupported(display, 0L)) == 0L) { + delete("No visuals reported as valid."); + return; + } else + CHECK; + + exact_def_return = &exactcol; + for(resetsupvis(vmask); nextsupvis(&vp); ) { + + colormap = makecolmap(display, vp->visual, AllocNone); + + for(i=0; i< NELEM(list); i++) { + + color_name = list[i]; + status = XCALL; + + if(status == 0) { + report("Colour name \"%s\" is not supported.", list[i]); + FAIL; + } else { + XFreeColors(display, colormap, &exactcol.pixel, 1, (unsigned long)0); + CHECK; + } + } + } + + CHECKPASS(1 + nsupvis() * NELEM(list)); + +>>ASSERTION Good C +If any of the visual classes +.S GrayScale +or +.S StaticGray +support colourmaps with at least four colour cells: +When the visual type of the +.A colormap +argument is +.S GrayScale +or +.S StaticGray , +and +.A colormap +has at least four colour cells, +then all colour names in the table which are in set M are recognised +on a call to xname. +.tL "Set" "Color name(s)" +.tL "M" "gray" "grey" +.tL "M" "dark gray" "dark grey" +>>STRATEGY +If the server supports GrayScale or StaticGray with colourmap size greater than 4: + For those supported visuals: + Create a colourmap using XCreateColormap. + For each colour name in the table: + Obtain the rgb values for the for the colour using xname. + Verify that the call did not return 0. + Free the allocated colourmap cell using XFreeColors. +>>CODE +int i; +Status status; +XVisualInfo *vp; +XColor exactcol; +unsigned long vmask; +static char *list[] = { "gray", "grey", "dark gray", "dark grey" }; + + + if( (vmask = visualsupported(display, 1L<<GrayScale)) != 0L) { + + resetsupvis(vmask); + (void) nextsupvis(&vp); + if(vp->colormap_size < 4) + vmask = 0L; + } + + + if( (vmask |= visualsupported(display, 1L<<StaticGray)) | StaticGray) { + + resetsupvis(1L<<StaticGray); + (void) nextsupvis(&vp); + if(vp->colormap_size < 4) + vmask &= ~(1L<<StaticGray); + } + + if(vmask == 0L) { + unsupported("StaticGray and GrayScale visuals are not supported."); + return; + } else + CHECK; + + exact_def_return = &exactcol; + for(resetsupvis(vmask); nextsupvis(&vp); ) { + + colormap = makecolmap(display, vp->visual, AllocNone); + for(i=0; i< NELEM(list); i++) { + + color_name = list[i]; + status = XCALL; + + if(status == 0L) { + report("Colour name \"%s\" is not supported.", color_name); + FAIL; + } else { + XFreeColors(display, colormap, &exactcol.pixel, 1, (unsigned long)0); + CHECK; + } + } + } + + CHECKPASS(1 + nsupvis()* NELEM(list)); + +>>ASSERTION Good C +If any of the visual classes +.S PseudoColor , +.S StaticColor , +.S TrueColor , +or +.S DirectColor +are supported: +When the visual type of the +.A colormap +argument is +.S PseudoColor , +.S StaticColor , +.S TrueColor , +or +.S DirectColor , +then all colour names in the table which are in set C are recognised +on a call to xname. +.tL "Set" "Color name(s)" +.tL "C" "blue" +.tL "C" "cyan" +.tL "C" "green" +.tL "C" "magenta" +.tL "C" "red" +.tL "C" "yellow" +>>STRATEGY +For each supported visual type from PseudoColor, StaticColor, TrueColor and DirectColor: + Create a colourmap of that type using XCreateColormap. + For the colournames in the table: + Obtain the rgb values for the colour using xname. + Verify that the call did not return 0. + Free the allocated colourmap cell using XFreeColors. +>>CODE +int i; +unsigned long vmask = (1L<<PseudoColor|1L<<StaticColor|1L<<TrueColor|1L<<DirectColor); +Status status; +XVisualInfo *vp; +XColor exactcol; +static char *list[] = { "blue", "cyan", "green", "magenta", "red", "yellow" }; + + + + if( (vmask = visualsupported(display, vmask)) == 0L) { + unsupported("Required visual types are not supported."); + return; + } else + CHECK; + + + exact_def_return = &exactcol; + for(resetsupvis(vmask); nextsupvis(&vp); ) { + + colormap = makecolmap(display, vp->visual, AllocNone); + for(i=0; i< NELEM(list); i++) { + + color_name = list[i]; + status = XCALL; + + if(status == 0L) { + report("Colour name \"%s\" is not supported.", color_name); + FAIL; + } else { + XFreeColors(display, colormap, &exactcol.pixel, 1, (unsigned long)0); + CHECK; + } + } + } + + CHECKPASS(nsupvis() * NELEM(list) + 1); + +>>ASSERTION Good A +When a colour name in the table which is in set M, V or X +is recognised on a call to xname, +then all other colour names in the table which are in set C, M, or V +are also recognised on another call to xname. +.tL "Set" "Color name(s)" +.tL "C" "blue" +.tL "C" "cyan" +.tL "C" "green" +.tL "C" "magenta" +.tL "C" "red" +.tL "C" "yellow" +.tL "M" "gray" "grey" +.tL "M" "dark gray" "dark grey" +.tL "V" "dark blue" +.tL "V" "brown" +.tL "V" "dark cyan" +.tL "V" "dark green" +.tL "V" "dark magenta" +.tL "V" "dark red" +.tL "X" "medium blue" +.tL "X" "midnight blue" +.tL "X" "navy blue" +.tL "X" "sky blue" +.tL "X" "coral" +.tL "X" "gold" +.tL "X" "dark slate gray" "dark slate grey" +.tL "X" "dim gray" "dim grey" +.tL "X" "light gray" "light grey" +.tL "X" "light green" +.tL "X" "forest green" +.tL "X" "lime green" +.tL "X" "pale green" +.tL "X" "spring green" +.tL "X" "maroon" +.tL "X" "orange" +.tL "X" "pink" +.tL "X" "indian red" +.tL "X" "orange red" +.tL "X" "violet red" +.tL "X" "salmon" +.tL "X" "sienna" +.tL "X" "tan" +.tL "X" "turquoise" +.tL "X" "violet" +.tL "X" "blue violet" +.tL "X" "wheat" +>>STRATEGY +If a colourname in sets M, V or X causes xname to return non-zero: + For each supported visual: + Verify that all the colour names in C, M and V also cause xname to return non-zero: + Free the allocated colourmap cell using XFreeColors. +>>CODE +XVisualInfo *vp; +unsigned long vmask; +int i; +int j; +int supported = 0; +int unsupported = 0; +Status status; +XColor exactcol; +static char *MVX[] = { "gray", "grey", "dark gray","dark grey","dark blue","brown","dark cyan","dark green","dark magenta", + "dark red","medium blue","midnight blue","navy blue","sky blue","coral","gold","dark slate gray", + "dark slate grey","dim gray","dim grey","light gray","light grey", "light green", "forest green", + "lime green","pale green","spring green","maroon","orange","pink","indian red","orange red", + "violet red","salmon","sienna","tan","turquoise","violet","blue violet","wheat" }; +static char *CMV[] = { "blue","cyan","green","magenta","red","yellow","gray","grey","dark gray","dark grey", + "dark blue","brown","dark cyan","dark green","dark magenta","dark red"}; + + if( (vmask = visualsupported(display, 0L)) == 0L) { + delete("No visuals reported as valid."); + return; + } else + CHECK; + + exact_def_return = &exactcol; + for(resetsupvis(vmask); nextsupvis(&vp); ) { + + colormap = makecolmap(display, vp->visual, AllocNone); + i = 0; + supported = 0; + color_name = MVX[i]; + status = XCALL; + + if(status != 0) { + supported++; + XFreeColors(display, colormap, &exactcol.pixel, 1, (unsigned long)0); + break; + } else + unsupported++; + } + + if(unsupported == NELEM(MVX) && supported == 0) { + PASS; + return; + } + + for(resetsupvis(vmask); nextsupvis(&vp); ) { + colormap = makecolmap(display, vp->visual, AllocNone); + for(j=0; j<NELEM(CMV); j++) { + color_name = CMV[j]; + status = XCALL; + if(status == (Status) 0) { + report("Colour name \"%s\" is not supported.", color_name); + FAIL; + } else { + XFreeColors(display, colormap, &exactcol.pixel, 1, (unsigned long)0); + CHECK; + } + } + } + + CHECKPASS(NELEM(CMV) * nsupvis() + 1); + diff --git a/xts5/Xopen/XCreateFontCursor/XCreateFontCursor.m b/xts5/Xopen/XCreateFontCursor/XCreateFontCursor.m new file mode 100644 index 00000000..032d02d3 --- /dev/null +++ b/xts5/Xopen/XCreateFontCursor/XCreateFontCursor.m @@ -0,0 +1,768 @@ +Copyright (c) 2005 X.Org Foundation L.L.C. + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies +of the Software, and to permit persons to whom the Software is furnished to do +so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. +$Header: /cvs/xtest/xtest/xts5/tset/Xopen/XCreateFontCursor/XCreateFontCursor.m,v 1.2 2005-11-03 08:44:00 jmichael Exp $ + +>># Project: VSW5 +>># +>># File: xts5/tset/XOPEN/XCreateFontCursor/XCreateFontCursor.m +>># +>># Description: +>># Tests for XCreateFontCursor() +>># +>># Modifications: +>># $Log: crtfntcrsr.m,v $ +>># Revision 1.2 2005-11-03 08:44:00 jmichael +>># clean up all vsw5 paths to use xts5 instead. +>># +>># Revision 1.1.1.2 2005/04/15 14:05:40 anderson +>># Reimport of the base with the legal name in the copyright fixed. +>># +>># Revision 8.0 1998/12/23 23:35:30 mar +>># Branch point for Release 5.0.2 +>># +>># Revision 7.0 1998/10/30 22:57:58 mar +>># Branch point for Release 5.0.2b1 +>># +>># Revision 6.0 1998/03/02 05:26:44 tbr +>># Branch point for Release 5.0.1 +>># +>># Revision 5.0 1998/01/26 03:23:17 tbr +>># Branch point for Release 5.0.1b1 +>># +>># Revision 4.0 1995/12/15 09:13:22 tbr +>># Branch point for Release 5.0.0 +>># +>># Revision 3.1 1995/12/15 01:16:38 andy +>># Prepare for GA Release +>># +/* + SCCS: @(#) crtfntcrsr.m Rel 1.5 (11/25/91) + + UniSoft Ltd., London, England + +(C) Copyright 1991 X/Open Company Limited + +All rights reserved. No part of this source code may be reproduced, +stored in a retrieval system, or transmitted, in any form or by any +means, electronic, mechanical, photocopying, recording or otherwise, +except as stated in the end-user licence agreement, without the prior +permission of the copyright owners. + +X/Open and the 'X' symbol are trademarks of X/Open Company Limited in +the UK and other countries. +*/ +>>TITLE XCreateFontCursor XOPEN +Cursor +XCreateFontCursor(display, shape) +Display *display = Dsp; +unsigned int shape; +>>SET startup fontstartup +>>SET cleanup fontcleanup +>>EXTERN +#include <X11/cursorfont.h> + +/* + * mkcolor() - return a pointer to a color structure. + * flag indicates whether or not color is foreground + * (Copied from rclrcrs.m.) + */ +static XColor * +mkcolor(flag) +{ + static XColor fore; + static XColor back; + static int first = 1; + + if (first) + { + first = 0; + + fore.pixel = BlackPixel(display, DefaultScreen(display)); + XQueryColor(display, DefaultColormap(display, DefaultScreen(display)), &fore); + back.pixel = WhitePixel(display, DefaultScreen(display)); + XQueryColor(display, DefaultColormap(display, DefaultScreen(display)), &back); + } + return(flag ? &fore : &back); +} + +static +void +test_font(symbol) +int symbol; +{ +Cursor qstat; +Window w; +XVisualInfo *vp; +int pass = 0, fail = 0; + +/* Create windows. */ + for (resetvinf(VI_WIN); nextvinf(&vp); ) { + w = makewin(display, vp); + + shape = symbol; + + trace("Shape used is %x", shape); +/* Call XCreateFontCursor with specified shape. */ + + qstat = XCALL; + +/* Verify that XCreateFontCursor returns non-zero. */ + if (qstat == 0) { + report("On a call to XCreateFontCursor,"); + report("wrong value %ld was returned", (long) qstat); + FAIL; + } else + CHECK; + +/* Call XDefineCursor and verify that no error occurs. */ + startcall(display); + if (isdeleted()) + return; + XDefineCursor(display, w, qstat); + endcall(display); + if (geterr() != Success) { + report("On a call to XDefineCursor,"); + report("Got %s, Expecting Success", errorname(geterr())); + FAIL; + } + else + CHECK; + +/* Call XRecolorCursor and verify that no error occurs. */ + startcall(display); + if (isdeleted()) + return; + XRecolorCursor(display, qstat, mkcolor(1), mkcolor(0)); + endcall(display); + if (geterr() != Success) { + report("On a call to XRecolorCursor,"); + report("Got %s, Expecting Success", errorname(geterr())); + FAIL; + } + else + CHECK; + +/* Call XFreeCursor and verify that no error occurs. */ + startcall(display); + if (isdeleted()) + return; + XFreeCursor(display, qstat); + endcall(display); + if (geterr() != Success) { + report("On a call to XFreeCursor,"); + report("Got %s, Expecting Success", errorname(geterr())); + FAIL; + } + else + CHECK; + } + + CHECKPASS(4*nvinf()); +} + +>>ASSERTION Good A +When the +.A shape +argument is +.S XC_X_cursor , +then a call to xname creates a +.S Cursor +and returns the cursor ID. +>>STRATEGY +Create windows. +Call XCreateFontCursor with shape XC_X_cursor. +Verify that XCreateFontCursor returns non-zero. +Call XDefineCursor and verify that no error occurs. +Call XRecolorCursor and verify that no error occurs. +Call XFreeCursor and verify that no error occurs. +>>CODE + + test_font(XC_X_cursor); + +>>ASSERTION Good A +When the +.A shape +argument is +.S XC_bottom_left_corner , +then a call to xname creates a +.S Cursor +and returns the cursor ID. +>>STRATEGY +Create windows. +Call XCreateFontCursor with shape XC_bottom_left_corner. +Verify that XCreateFontCursor returns non-zero. +Call XDefineCursor and verify that no error occurs. +Call XRecolorCursor and verify that no error occurs. +Call XFreeCursor and verify that no error occurs. +>>CODE + + test_font(XC_bottom_left_corner); + +>>ASSERTION Good A +When the +.A shape +argument is +.S XC_bottom_right_corner , +then a call to xname creates a +.S Cursor +and returns the cursor ID. +>>STRATEGY +Create windows. +Call XCreateFontCursor with shape XC_bottom_right_corner. +Verify that XCreateFontCursor returns non-zero. +Call XDefineCursor and verify that no error occurs. +Call XRecolorCursor and verify that no error occurs. +Call XFreeCursor and verify that no error occurs. +>>CODE + + test_font(XC_bottom_right_corner); + +>>ASSERTION Good A +When the +.A shape +argument is +.S XC_top_left_corner , +then a call to xname creates a +.S Cursor +and returns the cursor ID. +>>STRATEGY +Create windows. +Call XCreateFontCursor with shape XC_top_left_corner. +Verify that XCreateFontCursor returns non-zero. +Call XDefineCursor and verify that no error occurs. +Call XRecolorCursor and verify that no error occurs. +Call XFreeCursor and verify that no error occurs. +>>CODE + + test_font(XC_top_left_corner); + +>>ASSERTION Good A +When the +.A shape +argument is +.S XC_top_right_corner , +then a call to xname creates a +.S Cursor +and returns the cursor ID. +>>STRATEGY +Create windows. +Call XCreateFontCursor with shape XC_top_right_corner. +Verify that XCreateFontCursor returns non-zero. +Call XDefineCursor and verify that no error occurs. +Call XRecolorCursor and verify that no error occurs. +Call XFreeCursor and verify that no error occurs. +>>CODE + + test_font(XC_top_right_corner); + +>>ASSERTION Good A +When the +.A shape +argument is +.S XC_arrow , +then a call to xname creates a +.S Cursor +and returns the cursor ID. +>>STRATEGY +Create windows. +Call XCreateFontCursor with shape XC_arrow. +Verify that XCreateFontCursor returns non-zero. +Call XDefineCursor and verify that no error occurs. +Call XRecolorCursor and verify that no error occurs. +Call XFreeCursor and verify that no error occurs. +>>CODE + + test_font(XC_arrow); + +>>ASSERTION Good A +When the +.A shape +argument is +.S XC_based_arrow_down , +then a call to xname creates a +.S Cursor +and returns the cursor ID. +>>STRATEGY +Create windows. +Call XCreateFontCursor with shape XC_based_arrow_down. +Verify that XCreateFontCursor returns non-zero. +Call XDefineCursor and verify that no error occurs. +Call XRecolorCursor and verify that no error occurs. +Call XFreeCursor and verify that no error occurs. +>>CODE + + test_font(XC_based_arrow_down); + +>>ASSERTION Good A +When the +.A shape +argument is +.S XC_based_arrow_up , +then a call to xname creates a +.S Cursor +and returns the cursor ID. +>>STRATEGY +Create windows. +Call XCreateFontCursor with shape XC_based_arrow_up. +Verify that XCreateFontCursor returns non-zero. +Call XDefineCursor and verify that no error occurs. +Call XRecolorCursor and verify that no error occurs. +Call XFreeCursor and verify that no error occurs. +>>CODE + + test_font(XC_based_arrow_up); + +>>ASSERTION Good A +When the +.A shape +argument is +.S XC_double_arrow , +then a call to xname creates a +.S Cursor +and returns the cursor ID. +>>STRATEGY +Create windows. +Call XCreateFontCursor with shape XC_double_arrow. +Verify that XCreateFontCursor returns non-zero. +Call XDefineCursor and verify that no error occurs. +Call XRecolorCursor and verify that no error occurs. +Call XFreeCursor and verify that no error occurs. +>>CODE + + test_font(XC_double_arrow); + +>>ASSERTION Good A +When the +.A shape +argument is +.S XC_question_arrow , +then a call to xname creates a +.S Cursor +and returns the cursor ID. +>>STRATEGY +Create windows. +Call XCreateFontCursor with shape XC_question_arrow. +Verify that XCreateFontCursor returns non-zero. +Call XDefineCursor and verify that no error occurs. +Call XRecolorCursor and verify that no error occurs. +Call XFreeCursor and verify that no error occurs. +>>CODE + + test_font(XC_question_arrow); + +>>ASSERTION Good A +When the +.A shape +argument is +.S XC_sb_h_double_arrow , +then a call to xname creates a +.S Cursor +and returns the cursor ID. +>>STRATEGY +Create windows. +Call XCreateFontCursor with shape XC_sb_h_double_arrow. +Verify that XCreateFontCursor returns non-zero. +Call XDefineCursor and verify that no error occurs. +Call XRecolorCursor and verify that no error occurs. +Call XFreeCursor and verify that no error occurs. +>>CODE + + test_font(XC_sb_h_double_arrow); + +>>ASSERTION Good A +When the +.A shape +argument is +.S XC_sb_v_double_arrow , +then a call to xname creates a +.S Cursor +and returns the cursor ID. +>>STRATEGY +Create windows. +Call XCreateFontCursor with shape XC_sb_v_double_arrow. +Verify that XCreateFontCursor returns non-zero. +Call XDefineCursor and verify that no error occurs. +Call XRecolorCursor and verify that no error occurs. +Call XFreeCursor and verify that no error occurs. +>>CODE + + test_font(XC_sb_v_double_arrow); + +>>ASSERTION Good A +When the +.A shape +argument is +.S XC_top_left_arrow , +then a call to xname creates a +.S Cursor +and returns the cursor ID. +>>STRATEGY +Create windows. +Call XCreateFontCursor with shape XC_top_left_arrow. +Verify that XCreateFontCursor returns non-zero. +Call XDefineCursor and verify that no error occurs. +Call XRecolorCursor and verify that no error occurs. +Call XFreeCursor and verify that no error occurs. +>>CODE + + test_font(XC_top_left_arrow); + +>>ASSERTION Good A +When the +.A shape +argument is +.S XC_bottom_tee , +then a call to xname creates a +.S Cursor +and returns the cursor ID. +>>STRATEGY +Create windows. +Call XCreateFontCursor with shape XC_bottom_tee. +Verify that XCreateFontCursor returns non-zero. +Call XDefineCursor and verify that no error occurs. +Call XRecolorCursor and verify that no error occurs. +Call XFreeCursor and verify that no error occurs. +>>CODE + + test_font(XC_bottom_tee); + +>>ASSERTION Good A +When the +.A shape +argument is +.S XC_left_tee , +then a call to xname creates a +.S Cursor +and returns the cursor ID. +>>STRATEGY +Create windows. +Call XCreateFontCursor with shape XC_left_tee. +Verify that XCreateFontCursor returns non-zero. +Call XDefineCursor and verify that no error occurs. +Call XRecolorCursor and verify that no error occurs. +Call XFreeCursor and verify that no error occurs. +>>CODE + + test_font(XC_left_tee); + +>>ASSERTION Good A +When the +.A shape +argument is +.S XC_right_tee , +then a call to xname creates a +.S Cursor +and returns the cursor ID. +>>STRATEGY +Create windows. +Call XCreateFontCursor with shape XC_right_tee. +Verify that XCreateFontCursor returns non-zero. +Call XDefineCursor and verify that no error occurs. +Call XRecolorCursor and verify that no error occurs. +Call XFreeCursor and verify that no error occurs. +>>CODE + + test_font(XC_right_tee); + +>>ASSERTION Good A +When the +.A shape +argument is +.S XC_top_tee , +then a call to xname creates a +.S Cursor +and returns the cursor ID. +>>STRATEGY +Create windows. +Call XCreateFontCursor with shape XC_top_tee. +Verify that XCreateFontCursor returns non-zero. +Call XDefineCursor and verify that no error occurs. +Call XRecolorCursor and verify that no error occurs. +Call XFreeCursor and verify that no error occurs. +>>CODE + + test_font(XC_top_tee); + +>>ASSERTION Good A +When the +.A shape +argument is +.S XC_bottom_side , +then a call to xname creates a +.S Cursor +and returns the cursor ID. +>>STRATEGY +Create windows. +Call XCreateFontCursor with shape XC_bottom_side. +Verify that XCreateFontCursor returns non-zero. +Call XDefineCursor and verify that no error occurs. +Call XRecolorCursor and verify that no error occurs. +Call XFreeCursor and verify that no error occurs. +>>CODE + + test_font(XC_bottom_side); + +>>ASSERTION Good A +When the +.A shape +argument is +.S XC_left_side , +then a call to xname creates a +.S Cursor +and returns the cursor ID. +>>STRATEGY +Create windows. +Call XCreateFontCursor with shape XC_left_side. +Verify that XCreateFontCursor returns non-zero. +Call XDefineCursor and verify that no error occurs. +Call XRecolorCursor and verify that no error occurs. +Call XFreeCursor and verify that no error occurs. +>>CODE + + test_font(XC_left_side); + +>>ASSERTION Good A +When the +.A shape +argument is +.S XC_right_side , +then a call to xname creates a +.S Cursor +and returns the cursor ID. +>>STRATEGY +Create windows. +Call XCreateFontCursor with shape XC_right_side. +Verify that XCreateFontCursor returns non-zero. +Call XDefineCursor and verify that no error occurs. +Call XRecolorCursor and verify that no error occurs. +Call XFreeCursor and verify that no error occurs. +>>CODE + + test_font(XC_right_side); + +>>ASSERTION Good A +When the +.A shape +argument is +.S XC_top_side , +then a call to xname creates a +.S Cursor +and returns the cursor ID. +>>STRATEGY +Create windows. +Call XCreateFontCursor with shape XC_top_side. +Verify that XCreateFontCursor returns non-zero. +Call XDefineCursor and verify that no error occurs. +Call XRecolorCursor and verify that no error occurs. +Call XFreeCursor and verify that no error occurs. +>>CODE + + test_font(XC_top_side); + +>>ASSERTION Good A +When the +.A shape +argument is +.S XC_ll_angle , +then a call to xname creates a +.S Cursor +and returns the cursor ID. +>>STRATEGY +Create windows. +Call XCreateFontCursor with shape XC_ll_angle. +Verify that XCreateFontCursor returns non-zero. +Call XDefineCursor and verify that no error occurs. +Call XRecolorCursor and verify that no error occurs. +Call XFreeCursor and verify that no error occurs. +>>CODE + + test_font(XC_ll_angle); + +>>ASSERTION Good A +When the +.A shape +argument is +.S XC_lr_angle , +then a call to xname creates a +.S Cursor +and returns the cursor ID. +>>STRATEGY +Create windows. +Call XCreateFontCursor with shape XC_lr_angle. +Verify that XCreateFontCursor returns non-zero. +Call XDefineCursor and verify that no error occurs. +Call XRecolorCursor and verify that no error occurs. +Call XFreeCursor and verify that no error occurs. +>>CODE + + test_font(XC_lr_angle); + +>>ASSERTION Good A +When the +.A shape +argument is +.S XC_ul_angle , +then a call to xname creates a +.S Cursor +and returns the cursor ID. +>>STRATEGY +Create windows. +Call XCreateFontCursor with shape XC_ul_angle. +Verify that XCreateFontCursor returns non-zero. +Call XDefineCursor and verify that no error occurs. +Call XRecolorCursor and verify that no error occurs. +Call XFreeCursor and verify that no error occurs. +>>CODE + + test_font(XC_ul_angle); + +>>ASSERTION Good A +When the +.A shape +argument is +.S XC_ur_angle , +then a call to xname creates a +.S Cursor +and returns the cursor ID. +>>STRATEGY +Create windows. +Call XCreateFontCursor with shape XC_ur_angle. +Verify that XCreateFontCursor returns non-zero. +Call XDefineCursor and verify that no error occurs. +Call XRecolorCursor and verify that no error occurs. +Call XFreeCursor and verify that no error occurs. +>>CODE + + test_font(XC_ur_angle); + +>>ASSERTION Good A +When the +.A shape +argument is +.S XC_circle , +then a call to xname creates a +.S Cursor +and returns the cursor ID. +>>STRATEGY +Create windows. +Call XCreateFontCursor with shape XC_circle. +Verify that XCreateFontCursor returns non-zero. +Call XDefineCursor and verify that no error occurs. +Call XRecolorCursor and verify that no error occurs. +Call XFreeCursor and verify that no error occurs. +>>CODE + + test_font(XC_circle); + +>>ASSERTION Good A +When the +.A shape +argument is +.S XC_cross , +then a call to xname creates a +.S Cursor +and returns the cursor ID. +>>STRATEGY +Create windows. +Call XCreateFontCursor with shape XC_cross. +Verify that XCreateFontCursor returns non-zero. +Call XDefineCursor and verify that no error occurs. +Call XRecolorCursor and verify that no error occurs. +Call XFreeCursor and verify that no error occurs. +>>CODE + + test_font(XC_cross); + +>>ASSERTION Good A +When the +.A shape +argument is +.S XC_crosshair , +then a call to xname creates a +.S Cursor +and returns the cursor ID. +>>STRATEGY +Create windows. +Call XCreateFontCursor with shape XC_crosshair. +Verify that XCreateFontCursor returns non-zero. +Call XDefineCursor and verify that no error occurs. +Call XRecolorCursor and verify that no error occurs. +Call XFreeCursor and verify that no error occurs. +>>CODE + + test_font(XC_crosshair); + +>>ASSERTION Good A +When the +.A shape +argument is +.S XC_center_ptr , +then a call to xname creates a +.S Cursor +and returns the cursor ID. +>>STRATEGY +Create windows. +Call XCreateFontCursor with shape XC_center_ptr. +Verify that XCreateFontCursor returns non-zero. +Call XDefineCursor and verify that no error occurs. +Call XRecolorCursor and verify that no error occurs. +Call XFreeCursor and verify that no error occurs. +>>CODE + + test_font(XC_center_ptr); + +>>ASSERTION Good A +When the +.A shape +argument is +.S XC_left_ptr , +then a call to xname creates a +.S Cursor +and returns the cursor ID. +>>STRATEGY +Create windows. +Call XCreateFontCursor with shape XC_left_ptr. +Verify that XCreateFontCursor returns non-zero. +Call XDefineCursor and verify that no error occurs. +Call XRecolorCursor and verify that no error occurs. +Call XFreeCursor and verify that no error occurs. +>>CODE + + test_font(XC_left_ptr); + +>>ASSERTION Good A +When the +.A shape +argument is +.S XC_right_ptr , +then a call to xname creates a +.S Cursor +and returns the cursor ID. +>>STRATEGY +Create windows. +Call XCreateFontCursor with shape XC_right_ptr. +Verify that XCreateFontCursor returns non-zero. +Call XDefineCursor and verify that no error occurs. +Call XRecolorCursor and verify that no error occurs. +Call XFreeCursor and verify that no error occurs. +>>CODE + + test_font(XC_right_ptr); + diff --git a/xts5/Xopen/XKeysymToKeycode/Test1.c b/xts5/Xopen/XKeysymToKeycode/Test1.c new file mode 100644 index 00000000..780d8553 --- /dev/null +++ b/xts5/Xopen/XKeysymToKeycode/Test1.c @@ -0,0 +1,2099 @@ +/* +Copyright (c) 2005 X.Org Foundation L.L.C. + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies +of the Software, and to permit persons to whom the Software is furnished to do +so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. +*/ +/* +* $Header: /cvs/xtest/xtest/xts5/tset/Xopen/XKeysymToKeycode/Test1.c,v 1.2 2005-11-03 08:44:00 jmichael Exp $ +* +* Project: VSW5 +* +* File: xts5/tset/Xopen/XKeysymToKeycode/Test1.c +* +* Description: +* Tests for XKeysymToKeycode() +* +* Modifications: +* $Log: Test1.c,v $ +* Revision 1.2 2005-11-03 08:44:00 jmichael +* clean up all vsw5 paths to use xts5 instead. +* +* Revision 1.1.1.2 2005/04/15 14:05:40 anderson +* Reimport of the base with the legal name in the copyright fixed. +* +* Revision 8.0 1998/12/23 23:35:43 mar +* Branch point for Release 5.0.2 +* +* Revision 7.0 1998/10/30 22:58:21 mar +* Branch point for Release 5.0.2b1 +* +* Revision 6.0 1998/03/02 05:26:57 tbr +* Branch point for Release 5.0.1 +* +* Revision 5.0 1998/01/26 03:23:31 tbr +* Branch point for Release 5.0.1b1 +* +* Revision 4.1 1996/05/09 21:17:34 andy +* Fixed X includes +* +* Revision 4.0 1995/12/15 09:14:03 tbr +* Branch point for Release 5.0.0 +* +* Revision 3.1 1995/12/15 01:17:24 andy +* Prepare for GA Release +* +*/ +/* + * SCCS: @(#) Test1.c Rel 1.1 (11/28/91) + * + * UniSoft Ltd., London, England + * + * (C) Copyright 1991 X/Open Company Limited + * + * All rights reserved. No part of this source code may be reproduced, + * stored in a retrieval system, or transmitted, in any form or by any + * means, electronic, mechanical, photocopying, recording or otherwise, + * except as stated in the end-user licence agreement, without the prior + * permission of the copyright owners. + * + * X/Open and the 'X' symbol are trademarks of X/Open Company Limited in + * the UK and other countries. + */ + +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif + +#include <stdlib.h> +#include "xtest.h" +#include "X11/Xlib.h" +#include "X11/Xutil.h" +#include "X11/Xresource.h" +#include "tet_api.h" +#include "xtestlib.h" +#include "pixval.h" + +extern char *TestName; +extern Display *Dsp; + +int minkc; +int maxkc; +int keysyms_per_keycode; + +static int +test(symbol, str) +KeySym symbol; +char *str; +{ +KeyCode kycd; +int mod; + + kycd = XKeysymToKeycode(Dsp, symbol); + if(kycd == 0) { + trace("XKeysymToKeycode() returned 0 for KeySym \"XK_%s\".", str); + return(1); + } + + if(kycd > maxkc || kycd < minkc) { + report("XKeysymToKeycode() returned invalid keycode value %d for KeySym \"XK_%s\".", kycd, str); + return(0); + } + + for(mod = 0; mod < keysyms_per_keycode; mod++) { + if( symbol == XKeycodeToKeysym(Dsp, kycd, mod)) { + trace("KeySym \"XK_%s\", keycode %d, mod %d", + str, kycd, mod); + return(1); + } + } + + report("The keycode value %d for KeySym \"XK_%s\"", kycd, str); + report("never returns that KeySym when using XKeycodeToKeysym()"); + return(0); +} + +static void +reporterr(s) +char *s; +{ + report("Symbol XK_\"%s\" is not defined.", s); +} +#define XK_LATIN1 +#include <X11/keysymdef.h> +#undef XK_LATIN1 + +kysymtcd1() +{ +int pass = 0, fail = 0; + + XDisplayKeycodes(Dsp, &minkc, &maxkc); + XGetKeyboardMapping(Dsp, (KeyCode)minkc, 1, &keysyms_per_keycode); + +#ifdef XK_space + if(test(XK_space, "space") == 1) + CHECK; + else + FAIL; +#else + reporterr("space"); + FAIL; +#endif + +#ifdef XK_exclam + if(test(XK_exclam, "exclam") == 1) + CHECK; + else + FAIL; +#else + reporterr("exclam"); + FAIL; +#endif + +#ifdef XK_quotedbl + if(test(XK_quotedbl, "quotedbl") == 1) + CHECK; + else + FAIL; +#else + reporterr("quotedbl"); + FAIL; +#endif + +#ifdef XK_numbersign + if(test(XK_numbersign, "numbersign") == 1) + CHECK; + else + FAIL; +#else + reporterr("numbersign"); + FAIL; +#endif + +#ifdef XK_dollar + if(test(XK_dollar, "dollar") == 1) + CHECK; + else + FAIL; +#else + reporterr("dollar"); + FAIL; +#endif + +#ifdef XK_percent + if(test(XK_percent, "percent") == 1) + CHECK; + else + FAIL; +#else + reporterr("percent"); + FAIL; +#endif + +#ifdef XK_ampersand + if(test(XK_ampersand, "ampersand") == 1) + CHECK; + else + FAIL; +#else + reporterr("ampersand"); + FAIL; +#endif + +#ifdef XK_apostrophe + if(test(XK_apostrophe, "apostrophe") == 1) + CHECK; + else + FAIL; +#else + reporterr("apostrophe"); + FAIL; +#endif + +#ifdef XK_quoteright + if(test(XK_quoteright, "quoteright") == 1) + CHECK; + else + FAIL; +#else + reporterr("quoteright"); + FAIL; +#endif + +#ifdef XK_parenleft + if(test(XK_parenleft, "parenleft") == 1) + CHECK; + else + FAIL; +#else + reporterr("parenleft"); + FAIL; +#endif + +#ifdef XK_parenright + if(test(XK_parenright, "parenright") == 1) + CHECK; + else + FAIL; +#else + reporterr("parenright"); + FAIL; +#endif + +#ifdef XK_asterisk + if(test(XK_asterisk, "asterisk") == 1) + CHECK; + else + FAIL; +#else + reporterr("asterisk"); + FAIL; +#endif + +#ifdef XK_plus + if(test(XK_plus, "plus") == 1) + CHECK; + else + FAIL; +#else + reporterr("plus"); + FAIL; +#endif + +#ifdef XK_comma + if(test(XK_comma, "comma") == 1) + CHECK; + else + FAIL; +#else + reporterr("comma"); + FAIL; +#endif + +#ifdef XK_minus + if(test(XK_minus, "minus") == 1) + CHECK; + else + FAIL; +#else + reporterr("minus"); + FAIL; +#endif + +#ifdef XK_period + if(test(XK_period, "period") == 1) + CHECK; + else + FAIL; +#else + reporterr("period"); + FAIL; +#endif + +#ifdef XK_slash + if(test(XK_slash, "slash") == 1) + CHECK; + else + FAIL; +#else + reporterr("slash"); + FAIL; +#endif + +#ifdef XK_0 + if(test(XK_0, "0") == 1) + CHECK; + else + FAIL; +#else + reporterr("0"); + FAIL; +#endif + +#ifdef XK_1 + if(test(XK_1, "1") == 1) + CHECK; + else + FAIL; +#else + reporterr("1"); + FAIL; +#endif + +#ifdef XK_2 + if(test(XK_2, "2") == 1) + CHECK; + else + FAIL; +#else + reporterr("2"); + FAIL; +#endif + +#ifdef XK_3 + if(test(XK_3, "3") == 1) + CHECK; + else + FAIL; +#else + reporterr("3"); + FAIL; +#endif + +#ifdef XK_4 + if(test(XK_4, "4") == 1) + CHECK; + else + FAIL; +#else + reporterr("4"); + FAIL; +#endif + +#ifdef XK_5 + if(test(XK_5, "5") == 1) + CHECK; + else + FAIL; +#else + reporterr("5"); + FAIL; +#endif + +#ifdef XK_6 + if(test(XK_6, "6") == 1) + CHECK; + else + FAIL; +#else + reporterr("6"); + FAIL; +#endif + +#ifdef XK_7 + if(test(XK_7, "7") == 1) + CHECK; + else + FAIL; +#else + reporterr("7"); + FAIL; +#endif + +#ifdef XK_8 + if(test(XK_8, "8") == 1) + CHECK; + else + FAIL; +#else + reporterr("8"); + FAIL; +#endif + +#ifdef XK_9 + if(test(XK_9, "9") == 1) + CHECK; + else + FAIL; +#else + reporterr("9"); + FAIL; +#endif + +#ifdef XK_colon + if(test(XK_colon, "colon") == 1) + CHECK; + else + FAIL; +#else + reporterr("colon"); + FAIL; +#endif + +#ifdef XK_semicolon + if(test(XK_semicolon, "semicolon") == 1) + CHECK; + else + FAIL; +#else + reporterr("semicolon"); + FAIL; +#endif + +#ifdef XK_less + if(test(XK_less, "less") == 1) + CHECK; + else + FAIL; +#else + reporterr("less"); + FAIL; +#endif + +#ifdef XK_equal + if(test(XK_equal, "equal") == 1) + CHECK; + else + FAIL; +#else + reporterr("equal"); + FAIL; +#endif + +#ifdef XK_greater + if(test(XK_greater, "greater") == 1) + CHECK; + else + FAIL; +#else + reporterr("greater"); + FAIL; +#endif + +#ifdef XK_question + if(test(XK_question, "question") == 1) + CHECK; + else + FAIL; +#else + reporterr("question"); + FAIL; +#endif + +#ifdef XK_at + if(test(XK_at, "at") == 1) + CHECK; + else + FAIL; +#else + reporterr("at"); + FAIL; +#endif + +#ifdef XK_A + if(test(XK_A, "A") == 1) + CHECK; + else + FAIL; +#else + reporterr("A"); + FAIL; +#endif + +#ifdef XK_B + if(test(XK_B, "B") == 1) + CHECK; + else + FAIL; +#else + reporterr("B"); + FAIL; +#endif + +#ifdef XK_C + if(test(XK_C, "C") == 1) + CHECK; + else + FAIL; +#else + reporterr("C"); + FAIL; +#endif + +#ifdef XK_D + if(test(XK_D, "D") == 1) + CHECK; + else + FAIL; +#else + reporterr("D"); + FAIL; +#endif + +#ifdef XK_E + if(test(XK_E, "E") == 1) + CHECK; + else + FAIL; +#else + reporterr("E"); + FAIL; +#endif + +#ifdef XK_F + if(test(XK_F, "F") == 1) + CHECK; + else + FAIL; +#else + reporterr("F"); + FAIL; +#endif + +#ifdef XK_G + if(test(XK_G, "G") == 1) + CHECK; + else + FAIL; +#else + reporterr("G"); + FAIL; +#endif + +#ifdef XK_H + if(test(XK_H, "H") == 1) + CHECK; + else + FAIL; +#else + reporterr("H"); + FAIL; +#endif + +#ifdef XK_I + if(test(XK_I, "I") == 1) + CHECK; + else + FAIL; +#else + reporterr("I"); + FAIL; +#endif + +#ifdef XK_J + if(test(XK_J, "J") == 1) + CHECK; + else + FAIL; +#else + reporterr("J"); + FAIL; +#endif + +#ifdef XK_K + if(test(XK_K, "K") == 1) + CHECK; + else + FAIL; +#else + reporterr("K"); + FAIL; +#endif + +#ifdef XK_L + if(test(XK_L, "L") == 1) + CHECK; + else + FAIL; +#else + reporterr("L"); + FAIL; +#endif + +#ifdef XK_M + if(test(XK_M, "M") == 1) + CHECK; + else + FAIL; +#else + reporterr("M"); + FAIL; +#endif + +#ifdef XK_N + if(test(XK_N, "N") == 1) + CHECK; + else + FAIL; +#else + reporterr("N"); + FAIL; +#endif + +#ifdef XK_O + if(test(XK_O, "O") == 1) + CHECK; + else + FAIL; +#else + reporterr("O"); + FAIL; +#endif + +#ifdef XK_P + if(test(XK_P, "P") == 1) + CHECK; + else + FAIL; +#else + reporterr("P"); + FAIL; +#endif + +#ifdef XK_Q + if(test(XK_Q, "Q") == 1) + CHECK; + else + FAIL; +#else + reporterr("Q"); + FAIL; +#endif + +#ifdef XK_R + if(test(XK_R, "R") == 1) + CHECK; + else + FAIL; +#else + reporterr("R"); + FAIL; +#endif + +#ifdef XK_S + if(test(XK_S, "S") == 1) + CHECK; + else + FAIL; +#else + reporterr("S"); + FAIL; +#endif + +#ifdef XK_T + if(test(XK_T, "T") == 1) + CHECK; + else + FAIL; +#else + reporterr("T"); + FAIL; +#endif + +#ifdef XK_U + if(test(XK_U, "U") == 1) + CHECK; + else + FAIL; +#else + reporterr("U"); + FAIL; +#endif + +#ifdef XK_V + if(test(XK_V, "V") == 1) + CHECK; + else + FAIL; +#else + reporterr("V"); + FAIL; +#endif + +#ifdef XK_W + if(test(XK_W, "W") == 1) + CHECK; + else + FAIL; +#else + reporterr("W"); + FAIL; +#endif + +#ifdef XK_X + if(test(XK_X, "X") == 1) + CHECK; + else + FAIL; +#else + reporterr("X"); + FAIL; +#endif + +#ifdef XK_Y + if(test(XK_Y, "Y") == 1) + CHECK; + else + FAIL; +#else + reporterr("Y"); + FAIL; +#endif + +#ifdef XK_Z + if(test(XK_Z, "Z") == 1) + CHECK; + else + FAIL; +#else + reporterr("Z"); + FAIL; +#endif + +#ifdef XK_bracketleft + if(test(XK_bracketleft, "bracketleft") == 1) + CHECK; + else + FAIL; +#else + reporterr("bracketleft"); + FAIL; +#endif + +#ifdef XK_backslash + if(test(XK_backslash, "backslash") == 1) + CHECK; + else + FAIL; +#else + reporterr("backslash"); + FAIL; +#endif + +#ifdef XK_bracketright + if(test(XK_bracketright, "bracketright") == 1) + CHECK; + else + FAIL; +#else + reporterr("bracketright"); + FAIL; +#endif + +#ifdef XK_asciicircum + if(test(XK_asciicircum, "asciicircum") == 1) + CHECK; + else + FAIL; +#else + reporterr("asciicircum"); + FAIL; +#endif + +#ifdef XK_underscore + if(test(XK_underscore, "underscore") == 1) + CHECK; + else + FAIL; +#else + reporterr("underscore"); + FAIL; +#endif + +#ifdef XK_grave + if(test(XK_grave, "grave") == 1) + CHECK; + else + FAIL; +#else + reporterr("grave"); + FAIL; +#endif + +#ifdef XK_quoteleft + if(test(XK_quoteleft, "quoteleft") == 1) + CHECK; + else + FAIL; +#else + reporterr("quoteleft"); + FAIL; +#endif + +#ifdef XK_a + if(test(XK_a, "a") == 1) + CHECK; + else + FAIL; +#else + reporterr("a"); + FAIL; +#endif + +#ifdef XK_b + if(test(XK_b, "b") == 1) + CHECK; + else + FAIL; +#else + reporterr("b"); + FAIL; +#endif + +#ifdef XK_c + if(test(XK_c, "c") == 1) + CHECK; + else + FAIL; +#else + reporterr("c"); + FAIL; +#endif + +#ifdef XK_d + if(test(XK_d, "d") == 1) + CHECK; + else + FAIL; +#else + reporterr("d"); + FAIL; +#endif + +#ifdef XK_e + if(test(XK_e, "e") == 1) + CHECK; + else + FAIL; +#else + reporterr("e"); + FAIL; +#endif + +#ifdef XK_f + if(test(XK_f, "f") == 1) + CHECK; + else + FAIL; +#else + reporterr("f"); + FAIL; +#endif + +#ifdef XK_g + if(test(XK_g, "g") == 1) + CHECK; + else + FAIL; +#else + reporterr("g"); + FAIL; +#endif + +#ifdef XK_h + if(test(XK_h, "h") == 1) + CHECK; + else + FAIL; +#else + reporterr("h"); + FAIL; +#endif + +#ifdef XK_i + if(test(XK_i, "i") == 1) + CHECK; + else + FAIL; +#else + reporterr("i"); + FAIL; +#endif + +#ifdef XK_j + if(test(XK_j, "j") == 1) + CHECK; + else + FAIL; +#else + reporterr("j"); + FAIL; +#endif + +#ifdef XK_k + if(test(XK_k, "k") == 1) + CHECK; + else + FAIL; +#else + reporterr("k"); + FAIL; +#endif + +#ifdef XK_l + if(test(XK_l, "l") == 1) + CHECK; + else + FAIL; +#else + reporterr("l"); + FAIL; +#endif + +#ifdef XK_m + if(test(XK_m, "m") == 1) + CHECK; + else + FAIL; +#else + reporterr("m"); + FAIL; +#endif + +#ifdef XK_n + if(test(XK_n, "n") == 1) + CHECK; + else + FAIL; +#else + reporterr("n"); + FAIL; +#endif + +#ifdef XK_o + if(test(XK_o, "o") == 1) + CHECK; + else + FAIL; +#else + reporterr("o"); + FAIL; +#endif + +#ifdef XK_p + if(test(XK_p, "p") == 1) + CHECK; + else + FAIL; +#else + reporterr("p"); + FAIL; +#endif + +#ifdef XK_q + if(test(XK_q, "q") == 1) + CHECK; + else + FAIL; +#else + reporterr("q"); + FAIL; +#endif + +#ifdef XK_r + if(test(XK_r, "r") == 1) + CHECK; + else + FAIL; +#else + reporterr("r"); + FAIL; +#endif + +#ifdef XK_s + if(test(XK_s, "s") == 1) + CHECK; + else + FAIL; +#else + reporterr("s"); + FAIL; +#endif + +#ifdef XK_t + if(test(XK_t, "t") == 1) + CHECK; + else + FAIL; +#else + reporterr("t"); + FAIL; +#endif + +#ifdef XK_u + if(test(XK_u, "u") == 1) + CHECK; + else + FAIL; +#else + reporterr("u"); + FAIL; +#endif + +#ifdef XK_v + if(test(XK_v, "v") == 1) + CHECK; + else + FAIL; +#else + reporterr("v"); + FAIL; +#endif + +#ifdef XK_w + if(test(XK_w, "w") == 1) + CHECK; + else + FAIL; +#else + reporterr("w"); + FAIL; +#endif + +#ifdef XK_x + if(test(XK_x, "x") == 1) + CHECK; + else + FAIL; +#else + reporterr("x"); + FAIL; +#endif + +#ifdef XK_y + if(test(XK_y, "y") == 1) + CHECK; + else + FAIL; +#else + reporterr("y"); + FAIL; +#endif + +#ifdef XK_z + if(test(XK_z, "z") == 1) + CHECK; + else + FAIL; +#else + reporterr("z"); + FAIL; +#endif + +#ifdef XK_braceleft + if(test(XK_braceleft, "braceleft") == 1) + CHECK; + else + FAIL; +#else + reporterr("braceleft"); + FAIL; +#endif + +#ifdef XK_bar + if(test(XK_bar, "bar") == 1) + CHECK; + else + FAIL; +#else + reporterr("bar"); + FAIL; +#endif + +#ifdef XK_braceright + if(test(XK_braceright, "braceright") == 1) + CHECK; + else + FAIL; +#else + reporterr("braceright"); + FAIL; +#endif + +#ifdef XK_asciitilde + if(test(XK_asciitilde, "asciitilde") == 1) + CHECK; + else + FAIL; +#else + reporterr("asciitilde"); + FAIL; +#endif + +#ifdef XK_nobreakspace + if(test(XK_nobreakspace, "nobreakspace") == 1) + CHECK; + else + FAIL; +#else + reporterr("nobreakspace"); + FAIL; +#endif + +#ifdef XK_exclamdown + if(test(XK_exclamdown, "exclamdown") == 1) + CHECK; + else + FAIL; +#else + reporterr("exclamdown"); + FAIL; +#endif + +#ifdef XK_cent + if(test(XK_cent, "cent") == 1) + CHECK; + else + FAIL; +#else + reporterr("cent"); + FAIL; +#endif + +#ifdef XK_sterling + if(test(XK_sterling, "sterling") == 1) + CHECK; + else + FAIL; +#else + reporterr("sterling"); + FAIL; +#endif + +#ifdef XK_currency + if(test(XK_currency, "currency") == 1) + CHECK; + else + FAIL; +#else + reporterr("currency"); + FAIL; +#endif + +#ifdef XK_yen + if(test(XK_yen, "yen") == 1) + CHECK; + else + FAIL; +#else + reporterr("yen"); + FAIL; +#endif + +#ifdef XK_brokenbar + if(test(XK_brokenbar, "brokenbar") == 1) + CHECK; + else + FAIL; +#else + reporterr("brokenbar"); + FAIL; +#endif + +#ifdef XK_section + if(test(XK_section, "section") == 1) + CHECK; + else + FAIL; +#else + reporterr("section"); + FAIL; +#endif + +#ifdef XK_diaeresis + if(test(XK_diaeresis, "diaeresis") == 1) + CHECK; + else + FAIL; +#else + reporterr("diaeresis"); + FAIL; +#endif + +#ifdef XK_copyright + if(test(XK_copyright, "copyright") == 1) + CHECK; + else + FAIL; +#else + reporterr("copyright"); + FAIL; +#endif + +#ifdef XK_ordfeminine + if(test(XK_ordfeminine, "ordfeminine") == 1) + CHECK; + else + FAIL; +#else + reporterr("ordfeminine"); + FAIL; +#endif + +#ifdef XK_guillemotleft + if(test(XK_guillemotleft, "guillemotleft") == 1) + CHECK; + else + FAIL; +#else + reporterr("guillemotleft"); + FAIL; +#endif + +#ifdef XK_notsign + if(test(XK_notsign, "notsign") == 1) + CHECK; + else + FAIL; +#else + reporterr("notsign"); + FAIL; +#endif + +#ifdef XK_hyphen + if(test(XK_hyphen, "hyphen") == 1) + CHECK; + else + FAIL; +#else + reporterr("hyphen"); + FAIL; +#endif + +#ifdef XK_registered + if(test(XK_registered, "registered") == 1) + CHECK; + else + FAIL; +#else + reporterr("registered"); + FAIL; +#endif + +#ifdef XK_macron + if(test(XK_macron, "macron") == 1) + CHECK; + else + FAIL; +#else + reporterr("macron"); + FAIL; +#endif + +#ifdef XK_degree + if(test(XK_degree, "degree") == 1) + CHECK; + else + FAIL; +#else + reporterr("degree"); + FAIL; +#endif + +#ifdef XK_plusminus + if(test(XK_plusminus, "plusminus") == 1) + CHECK; + else + FAIL; +#else + reporterr("plusminus"); + FAIL; +#endif + +#ifdef XK_twosuperior + if(test(XK_twosuperior, "twosuperior") == 1) + CHECK; + else + FAIL; +#else + reporterr("twosuperior"); + FAIL; +#endif + +#ifdef XK_threesuperior + if(test(XK_threesuperior, "threesuperior") == 1) + CHECK; + else + FAIL; +#else + reporterr("threesuperior"); + FAIL; +#endif + +#ifdef XK_acute + if(test(XK_acute, "acute") == 1) + CHECK; + else + FAIL; +#else + reporterr("acute"); + FAIL; +#endif + +#ifdef XK_mu + if(test(XK_mu, "mu") == 1) + CHECK; + else + FAIL; +#else + reporterr("mu"); + FAIL; +#endif + +#ifdef XK_paragraph + if(test(XK_paragraph, "paragraph") == 1) + CHECK; + else + FAIL; +#else + reporterr("paragraph"); + FAIL; +#endif + +#ifdef XK_periodcentered + if(test(XK_periodcentered, "periodcentered") == 1) + CHECK; + else + FAIL; +#else + reporterr("periodcentered"); + FAIL; +#endif + +#ifdef XK_cedilla + if(test(XK_cedilla, "cedilla") == 1) + CHECK; + else + FAIL; +#else + reporterr("cedilla"); + FAIL; +#endif + +#ifdef XK_onesuperior + if(test(XK_onesuperior, "onesuperior") == 1) + CHECK; + else + FAIL; +#else + reporterr("onesuperior"); + FAIL; +#endif + +#ifdef XK_masculine + if(test(XK_masculine, "masculine") == 1) + CHECK; + else + FAIL; +#else + reporterr("masculine"); + FAIL; +#endif + +#ifdef XK_guillemotright + if(test(XK_guillemotright, "guillemotright") == 1) + CHECK; + else + FAIL; +#else + reporterr("guillemotright"); + FAIL; +#endif + +#ifdef XK_onequarter + if(test(XK_onequarter, "onequarter") == 1) + CHECK; + else + FAIL; +#else + reporterr("onequarter"); + FAIL; +#endif + +#ifdef XK_onehalf + if(test(XK_onehalf, "onehalf") == 1) + CHECK; + else + FAIL; +#else + reporterr("onehalf"); + FAIL; +#endif + +#ifdef XK_threequarters + if(test(XK_threequarters, "threequarters") == 1) + CHECK; + else + FAIL; +#else + reporterr("threequarters"); + FAIL; +#endif + +#ifdef XK_questiondown + if(test(XK_questiondown, "questiondown") == 1) + CHECK; + else + FAIL; +#else + reporterr("questiondown"); + FAIL; +#endif + +#ifdef XK_Agrave + if(test(XK_Agrave, "Agrave") == 1) + CHECK; + else + FAIL; +#else + reporterr("Agrave"); + FAIL; +#endif + +#ifdef XK_Aacute + if(test(XK_Aacute, "Aacute") == 1) + CHECK; + else + FAIL; +#else + reporterr("Aacute"); + FAIL; +#endif + +#ifdef XK_Acircumflex + if(test(XK_Acircumflex, "Acircumflex") == 1) + CHECK; + else + FAIL; +#else + reporterr("Acircumflex"); + FAIL; +#endif + +#ifdef XK_Atilde + if(test(XK_Atilde, "Atilde") == 1) + CHECK; + else + FAIL; +#else + reporterr("Atilde"); + FAIL; +#endif + +#ifdef XK_Adiaeresis + if(test(XK_Adiaeresis, "Adiaeresis") == 1) + CHECK; + else + FAIL; +#else + reporterr("Adiaeresis"); + FAIL; +#endif + +#ifdef XK_Aring + if(test(XK_Aring, "Aring") == 1) + CHECK; + else + FAIL; +#else + reporterr("Aring"); + FAIL; +#endif + +#ifdef XK_AE + if(test(XK_AE, "AE") == 1) + CHECK; + else + FAIL; +#else + reporterr("AE"); + FAIL; +#endif + +#ifdef XK_Ccedilla + if(test(XK_Ccedilla, "Ccedilla") == 1) + CHECK; + else + FAIL; +#else + reporterr("Ccedilla"); + FAIL; +#endif + +#ifdef XK_Egrave + if(test(XK_Egrave, "Egrave") == 1) + CHECK; + else + FAIL; +#else + reporterr("Egrave"); + FAIL; +#endif + +#ifdef XK_Eacute + if(test(XK_Eacute, "Eacute") == 1) + CHECK; + else + FAIL; +#else + reporterr("Eacute"); + FAIL; +#endif + +#ifdef XK_Ecircumflex + if(test(XK_Ecircumflex, "Ecircumflex") == 1) + CHECK; + else + FAIL; +#else + reporterr("Ecircumflex"); + FAIL; +#endif + +#ifdef XK_Ediaeresis + if(test(XK_Ediaeresis, "Ediaeresis") == 1) + CHECK; + else + FAIL; +#else + reporterr("Ediaeresis"); + FAIL; +#endif + +#ifdef XK_Igrave + if(test(XK_Igrave, "Igrave") == 1) + CHECK; + else + FAIL; +#else + reporterr("Igrave"); + FAIL; +#endif + +#ifdef XK_Iacute + if(test(XK_Iacute, "Iacute") == 1) + CHECK; + else + FAIL; +#else + reporterr("Iacute"); + FAIL; +#endif + +#ifdef XK_Icircumflex + if(test(XK_Icircumflex, "Icircumflex") == 1) + CHECK; + else + FAIL; +#else + reporterr("Icircumflex"); + FAIL; +#endif + +#ifdef XK_Idiaeresis + if(test(XK_Idiaeresis, "Idiaeresis") == 1) + CHECK; + else + FAIL; +#else + reporterr("Idiaeresis"); + FAIL; +#endif + +#ifdef XK_ETH + if(test(XK_ETH, "ETH") == 1) + CHECK; + else + FAIL; +#else + reporterr("ETH"); + FAIL; +#endif + +#ifdef XK_Eth + if(test(XK_Eth, "Eth") == 1) + CHECK; + else + FAIL; +#else + reporterr("Eth"); + FAIL; +#endif + +#ifdef XK_Ntilde + if(test(XK_Ntilde, "Ntilde") == 1) + CHECK; + else + FAIL; +#else + reporterr("Ntilde"); + FAIL; +#endif + +#ifdef XK_Ograve + if(test(XK_Ograve, "Ograve") == 1) + CHECK; + else + FAIL; +#else + reporterr("Ograve"); + FAIL; +#endif + +#ifdef XK_Oacute + if(test(XK_Oacute, "Oacute") == 1) + CHECK; + else + FAIL; +#else + reporterr("Oacute"); + FAIL; +#endif + +#ifdef XK_Ocircumflex + if(test(XK_Ocircumflex, "Ocircumflex") == 1) + CHECK; + else + FAIL; +#else + reporterr("Ocircumflex"); + FAIL; +#endif + +#ifdef XK_Otilde + if(test(XK_Otilde, "Otilde") == 1) + CHECK; + else + FAIL; +#else + reporterr("Otilde"); + FAIL; +#endif + +#ifdef XK_Odiaeresis + if(test(XK_Odiaeresis, "Odiaeresis") == 1) + CHECK; + else + FAIL; +#else + reporterr("Odiaeresis"); + FAIL; +#endif + +#ifdef XK_multiply + if(test(XK_multiply, "multiply") == 1) + CHECK; + else + FAIL; +#else + reporterr("multiply"); + FAIL; +#endif + +#ifdef XK_Ooblique + if(test(XK_Ooblique, "Ooblique") == 1) + CHECK; + else + FAIL; +#else + reporterr("Ooblique"); + FAIL; +#endif + +#ifdef XK_Ugrave + if(test(XK_Ugrave, "Ugrave") == 1) + CHECK; + else + FAIL; +#else + reporterr("Ugrave"); + FAIL; +#endif + +#ifdef XK_Uacute + if(test(XK_Uacute, "Uacute") == 1) + CHECK; + else + FAIL; +#else + reporterr("Uacute"); + FAIL; +#endif + +#ifdef XK_Ucircumflex + if(test(XK_Ucircumflex, "Ucircumflex") == 1) + CHECK; + else + FAIL; +#else + reporterr("Ucircumflex"); + FAIL; +#endif + +#ifdef XK_Udiaeresis + if(test(XK_Udiaeresis, "Udiaeresis") == 1) + CHECK; + else + FAIL; +#else + reporterr("Udiaeresis"); + FAIL; +#endif + +#ifdef XK_Yacute + if(test(XK_Yacute, "Yacute") == 1) + CHECK; + else + FAIL; +#else + reporterr("Yacute"); + FAIL; +#endif + +#ifdef XK_THORN + if(test(XK_THORN, "THORN") == 1) + CHECK; + else + FAIL; +#else + reporterr("THORN"); + FAIL; +#endif + +#ifdef XK_Thorn + if(test(XK_Thorn, "Thorn") == 1) + CHECK; + else + FAIL; +#else + reporterr("Thorn"); + FAIL; +#endif + +#ifdef XK_ssharp + if(test(XK_ssharp, "ssharp") == 1) + CHECK; + else + FAIL; +#else + reporterr("ssharp"); + FAIL; +#endif + +#ifdef XK_agrave + if(test(XK_agrave, "agrave") == 1) + CHECK; + else + FAIL; +#else + reporterr("agrave"); + FAIL; +#endif + +#ifdef XK_aacute + if(test(XK_aacute, "aacute") == 1) + CHECK; + else + FAIL; +#else + reporterr("aacute"); + FAIL; +#endif + +#ifdef XK_acircumflex + if(test(XK_acircumflex, "acircumflex") == 1) + CHECK; + else + FAIL; +#else + reporterr("acircumflex"); + FAIL; +#endif + +#ifdef XK_atilde + if(test(XK_atilde, "atilde") == 1) + CHECK; + else + FAIL; +#else + reporterr("atilde"); + FAIL; +#endif + +#ifdef XK_adiaeresis + if(test(XK_adiaeresis, "adiaeresis") == 1) + CHECK; + else + FAIL; +#else + reporterr("adiaeresis"); + FAIL; +#endif + +#ifdef XK_aring + if(test(XK_aring, "aring") == 1) + CHECK; + else + FAIL; +#else + reporterr("aring"); + FAIL; +#endif + +#ifdef XK_ae + if(test(XK_ae, "ae") == 1) + CHECK; + else + FAIL; +#else + reporterr("ae"); + FAIL; +#endif + +#ifdef XK_ccedilla + if(test(XK_ccedilla, "ccedilla") == 1) + CHECK; + else + FAIL; +#else + reporterr("ccedilla"); + FAIL; +#endif + +#ifdef XK_egrave + if(test(XK_egrave, "egrave") == 1) + CHECK; + else + FAIL; +#else + reporterr("egrave"); + FAIL; +#endif + +#ifdef XK_eacute + if(test(XK_eacute, "eacute") == 1) + CHECK; + else + FAIL; +#else + reporterr("eacute"); + FAIL; +#endif + +#ifdef XK_ecircumflex + if(test(XK_ecircumflex, "ecircumflex") == 1) + CHECK; + else + FAIL; +#else + reporterr("ecircumflex"); + FAIL; +#endif + +#ifdef XK_ediaeresis + if(test(XK_ediaeresis, "ediaeresis") == 1) + CHECK; + else + FAIL; +#else + reporterr("ediaeresis"); + FAIL; +#endif + +#ifdef XK_igrave + if(test(XK_igrave, "igrave") == 1) + CHECK; + else + FAIL; +#else + reporterr("igrave"); + FAIL; +#endif + +#ifdef XK_iacute + if(test(XK_iacute, "iacute") == 1) + CHECK; + else + FAIL; +#else + reporterr("iacute"); + FAIL; +#endif + +#ifdef XK_icircumflex + if(test(XK_icircumflex, "icircumflex") == 1) + CHECK; + else + FAIL; +#else + reporterr("icircumflex"); + FAIL; +#endif + +#ifdef XK_idiaeresis + if(test(XK_idiaeresis, "idiaeresis") == 1) + CHECK; + else + FAIL; +#else + reporterr("idiaeresis"); + FAIL; +#endif + +#ifdef XK_eth + if(test(XK_eth, "eth") == 1) + CHECK; + else + FAIL; +#else + reporterr("eth"); + FAIL; +#endif + +#ifdef XK_ntilde + if(test(XK_ntilde, "ntilde") == 1) + CHECK; + else + FAIL; +#else + reporterr("ntilde"); + FAIL; +#endif + +#ifdef XK_ograve + if(test(XK_ograve, "ograve") == 1) + CHECK; + else + FAIL; +#else + reporterr("ograve"); + FAIL; +#endif + +#ifdef XK_oacute + if(test(XK_oacute, "oacute") == 1) + CHECK; + else + FAIL; +#else + reporterr("oacute"); + FAIL; +#endif + +#ifdef XK_ocircumflex + if(test(XK_ocircumflex, "ocircumflex") == 1) + CHECK; + else + FAIL; +#else + reporterr("ocircumflex"); + FAIL; +#endif + +#ifdef XK_otilde + if(test(XK_otilde, "otilde") == 1) + CHECK; + else + FAIL; +#else + reporterr("otilde"); + FAIL; +#endif + +#ifdef XK_odiaeresis + if(test(XK_odiaeresis, "odiaeresis") == 1) + CHECK; + else + FAIL; +#else + reporterr("odiaeresis"); + FAIL; +#endif + +#ifdef XK_division + if(test(XK_division, "division") == 1) + CHECK; + else + FAIL; +#else + reporterr("division"); + FAIL; +#endif + +#ifdef XK_oslash + if(test(XK_oslash, "oslash") == 1) + CHECK; + else + FAIL; +#else + reporterr("oslash"); + FAIL; +#endif + +#ifdef XK_ugrave + if(test(XK_ugrave, "ugrave") == 1) + CHECK; + else + FAIL; +#else + reporterr("ugrave"); + FAIL; +#endif + +#ifdef XK_uacute + if(test(XK_uacute, "uacute") == 1) + CHECK; + else + FAIL; +#else + reporterr("uacute"); + FAIL; +#endif + +#ifdef XK_ucircumflex + if(test(XK_ucircumflex, "ucircumflex") == 1) + CHECK; + else + FAIL; +#else + reporterr("ucircumflex"); + FAIL; +#endif + +#ifdef XK_udiaeresis + if(test(XK_udiaeresis, "udiaeresis") == 1) + CHECK; + else + FAIL; +#else + reporterr("udiaeresis"); + FAIL; +#endif + +#ifdef XK_yacute + if(test(XK_yacute, "yacute") == 1) + CHECK; + else + FAIL; +#else + reporterr("yacute"); + FAIL; +#endif + +#ifdef XK_thorn + if(test(XK_thorn, "thorn") == 1) + CHECK; + else + FAIL; +#else + reporterr("thorn"); + FAIL; +#endif + +#ifdef XK_ydiaeresis + if(test(XK_ydiaeresis, "ydiaeresis") == 1) + CHECK; + else + FAIL; +#else + reporterr("ydiaeresis"); + FAIL; +#endif + + CHECKPASS(195); +} diff --git a/xts5/Xopen/XKeysymToKeycode/Test2.c b/xts5/Xopen/XKeysymToKeycode/Test2.c new file mode 100644 index 00000000..d6fe5e89 --- /dev/null +++ b/xts5/Xopen/XKeysymToKeycode/Test2.c @@ -0,0 +1,719 @@ +/* +Copyright (c) 2005 X.Org Foundation L.L.C. + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies +of the Software, and to permit persons to whom the Software is furnished to do +so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. +*/ +/* +* $Header: /cvs/xtest/xtest/xts5/tset/Xopen/XKeysymToKeycode/Test2.c,v 1.2 2005-11-03 08:44:00 jmichael Exp $ +* +* Project: VSW5 +* +* File: xts5/tset/Xopen/XKeysymToKeycode/Test2.c +* +* Description: +* Tests for XKeysymToKeycode() +* +* Modifications: +* $Log: Test2.c,v $ +* Revision 1.2 2005-11-03 08:44:00 jmichael +* clean up all vsw5 paths to use xts5 instead. +* +* Revision 1.1.1.2 2005/04/15 14:05:40 anderson +* Reimport of the base with the legal name in the copyright fixed. +* +* Revision 8.0 1998/12/23 23:35:44 mar +* Branch point for Release 5.0.2 +* +* Revision 7.0 1998/10/30 22:58:22 mar +* Branch point for Release 5.0.2b1 +* +* Revision 6.0 1998/03/02 05:26:58 tbr +* Branch point for Release 5.0.1 +* +* Revision 5.0 1998/01/26 03:23:31 tbr +* Branch point for Release 5.0.1b1 +* +* Revision 4.1 1996/05/09 21:17:34 andy +* Fixed X includes +* +* Revision 4.0 1995/12/15 09:14:05 tbr +* Branch point for Release 5.0.0 +* +* Revision 3.1 1995/12/15 01:17:25 andy +* Prepare for GA Release +* +*/ +/* + * SCCS: @(#) Test2.c Rel 1.1 (11/28/91) + * + * UniSoft Ltd., London, England + * + * (C) Copyright 1991 X/Open Company Limited + * + * All rights reserved. No part of this source code may be reproduced, + * stored in a retrieval system, or transmitted, in any form or by any + * means, electronic, mechanical, photocopying, recording or otherwise, + * except as stated in the end-user licence agreement, without the prior + * permission of the copyright owners. + * + * X/Open and the 'X' symbol are trademarks of X/Open Company Limited in + * the UK and other countries. + */ + +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif + +#include <stdlib.h> +#include "xtest.h" +#include "X11/Xlib.h" +#include "X11/Xutil.h" +#include "X11/Xresource.h" +#include "tet_api.h" +#include "xtestlib.h" +#include "pixval.h" + +extern char *TestName; +extern Display *Dsp; + +int minkc; +int maxkc; +int keysyms_per_keycode; + +static int +test(symbol, str) +KeySym symbol; +char *str; +{ +KeyCode kycd; +int mod; + + kycd = XKeysymToKeycode(Dsp, symbol); + if(kycd == 0) { + trace("XKeysymToKeycode() returned 0 for KeySym \"XK_%s\".", str); + return(1); + } + + if(kycd > maxkc || kycd < minkc) { + report("XKeysymToKeycode() returned invalid keycode value %d for KeySym \"XK_%s\".", kycd, str); + return(0); + } + + for(mod = 0; mod < keysyms_per_keycode; mod++) { + if( symbol == XKeycodeToKeysym(Dsp, kycd, mod)) { + trace("KeySym \"XK_%s\", keycode %d, mod %d", + str, kycd, mod); + return(1); + } + } + + report("The keycode value %d for KeySym \"XK_%s\"", kycd, str); + report("never returns that KeySym when using XKeycodeToKeysym()"); + return(0); +} + +static void +reporterr(s) +char *s; +{ + report("Symbol XK_\"%s\" is not defined.", s); +} +#define XK_LATIN2 +#include <X11/keysymdef.h> +#undef XK_LATIN2 + +kysymtcd2() +{ +int pass = 0, fail = 0; + + XDisplayKeycodes(Dsp, &minkc, &maxkc); + XGetKeyboardMapping(Dsp, (KeyCode)minkc, 1, &keysyms_per_keycode); + +#ifdef XK_Aogonek + if(test(XK_Aogonek, "Aogonek") == 1) + CHECK; + else + FAIL; +#else + reporterr("Aogonek"); + FAIL; +#endif + +#ifdef XK_breve + if(test(XK_breve, "breve") == 1) + CHECK; + else + FAIL; +#else + reporterr("breve"); + FAIL; +#endif + +#ifdef XK_Lstroke + if(test(XK_Lstroke, "Lstroke") == 1) + CHECK; + else + FAIL; +#else + reporterr("Lstroke"); + FAIL; +#endif + +#ifdef XK_Lcaron + if(test(XK_Lcaron, "Lcaron") == 1) + CHECK; + else + FAIL; +#else + reporterr("Lcaron"); + FAIL; +#endif + +#ifdef XK_Sacute + if(test(XK_Sacute, "Sacute") == 1) + CHECK; + else + FAIL; +#else + reporterr("Sacute"); + FAIL; +#endif + +#ifdef XK_Scaron + if(test(XK_Scaron, "Scaron") == 1) + CHECK; + else + FAIL; +#else + reporterr("Scaron"); + FAIL; +#endif + +#ifdef XK_Scedilla + if(test(XK_Scedilla, "Scedilla") == 1) + CHECK; + else + FAIL; +#else + reporterr("Scedilla"); + FAIL; +#endif + +#ifdef XK_Tcaron + if(test(XK_Tcaron, "Tcaron") == 1) + CHECK; + else + FAIL; +#else + reporterr("Tcaron"); + FAIL; +#endif + +#ifdef XK_Zacute + if(test(XK_Zacute, "Zacute") == 1) + CHECK; + else + FAIL; +#else + reporterr("Zacute"); + FAIL; +#endif + +#ifdef XK_Zcaron + if(test(XK_Zcaron, "Zcaron") == 1) + CHECK; + else + FAIL; +#else + reporterr("Zcaron"); + FAIL; +#endif + +#ifdef XK_Zabovedot + if(test(XK_Zabovedot, "Zabovedot") == 1) + CHECK; + else + FAIL; +#else + reporterr("Zabovedot"); + FAIL; +#endif + +#ifdef XK_aogonek + if(test(XK_aogonek, "aogonek") == 1) + CHECK; + else + FAIL; +#else + reporterr("aogonek"); + FAIL; +#endif + +#ifdef XK_ogonek + if(test(XK_ogonek, "ogonek") == 1) + CHECK; + else + FAIL; +#else + reporterr("ogonek"); + FAIL; +#endif + +#ifdef XK_lstroke + if(test(XK_lstroke, "lstroke") == 1) + CHECK; + else + FAIL; +#else + reporterr("lstroke"); + FAIL; +#endif + +#ifdef XK_lcaron + if(test(XK_lcaron, "lcaron") == 1) + CHECK; + else + FAIL; +#else + reporterr("lcaron"); + FAIL; +#endif + +#ifdef XK_sacute + if(test(XK_sacute, "sacute") == 1) + CHECK; + else + FAIL; +#else + reporterr("sacute"); + FAIL; +#endif + +#ifdef XK_caron + if(test(XK_caron, "caron") == 1) + CHECK; + else + FAIL; +#else + reporterr("caron"); + FAIL; +#endif + +#ifdef XK_scaron + if(test(XK_scaron, "scaron") == 1) + CHECK; + else + FAIL; +#else + reporterr("scaron"); + FAIL; +#endif + +#ifdef XK_scedilla + if(test(XK_scedilla, "scedilla") == 1) + CHECK; + else + FAIL; +#else + reporterr("scedilla"); + FAIL; +#endif + +#ifdef XK_tcaron + if(test(XK_tcaron, "tcaron") == 1) + CHECK; + else + FAIL; +#else + reporterr("tcaron"); + FAIL; +#endif + +#ifdef XK_zacute + if(test(XK_zacute, "zacute") == 1) + CHECK; + else + FAIL; +#else + reporterr("zacute"); + FAIL; +#endif + +#ifdef XK_doubleacute + if(test(XK_doubleacute, "doubleacute") == 1) + CHECK; + else + FAIL; +#else + reporterr("doubleacute"); + FAIL; +#endif + +#ifdef XK_zcaron + if(test(XK_zcaron, "zcaron") == 1) + CHECK; + else + FAIL; +#else + reporterr("zcaron"); + FAIL; +#endif + +#ifdef XK_zabovedot + if(test(XK_zabovedot, "zabovedot") == 1) + CHECK; + else + FAIL; +#else + reporterr("zabovedot"); + FAIL; +#endif + +#ifdef XK_Racute + if(test(XK_Racute, "Racute") == 1) + CHECK; + else + FAIL; +#else + reporterr("Racute"); + FAIL; +#endif + +#ifdef XK_Abreve + if(test(XK_Abreve, "Abreve") == 1) + CHECK; + else + FAIL; +#else + reporterr("Abreve"); + FAIL; +#endif + +#ifdef XK_Lacute + if(test(XK_Lacute, "Lacute") == 1) + CHECK; + else + FAIL; +#else + reporterr("Lacute"); + FAIL; +#endif + +#ifdef XK_Cacute + if(test(XK_Cacute, "Cacute") == 1) + CHECK; + else + FAIL; +#else + reporterr("Cacute"); + FAIL; +#endif + +#ifdef XK_Ccaron + if(test(XK_Ccaron, "Ccaron") == 1) + CHECK; + else + FAIL; +#else + reporterr("Ccaron"); + FAIL; +#endif + +#ifdef XK_Eogonek + if(test(XK_Eogonek, "Eogonek") == 1) + CHECK; + else + FAIL; +#else + reporterr("Eogonek"); + FAIL; +#endif + +#ifdef XK_Ecaron + if(test(XK_Ecaron, "Ecaron") == 1) + CHECK; + else + FAIL; +#else + reporterr("Ecaron"); + FAIL; +#endif + +#ifdef XK_Dcaron + if(test(XK_Dcaron, "Dcaron") == 1) + CHECK; + else + FAIL; +#else + reporterr("Dcaron"); + FAIL; +#endif + +#ifdef XK_Dstroke + if(test(XK_Dstroke, "Dstroke") == 1) + CHECK; + else + FAIL; +#else + reporterr("Dstroke"); + FAIL; +#endif + +#ifdef XK_Nacute + if(test(XK_Nacute, "Nacute") == 1) + CHECK; + else + FAIL; +#else + reporterr("Nacute"); + FAIL; +#endif + +#ifdef XK_Ncaron + if(test(XK_Ncaron, "Ncaron") == 1) + CHECK; + else + FAIL; +#else + reporterr("Ncaron"); + FAIL; +#endif + +#ifdef XK_Odoubleacute + if(test(XK_Odoubleacute, "Odoubleacute") == 1) + CHECK; + else + FAIL; +#else + reporterr("Odoubleacute"); + FAIL; +#endif + +#ifdef XK_Rcaron + if(test(XK_Rcaron, "Rcaron") == 1) + CHECK; + else + FAIL; +#else + reporterr("Rcaron"); + FAIL; +#endif + +#ifdef XK_Uring + if(test(XK_Uring, "Uring") == 1) + CHECK; + else + FAIL; +#else + reporterr("Uring"); + FAIL; +#endif + +#ifdef XK_Udoubleacute + if(test(XK_Udoubleacute, "Udoubleacute") == 1) + CHECK; + else + FAIL; +#else + reporterr("Udoubleacute"); + FAIL; +#endif + +#ifdef XK_Tcedilla + if(test(XK_Tcedilla, "Tcedilla") == 1) + CHECK; + else + FAIL; +#else + reporterr("Tcedilla"); + FAIL; +#endif + +#ifdef XK_racute + if(test(XK_racute, "racute") == 1) + CHECK; + else + FAIL; +#else + reporterr("racute"); + FAIL; +#endif + +#ifdef XK_abreve + if(test(XK_abreve, "abreve") == 1) + CHECK; + else + FAIL; +#else + reporterr("abreve"); + FAIL; +#endif + +#ifdef XK_lacute + if(test(XK_lacute, "lacute") == 1) + CHECK; + else + FAIL; +#else + reporterr("lacute"); + FAIL; +#endif + +#ifdef XK_cacute + if(test(XK_cacute, "cacute") == 1) + CHECK; + else + FAIL; +#else + reporterr("cacute"); + FAIL; +#endif + +#ifdef XK_ccaron + if(test(XK_ccaron, "ccaron") == 1) + CHECK; + else + FAIL; +#else + reporterr("ccaron"); + FAIL; +#endif + +#ifdef XK_eogonek + if(test(XK_eogonek, "eogonek") == 1) + CHECK; + else + FAIL; +#else + reporterr("eogonek"); + FAIL; +#endif + +#ifdef XK_ecaron + if(test(XK_ecaron, "ecaron") == 1) + CHECK; + else + FAIL; +#else + reporterr("ecaron"); + FAIL; +#endif + +#ifdef XK_dcaron + if(test(XK_dcaron, "dcaron") == 1) + CHECK; + else + FAIL; +#else + reporterr("dcaron"); + FAIL; +#endif + +#ifdef XK_dstroke + if(test(XK_dstroke, "dstroke") == 1) + CHECK; + else + FAIL; +#else + reporterr("dstroke"); + FAIL; +#endif + +#ifdef XK_nacute + if(test(XK_nacute, "nacute") == 1) + CHECK; + else + FAIL; +#else + reporterr("nacute"); + FAIL; +#endif + +#ifdef XK_ncaron + if(test(XK_ncaron, "ncaron") == 1) + CHECK; + else + FAIL; +#else + reporterr("ncaron"); + FAIL; +#endif + +#ifdef XK_odoubleacute + if(test(XK_odoubleacute, "odoubleacute") == 1) + CHECK; + else + FAIL; +#else + reporterr("odoubleacute"); + FAIL; +#endif + +#ifdef XK_rcaron + if(test(XK_rcaron, "rcaron") == 1) + CHECK; + else + FAIL; +#else + reporterr("rcaron"); + FAIL; +#endif + +#ifdef XK_uring + if(test(XK_uring, "uring") == 1) + CHECK; + else + FAIL; +#else + reporterr("uring"); + FAIL; +#endif + +#ifdef XK_udoubleacute + if(test(XK_udoubleacute, "udoubleacute") == 1) + CHECK; + else + FAIL; +#else + reporterr("udoubleacute"); + FAIL; +#endif + +#ifdef XK_tcedilla + if(test(XK_tcedilla, "tcedilla") == 1) + CHECK; + else + FAIL; +#else + reporterr("tcedilla"); + FAIL; +#endif + +#ifdef XK_abovedot + if(test(XK_abovedot, "abovedot") == 1) + CHECK; + else + FAIL; +#else + reporterr("abovedot"); + FAIL; +#endif + + CHECKPASS(57); +} diff --git a/xts5/Xopen/XKeysymToKeycode/Test3.c b/xts5/Xopen/XKeysymToKeycode/Test3.c new file mode 100644 index 00000000..681aeb8f --- /dev/null +++ b/xts5/Xopen/XKeysymToKeycode/Test3.c @@ -0,0 +1,369 @@ +/* +Copyright (c) 2005 X.Org Foundation L.L.C. + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies +of the Software, and to permit persons to whom the Software is furnished to do +so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. +*/ +/* +* $Header: /cvs/xtest/xtest/xts5/tset/Xopen/XKeysymToKeycode/Test3.c,v 1.2 2005-11-03 08:44:00 jmichael Exp $ +* +* Project: VSW5 +* +* File: xts5/tset/Xopen/XKeysymToKeycode/Test3.c +* +* Description: +* Tests for XKeysymToKeycode() +* +* Modifications: +* $Log: Test3.c,v $ +* Revision 1.2 2005-11-03 08:44:00 jmichael +* clean up all vsw5 paths to use xts5 instead. +* +* Revision 1.1.1.2 2005/04/15 14:05:40 anderson +* Reimport of the base with the legal name in the copyright fixed. +* +* Revision 8.0 1998/12/23 23:35:44 mar +* Branch point for Release 5.0.2 +* +* Revision 7.0 1998/10/30 22:58:23 mar +* Branch point for Release 5.0.2b1 +* +* Revision 6.0 1998/03/02 05:26:58 tbr +* Branch point for Release 5.0.1 +* +* Revision 5.0 1998/01/26 03:23:32 tbr +* Branch point for Release 5.0.1b1 +* +* Revision 4.1 1996/05/09 21:17:34 andy +* Fixed X includes +* +* Revision 4.0 1995/12/15 09:14:06 tbr +* Branch point for Release 5.0.0 +* +* Revision 3.1 1995/12/15 01:17:27 andy +* Prepare for GA Release +* +*/ +/* + * SCCS: @(#) Test3.c Rel 1.1 (11/28/91) + * + * UniSoft Ltd., London, England + * + * (C) Copyright 1991 X/Open Company Limited + * + * All rights reserved. No part of this source code may be reproduced, + * stored in a retrieval system, or transmitted, in any form or by any + * means, electronic, mechanical, photocopying, recording or otherwise, + * except as stated in the end-user licence agreement, without the prior + * permission of the copyright owners. + * + * X/Open and the 'X' symbol are trademarks of X/Open Company Limited in + * the UK and other countries. + */ + +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif + +#include <stdlib.h> +#include "xtest.h" +#include "X11/Xlib.h" +#include "X11/Xutil.h" +#include "X11/Xresource.h" +#include "tet_api.h" +#include "xtestlib.h" +#include "pixval.h" + +extern char *TestName; +extern Display *Dsp; + +int minkc; +int maxkc; +int keysyms_per_keycode; + +static int +test(symbol, str) +KeySym symbol; +char *str; +{ +KeyCode kycd; +int mod; + + kycd = XKeysymToKeycode(Dsp, symbol); + if(kycd == 0) { + trace("XKeysymToKeycode() returned 0 for KeySym \"XK_%s\".", str); + return(1); + } + + if(kycd > maxkc || kycd < minkc) { + report("XKeysymToKeycode() returned invalid keycode value %d for KeySym \"XK_%s\".", kycd, str); + return(0); + } + + for(mod = 0; mod < keysyms_per_keycode; mod++) { + if( symbol == XKeycodeToKeysym(Dsp, kycd, mod)) { + trace("KeySym \"XK_%s\", keycode %d, mod %d", + str, kycd, mod); + return(1); + } + } + + report("The keycode value %d for KeySym \"XK_%s\"", kycd, str); + report("never returns that KeySym when using XKeycodeToKeysym()"); + return(0); +} + +static void +reporterr(s) +char *s; +{ + report("Symbol XK_\"%s\" is not defined.", s); +} +#define XK_LATIN3 +#include <X11/keysymdef.h> +#undef XK_LATIN3 + +kysymtcd3() +{ +int pass = 0, fail = 0; + + XDisplayKeycodes(Dsp, &minkc, &maxkc); + XGetKeyboardMapping(Dsp, (KeyCode)minkc, 1, &keysyms_per_keycode); + +#ifdef XK_Hstroke + if(test(XK_Hstroke, "Hstroke") == 1) + CHECK; + else + FAIL; +#else + reporterr("Hstroke"); + FAIL; +#endif + +#ifdef XK_Hcircumflex + if(test(XK_Hcircumflex, "Hcircumflex") == 1) + CHECK; + else + FAIL; +#else + reporterr("Hcircumflex"); + FAIL; +#endif + +#ifdef XK_Iabovedot + if(test(XK_Iabovedot, "Iabovedot") == 1) + CHECK; + else + FAIL; +#else + reporterr("Iabovedot"); + FAIL; +#endif + +#ifdef XK_Gbreve + if(test(XK_Gbreve, "Gbreve") == 1) + CHECK; + else + FAIL; +#else + reporterr("Gbreve"); + FAIL; +#endif + +#ifdef XK_Jcircumflex + if(test(XK_Jcircumflex, "Jcircumflex") == 1) + CHECK; + else + FAIL; +#else + reporterr("Jcircumflex"); + FAIL; +#endif + +#ifdef XK_hstroke + if(test(XK_hstroke, "hstroke") == 1) + CHECK; + else + FAIL; +#else + reporterr("hstroke"); + FAIL; +#endif + +#ifdef XK_hcircumflex + if(test(XK_hcircumflex, "hcircumflex") == 1) + CHECK; + else + FAIL; +#else + reporterr("hcircumflex"); + FAIL; +#endif + +#ifdef XK_idotless + if(test(XK_idotless, "idotless") == 1) + CHECK; + else + FAIL; +#else + reporterr("idotless"); + FAIL; +#endif + +#ifdef XK_gbreve + if(test(XK_gbreve, "gbreve") == 1) + CHECK; + else + FAIL; +#else + reporterr("gbreve"); + FAIL; +#endif + +#ifdef XK_jcircumflex + if(test(XK_jcircumflex, "jcircumflex") == 1) + CHECK; + else + FAIL; +#else + reporterr("jcircumflex"); + FAIL; +#endif + +#ifdef XK_Cabovedot + if(test(XK_Cabovedot, "Cabovedot") == 1) + CHECK; + else + FAIL; +#else + reporterr("Cabovedot"); + FAIL; +#endif + +#ifdef XK_Ccircumflex + if(test(XK_Ccircumflex, "Ccircumflex") == 1) + CHECK; + else + FAIL; +#else + reporterr("Ccircumflex"); + FAIL; +#endif + +#ifdef XK_Gabovedot + if(test(XK_Gabovedot, "Gabovedot") == 1) + CHECK; + else + FAIL; +#else + reporterr("Gabovedot"); + FAIL; +#endif + +#ifdef XK_Gcircumflex + if(test(XK_Gcircumflex, "Gcircumflex") == 1) + CHECK; + else + FAIL; +#else + reporterr("Gcircumflex"); + FAIL; +#endif + +#ifdef XK_Ubreve + if(test(XK_Ubreve, "Ubreve") == 1) + CHECK; + else + FAIL; +#else + reporterr("Ubreve"); + FAIL; +#endif + +#ifdef XK_Scircumflex + if(test(XK_Scircumflex, "Scircumflex") == 1) + CHECK; + else + FAIL; +#else + reporterr("Scircumflex"); + FAIL; +#endif + +#ifdef XK_cabovedot + if(test(XK_cabovedot, "cabovedot") == 1) + CHECK; + else + FAIL; +#else + reporterr("cabovedot"); + FAIL; +#endif + +#ifdef XK_ccircumflex + if(test(XK_ccircumflex, "ccircumflex") == 1) + CHECK; + else + FAIL; +#else + reporterr("ccircumflex"); + FAIL; +#endif + +#ifdef XK_gabovedot + if(test(XK_gabovedot, "gabovedot") == 1) + CHECK; + else + FAIL; +#else + reporterr("gabovedot"); + FAIL; +#endif + +#ifdef XK_gcircumflex + if(test(XK_gcircumflex, "gcircumflex") == 1) + CHECK; + else + FAIL; +#else + reporterr("gcircumflex"); + FAIL; +#endif + +#ifdef XK_ubreve + if(test(XK_ubreve, "ubreve") == 1) + CHECK; + else + FAIL; +#else + reporterr("ubreve"); + FAIL; +#endif + +#ifdef XK_scircumflex + if(test(XK_scircumflex, "scircumflex") == 1) + CHECK; + else + FAIL; +#else + reporterr("scircumflex"); + FAIL; +#endif + + CHECKPASS(22); +} diff --git a/xts5/Xopen/XKeysymToKeycode/Test4.c b/xts5/Xopen/XKeysymToKeycode/Test4.c new file mode 100644 index 00000000..449fafe1 --- /dev/null +++ b/xts5/Xopen/XKeysymToKeycode/Test4.c @@ -0,0 +1,509 @@ +/* +Copyright (c) 2005 X.Org Foundation L.L.C. + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies +of the Software, and to permit persons to whom the Software is furnished to do +so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. +*/ +/* +* $Header: /cvs/xtest/xtest/xts5/tset/Xopen/XKeysymToKeycode/Test4.c,v 1.2 2005-11-03 08:44:00 jmichael Exp $ +* +* Project: VSW5 +* +* File: xts5/tset/Xopen/XKeysymToKeycode/Test4.c +* +* Description: +* Tests for XKeysymToKeycode() +* +* Modifications: +* $Log: Test4.c,v $ +* Revision 1.2 2005-11-03 08:44:00 jmichael +* clean up all vsw5 paths to use xts5 instead. +* +* Revision 1.1.1.2 2005/04/15 14:05:40 anderson +* Reimport of the base with the legal name in the copyright fixed. +* +* Revision 8.0 1998/12/23 23:35:45 mar +* Branch point for Release 5.0.2 +* +* Revision 7.0 1998/10/30 22:58:24 mar +* Branch point for Release 5.0.2b1 +* +* Revision 6.0 1998/03/02 05:26:59 tbr +* Branch point for Release 5.0.1 +* +* Revision 5.0 1998/01/26 03:23:32 tbr +* Branch point for Release 5.0.1b1 +* +* Revision 4.1 1996/05/09 21:17:34 andy +* Fixed X includes +* +* Revision 4.0 1995/12/15 09:14:07 tbr +* Branch point for Release 5.0.0 +* +* Revision 3.1 1995/12/15 01:17:28 andy +* Prepare for GA Release +* +*/ +/* + * SCCS: @(#) Test4.c Rel 1.1 (11/28/91) + * + * UniSoft Ltd., London, England + * + * (C) Copyright 1991 X/Open Company Limited + * + * All rights reserved. No part of this source code may be reproduced, + * stored in a retrieval system, or transmitted, in any form or by any + * means, electronic, mechanical, photocopying, recording or otherwise, + * except as stated in the end-user licence agreement, without the prior + * permission of the copyright owners. + * + * X/Open and the 'X' symbol are trademarks of X/Open Company Limited in + * the UK and other countries. + */ + +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif + +#include <stdlib.h> +#include "xtest.h" +#include "X11/Xlib.h" +#include "X11/Xutil.h" +#include "X11/Xresource.h" +#include "tet_api.h" +#include "xtestlib.h" +#include "pixval.h" + +extern char *TestName; +extern Display *Dsp; + +int minkc; +int maxkc; +int keysyms_per_keycode; + +static int +test(symbol, str) +KeySym symbol; +char *str; +{ +KeyCode kycd; +int mod; + + kycd = XKeysymToKeycode(Dsp, symbol); + if(kycd == 0) { + trace("XKeysymToKeycode() returned 0 for KeySym \"XK_%s\".", str); + return(1); + } + + if(kycd > maxkc || kycd < minkc) { + report("XKeysymToKeycode() returned invalid keycode value %d for KeySym \"XK_%s\".", kycd, str); + return(0); + } + + for(mod = 0; mod < keysyms_per_keycode; mod++) { + if( symbol == XKeycodeToKeysym(Dsp, kycd, mod)) { + trace("KeySym \"XK_%s\", keycode %d, mod %d", + str, kycd, mod); + return(1); + } + } + + report("The keycode value %d for KeySym \"XK_%s\"", kycd, str); + report("never returns that KeySym when using XKeycodeToKeysym()"); + return(0); +} + +static void +reporterr(s) +char *s; +{ + report("Symbol XK_\"%s\" is not defined.", s); +} +#define XK_LATIN4 +#include <X11/keysymdef.h> +#undef XK_LATIN4 + +kysymtcd4() +{ +int pass = 0, fail = 0; + + XDisplayKeycodes(Dsp, &minkc, &maxkc); + XGetKeyboardMapping(Dsp, (KeyCode)minkc, 1, &keysyms_per_keycode); + +#ifdef XK_kra + if(test(XK_kra, "kra") == 1) + CHECK; + else + FAIL; +#else + reporterr("kra"); + FAIL; +#endif + +#ifdef XK_kappa + if(test(XK_kappa, "kappa") == 1) + CHECK; + else + FAIL; +#else + reporterr("kappa"); + FAIL; +#endif + +#ifdef XK_Rcedilla + if(test(XK_Rcedilla, "Rcedilla") == 1) + CHECK; + else + FAIL; +#else + reporterr("Rcedilla"); + FAIL; +#endif + +#ifdef XK_Itilde + if(test(XK_Itilde, "Itilde") == 1) + CHECK; + else + FAIL; +#else + reporterr("Itilde"); + FAIL; +#endif + +#ifdef XK_Lcedilla + if(test(XK_Lcedilla, "Lcedilla") == 1) + CHECK; + else + FAIL; +#else + reporterr("Lcedilla"); + FAIL; +#endif + +#ifdef XK_Emacron + if(test(XK_Emacron, "Emacron") == 1) + CHECK; + else + FAIL; +#else + reporterr("Emacron"); + FAIL; +#endif + +#ifdef XK_Gcedilla + if(test(XK_Gcedilla, "Gcedilla") == 1) + CHECK; + else + FAIL; +#else + reporterr("Gcedilla"); + FAIL; +#endif + +#ifdef XK_Tslash + if(test(XK_Tslash, "Tslash") == 1) + CHECK; + else + FAIL; +#else + reporterr("Tslash"); + FAIL; +#endif + +#ifdef XK_rcedilla + if(test(XK_rcedilla, "rcedilla") == 1) + CHECK; + else + FAIL; +#else + reporterr("rcedilla"); + FAIL; +#endif + +#ifdef XK_itilde + if(test(XK_itilde, "itilde") == 1) + CHECK; + else + FAIL; +#else + reporterr("itilde"); + FAIL; +#endif + +#ifdef XK_lcedilla + if(test(XK_lcedilla, "lcedilla") == 1) + CHECK; + else + FAIL; +#else + reporterr("lcedilla"); + FAIL; +#endif + +#ifdef XK_emacron + if(test(XK_emacron, "emacron") == 1) + CHECK; + else + FAIL; +#else + reporterr("emacron"); + FAIL; +#endif + +#ifdef XK_gcedilla + if(test(XK_gcedilla, "gcedilla") == 1) + CHECK; + else + FAIL; +#else + reporterr("gcedilla"); + FAIL; +#endif + +#ifdef XK_tslash + if(test(XK_tslash, "tslash") == 1) + CHECK; + else + FAIL; +#else + reporterr("tslash"); + FAIL; +#endif + +#ifdef XK_ENG + if(test(XK_ENG, "ENG") == 1) + CHECK; + else + FAIL; +#else + reporterr("ENG"); + FAIL; +#endif + +#ifdef XK_eng + if(test(XK_eng, "eng") == 1) + CHECK; + else + FAIL; +#else + reporterr("eng"); + FAIL; +#endif + +#ifdef XK_Amacron + if(test(XK_Amacron, "Amacron") == 1) + CHECK; + else + FAIL; +#else + reporterr("Amacron"); + FAIL; +#endif + +#ifdef XK_Iogonek + if(test(XK_Iogonek, "Iogonek") == 1) + CHECK; + else + FAIL; +#else + reporterr("Iogonek"); + FAIL; +#endif + +#ifdef XK_Eabovedot + if(test(XK_Eabovedot, "Eabovedot") == 1) + CHECK; + else + FAIL; +#else + reporterr("Eabovedot"); + FAIL; +#endif + +#ifdef XK_Imacron + if(test(XK_Imacron, "Imacron") == 1) + CHECK; + else + FAIL; +#else + reporterr("Imacron"); + FAIL; +#endif + +#ifdef XK_Ncedilla + if(test(XK_Ncedilla, "Ncedilla") == 1) + CHECK; + else + FAIL; +#else + reporterr("Ncedilla"); + FAIL; +#endif + +#ifdef XK_Omacron + if(test(XK_Omacron, "Omacron") == 1) + CHECK; + else + FAIL; +#else + reporterr("Omacron"); + FAIL; +#endif + +#ifdef XK_Kcedilla + if(test(XK_Kcedilla, "Kcedilla") == 1) + CHECK; + else + FAIL; +#else + reporterr("Kcedilla"); + FAIL; +#endif + +#ifdef XK_Uogonek + if(test(XK_Uogonek, "Uogonek") == 1) + CHECK; + else + FAIL; +#else + reporterr("Uogonek"); + FAIL; +#endif + +#ifdef XK_Utilde + if(test(XK_Utilde, "Utilde") == 1) + CHECK; + else + FAIL; +#else + reporterr("Utilde"); + FAIL; +#endif + +#ifdef XK_Umacron + if(test(XK_Umacron, "Umacron") == 1) + CHECK; + else + FAIL; +#else + reporterr("Umacron"); + FAIL; +#endif + +#ifdef XK_amacron + if(test(XK_amacron, "amacron") == 1) + CHECK; + else + FAIL; +#else + reporterr("amacron"); + FAIL; +#endif + +#ifdef XK_iogonek + if(test(XK_iogonek, "iogonek") == 1) + CHECK; + else + FAIL; +#else + reporterr("iogonek"); + FAIL; +#endif + +#ifdef XK_eabovedot + if(test(XK_eabovedot, "eabovedot") == 1) + CHECK; + else + FAIL; +#else + reporterr("eabovedot"); + FAIL; +#endif + +#ifdef XK_imacron + if(test(XK_imacron, "imacron") == 1) + CHECK; + else + FAIL; +#else + reporterr("imacron"); + FAIL; +#endif + +#ifdef XK_ncedilla + if(test(XK_ncedilla, "ncedilla") == 1) + CHECK; + else + FAIL; +#else + reporterr("ncedilla"); + FAIL; +#endif + +#ifdef XK_omacron + if(test(XK_omacron, "omacron") == 1) + CHECK; + else + FAIL; +#else + reporterr("omacron"); + FAIL; +#endif + +#ifdef XK_kcedilla + if(test(XK_kcedilla, "kcedilla") == 1) + CHECK; + else + FAIL; +#else + reporterr("kcedilla"); + FAIL; +#endif + +#ifdef XK_uogonek + if(test(XK_uogonek, "uogonek") == 1) + CHECK; + else + FAIL; +#else + reporterr("uogonek"); + FAIL; +#endif + +#ifdef XK_utilde + if(test(XK_utilde, "utilde") == 1) + CHECK; + else + FAIL; +#else + reporterr("utilde"); + FAIL; +#endif + +#ifdef XK_umacron + if(test(XK_umacron, "umacron") == 1) + CHECK; + else + FAIL; +#else + reporterr("umacron"); + FAIL; +#endif + + CHECKPASS(36); +} diff --git a/xts5/Xopen/XKeysymToKeycode/TestA.c b/xts5/Xopen/XKeysymToKeycode/TestA.c new file mode 100644 index 00000000..61743db4 --- /dev/null +++ b/xts5/Xopen/XKeysymToKeycode/TestA.c @@ -0,0 +1,649 @@ +/* +Copyright (c) 2005 X.Org Foundation L.L.C. + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies +of the Software, and to permit persons to whom the Software is furnished to do +so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. +*/ +/* +* $Header: /cvs/xtest/xtest/xts5/tset/Xopen/XKeysymToKeycode/TestA.c,v 1.2 2005-11-03 08:44:00 jmichael Exp $ +* +* Project: VSW5 +* +* File: xts5/tset/Xopen/XKeysymToKeycode/TestA.c +* +* Description: +* Tests for XKeysymToKeycode() +* +* Modifications: +* $Log: TestA.c,v $ +* Revision 1.2 2005-11-03 08:44:00 jmichael +* clean up all vsw5 paths to use xts5 instead. +* +* Revision 1.1.1.2 2005/04/15 14:05:40 anderson +* Reimport of the base with the legal name in the copyright fixed. +* +* Revision 8.0 1998/12/23 23:35:45 mar +* Branch point for Release 5.0.2 +* +* Revision 7.0 1998/10/30 22:58:25 mar +* Branch point for Release 5.0.2b1 +* +* Revision 6.0 1998/03/02 05:26:59 tbr +* Branch point for Release 5.0.1 +* +* Revision 5.0 1998/01/26 03:23:33 tbr +* Branch point for Release 5.0.1b1 +* +* Revision 4.1 1996/05/09 21:17:34 andy +* Fixed X includes +* +* Revision 4.0 1995/12/15 09:14:09 tbr +* Branch point for Release 5.0.0 +* +* Revision 3.1 1995/12/15 01:17:30 andy +* Prepare for GA Release +* +*/ +/* + * SCCS: @(#) TestA.c Rel 1.1 (11/28/91) + * + * UniSoft Ltd., London, England + * + * (C) Copyright 1991 X/Open Company Limited + * + * All rights reserved. No part of this source code may be reproduced, + * stored in a retrieval system, or transmitted, in any form or by any + * means, electronic, mechanical, photocopying, recording or otherwise, + * except as stated in the end-user licence agreement, without the prior + * permission of the copyright owners. + * + * X/Open and the 'X' symbol are trademarks of X/Open Company Limited in + * the UK and other countries. + */ + +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif + +#include <stdlib.h> +#include "xtest.h" +#include "X11/Xlib.h" +#include "X11/Xutil.h" +#include "X11/Xresource.h" +#include "tet_api.h" +#include "xtestlib.h" +#include "pixval.h" + +extern char *TestName; +extern Display *Dsp; + +int minkc; +int maxkc; +int keysyms_per_keycode; + +static int +test(symbol, str) +KeySym symbol; +char *str; +{ +KeyCode kycd; +int mod; + + kycd = XKeysymToKeycode(Dsp, symbol); + if(kycd == 0) { + trace("XKeysymToKeycode() returned 0 for KeySym \"XK_%s\".", str); + return(1); + } + + if(kycd > maxkc || kycd < minkc) { + report("XKeysymToKeycode() returned invalid keycode value %d for KeySym \"XK_%s\".", kycd, str); + return(0); + } + + for(mod = 0; mod < keysyms_per_keycode; mod++) { + if( symbol == XKeycodeToKeysym(Dsp, kycd, mod)) { + trace("KeySym \"XK_%s\", keycode %d, mod %d", + str, kycd, mod); + return(1); + } + } + + report("The keycode value %d for KeySym \"XK_%s\"", kycd, str); + report("never returns that KeySym when using XKeycodeToKeysym()"); + return(0); +} + +static void +reporterr(s) +char *s; +{ + report("Symbol XK_\"%s\" is not defined.", s); +} +#define XK_ARABIC +#include <X11/keysymdef.h> +#undef XK_ARABIC + +kysymtcdA() +{ +int pass = 0, fail = 0; + + XDisplayKeycodes(Dsp, &minkc, &maxkc); + XGetKeyboardMapping(Dsp, (KeyCode)minkc, 1, &keysyms_per_keycode); + +#ifdef XK_Arabic_comma + if(test(XK_Arabic_comma, "Arabic_comma") == 1) + CHECK; + else + FAIL; +#else + reporterr("Arabic_comma"); + FAIL; +#endif + +#ifdef XK_Arabic_semicolon + if(test(XK_Arabic_semicolon, "Arabic_semicolon") == 1) + CHECK; + else + FAIL; +#else + reporterr("Arabic_semicolon"); + FAIL; +#endif + +#ifdef XK_Arabic_question_mark + if(test(XK_Arabic_question_mark, "Arabic_question_mark") == 1) + CHECK; + else + FAIL; +#else + reporterr("Arabic_question_mark"); + FAIL; +#endif + +#ifdef XK_Arabic_hamza + if(test(XK_Arabic_hamza, "Arabic_hamza") == 1) + CHECK; + else + FAIL; +#else + reporterr("Arabic_hamza"); + FAIL; +#endif + +#ifdef XK_Arabic_maddaonalef + if(test(XK_Arabic_maddaonalef, "Arabic_maddaonalef") == 1) + CHECK; + else + FAIL; +#else + reporterr("Arabic_maddaonalef"); + FAIL; +#endif + +#ifdef XK_Arabic_hamzaonalef + if(test(XK_Arabic_hamzaonalef, "Arabic_hamzaonalef") == 1) + CHECK; + else + FAIL; +#else + reporterr("Arabic_hamzaonalef"); + FAIL; +#endif + +#ifdef XK_Arabic_hamzaonwaw + if(test(XK_Arabic_hamzaonwaw, "Arabic_hamzaonwaw") == 1) + CHECK; + else + FAIL; +#else + reporterr("Arabic_hamzaonwaw"); + FAIL; +#endif + +#ifdef XK_Arabic_hamzaunderalef + if(test(XK_Arabic_hamzaunderalef, "Arabic_hamzaunderalef") == 1) + CHECK; + else + FAIL; +#else + reporterr("Arabic_hamzaunderalef"); + FAIL; +#endif + +#ifdef XK_Arabic_hamzaonyeh + if(test(XK_Arabic_hamzaonyeh, "Arabic_hamzaonyeh") == 1) + CHECK; + else + FAIL; +#else + reporterr("Arabic_hamzaonyeh"); + FAIL; +#endif + +#ifdef XK_Arabic_alef + if(test(XK_Arabic_alef, "Arabic_alef") == 1) + CHECK; + else + FAIL; +#else + reporterr("Arabic_alef"); + FAIL; +#endif + +#ifdef XK_Arabic_beh + if(test(XK_Arabic_beh, "Arabic_beh") == 1) + CHECK; + else + FAIL; +#else + reporterr("Arabic_beh"); + FAIL; +#endif + +#ifdef XK_Arabic_tehmarbuta + if(test(XK_Arabic_tehmarbuta, "Arabic_tehmarbuta") == 1) + CHECK; + else + FAIL; +#else + reporterr("Arabic_tehmarbuta"); + FAIL; +#endif + +#ifdef XK_Arabic_teh + if(test(XK_Arabic_teh, "Arabic_teh") == 1) + CHECK; + else + FAIL; +#else + reporterr("Arabic_teh"); + FAIL; +#endif + +#ifdef XK_Arabic_theh + if(test(XK_Arabic_theh, "Arabic_theh") == 1) + CHECK; + else + FAIL; +#else + reporterr("Arabic_theh"); + FAIL; +#endif + +#ifdef XK_Arabic_jeem + if(test(XK_Arabic_jeem, "Arabic_jeem") == 1) + CHECK; + else + FAIL; +#else + reporterr("Arabic_jeem"); + FAIL; +#endif + +#ifdef XK_Arabic_hah + if(test(XK_Arabic_hah, "Arabic_hah") == 1) + CHECK; + else + FAIL; +#else + reporterr("Arabic_hah"); + FAIL; +#endif + +#ifdef XK_Arabic_khah + if(test(XK_Arabic_khah, "Arabic_khah") == 1) + CHECK; + else + FAIL; +#else + reporterr("Arabic_khah"); + FAIL; +#endif + +#ifdef XK_Arabic_dal + if(test(XK_Arabic_dal, "Arabic_dal") == 1) + CHECK; + else + FAIL; +#else + reporterr("Arabic_dal"); + FAIL; +#endif + +#ifdef XK_Arabic_thal + if(test(XK_Arabic_thal, "Arabic_thal") == 1) + CHECK; + else + FAIL; +#else + reporterr("Arabic_thal"); + FAIL; +#endif + +#ifdef XK_Arabic_ra + if(test(XK_Arabic_ra, "Arabic_ra") == 1) + CHECK; + else + FAIL; +#else + reporterr("Arabic_ra"); + FAIL; +#endif + +#ifdef XK_Arabic_zain + if(test(XK_Arabic_zain, "Arabic_zain") == 1) + CHECK; + else + FAIL; +#else + reporterr("Arabic_zain"); + FAIL; +#endif + +#ifdef XK_Arabic_seen + if(test(XK_Arabic_seen, "Arabic_seen") == 1) + CHECK; + else + FAIL; +#else + reporterr("Arabic_seen"); + FAIL; +#endif + +#ifdef XK_Arabic_sheen + if(test(XK_Arabic_sheen, "Arabic_sheen") == 1) + CHECK; + else + FAIL; +#else + reporterr("Arabic_sheen"); + FAIL; +#endif + +#ifdef XK_Arabic_sad + if(test(XK_Arabic_sad, "Arabic_sad") == 1) + CHECK; + else + FAIL; +#else + reporterr("Arabic_sad"); + FAIL; +#endif + +#ifdef XK_Arabic_dad + if(test(XK_Arabic_dad, "Arabic_dad") == 1) + CHECK; + else + FAIL; +#else + reporterr("Arabic_dad"); + FAIL; +#endif + +#ifdef XK_Arabic_tah + if(test(XK_Arabic_tah, "Arabic_tah") == 1) + CHECK; + else + FAIL; +#else + reporterr("Arabic_tah"); + FAIL; +#endif + +#ifdef XK_Arabic_zah + if(test(XK_Arabic_zah, "Arabic_zah") == 1) + CHECK; + else + FAIL; +#else + reporterr("Arabic_zah"); + FAIL; +#endif + +#ifdef XK_Arabic_ain + if(test(XK_Arabic_ain, "Arabic_ain") == 1) + CHECK; + else + FAIL; +#else + reporterr("Arabic_ain"); + FAIL; +#endif + +#ifdef XK_Arabic_ghain + if(test(XK_Arabic_ghain, "Arabic_ghain") == 1) + CHECK; + else + FAIL; +#else + reporterr("Arabic_ghain"); + FAIL; +#endif + +#ifdef XK_Arabic_tatweel + if(test(XK_Arabic_tatweel, "Arabic_tatweel") == 1) + CHECK; + else + FAIL; +#else + reporterr("Arabic_tatweel"); + FAIL; +#endif + +#ifdef XK_Arabic_feh + if(test(XK_Arabic_feh, "Arabic_feh") == 1) + CHECK; + else + FAIL; +#else + reporterr("Arabic_feh"); + FAIL; +#endif + +#ifdef XK_Arabic_qaf + if(test(XK_Arabic_qaf, "Arabic_qaf") == 1) + CHECK; + else + FAIL; +#else + reporterr("Arabic_qaf"); + FAIL; +#endif + +#ifdef XK_Arabic_kaf + if(test(XK_Arabic_kaf, "Arabic_kaf") == 1) + CHECK; + else + FAIL; +#else + reporterr("Arabic_kaf"); + FAIL; +#endif + +#ifdef XK_Arabic_lam + if(test(XK_Arabic_lam, "Arabic_lam") == 1) + CHECK; + else + FAIL; +#else + reporterr("Arabic_lam"); + FAIL; +#endif + +#ifdef XK_Arabic_meem + if(test(XK_Arabic_meem, "Arabic_meem") == 1) + CHECK; + else + FAIL; +#else + reporterr("Arabic_meem"); + FAIL; +#endif + +#ifdef XK_Arabic_noon + if(test(XK_Arabic_noon, "Arabic_noon") == 1) + CHECK; + else + FAIL; +#else + reporterr("Arabic_noon"); + FAIL; +#endif + +#ifdef XK_Arabic_ha + if(test(XK_Arabic_ha, "Arabic_ha") == 1) + CHECK; + else + FAIL; +#else + reporterr("Arabic_ha"); + FAIL; +#endif + +#ifdef XK_Arabic_heh + if(test(XK_Arabic_heh, "Arabic_heh") == 1) + CHECK; + else + FAIL; +#else + reporterr("Arabic_heh"); + FAIL; +#endif + +#ifdef XK_Arabic_waw + if(test(XK_Arabic_waw, "Arabic_waw") == 1) + CHECK; + else + FAIL; +#else + reporterr("Arabic_waw"); + FAIL; +#endif + +#ifdef XK_Arabic_alefmaksura + if(test(XK_Arabic_alefmaksura, "Arabic_alefmaksura") == 1) + CHECK; + else + FAIL; +#else + reporterr("Arabic_alefmaksura"); + FAIL; +#endif + +#ifdef XK_Arabic_yeh + if(test(XK_Arabic_yeh, "Arabic_yeh") == 1) + CHECK; + else + FAIL; +#else + reporterr("Arabic_yeh"); + FAIL; +#endif + +#ifdef XK_Arabic_fathatan + if(test(XK_Arabic_fathatan, "Arabic_fathatan") == 1) + CHECK; + else + FAIL; +#else + reporterr("Arabic_fathatan"); + FAIL; +#endif + +#ifdef XK_Arabic_dammatan + if(test(XK_Arabic_dammatan, "Arabic_dammatan") == 1) + CHECK; + else + FAIL; +#else + reporterr("Arabic_dammatan"); + FAIL; +#endif + +#ifdef XK_Arabic_kasratan + if(test(XK_Arabic_kasratan, "Arabic_kasratan") == 1) + CHECK; + else + FAIL; +#else + reporterr("Arabic_kasratan"); + FAIL; +#endif + +#ifdef XK_Arabic_fatha + if(test(XK_Arabic_fatha, "Arabic_fatha") == 1) + CHECK; + else + FAIL; +#else + reporterr("Arabic_fatha"); + FAIL; +#endif + +#ifdef XK_Arabic_damma + if(test(XK_Arabic_damma, "Arabic_damma") == 1) + CHECK; + else + FAIL; +#else + reporterr("Arabic_damma"); + FAIL; +#endif + +#ifdef XK_Arabic_kasra + if(test(XK_Arabic_kasra, "Arabic_kasra") == 1) + CHECK; + else + FAIL; +#else + reporterr("Arabic_kasra"); + FAIL; +#endif + +#ifdef XK_Arabic_shadda + if(test(XK_Arabic_shadda, "Arabic_shadda") == 1) + CHECK; + else + FAIL; +#else + reporterr("Arabic_shadda"); + FAIL; +#endif + +#ifdef XK_Arabic_sukun + if(test(XK_Arabic_sukun, "Arabic_sukun") == 1) + CHECK; + else + FAIL; +#else + reporterr("Arabic_sukun"); + FAIL; +#endif + +#ifdef XK_Arabic_switch + if(test(XK_Arabic_switch, "Arabic_switch") == 1) + CHECK; + else + FAIL; +#else + reporterr("Arabic_switch"); + FAIL; +#endif + + CHECKPASS(50); +} diff --git a/xts5/Xopen/XKeysymToKeycode/TestC.c b/xts5/Xopen/XKeysymToKeycode/TestC.c new file mode 100644 index 00000000..a3e6647d --- /dev/null +++ b/xts5/Xopen/XKeysymToKeycode/TestC.c @@ -0,0 +1,1219 @@ +/* +Copyright (c) 2005 X.Org Foundation L.L.C. + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies +of the Software, and to permit persons to whom the Software is furnished to do +so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. +*/ +/* +* $Header: /cvs/xtest/xtest/xts5/tset/Xopen/XKeysymToKeycode/TestC.c,v 1.2 2005-11-03 08:44:00 jmichael Exp $ +* +* Project: VSW5 +* +* File: xts5/tset/Xopen/XKeysymToKeycode/TestC.c +* +* Description: +* Tests for XKeysymToKeycode() +* +* Modifications: +* $Log: TestC.c,v $ +* Revision 1.2 2005-11-03 08:44:00 jmichael +* clean up all vsw5 paths to use xts5 instead. +* +* Revision 1.1.1.2 2005/04/15 14:05:40 anderson +* Reimport of the base with the legal name in the copyright fixed. +* +* Revision 8.0 1998/12/23 23:35:46 mar +* Branch point for Release 5.0.2 +* +* Revision 7.0 1998/10/30 22:58:25 mar +* Branch point for Release 5.0.2b1 +* +* Revision 6.0 1998/03/02 05:27:00 tbr +* Branch point for Release 5.0.1 +* +* Revision 5.0 1998/01/26 03:23:33 tbr +* Branch point for Release 5.0.1b1 +* +* Revision 4.1 1996/05/09 21:17:34 andy +* Fixed X includes +* +* Revision 4.0 1995/12/15 09:14:10 tbr +* Branch point for Release 5.0.0 +* +* Revision 3.1 1995/12/15 01:17:31 andy +* Prepare for GA Release +* +*/ +/* + * SCCS: @(#) TestC.c Rel 1.1 (11/28/91) + * + * UniSoft Ltd., London, England + * + * (C) Copyright 1991 X/Open Company Limited + * + * All rights reserved. No part of this source code may be reproduced, + * stored in a retrieval system, or transmitted, in any form or by any + * means, electronic, mechanical, photocopying, recording or otherwise, + * except as stated in the end-user licence agreement, without the prior + * permission of the copyright owners. + * + * X/Open and the 'X' symbol are trademarks of X/Open Company Limited in + * the UK and other countries. + */ + +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif + +#include <stdlib.h> +#include "xtest.h" +#include "X11/Xlib.h" +#include "X11/Xutil.h" +#include "X11/Xresource.h" +#include "tet_api.h" +#include "xtestlib.h" +#include "pixval.h" + +extern char *TestName; +extern Display *Dsp; + +int minkc; +int maxkc; +int keysyms_per_keycode; + +static int +test(symbol, str) +KeySym symbol; +char *str; +{ +KeyCode kycd; +int mod; + + kycd = XKeysymToKeycode(Dsp, symbol); + if(kycd == 0) { + trace("XKeysymToKeycode() returned 0 for KeySym \"XK_%s\".", str); + return(1); + } + + if(kycd > maxkc || kycd < minkc) { + report("XKeysymToKeycode() returned invalid keycode value %d for KeySym \"XK_%s\".", kycd, str); + return(0); + } + + for(mod = 0; mod < keysyms_per_keycode; mod++) { + if( symbol == XKeycodeToKeysym(Dsp, kycd, mod)) { + trace("KeySym \"XK_%s\", keycode %d, mod %d", + str, kycd, mod); + return(1); + } + } + + report("The keycode value %d for KeySym \"XK_%s\"", kycd, str); + report("never returns that KeySym when using XKeycodeToKeysym()"); + return(0); +} + +static void +reporterr(s) +char *s; +{ + report("Symbol XK_\"%s\" is not defined.", s); +} +#define XK_CYRILLIC +#include <X11/keysymdef.h> +#undef XK_CYRILLIC + +kysymtcdC() +{ +int pass = 0, fail = 0; + + XDisplayKeycodes(Dsp, &minkc, &maxkc); + XGetKeyboardMapping(Dsp, (KeyCode)minkc, 1, &keysyms_per_keycode); + +#ifdef XK_Serbian_dje + if(test(XK_Serbian_dje, "Serbian_dje") == 1) + CHECK; + else + FAIL; +#else + reporterr("Serbian_dje"); + FAIL; +#endif + +#ifdef XK_Macedonia_gje + if(test(XK_Macedonia_gje, "Macedonia_gje") == 1) + CHECK; + else + FAIL; +#else + reporterr("Macedonia_gje"); + FAIL; +#endif + +#ifdef XK_Cyrillic_io + if(test(XK_Cyrillic_io, "Cyrillic_io") == 1) + CHECK; + else + FAIL; +#else + reporterr("Cyrillic_io"); + FAIL; +#endif + +#ifdef XK_Ukrainian_ie + if(test(XK_Ukrainian_ie, "Ukrainian_ie") == 1) + CHECK; + else + FAIL; +#else + reporterr("Ukrainian_ie"); + FAIL; +#endif + +#ifdef XK_Ukranian_je + if(test(XK_Ukranian_je, "Ukranian_je") == 1) + CHECK; + else + FAIL; +#else + reporterr("Ukranian_je"); + FAIL; +#endif + +#ifdef XK_Macedonia_dse + if(test(XK_Macedonia_dse, "Macedonia_dse") == 1) + CHECK; + else + FAIL; +#else + reporterr("Macedonia_dse"); + FAIL; +#endif + +#ifdef XK_Ukrainian_i + if(test(XK_Ukrainian_i, "Ukrainian_i") == 1) + CHECK; + else + FAIL; +#else + reporterr("Ukrainian_i"); + FAIL; +#endif + +#ifdef XK_Ukranian_i + if(test(XK_Ukranian_i, "Ukranian_i") == 1) + CHECK; + else + FAIL; +#else + reporterr("Ukranian_i"); + FAIL; +#endif + +#ifdef XK_Ukrainian_yi + if(test(XK_Ukrainian_yi, "Ukrainian_yi") == 1) + CHECK; + else + FAIL; +#else + reporterr("Ukrainian_yi"); + FAIL; +#endif + +#ifdef XK_Ukranian_yi + if(test(XK_Ukranian_yi, "Ukranian_yi") == 1) + CHECK; + else + FAIL; +#else + reporterr("Ukranian_yi"); + FAIL; +#endif + +#ifdef XK_Cyrillic_je + if(test(XK_Cyrillic_je, "Cyrillic_je") == 1) + CHECK; + else + FAIL; +#else + reporterr("Cyrillic_je"); + FAIL; +#endif + +#ifdef XK_Serbian_je + if(test(XK_Serbian_je, "Serbian_je") == 1) + CHECK; + else + FAIL; +#else + reporterr("Serbian_je"); + FAIL; +#endif + +#ifdef XK_Cyrillic_lje + if(test(XK_Cyrillic_lje, "Cyrillic_lje") == 1) + CHECK; + else + FAIL; +#else + reporterr("Cyrillic_lje"); + FAIL; +#endif + +#ifdef XK_Serbian_lje + if(test(XK_Serbian_lje, "Serbian_lje") == 1) + CHECK; + else + FAIL; +#else + reporterr("Serbian_lje"); + FAIL; +#endif + +#ifdef XK_Cyrillic_nje + if(test(XK_Cyrillic_nje, "Cyrillic_nje") == 1) + CHECK; + else + FAIL; +#else + reporterr("Cyrillic_nje"); + FAIL; +#endif + +#ifdef XK_Serbian_nje + if(test(XK_Serbian_nje, "Serbian_nje") == 1) + CHECK; + else + FAIL; +#else + reporterr("Serbian_nje"); + FAIL; +#endif + +#ifdef XK_Serbian_tshe + if(test(XK_Serbian_tshe, "Serbian_tshe") == 1) + CHECK; + else + FAIL; +#else + reporterr("Serbian_tshe"); + FAIL; +#endif + +#ifdef XK_Macedonia_kje + if(test(XK_Macedonia_kje, "Macedonia_kje") == 1) + CHECK; + else + FAIL; +#else + reporterr("Macedonia_kje"); + FAIL; +#endif + +#ifdef XK_Byelorussian_shortu + if(test(XK_Byelorussian_shortu, "Byelorussian_shortu") == 1) + CHECK; + else + FAIL; +#else + reporterr("Byelorussian_shortu"); + FAIL; +#endif + +#ifdef XK_Cyrillic_dzhe + if(test(XK_Cyrillic_dzhe, "Cyrillic_dzhe") == 1) + CHECK; + else + FAIL; +#else + reporterr("Cyrillic_dzhe"); + FAIL; +#endif + +#ifdef XK_Serbian_dze + if(test(XK_Serbian_dze, "Serbian_dze") == 1) + CHECK; + else + FAIL; +#else + reporterr("Serbian_dze"); + FAIL; +#endif + +#ifdef XK_numerosign + if(test(XK_numerosign, "numerosign") == 1) + CHECK; + else + FAIL; +#else + reporterr("numerosign"); + FAIL; +#endif + +#ifdef XK_Serbian_DJE + if(test(XK_Serbian_DJE, "Serbian_DJE") == 1) + CHECK; + else + FAIL; +#else + reporterr("Serbian_DJE"); + FAIL; +#endif + +#ifdef XK_Macedonia_GJE + if(test(XK_Macedonia_GJE, "Macedonia_GJE") == 1) + CHECK; + else + FAIL; +#else + reporterr("Macedonia_GJE"); + FAIL; +#endif + +#ifdef XK_Cyrillic_IO + if(test(XK_Cyrillic_IO, "Cyrillic_IO") == 1) + CHECK; + else + FAIL; +#else + reporterr("Cyrillic_IO"); + FAIL; +#endif + +#ifdef XK_Ukrainian_IE + if(test(XK_Ukrainian_IE, "Ukrainian_IE") == 1) + CHECK; + else + FAIL; +#else + reporterr("Ukrainian_IE"); + FAIL; +#endif + +#ifdef XK_Ukranian_JE + if(test(XK_Ukranian_JE, "Ukranian_JE") == 1) + CHECK; + else + FAIL; +#else + reporterr("Ukranian_JE"); + FAIL; +#endif + +#ifdef XK_Macedonia_DSE + if(test(XK_Macedonia_DSE, "Macedonia_DSE") == 1) + CHECK; + else + FAIL; +#else + reporterr("Macedonia_DSE"); + FAIL; +#endif + +#ifdef XK_Ukrainian_I + if(test(XK_Ukrainian_I, "Ukrainian_I") == 1) + CHECK; + else + FAIL; +#else + reporterr("Ukrainian_I"); + FAIL; +#endif + +#ifdef XK_Ukranian_I + if(test(XK_Ukranian_I, "Ukranian_I") == 1) + CHECK; + else + FAIL; +#else + reporterr("Ukranian_I"); + FAIL; +#endif + +#ifdef XK_Ukrainian_YI + if(test(XK_Ukrainian_YI, "Ukrainian_YI") == 1) + CHECK; + else + FAIL; +#else + reporterr("Ukrainian_YI"); + FAIL; +#endif + +#ifdef XK_Ukranian_YI + if(test(XK_Ukranian_YI, "Ukranian_YI") == 1) + CHECK; + else + FAIL; +#else + reporterr("Ukranian_YI"); + FAIL; +#endif + +#ifdef XK_Cyrillic_JE + if(test(XK_Cyrillic_JE, "Cyrillic_JE") == 1) + CHECK; + else + FAIL; +#else + reporterr("Cyrillic_JE"); + FAIL; +#endif + +#ifdef XK_Serbian_JE + if(test(XK_Serbian_JE, "Serbian_JE") == 1) + CHECK; + else + FAIL; +#else + reporterr("Serbian_JE"); + FAIL; +#endif + +#ifdef XK_Cyrillic_LJE + if(test(XK_Cyrillic_LJE, "Cyrillic_LJE") == 1) + CHECK; + else + FAIL; +#else + reporterr("Cyrillic_LJE"); + FAIL; +#endif + +#ifdef XK_Serbian_LJE + if(test(XK_Serbian_LJE, "Serbian_LJE") == 1) + CHECK; + else + FAIL; +#else + reporterr("Serbian_LJE"); + FAIL; +#endif + +#ifdef XK_Cyrillic_NJE + if(test(XK_Cyrillic_NJE, "Cyrillic_NJE") == 1) + CHECK; + else + FAIL; +#else + reporterr("Cyrillic_NJE"); + FAIL; +#endif + +#ifdef XK_Serbian_NJE + if(test(XK_Serbian_NJE, "Serbian_NJE") == 1) + CHECK; + else + FAIL; +#else + reporterr("Serbian_NJE"); + FAIL; +#endif + +#ifdef XK_Serbian_TSHE + if(test(XK_Serbian_TSHE, "Serbian_TSHE") == 1) + CHECK; + else + FAIL; +#else + reporterr("Serbian_TSHE"); + FAIL; +#endif + +#ifdef XK_Macedonia_KJE + if(test(XK_Macedonia_KJE, "Macedonia_KJE") == 1) + CHECK; + else + FAIL; +#else + reporterr("Macedonia_KJE"); + FAIL; +#endif + +#ifdef XK_Byelorussian_SHORTU + if(test(XK_Byelorussian_SHORTU, "Byelorussian_SHORTU") == 1) + CHECK; + else + FAIL; +#else + reporterr("Byelorussian_SHORTU"); + FAIL; +#endif + +#ifdef XK_Cyrillic_DZHE + if(test(XK_Cyrillic_DZHE, "Cyrillic_DZHE") == 1) + CHECK; + else + FAIL; +#else + reporterr("Cyrillic_DZHE"); + FAIL; +#endif + +#ifdef XK_Serbian_DZE + if(test(XK_Serbian_DZE, "Serbian_DZE") == 1) + CHECK; + else + FAIL; +#else + reporterr("Serbian_DZE"); + FAIL; +#endif + +#ifdef XK_Cyrillic_yu + if(test(XK_Cyrillic_yu, "Cyrillic_yu") == 1) + CHECK; + else + FAIL; +#else + reporterr("Cyrillic_yu"); + FAIL; +#endif + +#ifdef XK_Cyrillic_a + if(test(XK_Cyrillic_a, "Cyrillic_a") == 1) + CHECK; + else + FAIL; +#else + reporterr("Cyrillic_a"); + FAIL; +#endif + +#ifdef XK_Cyrillic_be + if(test(XK_Cyrillic_be, "Cyrillic_be") == 1) + CHECK; + else + FAIL; +#else + reporterr("Cyrillic_be"); + FAIL; +#endif + +#ifdef XK_Cyrillic_tse + if(test(XK_Cyrillic_tse, "Cyrillic_tse") == 1) + CHECK; + else + FAIL; +#else + reporterr("Cyrillic_tse"); + FAIL; +#endif + +#ifdef XK_Cyrillic_de + if(test(XK_Cyrillic_de, "Cyrillic_de") == 1) + CHECK; + else + FAIL; +#else + reporterr("Cyrillic_de"); + FAIL; +#endif + +#ifdef XK_Cyrillic_ie + if(test(XK_Cyrillic_ie, "Cyrillic_ie") == 1) + CHECK; + else + FAIL; +#else + reporterr("Cyrillic_ie"); + FAIL; +#endif + +#ifdef XK_Cyrillic_ef + if(test(XK_Cyrillic_ef, "Cyrillic_ef") == 1) + CHECK; + else + FAIL; +#else + reporterr("Cyrillic_ef"); + FAIL; +#endif + +#ifdef XK_Cyrillic_ghe + if(test(XK_Cyrillic_ghe, "Cyrillic_ghe") == 1) + CHECK; + else + FAIL; +#else + reporterr("Cyrillic_ghe"); + FAIL; +#endif + +#ifdef XK_Cyrillic_ha + if(test(XK_Cyrillic_ha, "Cyrillic_ha") == 1) + CHECK; + else + FAIL; +#else + reporterr("Cyrillic_ha"); + FAIL; +#endif + +#ifdef XK_Cyrillic_i + if(test(XK_Cyrillic_i, "Cyrillic_i") == 1) + CHECK; + else + FAIL; +#else + reporterr("Cyrillic_i"); + FAIL; +#endif + +#ifdef XK_Cyrillic_shorti + if(test(XK_Cyrillic_shorti, "Cyrillic_shorti") == 1) + CHECK; + else + FAIL; +#else + reporterr("Cyrillic_shorti"); + FAIL; +#endif + +#ifdef XK_Cyrillic_ka + if(test(XK_Cyrillic_ka, "Cyrillic_ka") == 1) + CHECK; + else + FAIL; +#else + reporterr("Cyrillic_ka"); + FAIL; +#endif + +#ifdef XK_Cyrillic_el + if(test(XK_Cyrillic_el, "Cyrillic_el") == 1) + CHECK; + else + FAIL; +#else + reporterr("Cyrillic_el"); + FAIL; +#endif + +#ifdef XK_Cyrillic_em + if(test(XK_Cyrillic_em, "Cyrillic_em") == 1) + CHECK; + else + FAIL; +#else + reporterr("Cyrillic_em"); + FAIL; +#endif + +#ifdef XK_Cyrillic_en + if(test(XK_Cyrillic_en, "Cyrillic_en") == 1) + CHECK; + else + FAIL; +#else + reporterr("Cyrillic_en"); + FAIL; +#endif + +#ifdef XK_Cyrillic_o + if(test(XK_Cyrillic_o, "Cyrillic_o") == 1) + CHECK; + else + FAIL; +#else + reporterr("Cyrillic_o"); + FAIL; +#endif + +#ifdef XK_Cyrillic_pe + if(test(XK_Cyrillic_pe, "Cyrillic_pe") == 1) + CHECK; + else + FAIL; +#else + reporterr("Cyrillic_pe"); + FAIL; +#endif + +#ifdef XK_Cyrillic_ya + if(test(XK_Cyrillic_ya, "Cyrillic_ya") == 1) + CHECK; + else + FAIL; +#else + reporterr("Cyrillic_ya"); + FAIL; +#endif + +#ifdef XK_Cyrillic_er + if(test(XK_Cyrillic_er, "Cyrillic_er") == 1) + CHECK; + else + FAIL; +#else + reporterr("Cyrillic_er"); + FAIL; +#endif + +#ifdef XK_Cyrillic_es + if(test(XK_Cyrillic_es, "Cyrillic_es") == 1) + CHECK; + else + FAIL; +#else + reporterr("Cyrillic_es"); + FAIL; +#endif + +#ifdef XK_Cyrillic_te + if(test(XK_Cyrillic_te, "Cyrillic_te") == 1) + CHECK; + else + FAIL; +#else + reporterr("Cyrillic_te"); + FAIL; +#endif + +#ifdef XK_Cyrillic_u + if(test(XK_Cyrillic_u, "Cyrillic_u") == 1) + CHECK; + else + FAIL; +#else + reporterr("Cyrillic_u"); + FAIL; +#endif + +#ifdef XK_Cyrillic_zhe + if(test(XK_Cyrillic_zhe, "Cyrillic_zhe") == 1) + CHECK; + else + FAIL; +#else + reporterr("Cyrillic_zhe"); + FAIL; +#endif + +#ifdef XK_Cyrillic_ve + if(test(XK_Cyrillic_ve, "Cyrillic_ve") == 1) + CHECK; + else + FAIL; +#else + reporterr("Cyrillic_ve"); + FAIL; +#endif + +#ifdef XK_Cyrillic_softsign + if(test(XK_Cyrillic_softsign, "Cyrillic_softsign") == 1) + CHECK; + else + FAIL; +#else + reporterr("Cyrillic_softsign"); + FAIL; +#endif + +#ifdef XK_Cyrillic_yeru + if(test(XK_Cyrillic_yeru, "Cyrillic_yeru") == 1) + CHECK; + else + FAIL; +#else + reporterr("Cyrillic_yeru"); + FAIL; +#endif + +#ifdef XK_Cyrillic_ze + if(test(XK_Cyrillic_ze, "Cyrillic_ze") == 1) + CHECK; + else + FAIL; +#else + reporterr("Cyrillic_ze"); + FAIL; +#endif + +#ifdef XK_Cyrillic_sha + if(test(XK_Cyrillic_sha, "Cyrillic_sha") == 1) + CHECK; + else + FAIL; +#else + reporterr("Cyrillic_sha"); + FAIL; +#endif + +#ifdef XK_Cyrillic_e + if(test(XK_Cyrillic_e, "Cyrillic_e") == 1) + CHECK; + else + FAIL; +#else + reporterr("Cyrillic_e"); + FAIL; +#endif + +#ifdef XK_Cyrillic_shcha + if(test(XK_Cyrillic_shcha, "Cyrillic_shcha") == 1) + CHECK; + else + FAIL; +#else + reporterr("Cyrillic_shcha"); + FAIL; +#endif + +#ifdef XK_Cyrillic_che + if(test(XK_Cyrillic_che, "Cyrillic_che") == 1) + CHECK; + else + FAIL; +#else + reporterr("Cyrillic_che"); + FAIL; +#endif + +#ifdef XK_Cyrillic_hardsign + if(test(XK_Cyrillic_hardsign, "Cyrillic_hardsign") == 1) + CHECK; + else + FAIL; +#else + reporterr("Cyrillic_hardsign"); + FAIL; +#endif + +#ifdef XK_Cyrillic_YU + if(test(XK_Cyrillic_YU, "Cyrillic_YU") == 1) + CHECK; + else + FAIL; +#else + reporterr("Cyrillic_YU"); + FAIL; +#endif + +#ifdef XK_Cyrillic_A + if(test(XK_Cyrillic_A, "Cyrillic_A") == 1) + CHECK; + else + FAIL; +#else + reporterr("Cyrillic_A"); + FAIL; +#endif + +#ifdef XK_Cyrillic_BE + if(test(XK_Cyrillic_BE, "Cyrillic_BE") == 1) + CHECK; + else + FAIL; +#else + reporterr("Cyrillic_BE"); + FAIL; +#endif + +#ifdef XK_Cyrillic_TSE + if(test(XK_Cyrillic_TSE, "Cyrillic_TSE") == 1) + CHECK; + else + FAIL; +#else + reporterr("Cyrillic_TSE"); + FAIL; +#endif + +#ifdef XK_Cyrillic_DE + if(test(XK_Cyrillic_DE, "Cyrillic_DE") == 1) + CHECK; + else + FAIL; +#else + reporterr("Cyrillic_DE"); + FAIL; +#endif + +#ifdef XK_Cyrillic_IE + if(test(XK_Cyrillic_IE, "Cyrillic_IE") == 1) + CHECK; + else + FAIL; +#else + reporterr("Cyrillic_IE"); + FAIL; +#endif + +#ifdef XK_Cyrillic_EF + if(test(XK_Cyrillic_EF, "Cyrillic_EF") == 1) + CHECK; + else + FAIL; +#else + reporterr("Cyrillic_EF"); + FAIL; +#endif + +#ifdef XK_Cyrillic_GHE + if(test(XK_Cyrillic_GHE, "Cyrillic_GHE") == 1) + CHECK; + else + FAIL; +#else + reporterr("Cyrillic_GHE"); + FAIL; +#endif + +#ifdef XK_Cyrillic_HA + if(test(XK_Cyrillic_HA, "Cyrillic_HA") == 1) + CHECK; + else + FAIL; +#else + reporterr("Cyrillic_HA"); + FAIL; +#endif + +#ifdef XK_Cyrillic_I + if(test(XK_Cyrillic_I, "Cyrillic_I") == 1) + CHECK; + else + FAIL; +#else + reporterr("Cyrillic_I"); + FAIL; +#endif + +#ifdef XK_Cyrillic_SHORTI + if(test(XK_Cyrillic_SHORTI, "Cyrillic_SHORTI") == 1) + CHECK; + else + FAIL; +#else + reporterr("Cyrillic_SHORTI"); + FAIL; +#endif + +#ifdef XK_Cyrillic_KA + if(test(XK_Cyrillic_KA, "Cyrillic_KA") == 1) + CHECK; + else + FAIL; +#else + reporterr("Cyrillic_KA"); + FAIL; +#endif + +#ifdef XK_Cyrillic_EL + if(test(XK_Cyrillic_EL, "Cyrillic_EL") == 1) + CHECK; + else + FAIL; +#else + reporterr("Cyrillic_EL"); + FAIL; +#endif + +#ifdef XK_Cyrillic_EM + if(test(XK_Cyrillic_EM, "Cyrillic_EM") == 1) + CHECK; + else + FAIL; +#else + reporterr("Cyrillic_EM"); + FAIL; +#endif + +#ifdef XK_Cyrillic_EN + if(test(XK_Cyrillic_EN, "Cyrillic_EN") == 1) + CHECK; + else + FAIL; +#else + reporterr("Cyrillic_EN"); + FAIL; +#endif + +#ifdef XK_Cyrillic_O + if(test(XK_Cyrillic_O, "Cyrillic_O") == 1) + CHECK; + else + FAIL; +#else + reporterr("Cyrillic_O"); + FAIL; +#endif + +#ifdef XK_Cyrillic_PE + if(test(XK_Cyrillic_PE, "Cyrillic_PE") == 1) + CHECK; + else + FAIL; +#else + reporterr("Cyrillic_PE"); + FAIL; +#endif + +#ifdef XK_Cyrillic_YA + if(test(XK_Cyrillic_YA, "Cyrillic_YA") == 1) + CHECK; + else + FAIL; +#else + reporterr("Cyrillic_YA"); + FAIL; +#endif + +#ifdef XK_Cyrillic_ER + if(test(XK_Cyrillic_ER, "Cyrillic_ER") == 1) + CHECK; + else + FAIL; +#else + reporterr("Cyrillic_ER"); + FAIL; +#endif + +#ifdef XK_Cyrillic_ES + if(test(XK_Cyrillic_ES, "Cyrillic_ES") == 1) + CHECK; + else + FAIL; +#else + reporterr("Cyrillic_ES"); + FAIL; +#endif + +#ifdef XK_Cyrillic_TE + if(test(XK_Cyrillic_TE, "Cyrillic_TE") == 1) + CHECK; + else + FAIL; +#else + reporterr("Cyrillic_TE"); + FAIL; +#endif + +#ifdef XK_Cyrillic_U + if(test(XK_Cyrillic_U, "Cyrillic_U") == 1) + CHECK; + else + FAIL; +#else + reporterr("Cyrillic_U"); + FAIL; +#endif + +#ifdef XK_Cyrillic_ZHE + if(test(XK_Cyrillic_ZHE, "Cyrillic_ZHE") == 1) + CHECK; + else + FAIL; +#else + reporterr("Cyrillic_ZHE"); + FAIL; +#endif + +#ifdef XK_Cyrillic_VE + if(test(XK_Cyrillic_VE, "Cyrillic_VE") == 1) + CHECK; + else + FAIL; +#else + reporterr("Cyrillic_VE"); + FAIL; +#endif + +#ifdef XK_Cyrillic_SOFTSIGN + if(test(XK_Cyrillic_SOFTSIGN, "Cyrillic_SOFTSIGN") == 1) + CHECK; + else + FAIL; +#else + reporterr("Cyrillic_SOFTSIGN"); + FAIL; +#endif + +#ifdef XK_Cyrillic_YERU + if(test(XK_Cyrillic_YERU, "Cyrillic_YERU") == 1) + CHECK; + else + FAIL; +#else + reporterr("Cyrillic_YERU"); + FAIL; +#endif + +#ifdef XK_Cyrillic_ZE + if(test(XK_Cyrillic_ZE, "Cyrillic_ZE") == 1) + CHECK; + else + FAIL; +#else + reporterr("Cyrillic_ZE"); + FAIL; +#endif + +#ifdef XK_Cyrillic_SHA + if(test(XK_Cyrillic_SHA, "Cyrillic_SHA") == 1) + CHECK; + else + FAIL; +#else + reporterr("Cyrillic_SHA"); + FAIL; +#endif + +#ifdef XK_Cyrillic_E + if(test(XK_Cyrillic_E, "Cyrillic_E") == 1) + CHECK; + else + FAIL; +#else + reporterr("Cyrillic_E"); + FAIL; +#endif + +#ifdef XK_Cyrillic_SHCHA + if(test(XK_Cyrillic_SHCHA, "Cyrillic_SHCHA") == 1) + CHECK; + else + FAIL; +#else + reporterr("Cyrillic_SHCHA"); + FAIL; +#endif + +#ifdef XK_Cyrillic_CHE + if(test(XK_Cyrillic_CHE, "Cyrillic_CHE") == 1) + CHECK; + else + FAIL; +#else + reporterr("Cyrillic_CHE"); + FAIL; +#endif + +#ifdef XK_Cyrillic_HARDSIGN + if(test(XK_Cyrillic_HARDSIGN, "Cyrillic_HARDSIGN") == 1) + CHECK; + else + FAIL; +#else + reporterr("Cyrillic_HARDSIGN"); + FAIL; +#endif + + CHECKPASS(107); +} diff --git a/xts5/Xopen/XKeysymToKeycode/TestG.c b/xts5/Xopen/XKeysymToKeycode/TestG.c new file mode 100644 index 00000000..3551a96e --- /dev/null +++ b/xts5/Xopen/XKeysymToKeycode/TestG.c @@ -0,0 +1,889 @@ +/* +Copyright (c) 2005 X.Org Foundation L.L.C. + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies +of the Software, and to permit persons to whom the Software is furnished to do +so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. +*/ +/* +* $Header: /cvs/xtest/xtest/xts5/tset/Xopen/XKeysymToKeycode/TestG.c,v 1.2 2005-11-03 08:44:00 jmichael Exp $ +* +* Project: VSW5 +* +* File: xts5/tset/Xopen/XKeysymToKeycode/TestG.c +* +* Description: +* Tests for XKeysymToKeycode() +* +* Modifications: +* $Log: TestG.c,v $ +* Revision 1.2 2005-11-03 08:44:00 jmichael +* clean up all vsw5 paths to use xts5 instead. +* +* Revision 1.1.1.2 2005/04/15 14:05:40 anderson +* Reimport of the base with the legal name in the copyright fixed. +* +* Revision 8.0 1998/12/23 23:35:46 mar +* Branch point for Release 5.0.2 +* +* Revision 7.0 1998/10/30 22:58:26 mar +* Branch point for Release 5.0.2b1 +* +* Revision 6.0 1998/03/02 05:27:00 tbr +* Branch point for Release 5.0.1 +* +* Revision 5.0 1998/01/26 03:23:33 tbr +* Branch point for Release 5.0.1b1 +* +* Revision 4.1 1996/05/09 21:17:34 andy +* Fixed X includes +* +* Revision 4.0 1995/12/15 09:14:12 tbr +* Branch point for Release 5.0.0 +* +* Revision 3.1 1995/12/15 01:17:33 andy +* Prepare for GA Release +* +*/ +/* + * SCCS: @(#) TestG.c Rel 1.1 (11/28/91) + * + * UniSoft Ltd., London, England + * + * (C) Copyright 1991 X/Open Company Limited + * + * All rights reserved. No part of this source code may be reproduced, + * stored in a retrieval system, or transmitted, in any form or by any + * means, electronic, mechanical, photocopying, recording or otherwise, + * except as stated in the end-user licence agreement, without the prior + * permission of the copyright owners. + * + * X/Open and the 'X' symbol are trademarks of X/Open Company Limited in + * the UK and other countries. + */ + +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif + +#include <stdlib.h> +#include "xtest.h" +#include "X11/Xlib.h" +#include "X11/Xutil.h" +#include "X11/Xresource.h" +#include "tet_api.h" +#include "xtestlib.h" +#include "pixval.h" + +extern char *TestName; +extern Display *Dsp; + +int minkc; +int maxkc; +int keysyms_per_keycode; + +static int +test(symbol, str) +KeySym symbol; +char *str; +{ +KeyCode kycd; +int mod; + + kycd = XKeysymToKeycode(Dsp, symbol); + if(kycd == 0) { + trace("XKeysymToKeycode() returned 0 for KeySym \"XK_%s\".", str); + return(1); + } + + if(kycd > maxkc || kycd < minkc) { + report("XKeysymToKeycode() returned invalid keycode value %d for KeySym \"XK_%s\".", kycd, str); + return(0); + } + + for(mod = 0; mod < keysyms_per_keycode; mod++) { + if( symbol == XKeycodeToKeysym(Dsp, kycd, mod)) { + trace("KeySym \"XK_%s\", keycode %d, mod %d", + str, kycd, mod); + return(1); + } + } + + report("The keycode value %d for KeySym \"XK_%s\"", kycd, str); + report("never returns that KeySym when using XKeycodeToKeysym()"); + return(0); +} + +static void +reporterr(s) +char *s; +{ + report("Symbol XK_\"%s\" is not defined.", s); +} +#define XK_GREEK +#include <X11/keysymdef.h> +#undef XK_GREEK + +kysymtcdG() +{ +int pass = 0, fail = 0; + + XDisplayKeycodes(Dsp, &minkc, &maxkc); + XGetKeyboardMapping(Dsp, (KeyCode)minkc, 1, &keysyms_per_keycode); + +#ifdef XK_Greek_ALPHAaccent + if(test(XK_Greek_ALPHAaccent, "Greek_ALPHAaccent") == 1) + CHECK; + else + FAIL; +#else + reporterr("Greek_ALPHAaccent"); + FAIL; +#endif + +#ifdef XK_Greek_EPSILONaccent + if(test(XK_Greek_EPSILONaccent, "Greek_EPSILONaccent") == 1) + CHECK; + else + FAIL; +#else + reporterr("Greek_EPSILONaccent"); + FAIL; +#endif + +#ifdef XK_Greek_ETAaccent + if(test(XK_Greek_ETAaccent, "Greek_ETAaccent") == 1) + CHECK; + else + FAIL; +#else + reporterr("Greek_ETAaccent"); + FAIL; +#endif + +#ifdef XK_Greek_IOTAaccent + if(test(XK_Greek_IOTAaccent, "Greek_IOTAaccent") == 1) + CHECK; + else + FAIL; +#else + reporterr("Greek_IOTAaccent"); + FAIL; +#endif + +#ifdef XK_Greek_IOTAdiaeresis + if(test(XK_Greek_IOTAdiaeresis, "Greek_IOTAdiaeresis") == 1) + CHECK; + else + FAIL; +#else + reporterr("Greek_IOTAdiaeresis"); + FAIL; +#endif + +#ifdef XK_Greek_OMICRONaccent + if(test(XK_Greek_OMICRONaccent, "Greek_OMICRONaccent") == 1) + CHECK; + else + FAIL; +#else + reporterr("Greek_OMICRONaccent"); + FAIL; +#endif + +#ifdef XK_Greek_UPSILONaccent + if(test(XK_Greek_UPSILONaccent, "Greek_UPSILONaccent") == 1) + CHECK; + else + FAIL; +#else + reporterr("Greek_UPSILONaccent"); + FAIL; +#endif + +#ifdef XK_Greek_UPSILONdieresis + if(test(XK_Greek_UPSILONdieresis, "Greek_UPSILONdieresis") == 1) + CHECK; + else + FAIL; +#else + reporterr("Greek_UPSILONdieresis"); + FAIL; +#endif + +#ifdef XK_Greek_OMEGAaccent + if(test(XK_Greek_OMEGAaccent, "Greek_OMEGAaccent") == 1) + CHECK; + else + FAIL; +#else + reporterr("Greek_OMEGAaccent"); + FAIL; +#endif + +#ifdef XK_Greek_accentdieresis + if(test(XK_Greek_accentdieresis, "Greek_accentdieresis") == 1) + CHECK; + else + FAIL; +#else + reporterr("Greek_accentdieresis"); + FAIL; +#endif + +#ifdef XK_Greek_horizbar + if(test(XK_Greek_horizbar, "Greek_horizbar") == 1) + CHECK; + else + FAIL; +#else + reporterr("Greek_horizbar"); + FAIL; +#endif + +#ifdef XK_Greek_alphaaccent + if(test(XK_Greek_alphaaccent, "Greek_alphaaccent") == 1) + CHECK; + else + FAIL; +#else + reporterr("Greek_alphaaccent"); + FAIL; +#endif + +#ifdef XK_Greek_epsilonaccent + if(test(XK_Greek_epsilonaccent, "Greek_epsilonaccent") == 1) + CHECK; + else + FAIL; +#else + reporterr("Greek_epsilonaccent"); + FAIL; +#endif + +#ifdef XK_Greek_etaaccent + if(test(XK_Greek_etaaccent, "Greek_etaaccent") == 1) + CHECK; + else + FAIL; +#else + reporterr("Greek_etaaccent"); + FAIL; +#endif + +#ifdef XK_Greek_iotaaccent + if(test(XK_Greek_iotaaccent, "Greek_iotaaccent") == 1) + CHECK; + else + FAIL; +#else + reporterr("Greek_iotaaccent"); + FAIL; +#endif + +#ifdef XK_Greek_iotadieresis + if(test(XK_Greek_iotadieresis, "Greek_iotadieresis") == 1) + CHECK; + else + FAIL; +#else + reporterr("Greek_iotadieresis"); + FAIL; +#endif + +#ifdef XK_Greek_iotaaccentdieresis + if(test(XK_Greek_iotaaccentdieresis, "Greek_iotaaccentdieresis") == 1) + CHECK; + else + FAIL; +#else + reporterr("Greek_iotaaccentdieresis"); + FAIL; +#endif + +#ifdef XK_Greek_omicronaccent + if(test(XK_Greek_omicronaccent, "Greek_omicronaccent") == 1) + CHECK; + else + FAIL; +#else + reporterr("Greek_omicronaccent"); + FAIL; +#endif + +#ifdef XK_Greek_upsilonaccent + if(test(XK_Greek_upsilonaccent, "Greek_upsilonaccent") == 1) + CHECK; + else + FAIL; +#else + reporterr("Greek_upsilonaccent"); + FAIL; +#endif + +#ifdef XK_Greek_upsilondieresis + if(test(XK_Greek_upsilondieresis, "Greek_upsilondieresis") == 1) + CHECK; + else + FAIL; +#else + reporterr("Greek_upsilondieresis"); + FAIL; +#endif + +#ifdef XK_Greek_upsilonaccentdieresis + if(test(XK_Greek_upsilonaccentdieresis, "Greek_upsilonaccentdieresis") == 1) + CHECK; + else + FAIL; +#else + reporterr("Greek_upsilonaccentdieresis"); + FAIL; +#endif + +#ifdef XK_Greek_omegaaccent + if(test(XK_Greek_omegaaccent, "Greek_omegaaccent") == 1) + CHECK; + else + FAIL; +#else + reporterr("Greek_omegaaccent"); + FAIL; +#endif + +#ifdef XK_Greek_ALPHA + if(test(XK_Greek_ALPHA, "Greek_ALPHA") == 1) + CHECK; + else + FAIL; +#else + reporterr("Greek_ALPHA"); + FAIL; +#endif + +#ifdef XK_Greek_BETA + if(test(XK_Greek_BETA, "Greek_BETA") == 1) + CHECK; + else + FAIL; +#else + reporterr("Greek_BETA"); + FAIL; +#endif + +#ifdef XK_Greek_GAMMA + if(test(XK_Greek_GAMMA, "Greek_GAMMA") == 1) + CHECK; + else + FAIL; +#else + reporterr("Greek_GAMMA"); + FAIL; +#endif + +#ifdef XK_Greek_DELTA + if(test(XK_Greek_DELTA, "Greek_DELTA") == 1) + CHECK; + else + FAIL; +#else + reporterr("Greek_DELTA"); + FAIL; +#endif + +#ifdef XK_Greek_EPSILON + if(test(XK_Greek_EPSILON, "Greek_EPSILON") == 1) + CHECK; + else + FAIL; +#else + reporterr("Greek_EPSILON"); + FAIL; +#endif + +#ifdef XK_Greek_ZETA + if(test(XK_Greek_ZETA, "Greek_ZETA") == 1) + CHECK; + else + FAIL; +#else + reporterr("Greek_ZETA"); + FAIL; +#endif + +#ifdef XK_Greek_ETA + if(test(XK_Greek_ETA, "Greek_ETA") == 1) + CHECK; + else + FAIL; +#else + reporterr("Greek_ETA"); + FAIL; +#endif + +#ifdef XK_Greek_THETA + if(test(XK_Greek_THETA, "Greek_THETA") == 1) + CHECK; + else + FAIL; +#else + reporterr("Greek_THETA"); + FAIL; +#endif + +#ifdef XK_Greek_IOTA + if(test(XK_Greek_IOTA, "Greek_IOTA") == 1) + CHECK; + else + FAIL; +#else + reporterr("Greek_IOTA"); + FAIL; +#endif + +#ifdef XK_Greek_KAPPA + if(test(XK_Greek_KAPPA, "Greek_KAPPA") == 1) + CHECK; + else + FAIL; +#else + reporterr("Greek_KAPPA"); + FAIL; +#endif + +#ifdef XK_Greek_LAMBDA + if(test(XK_Greek_LAMBDA, "Greek_LAMBDA") == 1) + CHECK; + else + FAIL; +#else + reporterr("Greek_LAMBDA"); + FAIL; +#endif + +#ifdef XK_Greek_LAMDA + if(test(XK_Greek_LAMDA, "Greek_LAMDA") == 1) + CHECK; + else + FAIL; +#else + reporterr("Greek_LAMDA"); + FAIL; +#endif + +#ifdef XK_Greek_MU + if(test(XK_Greek_MU, "Greek_MU") == 1) + CHECK; + else + FAIL; +#else + reporterr("Greek_MU"); + FAIL; +#endif + +#ifdef XK_Greek_NU + if(test(XK_Greek_NU, "Greek_NU") == 1) + CHECK; + else + FAIL; +#else + reporterr("Greek_NU"); + FAIL; +#endif + +#ifdef XK_Greek_XI + if(test(XK_Greek_XI, "Greek_XI") == 1) + CHECK; + else + FAIL; +#else + reporterr("Greek_XI"); + FAIL; +#endif + +#ifdef XK_Greek_OMICRON + if(test(XK_Greek_OMICRON, "Greek_OMICRON") == 1) + CHECK; + else + FAIL; +#else + reporterr("Greek_OMICRON"); + FAIL; +#endif + +#ifdef XK_Greek_PI + if(test(XK_Greek_PI, "Greek_PI") == 1) + CHECK; + else + FAIL; +#else + reporterr("Greek_PI"); + FAIL; +#endif + +#ifdef XK_Greek_RHO + if(test(XK_Greek_RHO, "Greek_RHO") == 1) + CHECK; + else + FAIL; +#else + reporterr("Greek_RHO"); + FAIL; +#endif + +#ifdef XK_Greek_SIGMA + if(test(XK_Greek_SIGMA, "Greek_SIGMA") == 1) + CHECK; + else + FAIL; +#else + reporterr("Greek_SIGMA"); + FAIL; +#endif + +#ifdef XK_Greek_TAU + if(test(XK_Greek_TAU, "Greek_TAU") == 1) + CHECK; + else + FAIL; +#else + reporterr("Greek_TAU"); + FAIL; +#endif + +#ifdef XK_Greek_UPSILON + if(test(XK_Greek_UPSILON, "Greek_UPSILON") == 1) + CHECK; + else + FAIL; +#else + reporterr("Greek_UPSILON"); + FAIL; +#endif + +#ifdef XK_Greek_PHI + if(test(XK_Greek_PHI, "Greek_PHI") == 1) + CHECK; + else + FAIL; +#else + reporterr("Greek_PHI"); + FAIL; +#endif + +#ifdef XK_Greek_CHI + if(test(XK_Greek_CHI, "Greek_CHI") == 1) + CHECK; + else + FAIL; +#else + reporterr("Greek_CHI"); + FAIL; +#endif + +#ifdef XK_Greek_PSI + if(test(XK_Greek_PSI, "Greek_PSI") == 1) + CHECK; + else + FAIL; +#else + reporterr("Greek_PSI"); + FAIL; +#endif + +#ifdef XK_Greek_OMEGA + if(test(XK_Greek_OMEGA, "Greek_OMEGA") == 1) + CHECK; + else + FAIL; +#else + reporterr("Greek_OMEGA"); + FAIL; +#endif + +#ifdef XK_Greek_alpha + if(test(XK_Greek_alpha, "Greek_alpha") == 1) + CHECK; + else + FAIL; +#else + reporterr("Greek_alpha"); + FAIL; +#endif + +#ifdef XK_Greek_beta + if(test(XK_Greek_beta, "Greek_beta") == 1) + CHECK; + else + FAIL; +#else + reporterr("Greek_beta"); + FAIL; +#endif + +#ifdef XK_Greek_gamma + if(test(XK_Greek_gamma, "Greek_gamma") == 1) + CHECK; + else + FAIL; +#else + reporterr("Greek_gamma"); + FAIL; +#endif + +#ifdef XK_Greek_delta + if(test(XK_Greek_delta, "Greek_delta") == 1) + CHECK; + else + FAIL; +#else + reporterr("Greek_delta"); + FAIL; +#endif + +#ifdef XK_Greek_epsilon + if(test(XK_Greek_epsilon, "Greek_epsilon") == 1) + CHECK; + else + FAIL; +#else + reporterr("Greek_epsilon"); + FAIL; +#endif + +#ifdef XK_Greek_zeta + if(test(XK_Greek_zeta, "Greek_zeta") == 1) + CHECK; + else + FAIL; +#else + reporterr("Greek_zeta"); + FAIL; +#endif + +#ifdef XK_Greek_eta + if(test(XK_Greek_eta, "Greek_eta") == 1) + CHECK; + else + FAIL; +#else + reporterr("Greek_eta"); + FAIL; +#endif + +#ifdef XK_Greek_theta + if(test(XK_Greek_theta, "Greek_theta") == 1) + CHECK; + else + FAIL; +#else + reporterr("Greek_theta"); + FAIL; +#endif + +#ifdef XK_Greek_iota + if(test(XK_Greek_iota, "Greek_iota") == 1) + CHECK; + else + FAIL; +#else + reporterr("Greek_iota"); + FAIL; +#endif + +#ifdef XK_Greek_kappa + if(test(XK_Greek_kappa, "Greek_kappa") == 1) + CHECK; + else + FAIL; +#else + reporterr("Greek_kappa"); + FAIL; +#endif + +#ifdef XK_Greek_lambda + if(test(XK_Greek_lambda, "Greek_lambda") == 1) + CHECK; + else + FAIL; +#else + reporterr("Greek_lambda"); + FAIL; +#endif + +#ifdef XK_Greek_lamda + if(test(XK_Greek_lamda, "Greek_lamda") == 1) + CHECK; + else + FAIL; +#else + reporterr("Greek_lamda"); + FAIL; +#endif + +#ifdef XK_Greek_mu + if(test(XK_Greek_mu, "Greek_mu") == 1) + CHECK; + else + FAIL; +#else + reporterr("Greek_mu"); + FAIL; +#endif + +#ifdef XK_Greek_nu + if(test(XK_Greek_nu, "Greek_nu") == 1) + CHECK; + else + FAIL; +#else + reporterr("Greek_nu"); + FAIL; +#endif + +#ifdef XK_Greek_xi + if(test(XK_Greek_xi, "Greek_xi") == 1) + CHECK; + else + FAIL; +#else + reporterr("Greek_xi"); + FAIL; +#endif + +#ifdef XK_Greek_omicron + if(test(XK_Greek_omicron, "Greek_omicron") == 1) + CHECK; + else + FAIL; +#else + reporterr("Greek_omicron"); + FAIL; +#endif + +#ifdef XK_Greek_pi + if(test(XK_Greek_pi, "Greek_pi") == 1) + CHECK; + else + FAIL; +#else + reporterr("Greek_pi"); + FAIL; +#endif + +#ifdef XK_Greek_rho + if(test(XK_Greek_rho, "Greek_rho") == 1) + CHECK; + else + FAIL; +#else + reporterr("Greek_rho"); + FAIL; +#endif + +#ifdef XK_Greek_sigma + if(test(XK_Greek_sigma, "Greek_sigma") == 1) + CHECK; + else + FAIL; +#else + reporterr("Greek_sigma"); + FAIL; +#endif + +#ifdef XK_Greek_finalsmallsigma + if(test(XK_Greek_finalsmallsigma, "Greek_finalsmallsigma") == 1) + CHECK; + else + FAIL; +#else + reporterr("Greek_finalsmallsigma"); + FAIL; +#endif + +#ifdef XK_Greek_tau + if(test(XK_Greek_tau, "Greek_tau") == 1) + CHECK; + else + FAIL; +#else + reporterr("Greek_tau"); + FAIL; +#endif + +#ifdef XK_Greek_upsilon + if(test(XK_Greek_upsilon, "Greek_upsilon") == 1) + CHECK; + else + FAIL; +#else + reporterr("Greek_upsilon"); + FAIL; +#endif + +#ifdef XK_Greek_phi + if(test(XK_Greek_phi, "Greek_phi") == 1) + CHECK; + else + FAIL; +#else + reporterr("Greek_phi"); + FAIL; +#endif + +#ifdef XK_Greek_chi + if(test(XK_Greek_chi, "Greek_chi") == 1) + CHECK; + else + FAIL; +#else + reporterr("Greek_chi"); + FAIL; +#endif + +#ifdef XK_Greek_psi + if(test(XK_Greek_psi, "Greek_psi") == 1) + CHECK; + else + FAIL; +#else + reporterr("Greek_psi"); + FAIL; +#endif + +#ifdef XK_Greek_omega + if(test(XK_Greek_omega, "Greek_omega") == 1) + CHECK; + else + FAIL; +#else + reporterr("Greek_omega"); + FAIL; +#endif + +#ifdef XK_Greek_switch + if(test(XK_Greek_switch, "Greek_switch") == 1) + CHECK; + else + FAIL; +#else + reporterr("Greek_switch"); + FAIL; +#endif + + CHECKPASS(74); +} diff --git a/xts5/Xopen/XKeysymToKeycode/TestH.c b/xts5/Xopen/XKeysymToKeycode/TestH.c new file mode 100644 index 00000000..ea42345a --- /dev/null +++ b/xts5/Xopen/XKeysymToKeycode/TestH.c @@ -0,0 +1,549 @@ +/* +Copyright (c) 2005 X.Org Foundation L.L.C. + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies +of the Software, and to permit persons to whom the Software is furnished to do +so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. +*/ +/* +* $Header: /cvs/xtest/xtest/xts5/tset/Xopen/XKeysymToKeycode/TestH.c,v 1.2 2005-11-03 08:44:00 jmichael Exp $ +* +* Project: VSW5 +* +* File: xts5/tset/Xopen/XKeysymToKeycode/TestH.c +* +* Description: +* Tests for XKeysymToKeycode() +* +* Modifications: +* $Log: TestH.c,v $ +* Revision 1.2 2005-11-03 08:44:00 jmichael +* clean up all vsw5 paths to use xts5 instead. +* +* Revision 1.1.1.2 2005/04/15 14:05:40 anderson +* Reimport of the base with the legal name in the copyright fixed. +* +* Revision 8.0 1998/12/23 23:35:47 mar +* Branch point for Release 5.0.2 +* +* Revision 7.0 1998/10/30 22:58:27 mar +* Branch point for Release 5.0.2b1 +* +* Revision 6.0 1998/03/02 05:27:00 tbr +* Branch point for Release 5.0.1 +* +* Revision 5.0 1998/01/26 03:23:34 tbr +* Branch point for Release 5.0.1b1 +* +* Revision 4.1 1996/05/09 21:17:34 andy +* Fixed X includes +* +* Revision 4.0 1995/12/15 09:14:13 tbr +* Branch point for Release 5.0.0 +* +* Revision 3.1 1995/12/15 01:17:35 andy +* Prepare for GA Release +* +*/ +/* + * SCCS: @(#) TestH.c Rel 1.1 (11/28/91) + * + * UniSoft Ltd., London, England + * + * (C) Copyright 1991 X/Open Company Limited + * + * All rights reserved. No part of this source code may be reproduced, + * stored in a retrieval system, or transmitted, in any form or by any + * means, electronic, mechanical, photocopying, recording or otherwise, + * except as stated in the end-user licence agreement, without the prior + * permission of the copyright owners. + * + * X/Open and the 'X' symbol are trademarks of X/Open Company Limited in + * the UK and other countries. + */ + +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif + +#include <stdlib.h> +#include "xtest.h" +#include "X11/Xlib.h" +#include "X11/Xutil.h" +#include "X11/Xresource.h" +#include "tet_api.h" +#include "xtestlib.h" +#include "pixval.h" + +extern char *TestName; +extern Display *Dsp; + +int minkc; +int maxkc; +int keysyms_per_keycode; + +static int +test(symbol, str) +KeySym symbol; +char *str; +{ +KeyCode kycd; +int mod; + + kycd = XKeysymToKeycode(Dsp, symbol); + if(kycd == 0) { + trace("XKeysymToKeycode() returned 0 for KeySym \"XK_%s\".", str); + return(1); + } + + if(kycd > maxkc || kycd < minkc) { + report("XKeysymToKeycode() returned invalid keycode value %d for KeySym \"XK_%s\".", kycd, str); + return(0); + } + + for(mod = 0; mod < keysyms_per_keycode; mod++) { + if( symbol == XKeycodeToKeysym(Dsp, kycd, mod)) { + trace("KeySym \"XK_%s\", keycode %d, mod %d", + str, kycd, mod); + return(1); + } + } + + report("The keycode value %d for KeySym \"XK_%s\"", kycd, str); + report("never returns that KeySym when using XKeycodeToKeysym()"); + return(0); +} + +static void +reporterr(s) +char *s; +{ + report("Symbol XK_\"%s\" is not defined.", s); +} +#define XK_HEBREW +#include <X11/keysymdef.h> +#undef XK_HEBREW + +kysymtcdH() +{ +int pass = 0, fail = 0; + + XDisplayKeycodes(Dsp, &minkc, &maxkc); + XGetKeyboardMapping(Dsp, (KeyCode)minkc, 1, &keysyms_per_keycode); + +#ifdef XK_hebrew_doublelowline + if(test(XK_hebrew_doublelowline, "hebrew_doublelowline") == 1) + CHECK; + else + FAIL; +#else + reporterr("hebrew_doublelowline"); + FAIL; +#endif + +#ifdef XK_hebrew_aleph + if(test(XK_hebrew_aleph, "hebrew_aleph") == 1) + CHECK; + else + FAIL; +#else + reporterr("hebrew_aleph"); + FAIL; +#endif + +#ifdef XK_hebrew_bet + if(test(XK_hebrew_bet, "hebrew_bet") == 1) + CHECK; + else + FAIL; +#else + reporterr("hebrew_bet"); + FAIL; +#endif + +#ifdef XK_hebrew_beth + if(test(XK_hebrew_beth, "hebrew_beth") == 1) + CHECK; + else + FAIL; +#else + reporterr("hebrew_beth"); + FAIL; +#endif + +#ifdef XK_hebrew_gimel + if(test(XK_hebrew_gimel, "hebrew_gimel") == 1) + CHECK; + else + FAIL; +#else + reporterr("hebrew_gimel"); + FAIL; +#endif + +#ifdef XK_hebrew_gimmel + if(test(XK_hebrew_gimmel, "hebrew_gimmel") == 1) + CHECK; + else + FAIL; +#else + reporterr("hebrew_gimmel"); + FAIL; +#endif + +#ifdef XK_hebrew_dalet + if(test(XK_hebrew_dalet, "hebrew_dalet") == 1) + CHECK; + else + FAIL; +#else + reporterr("hebrew_dalet"); + FAIL; +#endif + +#ifdef XK_hebrew_daleth + if(test(XK_hebrew_daleth, "hebrew_daleth") == 1) + CHECK; + else + FAIL; +#else + reporterr("hebrew_daleth"); + FAIL; +#endif + +#ifdef XK_hebrew_he + if(test(XK_hebrew_he, "hebrew_he") == 1) + CHECK; + else + FAIL; +#else + reporterr("hebrew_he"); + FAIL; +#endif + +#ifdef XK_hebrew_waw + if(test(XK_hebrew_waw, "hebrew_waw") == 1) + CHECK; + else + FAIL; +#else + reporterr("hebrew_waw"); + FAIL; +#endif + +#ifdef XK_hebrew_zain + if(test(XK_hebrew_zain, "hebrew_zain") == 1) + CHECK; + else + FAIL; +#else + reporterr("hebrew_zain"); + FAIL; +#endif + +#ifdef XK_hebrew_zayin + if(test(XK_hebrew_zayin, "hebrew_zayin") == 1) + CHECK; + else + FAIL; +#else + reporterr("hebrew_zayin"); + FAIL; +#endif + +#ifdef XK_hebrew_chet + if(test(XK_hebrew_chet, "hebrew_chet") == 1) + CHECK; + else + FAIL; +#else + reporterr("hebrew_chet"); + FAIL; +#endif + +#ifdef XK_hebrew_het + if(test(XK_hebrew_het, "hebrew_het") == 1) + CHECK; + else + FAIL; +#else + reporterr("hebrew_het"); + FAIL; +#endif + +#ifdef XK_hebrew_tet + if(test(XK_hebrew_tet, "hebrew_tet") == 1) + CHECK; + else + FAIL; +#else + reporterr("hebrew_tet"); + FAIL; +#endif + +#ifdef XK_hebrew_teth + if(test(XK_hebrew_teth, "hebrew_teth") == 1) + CHECK; + else + FAIL; +#else + reporterr("hebrew_teth"); + FAIL; +#endif + +#ifdef XK_hebrew_yod + if(test(XK_hebrew_yod, "hebrew_yod") == 1) + CHECK; + else + FAIL; +#else + reporterr("hebrew_yod"); + FAIL; +#endif + +#ifdef XK_hebrew_finalkaph + if(test(XK_hebrew_finalkaph, "hebrew_finalkaph") == 1) + CHECK; + else + FAIL; +#else + reporterr("hebrew_finalkaph"); + FAIL; +#endif + +#ifdef XK_hebrew_kaph + if(test(XK_hebrew_kaph, "hebrew_kaph") == 1) + CHECK; + else + FAIL; +#else + reporterr("hebrew_kaph"); + FAIL; +#endif + +#ifdef XK_hebrew_lamed + if(test(XK_hebrew_lamed, "hebrew_lamed") == 1) + CHECK; + else + FAIL; +#else + reporterr("hebrew_lamed"); + FAIL; +#endif + +#ifdef XK_hebrew_finalmem + if(test(XK_hebrew_finalmem, "hebrew_finalmem") == 1) + CHECK; + else + FAIL; +#else + reporterr("hebrew_finalmem"); + FAIL; +#endif + +#ifdef XK_hebrew_mem + if(test(XK_hebrew_mem, "hebrew_mem") == 1) + CHECK; + else + FAIL; +#else + reporterr("hebrew_mem"); + FAIL; +#endif + +#ifdef XK_hebrew_finalnun + if(test(XK_hebrew_finalnun, "hebrew_finalnun") == 1) + CHECK; + else + FAIL; +#else + reporterr("hebrew_finalnun"); + FAIL; +#endif + +#ifdef XK_hebrew_nun + if(test(XK_hebrew_nun, "hebrew_nun") == 1) + CHECK; + else + FAIL; +#else + reporterr("hebrew_nun"); + FAIL; +#endif + +#ifdef XK_hebrew_samech + if(test(XK_hebrew_samech, "hebrew_samech") == 1) + CHECK; + else + FAIL; +#else + reporterr("hebrew_samech"); + FAIL; +#endif + +#ifdef XK_hebrew_samekh + if(test(XK_hebrew_samekh, "hebrew_samekh") == 1) + CHECK; + else + FAIL; +#else + reporterr("hebrew_samekh"); + FAIL; +#endif + +#ifdef XK_hebrew_ayin + if(test(XK_hebrew_ayin, "hebrew_ayin") == 1) + CHECK; + else + FAIL; +#else + reporterr("hebrew_ayin"); + FAIL; +#endif + +#ifdef XK_hebrew_finalpe + if(test(XK_hebrew_finalpe, "hebrew_finalpe") == 1) + CHECK; + else + FAIL; +#else + reporterr("hebrew_finalpe"); + FAIL; +#endif + +#ifdef XK_hebrew_pe + if(test(XK_hebrew_pe, "hebrew_pe") == 1) + CHECK; + else + FAIL; +#else + reporterr("hebrew_pe"); + FAIL; +#endif + +#ifdef XK_hebrew_finalzade + if(test(XK_hebrew_finalzade, "hebrew_finalzade") == 1) + CHECK; + else + FAIL; +#else + reporterr("hebrew_finalzade"); + FAIL; +#endif + +#ifdef XK_hebrew_finalzadi + if(test(XK_hebrew_finalzadi, "hebrew_finalzadi") == 1) + CHECK; + else + FAIL; +#else + reporterr("hebrew_finalzadi"); + FAIL; +#endif + +#ifdef XK_hebrew_zade + if(test(XK_hebrew_zade, "hebrew_zade") == 1) + CHECK; + else + FAIL; +#else + reporterr("hebrew_zade"); + FAIL; +#endif + +#ifdef XK_hebrew_zadi + if(test(XK_hebrew_zadi, "hebrew_zadi") == 1) + CHECK; + else + FAIL; +#else + reporterr("hebrew_zadi"); + FAIL; +#endif + +#ifdef XK_hebrew_qoph + if(test(XK_hebrew_qoph, "hebrew_qoph") == 1) + CHECK; + else + FAIL; +#else + reporterr("hebrew_qoph"); + FAIL; +#endif + +#ifdef XK_hebrew_kuf + if(test(XK_hebrew_kuf, "hebrew_kuf") == 1) + CHECK; + else + FAIL; +#else + reporterr("hebrew_kuf"); + FAIL; +#endif + +#ifdef XK_hebrew_resh + if(test(XK_hebrew_resh, "hebrew_resh") == 1) + CHECK; + else + FAIL; +#else + reporterr("hebrew_resh"); + FAIL; +#endif + +#ifdef XK_hebrew_shin + if(test(XK_hebrew_shin, "hebrew_shin") == 1) + CHECK; + else + FAIL; +#else + reporterr("hebrew_shin"); + FAIL; +#endif + +#ifdef XK_hebrew_taw + if(test(XK_hebrew_taw, "hebrew_taw") == 1) + CHECK; + else + FAIL; +#else + reporterr("hebrew_taw"); + FAIL; +#endif + +#ifdef XK_hebrew_taf + if(test(XK_hebrew_taf, "hebrew_taf") == 1) + CHECK; + else + FAIL; +#else + reporterr("hebrew_taf"); + FAIL; +#endif + +#ifdef XK_Hebrew_switch + if(test(XK_Hebrew_switch, "Hebrew_switch") == 1) + CHECK; + else + FAIL; +#else + reporterr("Hebrew_switch"); + FAIL; +#endif + + CHECKPASS(40); +} diff --git a/xts5/Xopen/XKeysymToKeycode/TestK.c b/xts5/Xopen/XKeysymToKeycode/TestK.c new file mode 100644 index 00000000..219869e3 --- /dev/null +++ b/xts5/Xopen/XKeysymToKeycode/TestK.c @@ -0,0 +1,849 @@ +/* +Copyright (c) 2005 X.Org Foundation L.L.C. + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies +of the Software, and to permit persons to whom the Software is furnished to do +so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. +*/ +/* +* $Header: /cvs/xtest/xtest/xts5/tset/Xopen/XKeysymToKeycode/TestK.c,v 1.2 2005-11-03 08:44:00 jmichael Exp $ +* +* Project: VSW5 +* +* File: xts5/tset/Xopen/XKeysymToKeycode/TestK.c +* +* Description: +* Tests for XKeysymToKeycode() +* +* Modifications: +* $Log: TestK.c,v $ +* Revision 1.2 2005-11-03 08:44:00 jmichael +* clean up all vsw5 paths to use xts5 instead. +* +* Revision 1.1.1.2 2005/04/15 14:05:40 anderson +* Reimport of the base with the legal name in the copyright fixed. +* +* Revision 8.0 1998/12/23 23:35:47 mar +* Branch point for Release 5.0.2 +* +* Revision 7.0 1998/10/30 22:58:28 mar +* Branch point for Release 5.0.2b1 +* +* Revision 6.0 1998/03/02 05:27:01 tbr +* Branch point for Release 5.0.1 +* +* Revision 5.0 1998/01/26 03:23:34 tbr +* Branch point for Release 5.0.1b1 +* +* Revision 4.1 1996/05/09 21:17:34 andy +* Fixed X includes +* +* Revision 4.0 1995/12/15 09:14:15 tbr +* Branch point for Release 5.0.0 +* +* Revision 3.1 1995/12/15 01:17:36 andy +* Prepare for GA Release +* +*/ +/* + * SCCS: @(#) TestK.c Rel 1.1 (11/28/91) + * + * UniSoft Ltd., London, England + * + * (C) Copyright 1991 X/Open Company Limited + * + * All rights reserved. No part of this source code may be reproduced, + * stored in a retrieval system, or transmitted, in any form or by any + * means, electronic, mechanical, photocopying, recording or otherwise, + * except as stated in the end-user licence agreement, without the prior + * permission of the copyright owners. + * + * X/Open and the 'X' symbol are trademarks of X/Open Company Limited in + * the UK and other countries. + */ + +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif + +#include <stdlib.h> +#include "xtest.h" +#include "X11/Xlib.h" +#include "X11/Xutil.h" +#include "X11/Xresource.h" +#include "tet_api.h" +#include "xtestlib.h" +#include "pixval.h" + +extern char *TestName; +extern Display *Dsp; + +int minkc; +int maxkc; +int keysyms_per_keycode; + +static int +test(symbol, str) +KeySym symbol; +char *str; +{ +KeyCode kycd; +int mod; + + kycd = XKeysymToKeycode(Dsp, symbol); + if(kycd == 0) { + trace("XKeysymToKeycode() returned 0 for KeySym \"XK_%s\".", str); + return(1); + } + + if(kycd > maxkc || kycd < minkc) { + report("XKeysymToKeycode() returned invalid keycode value %d for KeySym \"XK_%s\".", kycd, str); + return(0); + } + + for(mod = 0; mod < keysyms_per_keycode; mod++) { + if( symbol == XKeycodeToKeysym(Dsp, kycd, mod)) { + trace("KeySym \"XK_%s\", keycode %d, mod %d", + str, kycd, mod); + return(1); + } + } + + report("The keycode value %d for KeySym \"XK_%s\"", kycd, str); + report("never returns that KeySym when using XKeycodeToKeysym()"); + return(0); +} + +static void +reporterr(s) +char *s; +{ + report("Symbol XK_\"%s\" is not defined.", s); +} +#define XK_KATAKANA +#include <X11/keysymdef.h> +#undef XK_KATAKANA + +kysymtcdK() +{ +int pass = 0, fail = 0; + + XDisplayKeycodes(Dsp, &minkc, &maxkc); + XGetKeyboardMapping(Dsp, (KeyCode)minkc, 1, &keysyms_per_keycode); + +#ifdef XK_overline + if(test(XK_overline, "overline") == 1) + CHECK; + else + FAIL; +#else + reporterr("overline"); + FAIL; +#endif + +#ifdef XK_kana_fullstop + if(test(XK_kana_fullstop, "kana_fullstop") == 1) + CHECK; + else + FAIL; +#else + reporterr("kana_fullstop"); + FAIL; +#endif + +#ifdef XK_kana_openingbracket + if(test(XK_kana_openingbracket, "kana_openingbracket") == 1) + CHECK; + else + FAIL; +#else + reporterr("kana_openingbracket"); + FAIL; +#endif + +#ifdef XK_kana_closingbracket + if(test(XK_kana_closingbracket, "kana_closingbracket") == 1) + CHECK; + else + FAIL; +#else + reporterr("kana_closingbracket"); + FAIL; +#endif + +#ifdef XK_kana_comma + if(test(XK_kana_comma, "kana_comma") == 1) + CHECK; + else + FAIL; +#else + reporterr("kana_comma"); + FAIL; +#endif + +#ifdef XK_kana_conjunctive + if(test(XK_kana_conjunctive, "kana_conjunctive") == 1) + CHECK; + else + FAIL; +#else + reporterr("kana_conjunctive"); + FAIL; +#endif + +#ifdef XK_kana_middledot + if(test(XK_kana_middledot, "kana_middledot") == 1) + CHECK; + else + FAIL; +#else + reporterr("kana_middledot"); + FAIL; +#endif + +#ifdef XK_kana_WO + if(test(XK_kana_WO, "kana_WO") == 1) + CHECK; + else + FAIL; +#else + reporterr("kana_WO"); + FAIL; +#endif + +#ifdef XK_kana_a + if(test(XK_kana_a, "kana_a") == 1) + CHECK; + else + FAIL; +#else + reporterr("kana_a"); + FAIL; +#endif + +#ifdef XK_kana_i + if(test(XK_kana_i, "kana_i") == 1) + CHECK; + else + FAIL; +#else + reporterr("kana_i"); + FAIL; +#endif + +#ifdef XK_kana_u + if(test(XK_kana_u, "kana_u") == 1) + CHECK; + else + FAIL; +#else + reporterr("kana_u"); + FAIL; +#endif + +#ifdef XK_kana_e + if(test(XK_kana_e, "kana_e") == 1) + CHECK; + else + FAIL; +#else + reporterr("kana_e"); + FAIL; +#endif + +#ifdef XK_kana_o + if(test(XK_kana_o, "kana_o") == 1) + CHECK; + else + FAIL; +#else + reporterr("kana_o"); + FAIL; +#endif + +#ifdef XK_kana_ya + if(test(XK_kana_ya, "kana_ya") == 1) + CHECK; + else + FAIL; +#else + reporterr("kana_ya"); + FAIL; +#endif + +#ifdef XK_kana_yu + if(test(XK_kana_yu, "kana_yu") == 1) + CHECK; + else + FAIL; +#else + reporterr("kana_yu"); + FAIL; +#endif + +#ifdef XK_kana_yo + if(test(XK_kana_yo, "kana_yo") == 1) + CHECK; + else + FAIL; +#else + reporterr("kana_yo"); + FAIL; +#endif + +#ifdef XK_kana_tsu + if(test(XK_kana_tsu, "kana_tsu") == 1) + CHECK; + else + FAIL; +#else + reporterr("kana_tsu"); + FAIL; +#endif + +#ifdef XK_kana_tu + if(test(XK_kana_tu, "kana_tu") == 1) + CHECK; + else + FAIL; +#else + reporterr("kana_tu"); + FAIL; +#endif + +#ifdef XK_prolongedsound + if(test(XK_prolongedsound, "prolongedsound") == 1) + CHECK; + else + FAIL; +#else + reporterr("prolongedsound"); + FAIL; +#endif + +#ifdef XK_kana_A + if(test(XK_kana_A, "kana_A") == 1) + CHECK; + else + FAIL; +#else + reporterr("kana_A"); + FAIL; +#endif + +#ifdef XK_kana_I + if(test(XK_kana_I, "kana_I") == 1) + CHECK; + else + FAIL; +#else + reporterr("kana_I"); + FAIL; +#endif + +#ifdef XK_kana_U + if(test(XK_kana_U, "kana_U") == 1) + CHECK; + else + FAIL; +#else + reporterr("kana_U"); + FAIL; +#endif + +#ifdef XK_kana_E + if(test(XK_kana_E, "kana_E") == 1) + CHECK; + else + FAIL; +#else + reporterr("kana_E"); + FAIL; +#endif + +#ifdef XK_kana_O + if(test(XK_kana_O, "kana_O") == 1) + CHECK; + else + FAIL; +#else + reporterr("kana_O"); + FAIL; +#endif + +#ifdef XK_kana_KA + if(test(XK_kana_KA, "kana_KA") == 1) + CHECK; + else + FAIL; +#else + reporterr("kana_KA"); + FAIL; +#endif + +#ifdef XK_kana_KI + if(test(XK_kana_KI, "kana_KI") == 1) + CHECK; + else + FAIL; +#else + reporterr("kana_KI"); + FAIL; +#endif + +#ifdef XK_kana_KU + if(test(XK_kana_KU, "kana_KU") == 1) + CHECK; + else + FAIL; +#else + reporterr("kana_KU"); + FAIL; +#endif + +#ifdef XK_kana_KE + if(test(XK_kana_KE, "kana_KE") == 1) + CHECK; + else + FAIL; +#else + reporterr("kana_KE"); + FAIL; +#endif + +#ifdef XK_kana_KO + if(test(XK_kana_KO, "kana_KO") == 1) + CHECK; + else + FAIL; +#else + reporterr("kana_KO"); + FAIL; +#endif + +#ifdef XK_kana_SA + if(test(XK_kana_SA, "kana_SA") == 1) + CHECK; + else + FAIL; +#else + reporterr("kana_SA"); + FAIL; +#endif + +#ifdef XK_kana_SHI + if(test(XK_kana_SHI, "kana_SHI") == 1) + CHECK; + else + FAIL; +#else + reporterr("kana_SHI"); + FAIL; +#endif + +#ifdef XK_kana_SU + if(test(XK_kana_SU, "kana_SU") == 1) + CHECK; + else + FAIL; +#else + reporterr("kana_SU"); + FAIL; +#endif + +#ifdef XK_kana_SE + if(test(XK_kana_SE, "kana_SE") == 1) + CHECK; + else + FAIL; +#else + reporterr("kana_SE"); + FAIL; +#endif + +#ifdef XK_kana_SO + if(test(XK_kana_SO, "kana_SO") == 1) + CHECK; + else + FAIL; +#else + reporterr("kana_SO"); + FAIL; +#endif + +#ifdef XK_kana_TA + if(test(XK_kana_TA, "kana_TA") == 1) + CHECK; + else + FAIL; +#else + reporterr("kana_TA"); + FAIL; +#endif + +#ifdef XK_kana_CHI + if(test(XK_kana_CHI, "kana_CHI") == 1) + CHECK; + else + FAIL; +#else + reporterr("kana_CHI"); + FAIL; +#endif + +#ifdef XK_kana_TI + if(test(XK_kana_TI, "kana_TI") == 1) + CHECK; + else + FAIL; +#else + reporterr("kana_TI"); + FAIL; +#endif + +#ifdef XK_kana_TSU + if(test(XK_kana_TSU, "kana_TSU") == 1) + CHECK; + else + FAIL; +#else + reporterr("kana_TSU"); + FAIL; +#endif + +#ifdef XK_kana_TU + if(test(XK_kana_TU, "kana_TU") == 1) + CHECK; + else + FAIL; +#else + reporterr("kana_TU"); + FAIL; +#endif + +#ifdef XK_kana_TE + if(test(XK_kana_TE, "kana_TE") == 1) + CHECK; + else + FAIL; +#else + reporterr("kana_TE"); + FAIL; +#endif + +#ifdef XK_kana_TO + if(test(XK_kana_TO, "kana_TO") == 1) + CHECK; + else + FAIL; +#else + reporterr("kana_TO"); + FAIL; +#endif + +#ifdef XK_kana_NA + if(test(XK_kana_NA, "kana_NA") == 1) + CHECK; + else + FAIL; +#else + reporterr("kana_NA"); + FAIL; +#endif + +#ifdef XK_kana_NI + if(test(XK_kana_NI, "kana_NI") == 1) + CHECK; + else + FAIL; +#else + reporterr("kana_NI"); + FAIL; +#endif + +#ifdef XK_kana_NU + if(test(XK_kana_NU, "kana_NU") == 1) + CHECK; + else + FAIL; +#else + reporterr("kana_NU"); + FAIL; +#endif + +#ifdef XK_kana_NE + if(test(XK_kana_NE, "kana_NE") == 1) + CHECK; + else + FAIL; +#else + reporterr("kana_NE"); + FAIL; +#endif + +#ifdef XK_kana_NO + if(test(XK_kana_NO, "kana_NO") == 1) + CHECK; + else + FAIL; +#else + reporterr("kana_NO"); + FAIL; +#endif + +#ifdef XK_kana_HA + if(test(XK_kana_HA, "kana_HA") == 1) + CHECK; + else + FAIL; +#else + reporterr("kana_HA"); + FAIL; +#endif + +#ifdef XK_kana_HI + if(test(XK_kana_HI, "kana_HI") == 1) + CHECK; + else + FAIL; +#else + reporterr("kana_HI"); + FAIL; +#endif + +#ifdef XK_kana_FU + if(test(XK_kana_FU, "kana_FU") == 1) + CHECK; + else + FAIL; +#else + reporterr("kana_FU"); + FAIL; +#endif + +#ifdef XK_kana_HU + if(test(XK_kana_HU, "kana_HU") == 1) + CHECK; + else + FAIL; +#else + reporterr("kana_HU"); + FAIL; +#endif + +#ifdef XK_kana_HE + if(test(XK_kana_HE, "kana_HE") == 1) + CHECK; + else + FAIL; +#else + reporterr("kana_HE"); + FAIL; +#endif + +#ifdef XK_kana_HO + if(test(XK_kana_HO, "kana_HO") == 1) + CHECK; + else + FAIL; +#else + reporterr("kana_HO"); + FAIL; +#endif + +#ifdef XK_kana_MA + if(test(XK_kana_MA, "kana_MA") == 1) + CHECK; + else + FAIL; +#else + reporterr("kana_MA"); + FAIL; +#endif + +#ifdef XK_kana_MI + if(test(XK_kana_MI, "kana_MI") == 1) + CHECK; + else + FAIL; +#else + reporterr("kana_MI"); + FAIL; +#endif + +#ifdef XK_kana_MU + if(test(XK_kana_MU, "kana_MU") == 1) + CHECK; + else + FAIL; +#else + reporterr("kana_MU"); + FAIL; +#endif + +#ifdef XK_kana_ME + if(test(XK_kana_ME, "kana_ME") == 1) + CHECK; + else + FAIL; +#else + reporterr("kana_ME"); + FAIL; +#endif + +#ifdef XK_kana_MO + if(test(XK_kana_MO, "kana_MO") == 1) + CHECK; + else + FAIL; +#else + reporterr("kana_MO"); + FAIL; +#endif + +#ifdef XK_kana_YA + if(test(XK_kana_YA, "kana_YA") == 1) + CHECK; + else + FAIL; +#else + reporterr("kana_YA"); + FAIL; +#endif + +#ifdef XK_kana_YU + if(test(XK_kana_YU, "kana_YU") == 1) + CHECK; + else + FAIL; +#else + reporterr("kana_YU"); + FAIL; +#endif + +#ifdef XK_kana_YO + if(test(XK_kana_YO, "kana_YO") == 1) + CHECK; + else + FAIL; +#else + reporterr("kana_YO"); + FAIL; +#endif + +#ifdef XK_kana_RA + if(test(XK_kana_RA, "kana_RA") == 1) + CHECK; + else + FAIL; +#else + reporterr("kana_RA"); + FAIL; +#endif + +#ifdef XK_kana_RI + if(test(XK_kana_RI, "kana_RI") == 1) + CHECK; + else + FAIL; +#else + reporterr("kana_RI"); + FAIL; +#endif + +#ifdef XK_kana_RU + if(test(XK_kana_RU, "kana_RU") == 1) + CHECK; + else + FAIL; +#else + reporterr("kana_RU"); + FAIL; +#endif + +#ifdef XK_kana_RE + if(test(XK_kana_RE, "kana_RE") == 1) + CHECK; + else + FAIL; +#else + reporterr("kana_RE"); + FAIL; +#endif + +#ifdef XK_kana_RO + if(test(XK_kana_RO, "kana_RO") == 1) + CHECK; + else + FAIL; +#else + reporterr("kana_RO"); + FAIL; +#endif + +#ifdef XK_kana_WA + if(test(XK_kana_WA, "kana_WA") == 1) + CHECK; + else + FAIL; +#else + reporterr("kana_WA"); + FAIL; +#endif + +#ifdef XK_kana_N + if(test(XK_kana_N, "kana_N") == 1) + CHECK; + else + FAIL; +#else + reporterr("kana_N"); + FAIL; +#endif + +#ifdef XK_voicedsound + if(test(XK_voicedsound, "voicedsound") == 1) + CHECK; + else + FAIL; +#else + reporterr("voicedsound"); + FAIL; +#endif + +#ifdef XK_semivoicedsound + if(test(XK_semivoicedsound, "semivoicedsound") == 1) + CHECK; + else + FAIL; +#else + reporterr("semivoicedsound"); + FAIL; +#endif + +#ifdef XK_kana_switch + if(test(XK_kana_switch, "kana_switch") == 1) + CHECK; + else + FAIL; +#else + reporterr("kana_switch"); + FAIL; +#endif + + CHECKPASS(70); +} diff --git a/xts5/Xopen/XKeysymToKeycode/TestL.c b/xts5/Xopen/XKeysymToKeycode/TestL.c new file mode 100644 index 00000000..a3f2cc05 --- /dev/null +++ b/xts5/Xopen/XKeysymToKeycode/TestL.c @@ -0,0 +1,339 @@ +/* +Copyright (c) 2005 X.Org Foundation L.L.C. + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies +of the Software, and to permit persons to whom the Software is furnished to do +so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. +*/ +/* +* $Header: /cvs/xtest/xtest/xts5/tset/Xopen/XKeysymToKeycode/TestL.c,v 1.2 2005-11-03 08:44:00 jmichael Exp $ +* +* Project: VSW5 +* +* File: xts5/tset/Xopen/XKeysymToKeycode/TestL.c +* +* Description: +* Tests for XKeysymToKeycode() +* +* Modifications: +* $Log: TestL.c,v $ +* Revision 1.2 2005-11-03 08:44:00 jmichael +* clean up all vsw5 paths to use xts5 instead. +* +* Revision 1.1.1.2 2005/04/15 14:05:40 anderson +* Reimport of the base with the legal name in the copyright fixed. +* +* Revision 8.0 1998/12/23 23:35:48 mar +* Branch point for Release 5.0.2 +* +* Revision 7.0 1998/10/30 22:58:28 mar +* Branch point for Release 5.0.2b1 +* +* Revision 6.0 1998/03/02 05:27:01 tbr +* Branch point for Release 5.0.1 +* +* Revision 5.0 1998/01/26 03:23:35 tbr +* Branch point for Release 5.0.1b1 +* +* Revision 4.1 1996/05/09 21:17:34 andy +* Fixed X includes +* +* Revision 4.0 1995/12/15 09:14:16 tbr +* Branch point for Release 5.0.0 +* +* Revision 3.1 1995/12/15 01:17:38 andy +* Prepare for GA Release +* +*/ +/* + * SCCS: @(#) TestL.c Rel 1.1 (11/28/91) + * + * UniSoft Ltd., London, England + * + * (C) Copyright 1991 X/Open Company Limited + * + * All rights reserved. No part of this source code may be reproduced, + * stored in a retrieval system, or transmitted, in any form or by any + * means, electronic, mechanical, photocopying, recording or otherwise, + * except as stated in the end-user licence agreement, without the prior + * permission of the copyright owners. + * + * X/Open and the 'X' symbol are trademarks of X/Open Company Limited in + * the UK and other countries. + */ + +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif + +#include <stdlib.h> +#include "xtest.h" +#include "X11/Xlib.h" +#include "X11/Xutil.h" +#include "X11/Xresource.h" +#include "tet_api.h" +#include "xtestlib.h" +#include "pixval.h" + +extern char *TestName; +extern Display *Dsp; + +int minkc; +int maxkc; +int keysyms_per_keycode; + +static int +test(symbol, str) +KeySym symbol; +char *str; +{ +KeyCode kycd; +int mod; + + kycd = XKeysymToKeycode(Dsp, symbol); + if(kycd == 0) { + trace("XKeysymToKeycode() returned 0 for KeySym \"XK_%s\".", str); + return(1); + } + + if(kycd > maxkc || kycd < minkc) { + report("XKeysymToKeycode() returned invalid keycode value %d for KeySym \"XK_%s\".", kycd, str); + return(0); + } + + for(mod = 0; mod < keysyms_per_keycode; mod++) { + if( symbol == XKeycodeToKeysym(Dsp, kycd, mod)) { + trace("KeySym \"XK_%s\", keycode %d, mod %d", + str, kycd, mod); + return(1); + } + } + + report("The keycode value %d for KeySym \"XK_%s\"", kycd, str); + report("never returns that KeySym when using XKeycodeToKeysym()"); + return(0); +} + +static void +reporterr(s) +char *s; +{ + report("Symbol XK_\"%s\" is not defined.", s); +} +#define XK_APL +#include <X11/keysymdef.h> +#undef XK_APL + +kysymtcdL() +{ +int pass = 0, fail = 0; + + XDisplayKeycodes(Dsp, &minkc, &maxkc); + XGetKeyboardMapping(Dsp, (KeyCode)minkc, 1, &keysyms_per_keycode); + +#ifdef XK_leftcaret + if(test(XK_leftcaret, "leftcaret") == 1) + CHECK; + else + FAIL; +#else + reporterr("leftcaret"); + FAIL; +#endif + +#ifdef XK_rightcaret + if(test(XK_rightcaret, "rightcaret") == 1) + CHECK; + else + FAIL; +#else + reporterr("rightcaret"); + FAIL; +#endif + +#ifdef XK_downcaret + if(test(XK_downcaret, "downcaret") == 1) + CHECK; + else + FAIL; +#else + reporterr("downcaret"); + FAIL; +#endif + +#ifdef XK_upcaret + if(test(XK_upcaret, "upcaret") == 1) + CHECK; + else + FAIL; +#else + reporterr("upcaret"); + FAIL; +#endif + +#ifdef XK_overbar + if(test(XK_overbar, "overbar") == 1) + CHECK; + else + FAIL; +#else + reporterr("overbar"); + FAIL; +#endif + +#ifdef XK_downtack + if(test(XK_downtack, "downtack") == 1) + CHECK; + else + FAIL; +#else + reporterr("downtack"); + FAIL; +#endif + +#ifdef XK_upshoe + if(test(XK_upshoe, "upshoe") == 1) + CHECK; + else + FAIL; +#else + reporterr("upshoe"); + FAIL; +#endif + +#ifdef XK_downstile + if(test(XK_downstile, "downstile") == 1) + CHECK; + else + FAIL; +#else + reporterr("downstile"); + FAIL; +#endif + +#ifdef XK_underbar + if(test(XK_underbar, "underbar") == 1) + CHECK; + else + FAIL; +#else + reporterr("underbar"); + FAIL; +#endif + +#ifdef XK_jot + if(test(XK_jot, "jot") == 1) + CHECK; + else + FAIL; +#else + reporterr("jot"); + FAIL; +#endif + +#ifdef XK_quad + if(test(XK_quad, "quad") == 1) + CHECK; + else + FAIL; +#else + reporterr("quad"); + FAIL; +#endif + +#ifdef XK_uptack + if(test(XK_uptack, "uptack") == 1) + CHECK; + else + FAIL; +#else + reporterr("uptack"); + FAIL; +#endif + +#ifdef XK_circle + if(test(XK_circle, "circle") == 1) + CHECK; + else + FAIL; +#else + reporterr("circle"); + FAIL; +#endif + +#ifdef XK_upstile + if(test(XK_upstile, "upstile") == 1) + CHECK; + else + FAIL; +#else + reporterr("upstile"); + FAIL; +#endif + +#ifdef XK_downshoe + if(test(XK_downshoe, "downshoe") == 1) + CHECK; + else + FAIL; +#else + reporterr("downshoe"); + FAIL; +#endif + +#ifdef XK_rightshoe + if(test(XK_rightshoe, "rightshoe") == 1) + CHECK; + else + FAIL; +#else + reporterr("rightshoe"); + FAIL; +#endif + +#ifdef XK_leftshoe + if(test(XK_leftshoe, "leftshoe") == 1) + CHECK; + else + FAIL; +#else + reporterr("leftshoe"); + FAIL; +#endif + +#ifdef XK_lefttack + if(test(XK_lefttack, "lefttack") == 1) + CHECK; + else + FAIL; +#else + reporterr("lefttack"); + FAIL; +#endif + +#ifdef XK_righttack + if(test(XK_righttack, "righttack") == 1) + CHECK; + else + FAIL; +#else + reporterr("righttack"); + FAIL; +#endif + + CHECKPASS(19); +} diff --git a/xts5/Xopen/XKeysymToKeycode/TestM.c b/xts5/Xopen/XKeysymToKeycode/TestM.c new file mode 100644 index 00000000..f388ba83 --- /dev/null +++ b/xts5/Xopen/XKeysymToKeycode/TestM.c @@ -0,0 +1,1629 @@ +/* +Copyright (c) 2005 X.Org Foundation L.L.C. + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies +of the Software, and to permit persons to whom the Software is furnished to do +so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. +*/ +/* +* $Header: /cvs/xtest/xtest/xts5/tset/Xopen/XKeysymToKeycode/TestM.c,v 1.2 2005-11-03 08:44:00 jmichael Exp $ +* +* Project: VSW5 +* +* File: xts5/tset/Xopen/XKeysymToKeycode/TestM.c +* +* Description: +* Tests for XKeysymToKeycode() +* +* Modifications: +* $Log: TestM.c,v $ +* Revision 1.2 2005-11-03 08:44:00 jmichael +* clean up all vsw5 paths to use xts5 instead. +* +* Revision 1.1.1.2 2005/04/15 14:05:40 anderson +* Reimport of the base with the legal name in the copyright fixed. +* +* Revision 8.0 1998/12/23 23:35:48 mar +* Branch point for Release 5.0.2 +* +* Revision 7.0 1998/10/30 22:58:29 mar +* Branch point for Release 5.0.2b1 +* +* Revision 6.0 1998/03/02 05:27:02 tbr +* Branch point for Release 5.0.1 +* +* Revision 5.0 1998/01/26 03:23:35 tbr +* Branch point for Release 5.0.1b1 +* +* Revision 4.1 1996/05/09 21:17:34 andy +* Fixed X includes +* +* Revision 4.0 1995/12/15 09:14:17 tbr +* Branch point for Release 5.0.0 +* +* Revision 3.1 1995/12/15 01:17:40 andy +* Prepare for GA Release +* +*/ +/* + * SCCS: @(#) TestM.c Rel 1.1 (11/28/91) + * + * UniSoft Ltd., London, England + * + * (C) Copyright 1991 X/Open Company Limited + * + * All rights reserved. No part of this source code may be reproduced, + * stored in a retrieval system, or transmitted, in any form or by any + * means, electronic, mechanical, photocopying, recording or otherwise, + * except as stated in the end-user licence agreement, without the prior + * permission of the copyright owners. + * + * X/Open and the 'X' symbol are trademarks of X/Open Company Limited in + * the UK and other countries. + */ + +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif + +#include <stdlib.h> +#include "xtest.h" +#include "X11/Xlib.h" +#include "X11/Xutil.h" +#include "X11/Xresource.h" +#include "tet_api.h" +#include "xtestlib.h" +#include "pixval.h" + +extern char *TestName; +extern Display *Dsp; + +int minkc; +int maxkc; +int keysyms_per_keycode; + +static int +test(symbol, str) +KeySym symbol; +char *str; +{ +KeyCode kycd; +int mod; + + kycd = XKeysymToKeycode(Dsp, symbol); + if(kycd == 0) { + trace("XKeysymToKeycode() returned 0 for KeySym \"XK_%s\".", str); + return(1); + } + + if(kycd > maxkc || kycd < minkc) { + report("XKeysymToKeycode() returned invalid keycode value %d for KeySym \"XK_%s\".", kycd, str); + return(0); + } + + for(mod = 0; mod < keysyms_per_keycode; mod++) { + if( symbol == XKeycodeToKeysym(Dsp, kycd, mod)) { + trace("KeySym \"XK_%s\", keycode %d, mod %d", + str, kycd, mod); + return(1); + } + } + + report("The keycode value %d for KeySym \"XK_%s\"", kycd, str); + report("never returns that KeySym when using XKeycodeToKeysym()"); + return(0); +} + +static void +reporterr(s) +char *s; +{ + report("Symbol XK_\"%s\" is not defined.", s); +} +#define XK_MISCELLANY +#include <X11/keysymdef.h> +#undef XK_MISCELLANY + +kysymtcdM() +{ +int pass = 0, fail = 0; + + XDisplayKeycodes(Dsp, &minkc, &maxkc); + XGetKeyboardMapping(Dsp, (KeyCode)minkc, 1, &keysyms_per_keycode); + +#ifdef XK_BackSpace + if(test(XK_BackSpace, "BackSpace") == 1) + CHECK; + else + FAIL; +#else + reporterr("BackSpace"); + FAIL; +#endif + +#ifdef XK_Tab + if(test(XK_Tab, "Tab") == 1) + CHECK; + else + FAIL; +#else + reporterr("Tab"); + FAIL; +#endif + +#ifdef XK_Linefeed + if(test(XK_Linefeed, "Linefeed") == 1) + CHECK; + else + FAIL; +#else + reporterr("Linefeed"); + FAIL; +#endif + +#ifdef XK_Clear + if(test(XK_Clear, "Clear") == 1) + CHECK; + else + FAIL; +#else + reporterr("Clear"); + FAIL; +#endif + +#ifdef XK_Return + if(test(XK_Return, "Return") == 1) + CHECK; + else + FAIL; +#else + reporterr("Return"); + FAIL; +#endif + +#ifdef XK_Pause + if(test(XK_Pause, "Pause") == 1) + CHECK; + else + FAIL; +#else + reporterr("Pause"); + FAIL; +#endif + +#ifdef XK_Scroll_Lock + if(test(XK_Scroll_Lock, "Scroll_Lock") == 1) + CHECK; + else + FAIL; +#else + reporterr("Scroll_Lock"); + FAIL; +#endif + +#ifdef XK_Escape + if(test(XK_Escape, "Escape") == 1) + CHECK; + else + FAIL; +#else + reporterr("Escape"); + FAIL; +#endif + +#ifdef XK_Multi_key + if(test(XK_Multi_key, "Multi_key") == 1) + CHECK; + else + FAIL; +#else + reporterr("Multi_key"); + FAIL; +#endif + +#ifdef XK_Kanji + if(test(XK_Kanji, "Kanji") == 1) + CHECK; + else + FAIL; +#else + reporterr("Kanji"); + FAIL; +#endif + +#ifdef XK_Muhenkan + if(test(XK_Muhenkan, "Muhenkan") == 1) + CHECK; + else + FAIL; +#else + reporterr("Muhenkan"); + FAIL; +#endif + +#ifdef XK_Henkan + if(test(XK_Henkan, "Henkan") == 1) + CHECK; + else + FAIL; +#else + reporterr("Henkan"); + FAIL; +#endif + +#ifdef XK_Henkan_Mode + if(test(XK_Henkan_Mode, "Henkan_Mode") == 1) + CHECK; + else + FAIL; +#else + reporterr("Henkan_Mode"); + FAIL; +#endif + +#ifdef XK_Romaji + if(test(XK_Romaji, "Romaji") == 1) + CHECK; + else + FAIL; +#else + reporterr("Romaji"); + FAIL; +#endif + +#ifdef XK_Hiragana + if(test(XK_Hiragana, "Hiragana") == 1) + CHECK; + else + FAIL; +#else + reporterr("Hiragana"); + FAIL; +#endif + +#ifdef XK_Katakana + if(test(XK_Katakana, "Katakana") == 1) + CHECK; + else + FAIL; +#else + reporterr("Katakana"); + FAIL; +#endif + +#ifdef XK_Hiragana_Katakana + if(test(XK_Hiragana_Katakana, "Hiragana_Katakana") == 1) + CHECK; + else + FAIL; +#else + reporterr("Hiragana_Katakana"); + FAIL; +#endif + +#ifdef XK_Zenkaku + if(test(XK_Zenkaku, "Zenkaku") == 1) + CHECK; + else + FAIL; +#else + reporterr("Zenkaku"); + FAIL; +#endif + +#ifdef XK_Hankaku + if(test(XK_Hankaku, "Hankaku") == 1) + CHECK; + else + FAIL; +#else + reporterr("Hankaku"); + FAIL; +#endif + +#ifdef XK_Zenkaku_Hankaku + if(test(XK_Zenkaku_Hankaku, "Zenkaku_Hankaku") == 1) + CHECK; + else + FAIL; +#else + reporterr("Zenkaku_Hankaku"); + FAIL; +#endif + +#ifdef XK_Touroku + if(test(XK_Touroku, "Touroku") == 1) + CHECK; + else + FAIL; +#else + reporterr("Touroku"); + FAIL; +#endif + +#ifdef XK_Massyo + if(test(XK_Massyo, "Massyo") == 1) + CHECK; + else + FAIL; +#else + reporterr("Massyo"); + FAIL; +#endif + +#ifdef XK_Kana_Lock + if(test(XK_Kana_Lock, "Kana_Lock") == 1) + CHECK; + else + FAIL; +#else + reporterr("Kana_Lock"); + FAIL; +#endif + +#ifdef XK_Kana_Shift + if(test(XK_Kana_Shift, "Kana_Shift") == 1) + CHECK; + else + FAIL; +#else + reporterr("Kana_Shift"); + FAIL; +#endif + +#ifdef XK_Eisu_Shift + if(test(XK_Eisu_Shift, "Eisu_Shift") == 1) + CHECK; + else + FAIL; +#else + reporterr("Eisu_Shift"); + FAIL; +#endif + +#ifdef XK_Eisu_toggle + if(test(XK_Eisu_toggle, "Eisu_toggle") == 1) + CHECK; + else + FAIL; +#else + reporterr("Eisu_toggle"); + FAIL; +#endif + +#ifdef XK_Home + if(test(XK_Home, "Home") == 1) + CHECK; + else + FAIL; +#else + reporterr("Home"); + FAIL; +#endif + +#ifdef XK_Left + if(test(XK_Left, "Left") == 1) + CHECK; + else + FAIL; +#else + reporterr("Left"); + FAIL; +#endif + +#ifdef XK_Up + if(test(XK_Up, "Up") == 1) + CHECK; + else + FAIL; +#else + reporterr("Up"); + FAIL; +#endif + +#ifdef XK_Right + if(test(XK_Right, "Right") == 1) + CHECK; + else + FAIL; +#else + reporterr("Right"); + FAIL; +#endif + +#ifdef XK_Down + if(test(XK_Down, "Down") == 1) + CHECK; + else + FAIL; +#else + reporterr("Down"); + FAIL; +#endif + +#ifdef XK_Prior + if(test(XK_Prior, "Prior") == 1) + CHECK; + else + FAIL; +#else + reporterr("Prior"); + FAIL; +#endif + +#ifdef XK_Next + if(test(XK_Next, "Next") == 1) + CHECK; + else + FAIL; +#else + reporterr("Next"); + FAIL; +#endif + +#ifdef XK_End + if(test(XK_End, "End") == 1) + CHECK; + else + FAIL; +#else + reporterr("End"); + FAIL; +#endif + +#ifdef XK_Begin + if(test(XK_Begin, "Begin") == 1) + CHECK; + else + FAIL; +#else + reporterr("Begin"); + FAIL; +#endif + +#ifdef XK_Select + if(test(XK_Select, "Select") == 1) + CHECK; + else + FAIL; +#else + reporterr("Select"); + FAIL; +#endif + +#ifdef XK_Print + if(test(XK_Print, "Print") == 1) + CHECK; + else + FAIL; +#else + reporterr("Print"); + FAIL; +#endif + +#ifdef XK_Execute + if(test(XK_Execute, "Execute") == 1) + CHECK; + else + FAIL; +#else + reporterr("Execute"); + FAIL; +#endif + +#ifdef XK_Insert + if(test(XK_Insert, "Insert") == 1) + CHECK; + else + FAIL; +#else + reporterr("Insert"); + FAIL; +#endif + +#ifdef XK_Undo + if(test(XK_Undo, "Undo") == 1) + CHECK; + else + FAIL; +#else + reporterr("Undo"); + FAIL; +#endif + +#ifdef XK_Redo + if(test(XK_Redo, "Redo") == 1) + CHECK; + else + FAIL; +#else + reporterr("Redo"); + FAIL; +#endif + +#ifdef XK_Menu + if(test(XK_Menu, "Menu") == 1) + CHECK; + else + FAIL; +#else + reporterr("Menu"); + FAIL; +#endif + +#ifdef XK_Find + if(test(XK_Find, "Find") == 1) + CHECK; + else + FAIL; +#else + reporterr("Find"); + FAIL; +#endif + +#ifdef XK_Cancel + if(test(XK_Cancel, "Cancel") == 1) + CHECK; + else + FAIL; +#else + reporterr("Cancel"); + FAIL; +#endif + +#ifdef XK_Help + if(test(XK_Help, "Help") == 1) + CHECK; + else + FAIL; +#else + reporterr("Help"); + FAIL; +#endif + +#ifdef XK_Break + if(test(XK_Break, "Break") == 1) + CHECK; + else + FAIL; +#else + reporterr("Break"); + FAIL; +#endif + +#ifdef XK_Mode_switch + if(test(XK_Mode_switch, "Mode_switch") == 1) + CHECK; + else + FAIL; +#else + reporterr("Mode_switch"); + FAIL; +#endif + +#ifdef XK_script_switch + if(test(XK_script_switch, "script_switch") == 1) + CHECK; + else + FAIL; +#else + reporterr("script_switch"); + FAIL; +#endif + +#ifdef XK_Num_Lock + if(test(XK_Num_Lock, "Num_Lock") == 1) + CHECK; + else + FAIL; +#else + reporterr("Num_Lock"); + FAIL; +#endif + +#ifdef XK_KP_Space + if(test(XK_KP_Space, "KP_Space") == 1) + CHECK; + else + FAIL; +#else + reporterr("KP_Space"); + FAIL; +#endif + +#ifdef XK_KP_Tab + if(test(XK_KP_Tab, "KP_Tab") == 1) + CHECK; + else + FAIL; +#else + reporterr("KP_Tab"); + FAIL; +#endif + +#ifdef XK_KP_Enter + if(test(XK_KP_Enter, "KP_Enter") == 1) + CHECK; + else + FAIL; +#else + reporterr("KP_Enter"); + FAIL; +#endif + +#ifdef XK_KP_F1 + if(test(XK_KP_F1, "KP_F1") == 1) + CHECK; + else + FAIL; +#else + reporterr("KP_F1"); + FAIL; +#endif + +#ifdef XK_KP_F2 + if(test(XK_KP_F2, "KP_F2") == 1) + CHECK; + else + FAIL; +#else + reporterr("KP_F2"); + FAIL; +#endif + +#ifdef XK_KP_F3 + if(test(XK_KP_F3, "KP_F3") == 1) + CHECK; + else + FAIL; +#else + reporterr("KP_F3"); + FAIL; +#endif + +#ifdef XK_KP_F4 + if(test(XK_KP_F4, "KP_F4") == 1) + CHECK; + else + FAIL; +#else + reporterr("KP_F4"); + FAIL; +#endif + +#ifdef XK_KP_Multiply + if(test(XK_KP_Multiply, "KP_Multiply") == 1) + CHECK; + else + FAIL; +#else + reporterr("KP_Multiply"); + FAIL; +#endif + +#ifdef XK_KP_Add + if(test(XK_KP_Add, "KP_Add") == 1) + CHECK; + else + FAIL; +#else + reporterr("KP_Add"); + FAIL; +#endif + +#ifdef XK_KP_Separator + if(test(XK_KP_Separator, "KP_Separator") == 1) + CHECK; + else + FAIL; +#else + reporterr("KP_Separator"); + FAIL; +#endif + +#ifdef XK_KP_Subtract + if(test(XK_KP_Subtract, "KP_Subtract") == 1) + CHECK; + else + FAIL; +#else + reporterr("KP_Subtract"); + FAIL; +#endif + +#ifdef XK_KP_Decimal + if(test(XK_KP_Decimal, "KP_Decimal") == 1) + CHECK; + else + FAIL; +#else + reporterr("KP_Decimal"); + FAIL; +#endif + +#ifdef XK_KP_Divide + if(test(XK_KP_Divide, "KP_Divide") == 1) + CHECK; + else + FAIL; +#else + reporterr("KP_Divide"); + FAIL; +#endif + +#ifdef XK_KP_0 + if(test(XK_KP_0, "KP_0") == 1) + CHECK; + else + FAIL; +#else + reporterr("KP_0"); + FAIL; +#endif + +#ifdef XK_KP_1 + if(test(XK_KP_1, "KP_1") == 1) + CHECK; + else + FAIL; +#else + reporterr("KP_1"); + FAIL; +#endif + +#ifdef XK_KP_2 + if(test(XK_KP_2, "KP_2") == 1) + CHECK; + else + FAIL; +#else + reporterr("KP_2"); + FAIL; +#endif + +#ifdef XK_KP_3 + if(test(XK_KP_3, "KP_3") == 1) + CHECK; + else + FAIL; +#else + reporterr("KP_3"); + FAIL; +#endif + +#ifdef XK_KP_4 + if(test(XK_KP_4, "KP_4") == 1) + CHECK; + else + FAIL; +#else + reporterr("KP_4"); + FAIL; +#endif + +#ifdef XK_KP_5 + if(test(XK_KP_5, "KP_5") == 1) + CHECK; + else + FAIL; +#else + reporterr("KP_5"); + FAIL; +#endif + +#ifdef XK_KP_6 + if(test(XK_KP_6, "KP_6") == 1) + CHECK; + else + FAIL; +#else + reporterr("KP_6"); + FAIL; +#endif + +#ifdef XK_KP_7 + if(test(XK_KP_7, "KP_7") == 1) + CHECK; + else + FAIL; +#else + reporterr("KP_7"); + FAIL; +#endif + +#ifdef XK_KP_8 + if(test(XK_KP_8, "KP_8") == 1) + CHECK; + else + FAIL; +#else + reporterr("KP_8"); + FAIL; +#endif + +#ifdef XK_KP_9 + if(test(XK_KP_9, "KP_9") == 1) + CHECK; + else + FAIL; +#else + reporterr("KP_9"); + FAIL; +#endif + +#ifdef XK_KP_Equal + if(test(XK_KP_Equal, "KP_Equal") == 1) + CHECK; + else + FAIL; +#else + reporterr("KP_Equal"); + FAIL; +#endif + +#ifdef XK_F1 + if(test(XK_F1, "F1") == 1) + CHECK; + else + FAIL; +#else + reporterr("F1"); + FAIL; +#endif + +#ifdef XK_F2 + if(test(XK_F2, "F2") == 1) + CHECK; + else + FAIL; +#else + reporterr("F2"); + FAIL; +#endif + +#ifdef XK_F3 + if(test(XK_F3, "F3") == 1) + CHECK; + else + FAIL; +#else + reporterr("F3"); + FAIL; +#endif + +#ifdef XK_F4 + if(test(XK_F4, "F4") == 1) + CHECK; + else + FAIL; +#else + reporterr("F4"); + FAIL; +#endif + +#ifdef XK_F5 + if(test(XK_F5, "F5") == 1) + CHECK; + else + FAIL; +#else + reporterr("F5"); + FAIL; +#endif + +#ifdef XK_F6 + if(test(XK_F6, "F6") == 1) + CHECK; + else + FAIL; +#else + reporterr("F6"); + FAIL; +#endif + +#ifdef XK_F7 + if(test(XK_F7, "F7") == 1) + CHECK; + else + FAIL; +#else + reporterr("F7"); + FAIL; +#endif + +#ifdef XK_F8 + if(test(XK_F8, "F8") == 1) + CHECK; + else + FAIL; +#else + reporterr("F8"); + FAIL; +#endif + +#ifdef XK_F9 + if(test(XK_F9, "F9") == 1) + CHECK; + else + FAIL; +#else + reporterr("F9"); + FAIL; +#endif + +#ifdef XK_F10 + if(test(XK_F10, "F10") == 1) + CHECK; + else + FAIL; +#else + reporterr("F10"); + FAIL; +#endif + +#ifdef XK_F11 + if(test(XK_F11, "F11") == 1) + CHECK; + else + FAIL; +#else + reporterr("F11"); + FAIL; +#endif + +#ifdef XK_L1 + if(test(XK_L1, "L1") == 1) + CHECK; + else + FAIL; +#else + reporterr("L1"); + FAIL; +#endif + +#ifdef XK_F12 + if(test(XK_F12, "F12") == 1) + CHECK; + else + FAIL; +#else + reporterr("F12"); + FAIL; +#endif + +#ifdef XK_L2 + if(test(XK_L2, "L2") == 1) + CHECK; + else + FAIL; +#else + reporterr("L2"); + FAIL; +#endif + +#ifdef XK_F13 + if(test(XK_F13, "F13") == 1) + CHECK; + else + FAIL; +#else + reporterr("F13"); + FAIL; +#endif + +#ifdef XK_L3 + if(test(XK_L3, "L3") == 1) + CHECK; + else + FAIL; +#else + reporterr("L3"); + FAIL; +#endif + +#ifdef XK_F14 + if(test(XK_F14, "F14") == 1) + CHECK; + else + FAIL; +#else + reporterr("F14"); + FAIL; +#endif + +#ifdef XK_L4 + if(test(XK_L4, "L4") == 1) + CHECK; + else + FAIL; +#else + reporterr("L4"); + FAIL; +#endif + +#ifdef XK_F15 + if(test(XK_F15, "F15") == 1) + CHECK; + else + FAIL; +#else + reporterr("F15"); + FAIL; +#endif + +#ifdef XK_L5 + if(test(XK_L5, "L5") == 1) + CHECK; + else + FAIL; +#else + reporterr("L5"); + FAIL; +#endif + +#ifdef XK_F16 + if(test(XK_F16, "F16") == 1) + CHECK; + else + FAIL; +#else + reporterr("F16"); + FAIL; +#endif + +#ifdef XK_L6 + if(test(XK_L6, "L6") == 1) + CHECK; + else + FAIL; +#else + reporterr("L6"); + FAIL; +#endif + +#ifdef XK_F17 + if(test(XK_F17, "F17") == 1) + CHECK; + else + FAIL; +#else + reporterr("F17"); + FAIL; +#endif + +#ifdef XK_L7 + if(test(XK_L7, "L7") == 1) + CHECK; + else + FAIL; +#else + reporterr("L7"); + FAIL; +#endif + +#ifdef XK_F18 + if(test(XK_F18, "F18") == 1) + CHECK; + else + FAIL; +#else + reporterr("F18"); + FAIL; +#endif + +#ifdef XK_L8 + if(test(XK_L8, "L8") == 1) + CHECK; + else + FAIL; +#else + reporterr("L8"); + FAIL; +#endif + +#ifdef XK_F19 + if(test(XK_F19, "F19") == 1) + CHECK; + else + FAIL; +#else + reporterr("F19"); + FAIL; +#endif + +#ifdef XK_L9 + if(test(XK_L9, "L9") == 1) + CHECK; + else + FAIL; +#else + reporterr("L9"); + FAIL; +#endif + +#ifdef XK_F20 + if(test(XK_F20, "F20") == 1) + CHECK; + else + FAIL; +#else + reporterr("F20"); + FAIL; +#endif + +#ifdef XK_L10 + if(test(XK_L10, "L10") == 1) + CHECK; + else + FAIL; +#else + reporterr("L10"); + FAIL; +#endif + +#ifdef XK_F21 + if(test(XK_F21, "F21") == 1) + CHECK; + else + FAIL; +#else + reporterr("F21"); + FAIL; +#endif + +#ifdef XK_R1 + if(test(XK_R1, "R1") == 1) + CHECK; + else + FAIL; +#else + reporterr("R1"); + FAIL; +#endif + +#ifdef XK_F22 + if(test(XK_F22, "F22") == 1) + CHECK; + else + FAIL; +#else + reporterr("F22"); + FAIL; +#endif + +#ifdef XK_R2 + if(test(XK_R2, "R2") == 1) + CHECK; + else + FAIL; +#else + reporterr("R2"); + FAIL; +#endif + +#ifdef XK_F23 + if(test(XK_F23, "F23") == 1) + CHECK; + else + FAIL; +#else + reporterr("F23"); + FAIL; +#endif + +#ifdef XK_R3 + if(test(XK_R3, "R3") == 1) + CHECK; + else + FAIL; +#else + reporterr("R3"); + FAIL; +#endif + +#ifdef XK_F24 + if(test(XK_F24, "F24") == 1) + CHECK; + else + FAIL; +#else + reporterr("F24"); + FAIL; +#endif + +#ifdef XK_R4 + if(test(XK_R4, "R4") == 1) + CHECK; + else + FAIL; +#else + reporterr("R4"); + FAIL; +#endif + +#ifdef XK_F25 + if(test(XK_F25, "F25") == 1) + CHECK; + else + FAIL; +#else + reporterr("F25"); + FAIL; +#endif + +#ifdef XK_R5 + if(test(XK_R5, "R5") == 1) + CHECK; + else + FAIL; +#else + reporterr("R5"); + FAIL; +#endif + +#ifdef XK_F26 + if(test(XK_F26, "F26") == 1) + CHECK; + else + FAIL; +#else + reporterr("F26"); + FAIL; +#endif + +#ifdef XK_R6 + if(test(XK_R6, "R6") == 1) + CHECK; + else + FAIL; +#else + reporterr("R6"); + FAIL; +#endif + +#ifdef XK_F27 + if(test(XK_F27, "F27") == 1) + CHECK; + else + FAIL; +#else + reporterr("F27"); + FAIL; +#endif + +#ifdef XK_R7 + if(test(XK_R7, "R7") == 1) + CHECK; + else + FAIL; +#else + reporterr("R7"); + FAIL; +#endif + +#ifdef XK_F28 + if(test(XK_F28, "F28") == 1) + CHECK; + else + FAIL; +#else + reporterr("F28"); + FAIL; +#endif + +#ifdef XK_R8 + if(test(XK_R8, "R8") == 1) + CHECK; + else + FAIL; +#else + reporterr("R8"); + FAIL; +#endif + +#ifdef XK_F29 + if(test(XK_F29, "F29") == 1) + CHECK; + else + FAIL; +#else + reporterr("F29"); + FAIL; +#endif + +#ifdef XK_R9 + if(test(XK_R9, "R9") == 1) + CHECK; + else + FAIL; +#else + reporterr("R9"); + FAIL; +#endif + +#ifdef XK_F30 + if(test(XK_F30, "F30") == 1) + CHECK; + else + FAIL; +#else + reporterr("F30"); + FAIL; +#endif + +#ifdef XK_R10 + if(test(XK_R10, "R10") == 1) + CHECK; + else + FAIL; +#else + reporterr("R10"); + FAIL; +#endif + +#ifdef XK_F31 + if(test(XK_F31, "F31") == 1) + CHECK; + else + FAIL; +#else + reporterr("F31"); + FAIL; +#endif + +#ifdef XK_R11 + if(test(XK_R11, "R11") == 1) + CHECK; + else + FAIL; +#else + reporterr("R11"); + FAIL; +#endif + +#ifdef XK_F32 + if(test(XK_F32, "F32") == 1) + CHECK; + else + FAIL; +#else + reporterr("F32"); + FAIL; +#endif + +#ifdef XK_R12 + if(test(XK_R12, "R12") == 1) + CHECK; + else + FAIL; +#else + reporterr("R12"); + FAIL; +#endif + +#ifdef XK_F33 + if(test(XK_F33, "F33") == 1) + CHECK; + else + FAIL; +#else + reporterr("F33"); + FAIL; +#endif + +#ifdef XK_R13 + if(test(XK_R13, "R13") == 1) + CHECK; + else + FAIL; +#else + reporterr("R13"); + FAIL; +#endif + +#ifdef XK_F34 + if(test(XK_F34, "F34") == 1) + CHECK; + else + FAIL; +#else + reporterr("F34"); + FAIL; +#endif + +#ifdef XK_R14 + if(test(XK_R14, "R14") == 1) + CHECK; + else + FAIL; +#else + reporterr("R14"); + FAIL; +#endif + +#ifdef XK_F35 + if(test(XK_F35, "F35") == 1) + CHECK; + else + FAIL; +#else + reporterr("F35"); + FAIL; +#endif + +#ifdef XK_R15 + if(test(XK_R15, "R15") == 1) + CHECK; + else + FAIL; +#else + reporterr("R15"); + FAIL; +#endif + +#ifdef XK_Shift_L + if(test(XK_Shift_L, "Shift_L") == 1) + CHECK; + else + FAIL; +#else + reporterr("Shift_L"); + FAIL; +#endif + +#ifdef XK_Shift_R + if(test(XK_Shift_R, "Shift_R") == 1) + CHECK; + else + FAIL; +#else + reporterr("Shift_R"); + FAIL; +#endif + +#ifdef XK_Control_L + if(test(XK_Control_L, "Control_L") == 1) + CHECK; + else + FAIL; +#else + reporterr("Control_L"); + FAIL; +#endif + +#ifdef XK_Control_R + if(test(XK_Control_R, "Control_R") == 1) + CHECK; + else + FAIL; +#else + reporterr("Control_R"); + FAIL; +#endif + +#ifdef XK_Caps_Lock + if(test(XK_Caps_Lock, "Caps_Lock") == 1) + CHECK; + else + FAIL; +#else + reporterr("Caps_Lock"); + FAIL; +#endif + +#ifdef XK_Shift_Lock + if(test(XK_Shift_Lock, "Shift_Lock") == 1) + CHECK; + else + FAIL; +#else + reporterr("Shift_Lock"); + FAIL; +#endif + +#ifdef XK_Meta_L + if(test(XK_Meta_L, "Meta_L") == 1) + CHECK; + else + FAIL; +#else + reporterr("Meta_L"); + FAIL; +#endif + +#ifdef XK_Meta_R + if(test(XK_Meta_R, "Meta_R") == 1) + CHECK; + else + FAIL; +#else + reporterr("Meta_R"); + FAIL; +#endif + +#ifdef XK_Alt_L + if(test(XK_Alt_L, "Alt_L") == 1) + CHECK; + else + FAIL; +#else + reporterr("Alt_L"); + FAIL; +#endif + +#ifdef XK_Alt_R + if(test(XK_Alt_R, "Alt_R") == 1) + CHECK; + else + FAIL; +#else + reporterr("Alt_R"); + FAIL; +#endif + +#ifdef XK_Super_L + if(test(XK_Super_L, "Super_L") == 1) + CHECK; + else + FAIL; +#else + reporterr("Super_L"); + FAIL; +#endif + +#ifdef XK_Super_R + if(test(XK_Super_R, "Super_R") == 1) + CHECK; + else + FAIL; +#else + reporterr("Super_R"); + FAIL; +#endif + +#ifdef XK_Hyper_L + if(test(XK_Hyper_L, "Hyper_L") == 1) + CHECK; + else + FAIL; +#else + reporterr("Hyper_L"); + FAIL; +#endif + +#ifdef XK_Hyper_R + if(test(XK_Hyper_R, "Hyper_R") == 1) + CHECK; + else + FAIL; +#else + reporterr("Hyper_R"); + FAIL; +#endif + +#ifdef XK_Delete + if(test(XK_Delete, "Delete") == 1) + CHECK; + else + FAIL; +#else + reporterr("Delete"); + FAIL; +#endif + + CHECKPASS(148); +} diff --git a/xts5/Xopen/XKeysymToKeycode/TestP.c b/xts5/Xopen/XKeysymToKeycode/TestP.c new file mode 100644 index 00000000..e85d84eb --- /dev/null +++ b/xts5/Xopen/XKeysymToKeycode/TestP.c @@ -0,0 +1,979 @@ +/* +Copyright (c) 2005 X.Org Foundation L.L.C. + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies +of the Software, and to permit persons to whom the Software is furnished to do +so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. +*/ +/* +* $Header: /cvs/xtest/xtest/xts5/tset/Xopen/XKeysymToKeycode/TestP.c,v 1.2 2005-11-03 08:44:00 jmichael Exp $ +* +* Project: VSW5 +* +* File: xts5/tset/Xopen/XKeysymToKeycode/TestP.c +* +* Description: +* Tests for XKeysymToKeycode() +* +* Modifications: +* $Log: TestP.c,v $ +* Revision 1.2 2005-11-03 08:44:00 jmichael +* clean up all vsw5 paths to use xts5 instead. +* +* Revision 1.1.1.2 2005/04/15 14:05:40 anderson +* Reimport of the base with the legal name in the copyright fixed. +* +* Revision 8.0 1998/12/23 23:35:49 mar +* Branch point for Release 5.0.2 +* +* Revision 7.0 1998/10/30 22:58:30 mar +* Branch point for Release 5.0.2b1 +* +* Revision 6.0 1998/03/02 05:27:02 tbr +* Branch point for Release 5.0.1 +* +* Revision 5.0 1998/01/26 03:23:36 tbr +* Branch point for Release 5.0.1b1 +* +* Revision 4.1 1996/05/09 21:17:34 andy +* Fixed X includes +* +* Revision 4.0 1995/12/15 09:14:19 tbr +* Branch point for Release 5.0.0 +* +* Revision 3.1 1995/12/15 01:17:42 andy +* Prepare for GA Release +* +*/ +/* + * SCCS: @(#) TestP.c Rel 1.1 (11/28/91) + * + * UniSoft Ltd., London, England + * + * (C) Copyright 1991 X/Open Company Limited + * + * All rights reserved. No part of this source code may be reproduced, + * stored in a retrieval system, or transmitted, in any form or by any + * means, electronic, mechanical, photocopying, recording or otherwise, + * except as stated in the end-user licence agreement, without the prior + * permission of the copyright owners. + * + * X/Open and the 'X' symbol are trademarks of X/Open Company Limited in + * the UK and other countries. + */ + +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif + +#include <stdlib.h> +#include "xtest.h" +#include "X11/Xlib.h" +#include "X11/Xutil.h" +#include "X11/Xresource.h" +#include "tet_api.h" +#include "xtestlib.h" +#include "pixval.h" + +extern char *TestName; +extern Display *Dsp; + +int minkc; +int maxkc; +int keysyms_per_keycode; + +static int +test(symbol, str) +KeySym symbol; +char *str; +{ +KeyCode kycd; +int mod; + + kycd = XKeysymToKeycode(Dsp, symbol); + if(kycd == 0) { + trace("XKeysymToKeycode() returned 0 for KeySym \"XK_%s\".", str); + return(1); + } + + if(kycd > maxkc || kycd < minkc) { + report("XKeysymToKeycode() returned invalid keycode value %d for KeySym \"XK_%s\".", kycd, str); + return(0); + } + + for(mod = 0; mod < keysyms_per_keycode; mod++) { + if( symbol == XKeycodeToKeysym(Dsp, kycd, mod)) { + trace("KeySym \"XK_%s\", keycode %d, mod %d", + str, kycd, mod); + return(1); + } + } + + report("The keycode value %d for KeySym \"XK_%s\"", kycd, str); + report("never returns that KeySym when using XKeycodeToKeysym()"); + return(0); +} + +static void +reporterr(s) +char *s; +{ + report("Symbol XK_\"%s\" is not defined.", s); +} +#define XK_PUBLISHING +#include <X11/keysymdef.h> +#undef XK_PUBLISHING + +kysymtcdP() +{ +int pass = 0, fail = 0; + + XDisplayKeycodes(Dsp, &minkc, &maxkc); + XGetKeyboardMapping(Dsp, (KeyCode)minkc, 1, &keysyms_per_keycode); + +#ifdef XK_emspace + if(test(XK_emspace, "emspace") == 1) + CHECK; + else + FAIL; +#else + reporterr("emspace"); + FAIL; +#endif + +#ifdef XK_enspace + if(test(XK_enspace, "enspace") == 1) + CHECK; + else + FAIL; +#else + reporterr("enspace"); + FAIL; +#endif + +#ifdef XK_em3space + if(test(XK_em3space, "em3space") == 1) + CHECK; + else + FAIL; +#else + reporterr("em3space"); + FAIL; +#endif + +#ifdef XK_em4space + if(test(XK_em4space, "em4space") == 1) + CHECK; + else + FAIL; +#else + reporterr("em4space"); + FAIL; +#endif + +#ifdef XK_digitspace + if(test(XK_digitspace, "digitspace") == 1) + CHECK; + else + FAIL; +#else + reporterr("digitspace"); + FAIL; +#endif + +#ifdef XK_punctspace + if(test(XK_punctspace, "punctspace") == 1) + CHECK; + else + FAIL; +#else + reporterr("punctspace"); + FAIL; +#endif + +#ifdef XK_thinspace + if(test(XK_thinspace, "thinspace") == 1) + CHECK; + else + FAIL; +#else + reporterr("thinspace"); + FAIL; +#endif + +#ifdef XK_hairspace + if(test(XK_hairspace, "hairspace") == 1) + CHECK; + else + FAIL; +#else + reporterr("hairspace"); + FAIL; +#endif + +#ifdef XK_emdash + if(test(XK_emdash, "emdash") == 1) + CHECK; + else + FAIL; +#else + reporterr("emdash"); + FAIL; +#endif + +#ifdef XK_endash + if(test(XK_endash, "endash") == 1) + CHECK; + else + FAIL; +#else + reporterr("endash"); + FAIL; +#endif + +#ifdef XK_signifblank + if(test(XK_signifblank, "signifblank") == 1) + CHECK; + else + FAIL; +#else + reporterr("signifblank"); + FAIL; +#endif + +#ifdef XK_ellipsis + if(test(XK_ellipsis, "ellipsis") == 1) + CHECK; + else + FAIL; +#else + reporterr("ellipsis"); + FAIL; +#endif + +#ifdef XK_doubbaselinedot + if(test(XK_doubbaselinedot, "doubbaselinedot") == 1) + CHECK; + else + FAIL; +#else + reporterr("doubbaselinedot"); + FAIL; +#endif + +#ifdef XK_onethird + if(test(XK_onethird, "onethird") == 1) + CHECK; + else + FAIL; +#else + reporterr("onethird"); + FAIL; +#endif + +#ifdef XK_twothirds + if(test(XK_twothirds, "twothirds") == 1) + CHECK; + else + FAIL; +#else + reporterr("twothirds"); + FAIL; +#endif + +#ifdef XK_onefifth + if(test(XK_onefifth, "onefifth") == 1) + CHECK; + else + FAIL; +#else + reporterr("onefifth"); + FAIL; +#endif + +#ifdef XK_twofifths + if(test(XK_twofifths, "twofifths") == 1) + CHECK; + else + FAIL; +#else + reporterr("twofifths"); + FAIL; +#endif + +#ifdef XK_threefifths + if(test(XK_threefifths, "threefifths") == 1) + CHECK; + else + FAIL; +#else + reporterr("threefifths"); + FAIL; +#endif + +#ifdef XK_fourfifths + if(test(XK_fourfifths, "fourfifths") == 1) + CHECK; + else + FAIL; +#else + reporterr("fourfifths"); + FAIL; +#endif + +#ifdef XK_onesixth + if(test(XK_onesixth, "onesixth") == 1) + CHECK; + else + FAIL; +#else + reporterr("onesixth"); + FAIL; +#endif + +#ifdef XK_fivesixths + if(test(XK_fivesixths, "fivesixths") == 1) + CHECK; + else + FAIL; +#else + reporterr("fivesixths"); + FAIL; +#endif + +#ifdef XK_careof + if(test(XK_careof, "careof") == 1) + CHECK; + else + FAIL; +#else + reporterr("careof"); + FAIL; +#endif + +#ifdef XK_figdash + if(test(XK_figdash, "figdash") == 1) + CHECK; + else + FAIL; +#else + reporterr("figdash"); + FAIL; +#endif + +#ifdef XK_leftanglebracket + if(test(XK_leftanglebracket, "leftanglebracket") == 1) + CHECK; + else + FAIL; +#else + reporterr("leftanglebracket"); + FAIL; +#endif + +#ifdef XK_decimalpoint + if(test(XK_decimalpoint, "decimalpoint") == 1) + CHECK; + else + FAIL; +#else + reporterr("decimalpoint"); + FAIL; +#endif + +#ifdef XK_rightanglebracket + if(test(XK_rightanglebracket, "rightanglebracket") == 1) + CHECK; + else + FAIL; +#else + reporterr("rightanglebracket"); + FAIL; +#endif + +#ifdef XK_marker + if(test(XK_marker, "marker") == 1) + CHECK; + else + FAIL; +#else + reporterr("marker"); + FAIL; +#endif + +#ifdef XK_oneeighth + if(test(XK_oneeighth, "oneeighth") == 1) + CHECK; + else + FAIL; +#else + reporterr("oneeighth"); + FAIL; +#endif + +#ifdef XK_threeeighths + if(test(XK_threeeighths, "threeeighths") == 1) + CHECK; + else + FAIL; +#else + reporterr("threeeighths"); + FAIL; +#endif + +#ifdef XK_fiveeighths + if(test(XK_fiveeighths, "fiveeighths") == 1) + CHECK; + else + FAIL; +#else + reporterr("fiveeighths"); + FAIL; +#endif + +#ifdef XK_seveneighths + if(test(XK_seveneighths, "seveneighths") == 1) + CHECK; + else + FAIL; +#else + reporterr("seveneighths"); + FAIL; +#endif + +#ifdef XK_trademark + if(test(XK_trademark, "trademark") == 1) + CHECK; + else + FAIL; +#else + reporterr("trademark"); + FAIL; +#endif + +#ifdef XK_signaturemark + if(test(XK_signaturemark, "signaturemark") == 1) + CHECK; + else + FAIL; +#else + reporterr("signaturemark"); + FAIL; +#endif + +#ifdef XK_trademarkincircle + if(test(XK_trademarkincircle, "trademarkincircle") == 1) + CHECK; + else + FAIL; +#else + reporterr("trademarkincircle"); + FAIL; +#endif + +#ifdef XK_leftopentriangle + if(test(XK_leftopentriangle, "leftopentriangle") == 1) + CHECK; + else + FAIL; +#else + reporterr("leftopentriangle"); + FAIL; +#endif + +#ifdef XK_rightopentriangle + if(test(XK_rightopentriangle, "rightopentriangle") == 1) + CHECK; + else + FAIL; +#else + reporterr("rightopentriangle"); + FAIL; +#endif + +#ifdef XK_emopencircle + if(test(XK_emopencircle, "emopencircle") == 1) + CHECK; + else + FAIL; +#else + reporterr("emopencircle"); + FAIL; +#endif + +#ifdef XK_emopenrectangle + if(test(XK_emopenrectangle, "emopenrectangle") == 1) + CHECK; + else + FAIL; +#else + reporterr("emopenrectangle"); + FAIL; +#endif + +#ifdef XK_leftsinglequotemark + if(test(XK_leftsinglequotemark, "leftsinglequotemark") == 1) + CHECK; + else + FAIL; +#else + reporterr("leftsinglequotemark"); + FAIL; +#endif + +#ifdef XK_rightsinglequotemark + if(test(XK_rightsinglequotemark, "rightsinglequotemark") == 1) + CHECK; + else + FAIL; +#else + reporterr("rightsinglequotemark"); + FAIL; +#endif + +#ifdef XK_leftdoublequotemark + if(test(XK_leftdoublequotemark, "leftdoublequotemark") == 1) + CHECK; + else + FAIL; +#else + reporterr("leftdoublequotemark"); + FAIL; +#endif + +#ifdef XK_rightdoublequotemark + if(test(XK_rightdoublequotemark, "rightdoublequotemark") == 1) + CHECK; + else + FAIL; +#else + reporterr("rightdoublequotemark"); + FAIL; +#endif + +#ifdef XK_prescription + if(test(XK_prescription, "prescription") == 1) + CHECK; + else + FAIL; +#else + reporterr("prescription"); + FAIL; +#endif + +#ifdef XK_minutes + if(test(XK_minutes, "minutes") == 1) + CHECK; + else + FAIL; +#else + reporterr("minutes"); + FAIL; +#endif + +#ifdef XK_seconds + if(test(XK_seconds, "seconds") == 1) + CHECK; + else + FAIL; +#else + reporterr("seconds"); + FAIL; +#endif + +#ifdef XK_latincross + if(test(XK_latincross, "latincross") == 1) + CHECK; + else + FAIL; +#else + reporterr("latincross"); + FAIL; +#endif + +#ifdef XK_hexagram + if(test(XK_hexagram, "hexagram") == 1) + CHECK; + else + FAIL; +#else + reporterr("hexagram"); + FAIL; +#endif + +#ifdef XK_filledrectbullet + if(test(XK_filledrectbullet, "filledrectbullet") == 1) + CHECK; + else + FAIL; +#else + reporterr("filledrectbullet"); + FAIL; +#endif + +#ifdef XK_filledlefttribullet + if(test(XK_filledlefttribullet, "filledlefttribullet") == 1) + CHECK; + else + FAIL; +#else + reporterr("filledlefttribullet"); + FAIL; +#endif + +#ifdef XK_filledrighttribullet + if(test(XK_filledrighttribullet, "filledrighttribullet") == 1) + CHECK; + else + FAIL; +#else + reporterr("filledrighttribullet"); + FAIL; +#endif + +#ifdef XK_emfilledcircle + if(test(XK_emfilledcircle, "emfilledcircle") == 1) + CHECK; + else + FAIL; +#else + reporterr("emfilledcircle"); + FAIL; +#endif + +#ifdef XK_emfilledrect + if(test(XK_emfilledrect, "emfilledrect") == 1) + CHECK; + else + FAIL; +#else + reporterr("emfilledrect"); + FAIL; +#endif + +#ifdef XK_enopencircbullet + if(test(XK_enopencircbullet, "enopencircbullet") == 1) + CHECK; + else + FAIL; +#else + reporterr("enopencircbullet"); + FAIL; +#endif + +#ifdef XK_enopensquarebullet + if(test(XK_enopensquarebullet, "enopensquarebullet") == 1) + CHECK; + else + FAIL; +#else + reporterr("enopensquarebullet"); + FAIL; +#endif + +#ifdef XK_openrectbullet + if(test(XK_openrectbullet, "openrectbullet") == 1) + CHECK; + else + FAIL; +#else + reporterr("openrectbullet"); + FAIL; +#endif + +#ifdef XK_opentribulletup + if(test(XK_opentribulletup, "opentribulletup") == 1) + CHECK; + else + FAIL; +#else + reporterr("opentribulletup"); + FAIL; +#endif + +#ifdef XK_opentribulletdown + if(test(XK_opentribulletdown, "opentribulletdown") == 1) + CHECK; + else + FAIL; +#else + reporterr("opentribulletdown"); + FAIL; +#endif + +#ifdef XK_openstar + if(test(XK_openstar, "openstar") == 1) + CHECK; + else + FAIL; +#else + reporterr("openstar"); + FAIL; +#endif + +#ifdef XK_enfilledcircbullet + if(test(XK_enfilledcircbullet, "enfilledcircbullet") == 1) + CHECK; + else + FAIL; +#else + reporterr("enfilledcircbullet"); + FAIL; +#endif + +#ifdef XK_enfilledsqbullet + if(test(XK_enfilledsqbullet, "enfilledsqbullet") == 1) + CHECK; + else + FAIL; +#else + reporterr("enfilledsqbullet"); + FAIL; +#endif + +#ifdef XK_filledtribulletup + if(test(XK_filledtribulletup, "filledtribulletup") == 1) + CHECK; + else + FAIL; +#else + reporterr("filledtribulletup"); + FAIL; +#endif + +#ifdef XK_filledtribulletdown + if(test(XK_filledtribulletdown, "filledtribulletdown") == 1) + CHECK; + else + FAIL; +#else + reporterr("filledtribulletdown"); + FAIL; +#endif + +#ifdef XK_leftpointer + if(test(XK_leftpointer, "leftpointer") == 1) + CHECK; + else + FAIL; +#else + reporterr("leftpointer"); + FAIL; +#endif + +#ifdef XK_rightpointer + if(test(XK_rightpointer, "rightpointer") == 1) + CHECK; + else + FAIL; +#else + reporterr("rightpointer"); + FAIL; +#endif + +#ifdef XK_club + if(test(XK_club, "club") == 1) + CHECK; + else + FAIL; +#else + reporterr("club"); + FAIL; +#endif + +#ifdef XK_diamond + if(test(XK_diamond, "diamond") == 1) + CHECK; + else + FAIL; +#else + reporterr("diamond"); + FAIL; +#endif + +#ifdef XK_heart + if(test(XK_heart, "heart") == 1) + CHECK; + else + FAIL; +#else + reporterr("heart"); + FAIL; +#endif + +#ifdef XK_maltesecross + if(test(XK_maltesecross, "maltesecross") == 1) + CHECK; + else + FAIL; +#else + reporterr("maltesecross"); + FAIL; +#endif + +#ifdef XK_dagger + if(test(XK_dagger, "dagger") == 1) + CHECK; + else + FAIL; +#else + reporterr("dagger"); + FAIL; +#endif + +#ifdef XK_doubledagger + if(test(XK_doubledagger, "doubledagger") == 1) + CHECK; + else + FAIL; +#else + reporterr("doubledagger"); + FAIL; +#endif + +#ifdef XK_checkmark + if(test(XK_checkmark, "checkmark") == 1) + CHECK; + else + FAIL; +#else + reporterr("checkmark"); + FAIL; +#endif + +#ifdef XK_ballotcross + if(test(XK_ballotcross, "ballotcross") == 1) + CHECK; + else + FAIL; +#else + reporterr("ballotcross"); + FAIL; +#endif + +#ifdef XK_musicalsharp + if(test(XK_musicalsharp, "musicalsharp") == 1) + CHECK; + else + FAIL; +#else + reporterr("musicalsharp"); + FAIL; +#endif + +#ifdef XK_musicalflat + if(test(XK_musicalflat, "musicalflat") == 1) + CHECK; + else + FAIL; +#else + reporterr("musicalflat"); + FAIL; +#endif + +#ifdef XK_malesymbol + if(test(XK_malesymbol, "malesymbol") == 1) + CHECK; + else + FAIL; +#else + reporterr("malesymbol"); + FAIL; +#endif + +#ifdef XK_femalesymbol + if(test(XK_femalesymbol, "femalesymbol") == 1) + CHECK; + else + FAIL; +#else + reporterr("femalesymbol"); + FAIL; +#endif + +#ifdef XK_telephone + if(test(XK_telephone, "telephone") == 1) + CHECK; + else + FAIL; +#else + reporterr("telephone"); + FAIL; +#endif + +#ifdef XK_telephonerecorder + if(test(XK_telephonerecorder, "telephonerecorder") == 1) + CHECK; + else + FAIL; +#else + reporterr("telephonerecorder"); + FAIL; +#endif + +#ifdef XK_phonographcopyright + if(test(XK_phonographcopyright, "phonographcopyright") == 1) + CHECK; + else + FAIL; +#else + reporterr("phonographcopyright"); + FAIL; +#endif + +#ifdef XK_caret + if(test(XK_caret, "caret") == 1) + CHECK; + else + FAIL; +#else + reporterr("caret"); + FAIL; +#endif + +#ifdef XK_singlelowquotemark + if(test(XK_singlelowquotemark, "singlelowquotemark") == 1) + CHECK; + else + FAIL; +#else + reporterr("singlelowquotemark"); + FAIL; +#endif + +#ifdef XK_doublelowquotemark + if(test(XK_doublelowquotemark, "doublelowquotemark") == 1) + CHECK; + else + FAIL; +#else + reporterr("doublelowquotemark"); + FAIL; +#endif + +#ifdef XK_cursor + if(test(XK_cursor, "cursor") == 1) + CHECK; + else + FAIL; +#else + reporterr("cursor"); + FAIL; +#endif + + CHECKPASS(83); +} diff --git a/xts5/Xopen/XKeysymToKeycode/TestS.c b/xts5/Xopen/XKeysymToKeycode/TestS.c new file mode 100644 index 00000000..e76378ad --- /dev/null +++ b/xts5/Xopen/XKeysymToKeycode/TestS.c @@ -0,0 +1,389 @@ +/* +Copyright (c) 2005 X.Org Foundation L.L.C. + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies +of the Software, and to permit persons to whom the Software is furnished to do +so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. +*/ +/* +* $Header: /cvs/xtest/xtest/xts5/tset/Xopen/XKeysymToKeycode/TestS.c,v 1.2 2005-11-03 08:44:00 jmichael Exp $ +* +* Project: VSW5 +* +* File: xts5/tset/Xopen/XKeysymToKeycode/TestS.c +* +* Description: +* Tests for XKeysymToKeycode() +* +* Modifications: +* $Log: TestS.c,v $ +* Revision 1.2 2005-11-03 08:44:00 jmichael +* clean up all vsw5 paths to use xts5 instead. +* +* Revision 1.1.1.2 2005/04/15 14:05:40 anderson +* Reimport of the base with the legal name in the copyright fixed. +* +* Revision 8.0 1998/12/23 23:35:49 mar +* Branch point for Release 5.0.2 +* +* Revision 7.0 1998/10/30 22:58:30 mar +* Branch point for Release 5.0.2b1 +* +* Revision 6.0 1998/03/02 05:27:03 tbr +* Branch point for Release 5.0.1 +* +* Revision 5.0 1998/01/26 03:23:36 tbr +* Branch point for Release 5.0.1b1 +* +* Revision 4.1 1996/05/09 21:17:34 andy +* Fixed X includes +* +* Revision 4.0 1995/12/15 09:14:20 tbr +* Branch point for Release 5.0.0 +* +* Revision 3.1 1995/12/15 01:17:43 andy +* Prepare for GA Release +* +*/ +/* + * SCCS: @(#) TestS.c Rel 1.1 (11/28/91) + * + * UniSoft Ltd., London, England + * + * (C) Copyright 1991 X/Open Company Limited + * + * All rights reserved. No part of this source code may be reproduced, + * stored in a retrieval system, or transmitted, in any form or by any + * means, electronic, mechanical, photocopying, recording or otherwise, + * except as stated in the end-user licence agreement, without the prior + * permission of the copyright owners. + * + * X/Open and the 'X' symbol are trademarks of X/Open Company Limited in + * the UK and other countries. + */ + +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif + +#include <stdlib.h> +#include "xtest.h" +#include "X11/Xlib.h" +#include "X11/Xutil.h" +#include "X11/Xresource.h" +#include "tet_api.h" +#include "xtestlib.h" +#include "pixval.h" + +extern char *TestName; +extern Display *Dsp; + +int minkc; +int maxkc; +int keysyms_per_keycode; + +static int +test(symbol, str) +KeySym symbol; +char *str; +{ +KeyCode kycd; +int mod; + + kycd = XKeysymToKeycode(Dsp, symbol); + if(kycd == 0) { + trace("XKeysymToKeycode() returned 0 for KeySym \"XK_%s\".", str); + return(1); + } + + if(kycd > maxkc || kycd < minkc) { + report("XKeysymToKeycode() returned invalid keycode value %d for KeySym \"XK_%s\".", kycd, str); + return(0); + } + + for(mod = 0; mod < keysyms_per_keycode; mod++) { + if( symbol == XKeycodeToKeysym(Dsp, kycd, mod)) { + trace("KeySym \"XK_%s\", keycode %d, mod %d", + str, kycd, mod); + return(1); + } + } + + report("The keycode value %d for KeySym \"XK_%s\"", kycd, str); + report("never returns that KeySym when using XKeycodeToKeysym()"); + return(0); +} + +static void +reporterr(s) +char *s; +{ + report("Symbol XK_\"%s\" is not defined.", s); +} +#define XK_SPECIAL +#include <X11/keysymdef.h> +#undef XK_SPECIAL + +kysymtcdS() +{ +int pass = 0, fail = 0; + + XDisplayKeycodes(Dsp, &minkc, &maxkc); + XGetKeyboardMapping(Dsp, (KeyCode)minkc, 1, &keysyms_per_keycode); + +#ifdef XK_blank + if(test(XK_blank, "blank") == 1) + CHECK; + else + FAIL; +#else + reporterr("blank"); + FAIL; +#endif + +#ifdef XK_soliddiamond + if(test(XK_soliddiamond, "soliddiamond") == 1) + CHECK; + else + FAIL; +#else + reporterr("soliddiamond"); + FAIL; +#endif + +#ifdef XK_checkerboard + if(test(XK_checkerboard, "checkerboard") == 1) + CHECK; + else + FAIL; +#else + reporterr("checkerboard"); + FAIL; +#endif + +#ifdef XK_ht + if(test(XK_ht, "ht") == 1) + CHECK; + else + FAIL; +#else + reporterr("ht"); + FAIL; +#endif + +#ifdef XK_ff + if(test(XK_ff, "ff") == 1) + CHECK; + else + FAIL; +#else + reporterr("ff"); + FAIL; +#endif + +#ifdef XK_cr + if(test(XK_cr, "cr") == 1) + CHECK; + else + FAIL; +#else + reporterr("cr"); + FAIL; +#endif + +#ifdef XK_lf + if(test(XK_lf, "lf") == 1) + CHECK; + else + FAIL; +#else + reporterr("lf"); + FAIL; +#endif + +#ifdef XK_nl + if(test(XK_nl, "nl") == 1) + CHECK; + else + FAIL; +#else + reporterr("nl"); + FAIL; +#endif + +#ifdef XK_vt + if(test(XK_vt, "vt") == 1) + CHECK; + else + FAIL; +#else + reporterr("vt"); + FAIL; +#endif + +#ifdef XK_lowrightcorner + if(test(XK_lowrightcorner, "lowrightcorner") == 1) + CHECK; + else + FAIL; +#else + reporterr("lowrightcorner"); + FAIL; +#endif + +#ifdef XK_uprightcorner + if(test(XK_uprightcorner, "uprightcorner") == 1) + CHECK; + else + FAIL; +#else + reporterr("uprightcorner"); + FAIL; +#endif + +#ifdef XK_upleftcorner + if(test(XK_upleftcorner, "upleftcorner") == 1) + CHECK; + else + FAIL; +#else + reporterr("upleftcorner"); + FAIL; +#endif + +#ifdef XK_lowleftcorner + if(test(XK_lowleftcorner, "lowleftcorner") == 1) + CHECK; + else + FAIL; +#else + reporterr("lowleftcorner"); + FAIL; +#endif + +#ifdef XK_crossinglines + if(test(XK_crossinglines, "crossinglines") == 1) + CHECK; + else + FAIL; +#else + reporterr("crossinglines"); + FAIL; +#endif + +#ifdef XK_horizlinescan1 + if(test(XK_horizlinescan1, "horizlinescan1") == 1) + CHECK; + else + FAIL; +#else + reporterr("horizlinescan1"); + FAIL; +#endif + +#ifdef XK_horizlinescan3 + if(test(XK_horizlinescan3, "horizlinescan3") == 1) + CHECK; + else + FAIL; +#else + reporterr("horizlinescan3"); + FAIL; +#endif + +#ifdef XK_horizlinescan5 + if(test(XK_horizlinescan5, "horizlinescan5") == 1) + CHECK; + else + FAIL; +#else + reporterr("horizlinescan5"); + FAIL; +#endif + +#ifdef XK_horizlinescan7 + if(test(XK_horizlinescan7, "horizlinescan7") == 1) + CHECK; + else + FAIL; +#else + reporterr("horizlinescan7"); + FAIL; +#endif + +#ifdef XK_horizlinescan9 + if(test(XK_horizlinescan9, "horizlinescan9") == 1) + CHECK; + else + FAIL; +#else + reporterr("horizlinescan9"); + FAIL; +#endif + +#ifdef XK_leftt + if(test(XK_leftt, "leftt") == 1) + CHECK; + else + FAIL; +#else + reporterr("leftt"); + FAIL; +#endif + +#ifdef XK_rightt + if(test(XK_rightt, "rightt") == 1) + CHECK; + else + FAIL; +#else + reporterr("rightt"); + FAIL; +#endif + +#ifdef XK_bott + if(test(XK_bott, "bott") == 1) + CHECK; + else + FAIL; +#else + reporterr("bott"); + FAIL; +#endif + +#ifdef XK_topt + if(test(XK_topt, "topt") == 1) + CHECK; + else + FAIL; +#else + reporterr("topt"); + FAIL; +#endif + +#ifdef XK_vertbar + if(test(XK_vertbar, "vertbar") == 1) + CHECK; + else + FAIL; +#else + reporterr("vertbar"); + FAIL; +#endif + + CHECKPASS(24); +} diff --git a/xts5/Xopen/XKeysymToKeycode/TestT.c b/xts5/Xopen/XKeysymToKeycode/TestT.c new file mode 100644 index 00000000..6dfa4f1a --- /dev/null +++ b/xts5/Xopen/XKeysymToKeycode/TestT.c @@ -0,0 +1,639 @@ +/* +Copyright (c) 2005 X.Org Foundation L.L.C. + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies +of the Software, and to permit persons to whom the Software is furnished to do +so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. +*/ +/* +* $Header: /cvs/xtest/xtest/xts5/tset/Xopen/XKeysymToKeycode/TestT.c,v 1.2 2005-11-03 08:44:00 jmichael Exp $ +* +* Project: VSW5 +* +* File: xts5/tset/Xopen/XKeysymToKeycode/TestT.c +* +* Description: +* Tests for XKeysymToKeycode() +* +* Modifications: +* $Log: TestT.c,v $ +* Revision 1.2 2005-11-03 08:44:00 jmichael +* clean up all vsw5 paths to use xts5 instead. +* +* Revision 1.1.1.2 2005/04/15 14:05:40 anderson +* Reimport of the base with the legal name in the copyright fixed. +* +* Revision 8.0 1998/12/23 23:35:50 mar +* Branch point for Release 5.0.2 +* +* Revision 7.0 1998/10/30 22:58:31 mar +* Branch point for Release 5.0.2b1 +* +* Revision 6.0 1998/03/02 05:27:03 tbr +* Branch point for Release 5.0.1 +* +* Revision 5.0 1998/01/26 03:23:37 tbr +* Branch point for Release 5.0.1b1 +* +* Revision 4.1 1996/05/09 21:17:34 andy +* Fixed X includes +* +* Revision 4.0 1995/12/15 09:14:22 tbr +* Branch point for Release 5.0.0 +* +* Revision 3.1 1995/12/15 01:17:44 andy +* Prepare for GA Release +* +*/ +/* + * SCCS: @(#) TestT.c Rel 1.1 (11/28/91) + * + * UniSoft Ltd., London, England + * + * (C) Copyright 1991 X/Open Company Limited + * + * All rights reserved. No part of this source code may be reproduced, + * stored in a retrieval system, or transmitted, in any form or by any + * means, electronic, mechanical, photocopying, recording or otherwise, + * except as stated in the end-user licence agreement, without the prior + * permission of the copyright owners. + * + * X/Open and the 'X' symbol are trademarks of X/Open Company Limited in + * the UK and other countries. + */ + +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif + +#include <stdlib.h> +#include "xtest.h" +#include "X11/Xlib.h" +#include "X11/Xutil.h" +#include "X11/Xresource.h" +#include "tet_api.h" +#include "xtestlib.h" +#include "pixval.h" + +extern char *TestName; +extern Display *Dsp; + +int minkc; +int maxkc; +int keysyms_per_keycode; + +static int +test(symbol, str) +KeySym symbol; +char *str; +{ +KeyCode kycd; +int mod; + + kycd = XKeysymToKeycode(Dsp, symbol); + if(kycd == 0) { + trace("XKeysymToKeycode() returned 0 for KeySym \"XK_%s\".", str); + return(1); + } + + if(kycd > maxkc || kycd < minkc) { + report("XKeysymToKeycode() returned invalid keycode value %d for KeySym \"XK_%s\".", kycd, str); + return(0); + } + + for(mod = 0; mod < keysyms_per_keycode; mod++) { + if( symbol == XKeycodeToKeysym(Dsp, kycd, mod)) { + trace("KeySym \"XK_%s\", keycode %d, mod %d", + str, kycd, mod); + return(1); + } + } + + report("The keycode value %d for KeySym \"XK_%s\"", kycd, str); + report("never returns that KeySym when using XKeycodeToKeysym()"); + return(0); +} + +static void +reporterr(s) +char *s; +{ + report("Symbol XK_\"%s\" is not defined.", s); +} +#define XK_TECHNICAL +#include <X11/keysymdef.h> +#undef XK_TECHNICAL + +kysymtcdT() +{ +int pass = 0, fail = 0; + + XDisplayKeycodes(Dsp, &minkc, &maxkc); + XGetKeyboardMapping(Dsp, (KeyCode)minkc, 1, &keysyms_per_keycode); + +#ifdef XK_leftradical + if(test(XK_leftradical, "leftradical") == 1) + CHECK; + else + FAIL; +#else + reporterr("leftradical"); + FAIL; +#endif + +#ifdef XK_topleftradical + if(test(XK_topleftradical, "topleftradical") == 1) + CHECK; + else + FAIL; +#else + reporterr("topleftradical"); + FAIL; +#endif + +#ifdef XK_horizconnector + if(test(XK_horizconnector, "horizconnector") == 1) + CHECK; + else + FAIL; +#else + reporterr("horizconnector"); + FAIL; +#endif + +#ifdef XK_topintegral + if(test(XK_topintegral, "topintegral") == 1) + CHECK; + else + FAIL; +#else + reporterr("topintegral"); + FAIL; +#endif + +#ifdef XK_botintegral + if(test(XK_botintegral, "botintegral") == 1) + CHECK; + else + FAIL; +#else + reporterr("botintegral"); + FAIL; +#endif + +#ifdef XK_vertconnector + if(test(XK_vertconnector, "vertconnector") == 1) + CHECK; + else + FAIL; +#else + reporterr("vertconnector"); + FAIL; +#endif + +#ifdef XK_topleftsqbracket + if(test(XK_topleftsqbracket, "topleftsqbracket") == 1) + CHECK; + else + FAIL; +#else + reporterr("topleftsqbracket"); + FAIL; +#endif + +#ifdef XK_botleftsqbracket + if(test(XK_botleftsqbracket, "botleftsqbracket") == 1) + CHECK; + else + FAIL; +#else + reporterr("botleftsqbracket"); + FAIL; +#endif + +#ifdef XK_toprightsqbracket + if(test(XK_toprightsqbracket, "toprightsqbracket") == 1) + CHECK; + else + FAIL; +#else + reporterr("toprightsqbracket"); + FAIL; +#endif + +#ifdef XK_botrightsqbracket + if(test(XK_botrightsqbracket, "botrightsqbracket") == 1) + CHECK; + else + FAIL; +#else + reporterr("botrightsqbracket"); + FAIL; +#endif + +#ifdef XK_topleftparens + if(test(XK_topleftparens, "topleftparens") == 1) + CHECK; + else + FAIL; +#else + reporterr("topleftparens"); + FAIL; +#endif + +#ifdef XK_botleftparens + if(test(XK_botleftparens, "botleftparens") == 1) + CHECK; + else + FAIL; +#else + reporterr("botleftparens"); + FAIL; +#endif + +#ifdef XK_toprightparens + if(test(XK_toprightparens, "toprightparens") == 1) + CHECK; + else + FAIL; +#else + reporterr("toprightparens"); + FAIL; +#endif + +#ifdef XK_botrightparens + if(test(XK_botrightparens, "botrightparens") == 1) + CHECK; + else + FAIL; +#else + reporterr("botrightparens"); + FAIL; +#endif + +#ifdef XK_leftmiddlecurlybrace + if(test(XK_leftmiddlecurlybrace, "leftmiddlecurlybrace") == 1) + CHECK; + else + FAIL; +#else + reporterr("leftmiddlecurlybrace"); + FAIL; +#endif + +#ifdef XK_rightmiddlecurlybrace + if(test(XK_rightmiddlecurlybrace, "rightmiddlecurlybrace") == 1) + CHECK; + else + FAIL; +#else + reporterr("rightmiddlecurlybrace"); + FAIL; +#endif + +#ifdef XK_topleftsummation + if(test(XK_topleftsummation, "topleftsummation") == 1) + CHECK; + else + FAIL; +#else + reporterr("topleftsummation"); + FAIL; +#endif + +#ifdef XK_botleftsummation + if(test(XK_botleftsummation, "botleftsummation") == 1) + CHECK; + else + FAIL; +#else + reporterr("botleftsummation"); + FAIL; +#endif + +#ifdef XK_topvertsummationconnector + if(test(XK_topvertsummationconnector, "topvertsummationconnector") == 1) + CHECK; + else + FAIL; +#else + reporterr("topvertsummationconnector"); + FAIL; +#endif + +#ifdef XK_botvertsummationconnector + if(test(XK_botvertsummationconnector, "botvertsummationconnector") == 1) + CHECK; + else + FAIL; +#else + reporterr("botvertsummationconnector"); + FAIL; +#endif + +#ifdef XK_toprightsummation + if(test(XK_toprightsummation, "toprightsummation") == 1) + CHECK; + else + FAIL; +#else + reporterr("toprightsummation"); + FAIL; +#endif + +#ifdef XK_botrightsummation + if(test(XK_botrightsummation, "botrightsummation") == 1) + CHECK; + else + FAIL; +#else + reporterr("botrightsummation"); + FAIL; +#endif + +#ifdef XK_rightmiddlesummation + if(test(XK_rightmiddlesummation, "rightmiddlesummation") == 1) + CHECK; + else + FAIL; +#else + reporterr("rightmiddlesummation"); + FAIL; +#endif + +#ifdef XK_lessthanequal + if(test(XK_lessthanequal, "lessthanequal") == 1) + CHECK; + else + FAIL; +#else + reporterr("lessthanequal"); + FAIL; +#endif + +#ifdef XK_notequal + if(test(XK_notequal, "notequal") == 1) + CHECK; + else + FAIL; +#else + reporterr("notequal"); + FAIL; +#endif + +#ifdef XK_greaterthanequal + if(test(XK_greaterthanequal, "greaterthanequal") == 1) + CHECK; + else + FAIL; +#else + reporterr("greaterthanequal"); + FAIL; +#endif + +#ifdef XK_integral + if(test(XK_integral, "integral") == 1) + CHECK; + else + FAIL; +#else + reporterr("integral"); + FAIL; +#endif + +#ifdef XK_therefore + if(test(XK_therefore, "therefore") == 1) + CHECK; + else + FAIL; +#else + reporterr("therefore"); + FAIL; +#endif + +#ifdef XK_variation + if(test(XK_variation, "variation") == 1) + CHECK; + else + FAIL; +#else + reporterr("variation"); + FAIL; +#endif + +#ifdef XK_infinity + if(test(XK_infinity, "infinity") == 1) + CHECK; + else + FAIL; +#else + reporterr("infinity"); + FAIL; +#endif + +#ifdef XK_nabla + if(test(XK_nabla, "nabla") == 1) + CHECK; + else + FAIL; +#else + reporterr("nabla"); + FAIL; +#endif + +#ifdef XK_approximate + if(test(XK_approximate, "approximate") == 1) + CHECK; + else + FAIL; +#else + reporterr("approximate"); + FAIL; +#endif + +#ifdef XK_similarequal + if(test(XK_similarequal, "similarequal") == 1) + CHECK; + else + FAIL; +#else + reporterr("similarequal"); + FAIL; +#endif + +#ifdef XK_ifonlyif + if(test(XK_ifonlyif, "ifonlyif") == 1) + CHECK; + else + FAIL; +#else + reporterr("ifonlyif"); + FAIL; +#endif + +#ifdef XK_implies + if(test(XK_implies, "implies") == 1) + CHECK; + else + FAIL; +#else + reporterr("implies"); + FAIL; +#endif + +#ifdef XK_identical + if(test(XK_identical, "identical") == 1) + CHECK; + else + FAIL; +#else + reporterr("identical"); + FAIL; +#endif + +#ifdef XK_radical + if(test(XK_radical, "radical") == 1) + CHECK; + else + FAIL; +#else + reporterr("radical"); + FAIL; +#endif + +#ifdef XK_includedin + if(test(XK_includedin, "includedin") == 1) + CHECK; + else + FAIL; +#else + reporterr("includedin"); + FAIL; +#endif + +#ifdef XK_includes + if(test(XK_includes, "includes") == 1) + CHECK; + else + FAIL; +#else + reporterr("includes"); + FAIL; +#endif + +#ifdef XK_intersection + if(test(XK_intersection, "intersection") == 1) + CHECK; + else + FAIL; +#else + reporterr("intersection"); + FAIL; +#endif + +#ifdef XK_union + if(test(XK_union, "union") == 1) + CHECK; + else + FAIL; +#else + reporterr("union"); + FAIL; +#endif + +#ifdef XK_logicaland + if(test(XK_logicaland, "logicaland") == 1) + CHECK; + else + FAIL; +#else + reporterr("logicaland"); + FAIL; +#endif + +#ifdef XK_logicalor + if(test(XK_logicalor, "logicalor") == 1) + CHECK; + else + FAIL; +#else + reporterr("logicalor"); + FAIL; +#endif + +#ifdef XK_partialderivative + if(test(XK_partialderivative, "partialderivative") == 1) + CHECK; + else + FAIL; +#else + reporterr("partialderivative"); + FAIL; +#endif + +#ifdef XK_function + if(test(XK_function, "function") == 1) + CHECK; + else + FAIL; +#else + reporterr("function"); + FAIL; +#endif + +#ifdef XK_leftarrow + if(test(XK_leftarrow, "leftarrow") == 1) + CHECK; + else + FAIL; +#else + reporterr("leftarrow"); + FAIL; +#endif + +#ifdef XK_uparrow + if(test(XK_uparrow, "uparrow") == 1) + CHECK; + else + FAIL; +#else + reporterr("uparrow"); + FAIL; +#endif + +#ifdef XK_rightarrow + if(test(XK_rightarrow, "rightarrow") == 1) + CHECK; + else + FAIL; +#else + reporterr("rightarrow"); + FAIL; +#endif + +#ifdef XK_downarrow + if(test(XK_downarrow, "downarrow") == 1) + CHECK; + else + FAIL; +#else + reporterr("downarrow"); + FAIL; +#endif + + CHECKPASS(49); +} diff --git a/xts5/Xopen/XKeysymToKeycode/XKeysymToKeycode.m b/xts5/Xopen/XKeysymToKeycode/XKeysymToKeycode.m new file mode 100644 index 00000000..2affb55f --- /dev/null +++ b/xts5/Xopen/XKeysymToKeycode/XKeysymToKeycode.m @@ -0,0 +1,1327 @@ +Copyright (c) 2005 X.Org Foundation L.L.C. + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies +of the Software, and to permit persons to whom the Software is furnished to do +so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. +$Header: /cvs/xtest/xtest/xts5/tset/Xopen/XKeysymToKeycode/XKeysymToKeycode.m,v 1.2 2005-11-03 08:44:00 jmichael Exp $ + +>># Project: VSW5 +>># +>># File: xts5/tset/Xopen/XKeysymToKeycode/XKeysymToKeycode.m +>># +>># Description: +>># Tests for XKeysymToKeycode() +>># +>># Modifications: +>># $Log: kysymtkycd.m,v $ +>># Revision 1.2 2005-11-03 08:44:00 jmichael +>># clean up all vsw5 paths to use xts5 instead. +>># +>># Revision 1.1.1.2 2005/04/15 14:05:40 anderson +>># Reimport of the base with the legal name in the copyright fixed. +>># +>># Revision 8.0 1998/12/23 23:35:51 mar +>># Branch point for Release 5.0.2 +>># +>># Revision 7.0 1998/10/30 22:58:32 mar +>># Branch point for Release 5.0.2b1 +>># +>># Revision 6.0 1998/03/02 05:27:04 tbr +>># Branch point for Release 5.0.1 +>># +>># Revision 5.0 1998/01/26 03:23:38 tbr +>># Branch point for Release 5.0.1b1 +>># +>># Revision 4.0 1995/12/15 09:14:23 tbr +>># Branch point for Release 5.0.0 +>># +>># Revision 3.1 1995/12/15 01:17:48 andy +>># Prepare for GA Release +>># +/* + * SCCS: @(#) kysymtkycd.m Rel 1.5 (11/28/91) + * + * UniSoft Ltd., London, England + * + * (C) Copyright 1991 X/Open Company Limited + * + * All rights reserved. No part of this source code may be reproduced, + * stored in a retrieval system, or transmitted, in any form or by any + * means, electronic, mechanical, photocopying, recording or otherwise, + * except as stated in the end-user licence agreement, without the prior + * permission of the copyright owners. + * + * X/Open and the 'X' symbol are trademarks of X/Open Company Limited in + * the UK and other countries. + */ + +>>TITLE XKeysymToKeycode Xopen +>>CFILES Test1.c Test2.c Test3.c Test4.c TestA.c TestC.c TestG.c TestH.c TestK.c TestL.c TestM.c TestP.c TestS.c TestT.c +>>ASSERTION Good A +When the +.A keysym +argument is a +.S KeySym +in the table which is defined and has code 1, +then a call to xname returns the +.S KeyCode +defined for that +.S KeySym . +.tL "Code" "Value" "Name" +.tL "1" "20" "XK_space" +.tL "1" "21" "XK_exclam" +.tL "1" "22" "XK_quotedbl" +.tL "1" "23" "XK_numbersign" +.tL "1" "24" "XK_dollar" +.tL "1" "25" "XK_percent" +.tL "1" "26" "XK_ampersand" +.tL "1" "27" "XK_apostrophe" +.tL "1" "27" "XK_quoteright" +.tL "1" "28" "XK_parenleft" +.tL "1" "29" "XK_parenright" +.tL "1" "2A" "XK_asterisk" +.tL "1" "2B" "XK_plus" +.tL "1" "2C" "XK_comma" +.tL "1" "2D" "XK_minus" +.tL "1" "2E" "XK_period" +.tL "1" "2F" "XK_slash" +.tL "1" "30" "XK_0" +.tL "1" "31" "XK_1" +.tL "1" "32" "XK_2" +.tL "1" "33" "XK_3" +.tL "1" "34" "XK_4" +.tL "1" "35" "XK_5" +.tL "1" "36" "XK_6" +.tL "1" "37" "XK_7" +.tL "1" "38" "XK_8" +.tL "1" "39" "XK_9" +.tL "1" "3A" "XK_colon" +.tL "1" "3B" "XK_semicolon" +.tL "1" "3C" "XK_less" +.tL "1" "3D" "XK_equal" +.tL "1" "3E" "XK_greater" +.tL "1" "3F" "XK_question" +.tL "1" "40" "XK_at" +.tL "1" "41" "XK_A" +.tL "1" "42" "XK_B" +.tL "1" "43" "XK_C" +.tL "1" "44" "XK_D" +.tL "1" "45" "XK_E" +.tL "1" "46" "XK_F" +.tL "1" "47" "XK_G" +.tL "1" "48" "XK_H" +.tL "1" "49" "XK_I" +.tL "1" "4A" "XK_J" +.tL "1" "4B" "XK_K" +.tL "1" "4C" "XK_L" +.tL "1" "4D" "XK_M" +.tL "1" "4E" "XK_N" +.tL "1" "4F" "XK_O" +.tL "1" "50" "XK_P" +.tL "1" "51" "XK_Q" +.tL "1" "52" "XK_R" +.tL "1" "53" "XK_S" +.tL "1" "54" "XK_T" +.tL "1" "55" "XK_U" +.tL "1" "56" "XK_V" +.tL "1" "57" "XK_W" +.tL "1" "58" "XK_X" +.tL "1" "59" "XK_Y" +.tL "1" "5A" "XK_Z" +.tL "1" "5B" "XK_bracketleft" +.tL "1" "5C" "XK_backslash" +.tL "1" "5D" "XK_bracketright" +.tL "1" "5E" "XK_asciicircum" +.tL "1" "5F" "XK_underscore" +.tL "1" "60" "XK_grave" +.tL "1" "60" "XK_quoteleft" +.tL "1" "61" "XK_a" +.tL "1" "62" "XK_b" +.tL "1" "63" "XK_c" +.tL "1" "64" "XK_d" +.tL "1" "65" "XK_e" +.tL "1" "66" "XK_f" +.tL "1" "67" "XK_g" +.tL "1" "68" "XK_h" +.tL "1" "69" "XK_i" +.tL "1" "6A" "XK_j" +.tL "1" "6B" "XK_k" +.tL "1" "6C" "XK_l" +.tL "1" "6D" "XK_m" +.tL "1" "6E" "XK_n" +.tL "1" "6F" "XK_o" +.tL "1" "70" "XK_p" +.tL "1" "71" "XK_q" +.tL "1" "72" "XK_r" +.tL "1" "73" "XK_s" +.tL "1" "74" "XK_t" +.tL "1" "75" "XK_u" +.tL "1" "76" "XK_v" +.tL "1" "77" "XK_w" +.tL "1" "78" "XK_x" +.tL "1" "79" "XK_y" +.tL "1" "7A" "XK_z" +.tL "1" "7B" "XK_braceleft" +.tL "1" "7C" "XK_bar" +.tL "1" "7D" "XK_braceright" +.tL "1" "7E" "XK_asciitilde" +.tL "1" "A0" "XK_nobreakspace" +.tL "1" "A1" "XK_exclamdown" +.tL "1" "A2" "XK_cent" +.tL "1" "A3" "XK_sterling" +.tL "1" "A4" "XK_currency" +.tL "1" "A5" "XK_yen" +.tL "1" "A6" "XK_brokenbar" +.tL "1" "A7" "XK_section" +.tL "1" "A8" "XK_diaeresis" +.tL "1" "A9" "XK_copyright" +.tL "1" "AA" "XK_ordfeminine" +.tL "1" "AB" "XK_guillemotleft" +.tL "1" "AC" "XK_notsign" +.tL "1" "AD" "XK_hyphen" +.tL "1" "AE" "XK_registered" +.tL "1" "AF" "XK_macron" +.tL "1" "B0" "XK_degree" +.tL "1" "B1" "XK_plusminus" +.tL "1" "B2" "XK_twosuperior" +.tL "1" "B3" "XK_threesuperior" +.tL "1" "B4" "XK_acute" +.tL "1" "B5" "XK_mu" +.tL "1" "B6" "XK_paragraph" +.tL "1" "B7" "XK_periodcentered" +.tL "1" "B8" "XK_cedilla" +.tL "1" "B9" "XK_onesuperior" +.tL "1" "BA" "XK_masculine" +.tL "1" "BB" "XK_guillemotright" +.tL "1" "BC" "XK_onequarter" +.tL "1" "BD" "XK_onehalf" +.tL "1" "BE" "XK_threequarters" +.tL "1" "BF" "XK_questiondown" +.tL "1" "C0" "XK_Agrave" +.tL "1" "C1" "XK_Aacute" +.tL "1" "C2" "XK_Acircumflex" +.tL "1" "C3" "XK_Atilde" +.tL "1" "C4" "XK_Adiaeresis" +.tL "1" "C5" "XK_Aring" +.tL "1" "C6" "XK_AE" +.tL "1" "C7" "XK_Ccedilla" +.tL "1" "C8" "XK_Egrave" +.tL "1" "C9" "XK_Eacute" +.tL "1" "CA" "XK_Ecircumflex" +.tL "1" "CB" "XK_Ediaeresis" +.tL "1" "CC" "XK_Igrave" +.tL "1" "CD" "XK_Iacute" +.tL "1" "CE" "XK_Icircumflex" +.tL "1" "CF" "XK_Idiaeresis" +.tL "1" "D0" "XK_ETH" +.tL "1" "D0" "XK_Eth" +.tL "1" "D1" "XK_Ntilde" +.tL "1" "D2" "XK_Ograve" +.tL "1" "D3" "XK_Oacute" +.tL "1" "D4" "XK_Ocircumflex" +.tL "1" "D5" "XK_Otilde" +.tL "1" "D6" "XK_Odiaeresis" +.tL "1" "D7" "XK_multiply" +.tL "1" "D8" "XK_Ooblique" +.tL "1" "D9" "XK_Ugrave" +.tL "1" "DA" "XK_Uacute" +.tL "1" "DB" "XK_Ucircumflex" +.tL "1" "DC" "XK_Udiaeresis" +.tL "1" "DD" "XK_Yacute" +.tL "1" "DE" "XK_THORN" +.tL "1" "DE" "XK_Thorn" +.tL "1" "DF" "XK_ssharp" +.tL "1" "E0" "XK_agrave" +.tL "1" "E1" "XK_aacute" +.tL "1" "E2" "XK_acircumflex" +.tL "1" "E3" "XK_atilde" +.tL "1" "E4" "XK_adiaeresis" +.tL "1" "E5" "XK_aring" +.tL "1" "E6" "XK_ae" +.tL "1" "E7" "XK_ccedilla" +.tL "1" "E8" "XK_egrave" +.tL "1" "E9" "XK_eacute" +.tL "1" "EA" "XK_ecircumflex" +.tL "1" "EB" "XK_ediaeresis" +.tL "1" "EC" "XK_igrave" +.tL "1" "ED" "XK_iacute" +.tL "1" "EE" "XK_icircumflex" +.tL "1" "EF" "XK_idiaeresis" +.tL "1" "F0" "XK_eth" +.tL "1" "F1" "XK_ntilde" +.tL "1" "F2" "XK_ograve" +.tL "1" "F3" "XK_oacute" +.tL "1" "F4" "XK_ocircumflex" +.tL "1" "F5" "XK_otilde" +.tL "1" "F6" "XK_odiaeresis" +.tL "1" "F7" "XK_division" +.tL "1" "F8" "XK_oslash" +.tL "1" "F9" "XK_ugrave" +.tL "1" "FA" "XK_uacute" +.tL "1" "FB" "XK_ucircumflex" +.tL "1" "FC" "XK_udiaeresis" +.tL "1" "FD" "XK_yacute" +.tL "1" "FE" "XK_thorn" +.tL "1" "FF" "XK_ydiaeresis" +>>STRATEGY +For each KeySym in table with code 1: + Call XKeysymToKeycode to obtain the KeyCode defined for that KeySym. + Call XKeycodeToKeysym to obtain each KeySym for that KeyCode. + Verify that one of the KeySyms returned is the original KeySym. +>>CODE + + kysymtcd1(); + +>>ASSERTION Good A +When the +.A keysym +argument is a +.S KeySym +in the table which is defined and has code 2, +then a call to xname returns the +.S KeyCode +defined for that +.S KeySym . +.tL "Code" "Value" "Name" +.tL "2" "1A1" "XK_Aogonek" +.tL "2" "1A2" "XK_breve" +.tL "2" "1A3" "XK_Lstroke" +.tL "2" "1A5" "XK_Lcaron" +.tL "2" "1A6" "XK_Sacute" +.tL "2" "1A9" "XK_Scaron" +.tL "2" "1AA" "XK_Scedilla" +.tL "2" "1AB" "XK_Tcaron" +.tL "2" "1AC" "XK_Zacute" +.tL "2" "1AE" "XK_Zcaron" +.tL "2" "1AF" "XK_Zabovedot" +.tL "2" "1B1" "XK_aogonek" +.tL "2" "1B2" "XK_ogonek" +.tL "2" "1B3" "XK_lstroke" +.tL "2" "1B5" "XK_lcaron" +.tL "2" "1B6" "XK_sacute" +.tL "2" "1B7" "XK_caron" +.tL "2" "1B9" "XK_scaron" +.tL "2" "1BA" "XK_scedilla" +.tL "2" "1BB" "XK_tcaron" +.tL "2" "1BC" "XK_zacute" +.tL "2" "1BD" "XK_doubleacute" +.tL "2" "1BE" "XK_zcaron" +.tL "2" "1BF" "XK_zabovedot" +.tL "2" "1C0" "XK_Racute" +.tL "2" "1C3" "XK_Abreve" +.tL "2" "1C5" "XK_Lacute" +.tL "2" "1C6" "XK_Cacute" +.tL "2" "1C8" "XK_Ccaron" +.tL "2" "1CA" "XK_Eogonek" +.tL "2" "1CC" "XK_Ecaron" +.tL "2" "1CF" "XK_Dcaron" +.tL "2" "1D0" "XK_Dstroke" +.tL "2" "1D1" "XK_Nacute" +.tL "2" "1D2" "XK_Ncaron" +.tL "2" "1D5" "XK_Odoubleacute" +.tL "2" "1D8" "XK_Rcaron" +.tL "2" "1D9" "XK_Uring" +.tL "2" "1DB" "XK_Udoubleacute" +.tL "2" "1DE" "XK_Tcedilla" +.tL "2" "1E0" "XK_racute" +.tL "2" "1E3" "XK_abreve" +.tL "2" "1E5" "XK_lacute" +.tL "2" "1E6" "XK_cacute" +.tL "2" "1E8" "XK_ccaron" +.tL "2" "1EA" "XK_eogonek" +.tL "2" "1EC" "XK_ecaron" +.tL "2" "1EF" "XK_dcaron" +.tL "2" "1F0" "XK_dstroke" +.tL "2" "1F1" "XK_nacute" +.tL "2" "1F2" "XK_ncaron" +.tL "2" "1F5" "XK_odoubleacute" +.tL "2" "1F8" "XK_rcaron" +.tL "2" "1F9" "XK_uring" +.tL "2" "1FB" "XK_udoubleacute" +.tL "2" "1FE" "XK_tcedilla" +.tL "2" "1FF" "XK_abovedot" +>>STRATEGY +For each KeySym in table with code 2: + Call XKeysymToKeycode to obtain the KeyCode defined for that KeySym. + Call XKeycodeToKeysym to obtain each KeySym for that KeyCode. + Verify that one of the KeySyms returned is the original KeySym. +>>CODE + + kysymtcd2(); + +>>ASSERTION Good A +When the +.A keysym +argument is a +.S KeySym +in the table which is defined and has code 3, +then a call to xname returns the +.S KeyCode +defined for that +.S KeySym . +.tL "Code" "Value" "Name" +.tL "3" "2A1" "XK_Hstroke" +.tL "3" "2A6" "XK_Hcircumflex" +.tL "3" "2A9" "XK_Iabovedot" +.tL "3" "2AB" "XK_Gbreve" +.tL "3" "2AC" "XK_Jcircumflex" +.tL "3" "2B1" "XK_hstroke" +.tL "3" "2B6" "XK_hcircumflex" +.tL "3" "2B9" "XK_idotless" +.tL "3" "2BB" "XK_gbreve" +.tL "3" "2BC" "XK_jcircumflex" +.tL "3" "2C5" "XK_Cabovedot" +.tL "3" "2C6" "XK_Ccircumflex" +.tL "3" "2D5" "XK_Gabovedot" +.tL "3" "2D8" "XK_Gcircumflex" +.tL "3" "2DD" "XK_Ubreve" +.tL "3" "2DE" "XK_Scircumflex" +.tL "3" "2E5" "XK_cabovedot" +.tL "3" "2E6" "XK_ccircumflex" +.tL "3" "2F5" "XK_gabovedot" +.tL "3" "2F8" "XK_gcircumflex" +.tL "3" "2FD" "XK_ubreve" +.tL "3" "2FE" "XK_scircumflex" +>>STRATEGY +For each KeySym in table with code 3: + Call XKeysymToKeycode to obtain the KeyCode defined for that KeySym. + Call XKeycodeToKeysym to obtain each KeySym for that KeyCode. + Verify that one of the KeySyms returned is the original KeySym. +>>CODE + + kysymtcd3(); + +>>ASSERTION Good A +When the +.A keysym +argument is a +.S KeySym +in the table which is defined and has code 4, +then a call to xname returns the +.S KeyCode +defined for that +.S KeySym . +.tL "Code" "Value" "Name" +.tL "4" "3A2" "XK_kra" +.tL "4" "3A2" "XK_kappa" +.tL "4" "3A3" "XK_Rcedilla" +.tL "4" "3A5" "XK_Itilde" +.tL "4" "3A6" "XK_Lcedilla" +.tL "4" "3AA" "XK_Emacron" +.tL "4" "3AB" "XK_Gcedilla" +.tL "4" "3AC" "XK_Tslash" +.tL "4" "3B3" "XK_rcedilla" +.tL "4" "3B5" "XK_itilde" +.tL "4" "3B6" "XK_lcedilla" +.tL "4" "3BA" "XK_emacron" +.tL "4" "3BB" "XK_gcedilla" +.tL "4" "3BC" "XK_tslash" +.tL "4" "3BD" "XK_ENG" +.tL "4" "3BF" "XK_eng" +.tL "4" "3C0" "XK_Amacron" +.tL "4" "3C7" "XK_Iogonek" +.tL "4" "3CC" "XK_Eabovedot" +.tL "4" "3CF" "XK_Imacron" +.tL "4" "3D1" "XK_Ncedilla" +.tL "4" "3D2" "XK_Omacron" +.tL "4" "3D3" "XK_Kcedilla" +.tL "4" "3D9" "XK_Uogonek" +.tL "4" "3DD" "XK_Utilde" +.tL "4" "3DE" "XK_Umacron" +.tL "4" "3E0" "XK_amacron" +.tL "4" "3E7" "XK_iogonek" +.tL "4" "3EC" "XK_eabovedot" +.tL "4" "3EF" "XK_imacron" +.tL "4" "3F1" "XK_ncedilla" +.tL "4" "3F2" "XK_omacron" +.tL "4" "3F3" "XK_kcedilla" +.tL "4" "3F9" "XK_uogonek" +.tL "4" "3FD" "XK_utilde" +.tL "4" "3FE" "XK_umacron" +>>STRATEGY +For each KeySym in table with code 4: + Call XKeysymToKeycode to obtain the KeyCode defined for that KeySym. + Call XKeycodeToKeysym to obtain each KeySym for that KeyCode. + Verify that one of the KeySyms returned is the original KeySym. +>>CODE + + kysymtcd4(); + +>>ASSERTION Good A +When the +.A keysym +argument is a +.S KeySym +in the table which is defined and has code A, +then a call to xname returns the +.S KeyCode +defined for that +.S KeySym . +.tL "Code" "Value" "Name" +.tL "A" "5AC" "XK_Arabic_comma" +.tL "A" "5BB" "XK_Arabic_semicolon" +.tL "A" "5BF" "XK_Arabic_question_mark" +.tL "A" "5C1" "XK_Arabic_hamza" +.tL "A" "5C2" "XK_Arabic_maddaonalef" +.tL "A" "5C3" "XK_Arabic_hamzaonalef" +.tL "A" "5C4" "XK_Arabic_hamzaonwaw" +.tL "A" "5C5" "XK_Arabic_hamzaunderalef" +.tL "A" "5C6" "XK_Arabic_hamzaonyeh" +.tL "A" "5C7" "XK_Arabic_alef" +.tL "A" "5C8" "XK_Arabic_beh" +.tL "A" "5C9" "XK_Arabic_tehmarbuta" +.tL "A" "5CA" "XK_Arabic_teh" +.tL "A" "5CB" "XK_Arabic_theh" +.tL "A" "5CC" "XK_Arabic_jeem" +.tL "A" "5CD" "XK_Arabic_hah" +.tL "A" "5CE" "XK_Arabic_khah" +.tL "A" "5CF" "XK_Arabic_dal" +.tL "A" "5D0" "XK_Arabic_thal" +.tL "A" "5D1" "XK_Arabic_ra" +.tL "A" "5D2" "XK_Arabic_zain" +.tL "A" "5D3" "XK_Arabic_seen" +.tL "A" "5D4" "XK_Arabic_sheen" +.tL "A" "5D5" "XK_Arabic_sad" +.tL "A" "5D6" "XK_Arabic_dad" +.tL "A" "5D7" "XK_Arabic_tah" +.tL "A" "5D8" "XK_Arabic_zah" +.tL "A" "5D9" "XK_Arabic_ain" +.tL "A" "5DA" "XK_Arabic_ghain" +.tL "A" "5E0" "XK_Arabic_tatweel" +.tL "A" "5E1" "XK_Arabic_feh" +.tL "A" "5E2" "XK_Arabic_qaf" +.tL "A" "5E3" "XK_Arabic_kaf" +.tL "A" "5E4" "XK_Arabic_lam" +.tL "A" "5E5" "XK_Arabic_meem" +.tL "A" "5E6" "XK_Arabic_noon" +.tL "A" "5E7" "XK_Arabic_ha" +.tL "A" "5E7" "XK_Arabic_heh" +.tL "A" "5E8" "XK_Arabic_waw" +.tL "A" "5E9" "XK_Arabic_alefmaksura" +.tL "A" "5EA" "XK_Arabic_yeh" +.tL "A" "5EB" "XK_Arabic_fathatan" +.tL "A" "5EC" "XK_Arabic_dammatan" +.tL "A" "5ED" "XK_Arabic_kasratan" +.tL "A" "5EE" "XK_Arabic_fatha" +.tL "A" "5EF" "XK_Arabic_damma" +.tL "A" "5F0" "XK_Arabic_kasra" +.tL "A" "5F1" "XK_Arabic_shadda" +.tL "A" "5F2" "XK_Arabic_sukun" +.tL "A" "FF7E" "XK_Arabic_switch" +>>STRATEGY +For each KeySym in table with code A: + Call XKeysymToKeycode to obtain the KeyCode defined for that KeySym. + Call XKeycodeToKeysym to obtain each KeySym for that KeyCode. + Verify that one of the KeySyms returned is the original KeySym. +>>CODE + + kysymtcdA(); + +>>ASSERTION Good A +When the +.A keysym +argument is a +.S KeySym +in the table which is defined and has code C, +then a call to xname returns the +.S KeyCode +defined for that +.S KeySym . +.tL "Code" "Value" "Name" +.tL "C" "6A1" "XK_Serbian_dje" +.tL "C" "6A2" "XK_Macedonia_gje" +.tL "C" "6A3" "XK_Cyrillic_io" +.tL "C" "6A4" "XK_Ukrainian_ie" +.tL "C" "6A4" "XK_Ukranian_je" +.tL "C" "6A5" "XK_Macedonia_dse" +.tL "C" "6A6" "XK_Ukrainian_i" +.tL "C" "6A6" "XK_Ukranian_i" +.tL "C" "6A7" "XK_Ukrainian_yi" +.tL "C" "6A7" "XK_Ukranian_yi" +.tL "C" "6A8" "XK_Cyrillic_je" +.tL "C" "6A8" "XK_Serbian_je" +.tL "C" "6A9" "XK_Cyrillic_lje" +.tL "C" "6A9" "XK_Serbian_lje" +.tL "C" "6AA" "XK_Cyrillic_nje" +.tL "C" "6AA" "XK_Serbian_nje" +.tL "C" "6AB" "XK_Serbian_tshe" +.tL "C" "6AC" "XK_Macedonia_kje" +.tL "C" "6AE" "XK_Byelorussian_shortu" +.tL "C" "6AF" "XK_Cyrillic_dzhe" +.tL "C" "6AF" "XK_Serbian_dze" +.tL "C" "6B0" "XK_numerosign" +.tL "C" "6B1" "XK_Serbian_DJE" +.tL "C" "6B2" "XK_Macedonia_GJE" +.tL "C" "6B3" "XK_Cyrillic_IO" +.tL "C" "6B4" "XK_Ukrainian_IE" +.tL "C" "6B4" "XK_Ukranian_JE" +.tL "C" "6B5" "XK_Macedonia_DSE" +.tL "C" "6B6" "XK_Ukrainian_I" +.tL "C" "6B6" "XK_Ukranian_I" +.tL "C" "6B7" "XK_Ukrainian_YI" +.tL "C" "6B7" "XK_Ukranian_YI" +.tL "C" "6B8" "XK_Cyrillic_JE" +.tL "C" "6B8" "XK_Serbian_JE" +.tL "C" "6B9" "XK_Cyrillic_LJE" +.tL "C" "6B9" "XK_Serbian_LJE" +.tL "C" "6BA" "XK_Cyrillic_NJE" +.tL "C" "6BA" "XK_Serbian_NJE" +.tL "C" "6BB" "XK_Serbian_TSHE" +.tL "C" "6BC" "XK_Macedonia_KJE" +.tL "C" "6BE" "XK_Byelorussian_SHORTU" +.tL "C" "6BF" "XK_Cyrillic_DZHE" +.tL "C" "6BF" "XK_Serbian_DZE" +.tL "C" "6C0" "XK_Cyrillic_yu" +.tL "C" "6C1" "XK_Cyrillic_a" +.tL "C" "6C2" "XK_Cyrillic_be" +.tL "C" "6C3" "XK_Cyrillic_tse" +.tL "C" "6C4" "XK_Cyrillic_de" +.tL "C" "6C5" "XK_Cyrillic_ie" +.tL "C" "6C6" "XK_Cyrillic_ef" +.tL "C" "6C7" "XK_Cyrillic_ghe" +.tL "C" "6C8" "XK_Cyrillic_ha" +.tL "C" "6C9" "XK_Cyrillic_i" +.tL "C" "6CA" "XK_Cyrillic_shorti" +.tL "C" "6CB" "XK_Cyrillic_ka" +.tL "C" "6CC" "XK_Cyrillic_el" +.tL "C" "6CD" "XK_Cyrillic_em" +.tL "C" "6CE" "XK_Cyrillic_en" +.tL "C" "6CF" "XK_Cyrillic_o" +.tL "C" "6D0" "XK_Cyrillic_pe" +.tL "C" "6D1" "XK_Cyrillic_ya" +.tL "C" "6D2" "XK_Cyrillic_er" +.tL "C" "6D3" "XK_Cyrillic_es" +.tL "C" "6D4" "XK_Cyrillic_te" +.tL "C" "6D5" "XK_Cyrillic_u" +.tL "C" "6D6" "XK_Cyrillic_zhe" +.tL "C" "6D7" "XK_Cyrillic_ve" +.tL "C" "6D8" "XK_Cyrillic_softsign" +.tL "C" "6D9" "XK_Cyrillic_yeru" +.tL "C" "6DA" "XK_Cyrillic_ze" +.tL "C" "6DB" "XK_Cyrillic_sha" +.tL "C" "6DC" "XK_Cyrillic_e" +.tL "C" "6DD" "XK_Cyrillic_shcha" +.tL "C" "6DE" "XK_Cyrillic_che" +.tL "C" "6DF" "XK_Cyrillic_hardsign" +.tL "C" "6E0" "XK_Cyrillic_YU" +.tL "C" "6E1" "XK_Cyrillic_A" +.tL "C" "6E2" "XK_Cyrillic_BE" +.tL "C" "6E3" "XK_Cyrillic_TSE" +.tL "C" "6E4" "XK_Cyrillic_DE" +.tL "C" "6E5" "XK_Cyrillic_IE" +.tL "C" "6E6" "XK_Cyrillic_EF" +.tL "C" "6E7" "XK_Cyrillic_GHE" +.tL "C" "6E8" "XK_Cyrillic_HA" +.tL "C" "6E9" "XK_Cyrillic_I" +.tL "C" "6EA" "XK_Cyrillic_SHORTI" +.tL "C" "6EB" "XK_Cyrillic_KA" +.tL "C" "6EC" "XK_Cyrillic_EL" +.tL "C" "6ED" "XK_Cyrillic_EM" +.tL "C" "6EE" "XK_Cyrillic_EN" +.tL "C" "6EF" "XK_Cyrillic_O" +.tL "C" "6F0" "XK_Cyrillic_PE" +.tL "C" "6F1" "XK_Cyrillic_YA" +.tL "C" "6F2" "XK_Cyrillic_ER" +.tL "C" "6F3" "XK_Cyrillic_ES" +.tL "C" "6F4" "XK_Cyrillic_TE" +.tL "C" "6F5" "XK_Cyrillic_U" +.tL "C" "6F6" "XK_Cyrillic_ZHE" +.tL "C" "6F7" "XK_Cyrillic_VE" +.tL "C" "6F8" "XK_Cyrillic_SOFTSIGN" +.tL "C" "6F9" "XK_Cyrillic_YERU" +.tL "C" "6FA" "XK_Cyrillic_ZE" +.tL "C" "6FB" "XK_Cyrillic_SHA" +.tL "C" "6FC" "XK_Cyrillic_E" +.tL "C" "6FD" "XK_Cyrillic_SHCHA" +.tL "C" "6FE" "XK_Cyrillic_CHE" +.tL "C" "6FF" "XK_Cyrillic_HARDSIGN" +>>STRATEGY +For each KeySym in table with code C: + Call XKeysymToKeycode to obtain the KeyCode defined for that KeySym. + Call XKeycodeToKeysym to obtain each KeySym for that KeyCode. + Verify that one of the KeySyms returned is the original KeySym. +>>CODE + + kysymtcdC(); + +>>ASSERTION Good A +When the +.A keysym +argument is a +.S KeySym +in the table which is defined and has code G, +then a call to xname returns the +.S KeyCode +defined for that +.S KeySym . +.tL "Code" "Value" "Name" +.tL "G" "7A1" "XK_Greek_ALPHAaccent" +.tL "G" "7A2" "XK_Greek_EPSILONaccent" +.tL "G" "7A3" "XK_Greek_ETAaccent" +.tL "G" "7A4" "XK_Greek_IOTAaccent" +.tL "G" "7A5" "XK_Greek_IOTAdiaeresis" +.tL "G" "7A7" "XK_Greek_OMICRONaccent" +.tL "G" "7A8" "XK_Greek_UPSILONaccent" +.tL "G" "7A9" "XK_Greek_UPSILONdieresis" +.tL "G" "7AB" "XK_Greek_OMEGAaccent" +.tL "G" "7AE" "XK_Greek_accentdieresis" +.tL "G" "7AF" "XK_Greek_horizbar" +.tL "G" "7B1" "XK_Greek_alphaaccent" +.tL "G" "7B2" "XK_Greek_epsilonaccent" +.tL "G" "7B3" "XK_Greek_etaaccent" +.tL "G" "7B4" "XK_Greek_iotaaccent" +.tL "G" "7B5" "XK_Greek_iotadieresis" +.tL "G" "7B6" "XK_Greek_iotaaccentdieresis" +.tL "G" "7B7" "XK_Greek_omicronaccent" +.tL "G" "7B8" "XK_Greek_upsilonaccent" +.tL "G" "7B9" "XK_Greek_upsilondieresis" +.tL "G" "7BA" "XK_Greek_upsilonaccentdieresis" +.tL "G" "7BB" "XK_Greek_omegaaccent" +.tL "G" "7C1" "XK_Greek_ALPHA" +.tL "G" "7C2" "XK_Greek_BETA" +.tL "G" "7C3" "XK_Greek_GAMMA" +.tL "G" "7C4" "XK_Greek_DELTA" +.tL "G" "7C5" "XK_Greek_EPSILON" +.tL "G" "7C6" "XK_Greek_ZETA" +.tL "G" "7C7" "XK_Greek_ETA" +.tL "G" "7C8" "XK_Greek_THETA" +.tL "G" "7C9" "XK_Greek_IOTA" +.tL "G" "7CA" "XK_Greek_KAPPA" +.tL "G" "7CB" "XK_Greek_LAMBDA" +.tL "G" "7CB" "XK_Greek_LAMDA" +.tL "G" "7CC" "XK_Greek_MU" +.tL "G" "7CD" "XK_Greek_NU" +.tL "G" "7CE" "XK_Greek_XI" +.tL "G" "7CF" "XK_Greek_OMICRON" +.tL "G" "7D0" "XK_Greek_PI" +.tL "G" "7D1" "XK_Greek_RHO" +.tL "G" "7D2" "XK_Greek_SIGMA" +.tL "G" "7D4" "XK_Greek_TAU" +.tL "G" "7D5" "XK_Greek_UPSILON" +.tL "G" "7D6" "XK_Greek_PHI" +.tL "G" "7D7" "XK_Greek_CHI" +.tL "G" "7D8" "XK_Greek_PSI" +.tL "G" "7D9" "XK_Greek_OMEGA" +.tL "G" "7E1" "XK_Greek_alpha" +.tL "G" "7E2" "XK_Greek_beta" +.tL "G" "7E3" "XK_Greek_gamma" +.tL "G" "7E4" "XK_Greek_delta" +.tL "G" "7E5" "XK_Greek_epsilon" +.tL "G" "7E6" "XK_Greek_zeta" +.tL "G" "7E7" "XK_Greek_eta" +.tL "G" "7E8" "XK_Greek_theta" +.tL "G" "7E9" "XK_Greek_iota" +.tL "G" "7EA" "XK_Greek_kappa" +.tL "G" "7EB" "XK_Greek_lambda" +.tL "G" "7EB" "XK_Greek_lamda" +.tL "G" "7EC" "XK_Greek_mu" +.tL "G" "7ED" "XK_Greek_nu" +.tL "G" "7EE" "XK_Greek_xi" +.tL "G" "7EF" "XK_Greek_omicron" +.tL "G" "7F0" "XK_Greek_pi" +.tL "G" "7F1" "XK_Greek_rho" +.tL "G" "7F2" "XK_Greek_sigma" +.tL "G" "7F3" "XK_Greek_finalsmallsigma" +.tL "G" "7F4" "XK_Greek_tau" +.tL "G" "7F5" "XK_Greek_upsilon" +.tL "G" "7F6" "XK_Greek_phi" +.tL "G" "7F7" "XK_Greek_chi" +.tL "G" "7F8" "XK_Greek_psi" +.tL "G" "7F9" "XK_Greek_omega" +.tL "G" "FF7E" "XK_Greek_switch" +>>STRATEGY +For each KeySym in table with code G: + Call XKeysymToKeycode to obtain the KeyCode defined for that KeySym. + Call XKeycodeToKeysym to obtain each KeySym for that KeyCode. + Verify that one of the KeySyms returned is the original KeySym. +>>CODE + + kysymtcdG(); + +>>ASSERTION Good A +When the +.A keysym +argument is a +.S KeySym +in the table which is defined and has code H, +then a call to xname returns the +.S KeyCode +defined for that +.S KeySym . +.tL "Code" "Value" "Name" +.tL "H" "CDF" "XK_hebrew_doublelowline" +.tL "H" "CE0" "XK_hebrew_aleph" +.tL "H" "CE1" "XK_hebrew_bet" +.tL "H" "CE1" "XK_hebrew_beth" +.tL "H" "CE2" "XK_hebrew_gimel" +.tL "H" "CE2" "XK_hebrew_gimmel" +.tL "H" "CE3" "XK_hebrew_dalet" +.tL "H" "CE3" "XK_hebrew_daleth" +.tL "H" "CE4" "XK_hebrew_he" +.tL "H" "CE5" "XK_hebrew_waw" +.tL "H" "CE6" "XK_hebrew_zain" +.tL "H" "CE6" "XK_hebrew_zayin" +.tL "H" "CE7" "XK_hebrew_chet" +.tL "H" "CE7" "XK_hebrew_het" +.tL "H" "CE8" "XK_hebrew_tet" +.tL "H" "CE8" "XK_hebrew_teth" +.tL "H" "CE9" "XK_hebrew_yod" +.tL "H" "CEA" "XK_hebrew_finalkaph" +.tL "H" "CEB" "XK_hebrew_kaph" +.tL "H" "CEC" "XK_hebrew_lamed" +.tL "H" "CED" "XK_hebrew_finalmem" +.tL "H" "CEE" "XK_hebrew_mem" +.tL "H" "CEF" "XK_hebrew_finalnun" +.tL "H" "CF0" "XK_hebrew_nun" +.tL "H" "CF1" "XK_hebrew_samech" +.tL "H" "CF1" "XK_hebrew_samekh" +.tL "H" "CF2" "XK_hebrew_ayin" +.tL "H" "CF3" "XK_hebrew_finalpe" +.tL "H" "CF4" "XK_hebrew_pe" +.tL "H" "CF5" "XK_hebrew_finalzade" +.tL "H" "CF5" "XK_hebrew_finalzadi" +.tL "H" "CF6" "XK_hebrew_zade" +.tL "H" "CF6" "XK_hebrew_zadi" +.tL "H" "CF7" "XK_hebrew_qoph" +.tL "H" "CF7" "XK_hebrew_kuf" +.tL "H" "CF8" "XK_hebrew_resh" +.tL "H" "CF9" "XK_hebrew_shin" +.tL "H" "CFA" "XK_hebrew_taw" +.tL "H" "CFA" "XK_hebrew_taf" +.tL "H" "FF7E" "XK_Hebrew_switch" +>>STRATEGY +For each KeySym in table with code H: + Call XKeysymToKeycode to obtain the KeyCode defined for that KeySym. + Call XKeycodeToKeysym to obtain each KeySym for that KeyCode. + Verify that one of the KeySyms returned is the original KeySym. +>>CODE + + kysymtcdH(); + +>>ASSERTION Good A +When the +.A keysym +argument is a +.S KeySym +in the table which is defined and has code K, +then a call to xname returns the +.S KeyCode +defined for that +.S KeySym . +.tL "Code" "Value" "Name" +.tL "K" "47E" "XK_overline" +.tL "K" "4A1" "XK_kana_fullstop" +.tL "K" "4A2" "XK_kana_openingbracket" +.tL "K" "4A3" "XK_kana_closingbracket" +.tL "K" "4A4" "XK_kana_comma" +.tL "K" "4A5" "XK_kana_conjunctive" +.tL "K" "4A5" "XK_kana_middledot" +.tL "K" "4A6" "XK_kana_WO" +.tL "K" "4A7" "XK_kana_a" +.tL "K" "4A8" "XK_kana_i" +.tL "K" "4A9" "XK_kana_u" +.tL "K" "4AA" "XK_kana_e" +.tL "K" "4AB" "XK_kana_o" +.tL "K" "4AC" "XK_kana_ya" +.tL "K" "4AD" "XK_kana_yu" +.tL "K" "4AE" "XK_kana_yo" +.tL "K" "4AF" "XK_kana_tsu" +.tL "K" "4AF" "XK_kana_tu" +.tL "K" "4B0" "XK_prolongedsound" +.tL "K" "4B1" "XK_kana_A" +.tL "K" "4B2" "XK_kana_I" +.tL "K" "4B3" "XK_kana_U" +.tL "K" "4B4" "XK_kana_E" +.tL "K" "4B5" "XK_kana_O" +.tL "K" "4B6" "XK_kana_KA" +.tL "K" "4B7" "XK_kana_KI" +.tL "K" "4B8" "XK_kana_KU" +.tL "K" "4B9" "XK_kana_KE" +.tL "K" "4BA" "XK_kana_KO" +.tL "K" "4BB" "XK_kana_SA" +.tL "K" "4BC" "XK_kana_SHI" +.tL "K" "4BD" "XK_kana_SU" +.tL "K" "4BE" "XK_kana_SE" +.tL "K" "4BF" "XK_kana_SO" +.tL "K" "4C0" "XK_kana_TA" +.tL "K" "4C1" "XK_kana_CHI" +.tL "K" "4C1" "XK_kana_TI" +.tL "K" "4C2" "XK_kana_TSU" +.tL "K" "4C2" "XK_kana_TU" +.tL "K" "4C3" "XK_kana_TE" +.tL "K" "4C4" "XK_kana_TO" +.tL "K" "4C5" "XK_kana_NA" +.tL "K" "4C6" "XK_kana_NI" +.tL "K" "4C7" "XK_kana_NU" +.tL "K" "4C8" "XK_kana_NE" +.tL "K" "4C9" "XK_kana_NO" +.tL "K" "4CA" "XK_kana_HA" +.tL "K" "4CB" "XK_kana_HI" +.tL "K" "4CC" "XK_kana_FU" +.tL "K" "4CC" "XK_kana_HU" +.tL "K" "4CD" "XK_kana_HE" +.tL "K" "4CE" "XK_kana_HO" +.tL "K" "4CF" "XK_kana_MA" +.tL "K" "4D0" "XK_kana_MI" +.tL "K" "4D1" "XK_kana_MU" +.tL "K" "4D2" "XK_kana_ME" +.tL "K" "4D3" "XK_kana_MO" +.tL "K" "4D4" "XK_kana_YA" +.tL "K" "4D5" "XK_kana_YU" +.tL "K" "4D6" "XK_kana_YO" +.tL "K" "4D7" "XK_kana_RA" +.tL "K" "4D8" "XK_kana_RI" +.tL "K" "4D9" "XK_kana_RU" +.tL "K" "4DA" "XK_kana_RE" +.tL "K" "4DB" "XK_kana_RO" +.tL "K" "4DC" "XK_kana_WA" +.tL "K" "4DD" "XK_kana_N" +.tL "K" "4DE" "XK_voicedsound" +.tL "K" "4DF" "XK_semivoicedsound" +.tL "K" "FF7E" "XK_kana_switch" +>>STRATEGY +For each KeySym in table with code K: + Call XKeysymToKeycode to obtain the KeyCode defined for that KeySym. + Call XKeycodeToKeysym to obtain each KeySym for that KeyCode. + Verify that one of the KeySyms returned is the original KeySym. +>>CODE + + kysymtcdK(); + +>>ASSERTION Good A +When the +.A keysym +argument is a +.S KeySym +in the table which is defined and has code L, +then a call to xname returns the +.S KeyCode +defined for that +.S KeySym . +.tL "Code" "Value" "Name" +.tL "L" "BA3" "XK_leftcaret" +.tL "L" "BA6" "XK_rightcaret" +.tL "L" "BA8" "XK_downcaret" +.tL "L" "BA9" "XK_upcaret" +.tL "L" "BC0" "XK_overbar" +.tL "L" "BC2" "XK_downtack" +.tL "L" "BC3" "XK_upshoe" +.tL "L" "BC4" "XK_downstile" +.tL "L" "BC6" "XK_underbar" +.tL "L" "BCA" "XK_jot" +.tL "L" "BCC" "XK_quad" +.tL "L" "BCE" "XK_uptack" +.tL "L" "BCF" "XK_circle" +.tL "L" "BD3" "XK_upstile" +.tL "L" "BD6" "XK_downshoe" +.tL "L" "BD8" "XK_rightshoe" +.tL "L" "BDA" "XK_leftshoe" +.tL "L" "BDC" "XK_lefttack" +.tL "L" "BFC" "XK_righttack" +>>STRATEGY +For each KeySym in table with code L: + Call XKeysymToKeycode to obtain the KeyCode defined for that KeySym. + Call XKeycodeToKeysym to obtain each KeySym for that KeyCode. + Verify that one of the KeySyms returned is the original KeySym. +>>CODE + + kysymtcdL(); + +>>ASSERTION Good A +When the +.A keysym +argument is a +.S KeySym +in the table which is defined and has code M, +then a call to xname returns the +.S KeyCode +defined for that +.S KeySym . +.tL "Code" "Value" "Name" +.tL "M" "FF08" "XK_BackSpace" +.tL "M" "FF09" "XK_Tab" +.tL "M" "FF0A" "XK_Linefeed" +.tL "M" "FF0B" "XK_Clear" +.tL "M" "FF0D" "XK_Return" +.tL "M" "FF13" "XK_Pause" +.tL "M" "FF14" "XK_Scroll_Lock" +.tL "M" "FF1B" "XK_Escape" +.tL "M" "FF20" "XK_Multi_key" +.tL "M" "FF21" "XK_Kanji" +.tL "M" "FF22" "XK_Muhenkan" +.tL "M" "FF23" "XK_Henkan" +.tL "M" "FF23" "XK_Henkan_Mode" +.tL "M" "FF24" "XK_Romaji" +.tL "M" "FF25" "XK_Hiragana" +.tL "M" "FF26" "XK_Katakana" +.tL "M" "FF27" "XK_Hiragana_Katakana" +.tL "M" "FF28" "XK_Zenkaku" +.tL "M" "FF29" "XK_Hankaku" +.tL "M" "FF2A" "XK_Zenkaku_Hankaku" +.tL "M" "FF2B" "XK_Touroku" +.tL "M" "FF2C" "XK_Massyo" +.tL "M" "FF2D" "XK_Kana_Lock" +.tL "M" "FF2E" "XK_Kana_Shift" +.tL "M" "FF2F" "XK_Eisu_Shift" +.tL "M" "FF30" "XK_Eisu_toggle" +.tL "M" "FF50" "XK_Home" +.tL "M" "FF51" "XK_Left" +.tL "M" "FF52" "XK_Up" +.tL "M" "FF53" "XK_Right" +.tL "M" "FF54" "XK_Down" +.tL "M" "FF55" "XK_Prior" +.tL "M" "FF56" "XK_Next" +.tL "M" "FF57" "XK_End" +.tL "M" "FF58" "XK_Begin" +.tL "M" "FF60" "XK_Select" +.tL "M" "FF61" "XK_Print" +.tL "M" "FF62" "XK_Execute" +.tL "M" "FF63" "XK_Insert" +.tL "M" "FF65" "XK_Undo" +.tL "M" "FF66" "XK_Redo" +.tL "M" "FF67" "XK_Menu" +.tL "M" "FF68" "XK_Find" +.tL "M" "FF69" "XK_Cancel" +.tL "M" "FF6A" "XK_Help" +.tL "M" "FF6B" "XK_Break" +.tL "M" "FF7E" "XK_Mode_switch" +.tL "M" "FF7E" "XK_script_switch" +.tL "M" "FF7F" "XK_Num_Lock" +.tL "M" "FF80" "XK_KP_Space" +.tL "M" "FF89" "XK_KP_Tab" +.tL "M" "FF8D" "XK_KP_Enter" +.tL "M" "FF91" "XK_KP_F1" +.tL "M" "FF92" "XK_KP_F2" +.tL "M" "FF93" "XK_KP_F3" +.tL "M" "FF94" "XK_KP_F4" +.tL "M" "FFAA" "XK_KP_Multiply" +.tL "M" "FFAB" "XK_KP_Add" +.tL "M" "FFAC" "XK_KP_Separator" +.tL "M" "FFAD" "XK_KP_Subtract" +.tL "M" "FFAE" "XK_KP_Decimal" +.tL "M" "FFAF" "XK_KP_Divide" +.tL "M" "FFB0" "XK_KP_0" +.tL "M" "FFB1" "XK_KP_1" +.tL "M" "FFB2" "XK_KP_2" +.tL "M" "FFB3" "XK_KP_3" +.tL "M" "FFB4" "XK_KP_4" +.tL "M" "FFB5" "XK_KP_5" +.tL "M" "FFB6" "XK_KP_6" +.tL "M" "FFB7" "XK_KP_7" +.tL "M" "FFB8" "XK_KP_8" +.tL "M" "FFB9" "XK_KP_9" +.tL "M" "FFBD" "XK_KP_Equal" +.tL "M" "FFBE" "XK_F1" +.tL "M" "FFBF" "XK_F2" +.tL "M" "FFC0" "XK_F3" +.tL "M" "FFC1" "XK_F4" +.tL "M" "FFC2" "XK_F5" +.tL "M" "FFC3" "XK_F6" +.tL "M" "FFC4" "XK_F7" +.tL "M" "FFC5" "XK_F8" +.tL "M" "FFC6" "XK_F9" +.tL "M" "FFC7" "XK_F10" +.tL "M" "FFC8" "XK_F11" +.tL "M" "FFC8" "XK_L1" +.tL "M" "FFC9" "XK_F12" +.tL "M" "FFC9" "XK_L2" +.tL "M" "FFCA" "XK_F13" +.tL "M" "FFCA" "XK_L3" +.tL "M" "FFCB" "XK_F14" +.tL "M" "FFCB" "XK_L4" +.tL "M" "FFCC" "XK_F15" +.tL "M" "FFCC" "XK_L5" +.tL "M" "FFCD" "XK_F16" +.tL "M" "FFCD" "XK_L6" +.tL "M" "FFCE" "XK_F17" +.tL "M" "FFCE" "XK_L7" +.tL "M" "FFCF" "XK_F18" +.tL "M" "FFCF" "XK_L8" +.tL "M" "FFD0" "XK_F19" +.tL "M" "FFD0" "XK_L9" +.tL "M" "FFD1" "XK_F20" +.tL "M" "FFD1" "XK_L10" +.tL "M" "FFD2" "XK_F21" +.tL "M" "FFD2" "XK_R1" +.tL "M" "FFD3" "XK_F22" +.tL "M" "FFD3" "XK_R2" +.tL "M" "FFD4" "XK_F23" +.tL "M" "FFD4" "XK_R3" +.tL "M" "FFD5" "XK_F24" +.tL "M" "FFD5" "XK_R4" +.tL "M" "FFD6" "XK_F25" +.tL "M" "FFD6" "XK_R5" +.tL "M" "FFD7" "XK_F26" +.tL "M" "FFD7" "XK_R6" +.tL "M" "FFD8" "XK_F27" +.tL "M" "FFD8" "XK_R7" +.tL "M" "FFD9" "XK_F28" +.tL "M" "FFD9" "XK_R8" +.tL "M" "FFDA" "XK_F29" +.tL "M" "FFDA" "XK_R9" +.tL "M" "FFDB" "XK_F30" +.tL "M" "FFDB" "XK_R10" +.tL "M" "FFDC" "XK_F31" +.tL "M" "FFDC" "XK_R11" +.tL "M" "FFDD" "XK_F32" +.tL "M" "FFDD" "XK_R12" +.tL "M" "FFDE" "XK_F33" +.tL "M" "FFDE" "XK_R13" +.tL "M" "FFDF" "XK_F34" +.tL "M" "FFDF" "XK_R14" +.tL "M" "FFE0" "XK_F35" +.tL "M" "FFE0" "XK_R15" +.tL "M" "FFE1" "XK_Shift_L" +.tL "M" "FFE2" "XK_Shift_R" +.tL "M" "FFE3" "XK_Control_L" +.tL "M" "FFE4" "XK_Control_R" +.tL "M" "FFE5" "XK_Caps_Lock" +.tL "M" "FFE6" "XK_Shift_Lock" +.tL "M" "FFE7" "XK_Meta_L" +.tL "M" "FFE8" "XK_Meta_R" +.tL "M" "FFE9" "XK_Alt_L" +.tL "M" "FFEA" "XK_Alt_R" +.tL "M" "FFEB" "XK_Super_L" +.tL "M" "FFEC" "XK_Super_R" +.tL "M" "FFED" "XK_Hyper_L" +.tL "M" "FFEE" "XK_Hyper_R" +.tL "M" "FFFF" "XK_Delete" +>>STRATEGY +For each KeySym in table with code M: + Call XKeysymToKeycode to obtain the KeyCode defined for that KeySym. + Call XKeycodeToKeysym to obtain each KeySym for that KeyCode. + Verify that one of the KeySyms returned is the original KeySym. +>>CODE + + kysymtcdM(); + +>>ASSERTION Good A +When the +.A keysym +argument is a +.S KeySym +in the table which is defined and has code P, +then a call to xname returns the +.S KeyCode +defined for that +.S KeySym . +.tL "Code" "Value" "Name" +.tL "P" "AA1" "XK_emspace" +.tL "P" "AA2" "XK_enspace" +.tL "P" "AA3" "XK_em3space" +.tL "P" "AA4" "XK_em4space" +.tL "P" "AA5" "XK_digitspace" +.tL "P" "AA6" "XK_punctspace" +.tL "P" "AA7" "XK_thinspace" +.tL "P" "AA8" "XK_hairspace" +.tL "P" "AA9" "XK_emdash" +.tL "P" "AAA" "XK_endash" +.tL "P" "AAC" "XK_signifblank" +.tL "P" "AAE" "XK_ellipsis" +.tL "P" "AAF" "XK_doubbaselinedot" +.tL "P" "AB0" "XK_onethird" +.tL "P" "AB1" "XK_twothirds" +.tL "P" "AB2" "XK_onefifth" +.tL "P" "AB3" "XK_twofifths" +.tL "P" "AB4" "XK_threefifths" +.tL "P" "AB5" "XK_fourfifths" +.tL "P" "AB6" "XK_onesixth" +.tL "P" "AB7" "XK_fivesixths" +.tL "P" "AB8" "XK_careof" +.tL "P" "ABB" "XK_figdash" +.tL "P" "ABC" "XK_leftanglebracket" +.tL "P" "ABD" "XK_decimalpoint" +.tL "P" "ABE" "XK_rightanglebracket" +.tL "P" "ABF" "XK_marker" +.tL "P" "AC3" "XK_oneeighth" +.tL "P" "AC4" "XK_threeeighths" +.tL "P" "AC5" "XK_fiveeighths" +.tL "P" "AC6" "XK_seveneighths" +.tL "P" "AC9" "XK_trademark" +.tL "P" "ACA" "XK_signaturemark" +.tL "P" "ACB" "XK_trademarkincircle" +.tL "P" "ACC" "XK_leftopentriangle" +.tL "P" "ACD" "XK_rightopentriangle" +.tL "P" "ACE" "XK_emopencircle" +.tL "P" "ACF" "XK_emopenrectangle" +.tL "P" "AD0" "XK_leftsinglequotemark" +.tL "P" "AD1" "XK_rightsinglequotemark" +.tL "P" "AD2" "XK_leftdoublequotemark" +.tL "P" "AD3" "XK_rightdoublequotemark" +.tL "P" "AD4" "XK_prescription" +.tL "P" "AD6" "XK_minutes" +.tL "P" "AD7" "XK_seconds" +.tL "P" "AD9" "XK_latincross" +.tL "P" "ADA" "XK_hexagram" +.tL "P" "ADB" "XK_filledrectbullet" +.tL "P" "ADC" "XK_filledlefttribullet" +.tL "P" "ADD" "XK_filledrighttribullet" +.tL "P" "ADE" "XK_emfilledcircle" +.tL "P" "ADF" "XK_emfilledrect" +.tL "P" "AE0" "XK_enopencircbullet" +.tL "P" "AE1" "XK_enopensquarebullet" +.tL "P" "AE2" "XK_openrectbullet" +.tL "P" "AE3" "XK_opentribulletup" +.tL "P" "AE4" "XK_opentribulletdown" +.tL "P" "AE5" "XK_openstar" +.tL "P" "AE6" "XK_enfilledcircbullet" +.tL "P" "AE7" "XK_enfilledsqbullet" +.tL "P" "AE8" "XK_filledtribulletup" +.tL "P" "AE9" "XK_filledtribulletdown" +.tL "P" "AEA" "XK_leftpointer" +.tL "P" "AEB" "XK_rightpointer" +.tL "P" "AEC" "XK_club" +.tL "P" "AED" "XK_diamond" +.tL "P" "AEE" "XK_heart" +.tL "P" "AF0" "XK_maltesecross" +.tL "P" "AF1" "XK_dagger" +.tL "P" "AF2" "XK_doubledagger" +.tL "P" "AF3" "XK_checkmark" +.tL "P" "AF4" "XK_ballotcross" +.tL "P" "AF5" "XK_musicalsharp" +.tL "P" "AF6" "XK_musicalflat" +.tL "P" "AF7" "XK_malesymbol" +.tL "P" "AF8" "XK_femalesymbol" +.tL "P" "AF9" "XK_telephone" +.tL "P" "AFA" "XK_telephonerecorder" +.tL "P" "AFB" "XK_phonographcopyright" +.tL "P" "AFC" "XK_caret" +.tL "P" "AFD" "XK_singlelowquotemark" +.tL "P" "AFE" "XK_doublelowquotemark" +.tL "P" "AFF" "XK_cursor" +>>STRATEGY +For each KeySym in table with code P: + Call XKeysymToKeycode to obtain the KeyCode defined for that KeySym. + Call XKeycodeToKeysym to obtain each KeySym for that KeyCode. + Verify that one of the KeySyms returned is the original KeySym. +>>CODE + + kysymtcdP(); + +>>ASSERTION Good A +When the +.A keysym +argument is a +.S KeySym +in the table which is defined and has code S, +then a call to xname returns the +.S KeyCode +defined for that +.S KeySym . +.tL "Code" "Value" "Name" +.tL "S" "9DF" "XK_blank" +.tL "S" "9E0" "XK_soliddiamond" +.tL "S" "9E1" "XK_checkerboard" +.tL "S" "9E2" "XK_ht" +.tL "S" "9E3" "XK_ff" +.tL "S" "9E4" "XK_cr" +.tL "S" "9E5" "XK_lf" +.tL "S" "9E8" "XK_nl" +.tL "S" "9E9" "XK_vt" +.tL "S" "9EA" "XK_lowrightcorner" +.tL "S" "9EB" "XK_uprightcorner" +.tL "S" "9EC" "XK_upleftcorner" +.tL "S" "9ED" "XK_lowleftcorner" +.tL "S" "9EE" "XK_crossinglines" +.tL "S" "9EF" "XK_horizlinescan1" +.tL "S" "9F0" "XK_horizlinescan3" +.tL "S" "9F1" "XK_horizlinescan5" +.tL "S" "9F2" "XK_horizlinescan7" +.tL "S" "9F3" "XK_horizlinescan9" +.tL "S" "9F4" "XK_leftt" +.tL "S" "9F5" "XK_rightt" +.tL "S" "9F6" "XK_bott" +.tL "S" "9F7" "XK_topt" +.tL "S" "9F8" "XK_vertbar" +>>STRATEGY +For each KeySym in table with code S: + Call XKeysymToKeycode to obtain the KeyCode defined for that KeySym. + Call XKeycodeToKeysym to obtain each KeySym for that KeyCode. + Verify that one of the KeySyms returned is the original KeySym. +>>CODE + + kysymtcdS(); + +>>ASSERTION Good A +When the +.A keysym +argument is a +.S KeySym +in the table which is defined and has code T, +then a call to xname returns the +.S KeyCode +defined for that +.S KeySym . +.tL "Code" "Value" "Name" +.tL "T" "8A1" "XK_leftradical" +.tL "T" "8A2" "XK_topleftradical" +.tL "T" "8A3" "XK_horizconnector" +.tL "T" "8A4" "XK_topintegral" +.tL "T" "8A5" "XK_botintegral" +.tL "T" "8A6" "XK_vertconnector" +.tL "T" "8A7" "XK_topleftsqbracket" +.tL "T" "8A8" "XK_botleftsqbracket" +.tL "T" "8A9" "XK_toprightsqbracket" +.tL "T" "8AA" "XK_botrightsqbracket" +.tL "T" "8AB" "XK_topleftparens" +.tL "T" "8AC" "XK_botleftparens" +.tL "T" "8AD" "XK_toprightparens" +.tL "T" "8AE" "XK_botrightparens" +.tL "T" "8AF" "XK_leftmiddlecurlybrace" +.tL "T" "8B0" "XK_rightmiddlecurlybrace" +.tL "T" "8B1" "XK_topleftsummation" +.tL "T" "8B2" "XK_botleftsummation" +.tL "T" "8B3" "XK_topvertsummationconnector" +.tL "T" "8B4" "XK_botvertsummationconnector" +.tL "T" "8B5" "XK_toprightsummation" +.tL "T" "8B6" "XK_botrightsummation" +.tL "T" "8B7" "XK_rightmiddlesummation" +.tL "T" "8BC" "XK_lessthanequal" +.tL "T" "8BD" "XK_notequal" +.tL "T" "8BE" "XK_greaterthanequal" +.tL "T" "8BF" "XK_integral" +.tL "T" "8C0" "XK_therefore" +.tL "T" "8C1" "XK_variation" +.tL "T" "8C2" "XK_infinity" +.tL "T" "8C5" "XK_nabla" +.tL "T" "8C8" "XK_approximate" +.tL "T" "8C9" "XK_similarequal" +.tL "T" "8CD" "XK_ifonlyif" +.tL "T" "8CE" "XK_implies" +.tL "T" "8CF" "XK_identical" +.tL "T" "8D6" "XK_radical" +.tL "T" "8DA" "XK_includedin" +.tL "T" "8DB" "XK_includes" +.tL "T" "8DC" "XK_intersection" +.tL "T" "8DD" "XK_union" +.tL "T" "8DE" "XK_logicaland" +.tL "T" "8DF" "XK_logicalor" +.tL "T" "8EF" "XK_partialderivative" +.tL "T" "8F6" "XK_function" +.tL "T" "8FB" "XK_leftarrow" +.tL "T" "8FC" "XK_uparrow" +.tL "T" "8FD" "XK_rightarrow" +.tL "T" "8FE" "XK_downarrow" +>>STRATEGY +For each KeySym in table with code T: + Call XKeysymToKeycode to obtain the KeyCode defined for that KeySym. + Call XKeycodeToKeysym to obtain each KeySym for that KeyCode. + Verify that one of the KeySyms returned is the original KeySym. +>>CODE + + kysymtcdT(); + diff --git a/xts5/Xopen/XLookupColor/XLookupColor.m b/xts5/Xopen/XLookupColor/XLookupColor.m new file mode 100644 index 00000000..463cff1f --- /dev/null +++ b/xts5/Xopen/XLookupColor/XLookupColor.m @@ -0,0 +1,975 @@ +Copyright (c) 2005 X.Org Foundation L.L.C. + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies +of the Software, and to permit persons to whom the Software is furnished to do +so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. +$Header: /cvs/xtest/xtest/xts5/tset/Xopen/XLookupColor/XLookupColor.m,v 1.2 2005-11-03 08:44:00 jmichael Exp $ + +>># Project: VSW5 +>># +>># File: xts5/tset/Xopen/XLookupColor/XLookupColor.m +>># +>># Description: +>># Tests for XLookupColor() +>># +>># Modifications: +>># $Log: lkpclr.m,v $ +>># Revision 1.2 2005-11-03 08:44:00 jmichael +>># clean up all vsw5 paths to use xts5 instead. +>># +>># Revision 1.1.1.2 2005/04/15 14:05:40 anderson +>># Reimport of the base with the legal name in the copyright fixed. +>># +>># Revision 8.0 1998/12/23 23:35:52 mar +>># Branch point for Release 5.0.2 +>># +>># Revision 7.0 1998/10/30 22:58:34 mar +>># Branch point for Release 5.0.2b1 +>># +>># Revision 6.0 1998/03/02 05:27:05 tbr +>># Branch point for Release 5.0.1 +>># +>># Revision 5.0 1998/01/26 03:23:39 tbr +>># Branch point for Release 5.0.1b1 +>># +>># Revision 4.0 1995/12/15 09:14:27 tbr +>># Branch point for Release 5.0.0 +>># +>># Revision 3.1 1995/12/15 01:17:52 andy +>># Prepare for GA Release +>># +/* + * SCCS: @(#) lkpclr.m Rel 1.10 (12/10/91) + * + * UniSoft Ltd., London, England + * + * (C) Copyright 1991 X/Open Company Limited + * + * All rights reserved. No part of this source code may be reproduced, + * stored in a retrieval system, or transmitted, in any form or by any + * means, electronic, mechanical, photocopying, recording or otherwise, + * except as stated in the end-user licence agreement, without the prior + * permission of the copyright owners. + * + * X/Open and the 'X' symbol are trademarks of X/Open Company Limited in + * the UK and other countries. + */ +>>TITLE XLookupColor Xopen +Status +LookupColor(display, colormap, color_name, exact_def_return, screen_def_return) +Display *display = Dsp; +Colormap colormap = DefaultColormap(display, DefaultScreen(display)); +char *color_name = ""; +XColor *exact_def_return = &dummycol; +XColor *screen_def_return = &dummycol; +>>EXTERN + +XColor dummycol; + +static char *convertname(s) +char *s; +{ + char *res; + char *rp; + char *cp = s; + int len = strlen(s); + + if(s == (char *) NULL) + return((char *) NULL); + + if((res = rp = (char*) malloc(len + 1)) == (char *) NULL) { + delete("Malloc returned NULL."); + return((char *) NULL); + } + + while(*cp == ' ') + cp++; + + *rp++ = toupper(*cp++); + while(*cp) { + if(*cp == ' ') { + while(*cp == ' ') + cp++; + if(*cp) + *rp++ = toupper(*cp++); + } else + *rp++ = *cp++; + } + + *rp = '\0'; + return(res); +} + +>>ASSERTION Good A +When a colour name in the table is recognised on a call to xname, +then all other colour names on the same line of the table +are also recognised on another call to xname +using the same +.A display +and +.A colormap , +and the same values are returned by each call to xname in the +.M red , +.M green +and +.M blue +components of the +.S XColor +structures named by the +.A exact_def_return +argument and +.A screen_def_return +arguments. +.tL "Set" "Color name(s)" +.tL "M" "gray" "grey" +.tL "M" "dark gray" "dark grey" +.tL "X" "dark slate gray" "dark slate grey" +.tL "X" "dim gray" "dim grey" +.tL "X" "light gray" "light grey" +>>STRATEGY +For each supported visual type: + Create a colourmap of that type using XCreateColormap. + For each equivalent colour name: + Obtain the rgb values for the colour. + Verify that the exact rgb values are identical. + Verify that the supported rbg values are identical. +>>CODE +int i; +int firstunsupported; +int secondunsupported; +XVisualInfo *vp; +Status status; +XColor exactcol, screencol; +XColor exactcol2, screencol2; +unsigned long vmask; +static char *p[5][2] = + {{ "gray", "grey"}, + { "dark gray", "dark grey"}, + { "dark slate gray", "dark slate grey"}, + { "dim gray", "dim grey"}, + { "light gray", "light grey"}}; + + if( (vmask = visualsupported(display, 0L)) == 0L) { + delete("No visuals reported as valid."); + return; + } else + CHECK; + + for(resetsupvis(vmask); nextsupvis(&vp); ) { + + colormap = makecolmap(display, vp->visual, AllocNone); + for(i=0; i< NELEM(p); i++) { + + firstunsupported = secondunsupported = 0; + trace("Compare \"%s\" against \"%s\".", p[i][0], p[i][1]); + + exact_def_return = &exactcol; + screen_def_return = &screencol; + color_name= p[i][0]; + + status = XCALL; + + if( status == (Status) 0) { + trace("Colour \"%s\" is not supported.", color_name); + firstunsupported = 1; + } + + exact_def_return = &exactcol2; + screen_def_return = &screencol2; + color_name= p[i][1]; + + status = XCALL; + + if( status == (Status) 0) { + trace("Colour \"%s\" is not supported.", color_name); + secondunsupported = 1; + } + + if(firstunsupported && secondunsupported) { + CHECK; + CHECK; + CHECK; + continue; + } + + if(firstunsupported && !secondunsupported) { + report("Colour %s is unsupported.", p[i][0]); + report("Colour %s is supported.", p[i][1]); + FAIL; + } else if(!firstunsupported && secondunsupported) { + report("Colour %s is unsupported.", p[i][1]); + report("Colour %s is supported.", p[i][0]); + FAIL; + } else { + CHECK; + + if((exactcol2.red != exactcol.red) || + (exactcol2.green != exactcol.green) || + (exactcol2.blue != exactcol.blue) ) { + report("Colour names \"%s\" and \"%s\" do not yield the same exact rgb values.", + p[i][0], p[i][1]); + report("( r %u g %u b %u instead of r %u g %u b %u respectively.)", + exactcol.red, exactcol.green, exactcol.blue, + exactcol2.red, exactcol2.green, exactcol2.blue); + FAIL; + } else + CHECK; + + if((screencol2.red != screencol.red) || + (screencol2.green != screencol.green) || + (screencol2.blue != screencol.blue) ) { + report("Colour names \"%s\" and \"%s\" do not yield the same supported rgb values.", + p[i][0], p[i][1]); + report("( r %u g %u b %u instead of r %u g %u b %u respectively.)", + screencol.red, screencol.green, screencol.blue, + screencol2.red, screencol2.green, screencol2.blue); + FAIL; + } else + CHECK; + } + + } + } + + CHECKPASS(1 + 3 * nsupvis() * NELEM(p) ); + +>>ASSERTION Good A +When a colour name in the table is recognised on a call to xname, +and a colour name on a different line of the table +is also recognised on another call to xname +using the same +.A display +and +.A colormap , +then distinct values are returned by each call to xname in the +.M red , +.M green +and +.M blue +components of the +.S XColor +structures named by the +.A exact_def_return +argument and +.A screen_def_return +arguments. +.tL "Set" "Color name(s)" +.tL "A" "black" +.tL "A" "white" +.tL "C" "blue" +.tL "C" "cyan" +.tL "C" "green" +.tL "C" "magenta" +.tL "C" "red" +.tL "C" "yellow" +.tL "M" "gray" "grey" +.tL "M" "dark gray" "dark grey" +.tL "V" "dark blue" +.tL "V" "brown" +.tL "V" "dark cyan" +.tL "V" "dark green" +.tL "V" "dark magenta" +.tL "V" "dark red" +.tL "X" "medium blue" +.tL "X" "midnight blue" +.tL "X" "navy blue" +.tL "X" "sky blue" +.tL "X" "coral" +.tL "X" "gold" +.tL "X" "dark slate gray" "dark slate grey" +.tL "X" "dim gray" "dim grey" +.tL "X" "light gray" "light grey" +.tL "X" "light green" +.tL "X" "forest green" +.tL "X" "lime green" +.tL "X" "pale green" +.tL "X" "spring green" +.tL "X" "maroon" +.tL "X" "orange" +.tL "X" "pink" +.tL "X" "indian red" +.tL "X" "orange red" +.tL "X" "violet red" +.tL "X" "salmon" +.tL "X" "sienna" +.tL "X" "tan" +.tL "X" "turquoise" +.tL "X" "violet" +.tL "X" "blue violet" +.tL "X" "wheat" +>>STRATEGY +For each supported visual: + Create a colourmap of that type using XCreateColormap. + For each pair of colour names in the table: + Obtain the rgb values corresponding to the name using xname. + Verify that the rgb triples are different. +>>EXTERN +static int +compare(col1, col2, name1, name2, eflag) +XColor *col1; +XColor *col2; +char *name1; +char *name2; +int eflag; +{ + + if((col2->red == col1->red) && + (col2->green == col1->green) && + (col2->blue == col1->blue) ) { + report("Colour names \"%s\" and \"%s\" yield the same %s rgb values.", + name1, name2, eflag ? "exact" : "supported"); + trace("%s = r %u g %u b %u, %s = r %u g %u b %u", + name1, col1->red, col1->green, col1->blue, + name2, col2->red, col2->green, col2->blue); + return(0); + } + return(1); +} +>>CODE +XColor scols[43]; +XColor ecols[43]; +XColor scols2[5]; +XColor ecols2[5]; +Status status; +int i, j; +unsigned long vmask; +XVisualInfo *vp; +static char *list[43] = { + "gray", + "dark gray", + "dark slate gray", + "dim gray", + "light gray", + "black", + "white", + "blue", + "cyan", + "green", + "magenta", + "red", + "yellow", + "dark blue", + "brown", + "dark cyan", + "dark green", + "dark magenta", + "dark red", + "medium blue", + "midnight blue", + "navy blue", + "sky blue", + "coral", + "gold", + "light green", + "forest green", + "lime green", + "pale green", + "spring green", + "maroon", + "orange", + "pink", + "indian red", + "orange red", + "violet red", + "salmon", + "sienna", + "tan", + "turquoise", + "violet", + "blue violet", + "wheat"}; +static char *list2[5] = { + "grey", + "dark grey", + "dark slate grey", + "dim grey", + "light grey"}; + + if( (vmask = visualsupported(display, 0L)) == 0L) { + delete("No visuals reported as valid."); + return; + } else + CHECK; + + for(resetsupvis(vmask); nextsupvis(&vp); ) { + + colormap = makecolmap(display, vp->visual, AllocNone); + for(i=0; i<NELEM(list); i++) { + + color_name = list[i]; + exact_def_return = &ecols[i]; + screen_def_return = &scols[i]; + + status = XCALL; + + if(status == 0) { + trace("Colour \"%s\" is not supported.", color_name); + ecols[i].flags = 0; + } else { + ecols[i].flags = 1; + } + + if(i==0) + CHECK; + } + + /* + * test all pairs of colours - n! + * 2!(n-2)! + */ + for(i=0; i<NELEM(list)-1; i++) { + for(j=i+1; j<NELEM(list); j++) { + if((ecols[i].flags) && (ecols[j].flags)) { + if(compare(&ecols[i], &ecols[j], list[i], list[j], 1) == 0) + FAIL; + if(compare(&scols[i], &scols[j], list[i], list[j], 0) == 0) + FAIL; + } + } + + if(i==0) + CHECK; + } + + for(i=0; i<NELEM(list2); i++) { + + color_name = list2[i]; + exact_def_return = &ecols2[i]; + screen_def_return = &scols2[i]; + + status = XCALL; + + if(status == 0) { + trace("Colour \"%s\" is not supported.", color_name); + ecols2[i].flags = 0; + } else { + ecols2[i].flags = 1; + } + + if(i==0) + CHECK; + } + + for(i=0; i<NELEM(list2)-1; i++) { + for(j=i+5; j<NELEM(list); j++) { + if((ecols2[i].flags) && (ecols[j].flags)) { + if(compare(&ecols2[i], &ecols[j], list2[i], list[j], 1) == 0) + FAIL; + if(compare(&scols2[i], &scols[j], list2[i], list[j], 0) == 0) + FAIL; + } + } + + if(i==0) + CHECK; + + } + } + + CHECKPASS(1 + nsupvis() * 4); + +>>ASSERTION Good A +When a colour name in the table is recognised on a call to xname, +then the colour name with the first letter of each word in upper-case +and with no spaces between words +is also recognised on another call to xname +using the same +.A display +and +.A colormap , +and the same values are returned by each call to xname in the +.M red , +.M green +and +.M blue +components of the +.S XColor +structures named by the +.A exact_def_return +argument and +.A screen_def_return +arguments. +.tL "Set" "Color name(s)" +.tL "A" "black" +.tL "A" "white" +.tL "C" "blue" +.tL "C" "cyan" +.tL "C" "green" +.tL "C" "magenta" +.tL "C" "red" +.tL "C" "yellow" +.tL "M" "gray" "grey" +.tL "M" "dark gray" "dark grey" +.tL "V" "dark blue" +.tL "V" "brown" +.tL "V" "dark cyan" +.tL "V" "dark green" +.tL "V" "dark magenta" +.tL "V" "dark red" +.tL "X" "medium blue" +.tL "X" "midnight blue" +.tL "X" "navy blue" +.tL "X" "sky blue" +.tL "X" "coral" +.tL "X" "gold" +.tL "X" "dark slate gray" "dark slate grey" +.tL "X" "dim gray" "dim grey" +.tL "X" "light gray" "light grey" +.tL "X" "light green" +.tL "X" "forest green" +.tL "X" "lime green" +.tL "X" "pale green" +.tL "X" "spring green" +.tL "X" "maroon" +.tL "X" "orange" +.tL "X" "pink" +.tL "X" "indian red" +.tL "X" "orange red" +.tL "X" "violet red" +.tL "X" "salmon" +.tL "X" "sienna" +.tL "X" "tan" +.tL "X" "turquoise" +.tL "X" "violet" +.tL "X" "blue violet" +.tL "X" "wheat" +>>STRATEGY +For each supported visual type: + Create a colourmap of that type using XCreateColormap. + For each equivalent colour name: + Obtain the rgb values for the colour. + Verify that the exact rgb values are identical. + Verify that the supported rbg values are identical. +>>CODE +int i; +XVisualInfo *vp; +Status status; +XColor exactcol, screencol; +XColor exactcol2, screencol2; +unsigned long vmask; +static char *list[] = { + "black", + "white", + "blue", + "cyan", + "green", + "magenta", + "red", + "yellow", + "gray", + "grey", + "dark gray", + "dark grey", + "dark blue", + "brown", + "dark cyan", + "dark green", + "dark magenta", + "dark red", + "medium blue", + "midnight blue", + "navy blue", + "sky blue", + "coral", + "gold", + "dark slate gray", + "dark slate grey", + "dim gray", + "dim grey", + "light gray", + "light grey", + "light green", + "forest green", + "lime green", + "pale green", + "spring green", + "maroon", + "orange", + "pink", + "indian red", + "orange red", + "violet red", + "salmon", + "sienna", + "tan", + "turquoise", + "violet", + "blue violet", + "wheat" }; + + + if( (vmask = visualsupported(display, 0L)) == 0L) { + delete("No visuals reported as valid."); + return; + } + + for(resetsupvis(vmask); nextsupvis(&vp); ) { + + for(i=0; i< NELEM(list); i++) { + + color_name = list[i]; + colormap = makecolmap(display, vp->visual, AllocNone); + exact_def_return = &exactcol; + screen_def_return = &screencol; + status = XCALL; + + if(status == (Status) 0) { + trace("Colour name \"%s\" is not supported.", color_name); + CHECK; CHECK;CHECK; + } else { + + color_name = convertname(list[i]); + exact_def_return = &exactcol2; + screen_def_return = &screencol2; + status = XCALL; + + if(status == 0) { + report("Colour name \"%s\" is supported but \"%s\" is not.", list[i], color_name); + FAIL; + } else { + + CHECK; + + if((exactcol2.red != exactcol.red) || + (exactcol2.green != exactcol.green) || + (exactcol2.blue != exactcol.blue) ) { + report("Colour names \"%s\" and \"%s\" do not yield the same exact rgb values.", + list[i], color_name); + report("( r %u g %u b %u instead of r %u g %u b %u respectively.)", + exactcol.red, exactcol.green, exactcol.blue, + exactcol2.red, exactcol2.green, exactcol2.blue); + FAIL; + } else + CHECK; + + if((screencol2.red != screencol.red) || + (screencol2.green != screencol.green) || + (screencol2.blue != screencol.blue) ) { + report("Colour names \"%s\" and \"%s\" do not yield the same supported rgb values.", + list[i], color_name); + report("( r %u g %u b %u instead of r %u g %u b %u respectively.)", + screencol.red, screencol.green, screencol.blue, + screencol2.red, screencol2.green, screencol2.blue); + FAIL; + } else + CHECK; + + } + + if(!isdeleted()) + free(color_name); + } + + } + + } + + CHECKPASS(nsupvis() * 3 * NELEM(list)); + +>>ASSERTION Good A +All colour names in the table which are in set A are recognised +on a call to xname. +.tL "Set" "Color name(s)" +.tL "A" "black" +.tL "A" "white" +>>STRATEGY +For each supported visual type: + Create a colourmap of that type using XCreateColormap. + For the colournames in the table: + Obtain the rgb values for the colour using xname. + Verify that the call did not return 0. +>>CODE +int i; +Status status; +XVisualInfo *vp; +unsigned long vmask; +static char *list[] = { "black", "white" }; + + if( (vmask = visualsupported(display, 0L)) == 0L) { + delete("No visuals reported as valid."); + return; + } else + CHECK; + + for(resetsupvis(vmask); nextsupvis(&vp); ) { + + colormap = makecolmap(display, vp->visual, AllocNone); + + for(i=0; i< NELEM(list); i++) { + + color_name = list[i]; + status = XCALL; + + if(status == 0) { + report("Colour name \"%s\" is not supported.", list[i]); + FAIL; + } else + CHECK; + } + } + + CHECKPASS(1 + nsupvis() * NELEM(list)); + +>>ASSERTION Good C +If any of the visual classes +.S GrayScale +or +.S StaticGray +support colourmaps with at least four colour cells: +When the visual type of the +.A colormap +argument is +.S GrayScale +or +.S StaticGray , +and +.A colormap +has at least four colour cells, +then all colour names in the table which are in set M are recognised +on a call to xname. +.tL "Set" "Color name(s)" +.tL "M" "gray" "grey" +.tL "M" "dark gray" "dark grey" +>>STRATEGY +If the server supports GrayScale or StaticGray with colourmap size greater than 4: + For those supported visuals: + Create a colourmap using XCreateColormap. + For each colour name in the table: + Obtain the rgb values for the for the colour using xname. + Verify that the call did not return 0. +>>CODE +int i; +Status status; +XVisualInfo *vp; +unsigned long vmask; +static char *list[] = { "gray", "grey", "dark gray", "dark grey" }; + + + if( (vmask = visualsupported(display, 1L<<GrayScale)) != 0L) { + + resetsupvis(vmask); + (void) nextsupvis(&vp); + if(vp->colormap_size < 4) + vmask = 0L; + } + + + if( (vmask |= visualsupported(display, 1L<<StaticGray)) | StaticGray) { + + resetsupvis(1L<<StaticGray); + (void) nextsupvis(&vp); + if(vp->colormap_size < 4) + vmask &= ~(1L<<StaticGray); + } + + if(vmask == 0L) { + unsupported("StaticGray and GrayScale visuals are not supported."); + return; + } else + CHECK; + + for(resetsupvis(vmask); nextsupvis(&vp); ) { + + colormap = makecolmap(display, vp->visual, AllocNone); + for(i=0; i< NELEM(list); i++) { + + color_name = list[i]; + status = XCALL; + + if(status == 0L) { + report("Colour name \"%s\" is not supported.", color_name); + FAIL; + } else + CHECK; + } + } + + CHECKPASS(1 + nsupvis()* NELEM(list)); + +>>ASSERTION Good C +If any of the visual classes +.S PseudoColor , +.S StaticColor , +.S TrueColor , +or +.S DirectColor +are supported: +When the visual type of the +.A colormap +argument is +.S PseudoColor , +.S StaticColor , +.S TrueColor , +or +.S DirectColor , +then all colour names in the table which are in set C are recognised +on a call to xname. +.tL "Set" "Color name(s)" +.tL "C" "blue" +.tL "C" "cyan" +.tL "C" "green" +.tL "C" "magenta" +.tL "C" "red" +.tL "C" "yellow" +>>STRATEGY +For each supported visual type from PseudoColor, StaticColor, TrueColor and DirectColor: + Create a colourmap of that type using XCreateColormap. + For the colournames in the table: + Obtain the rgb values for the colour using xname. + Verify that the call did not return 0. +>>CODE +int i; +unsigned long vmask = (1L<<PseudoColor|1L<<StaticColor|1L<<TrueColor|1L<<DirectColor); +Status status; +XVisualInfo *vp; +static char *list[] = { "blue", "cyan", "green", "magenta", "red", "yellow" }; + + + + if( (vmask = visualsupported(display, vmask)) == 0L) { + unsupported("Required visual types are not supported."); + return; + } else + CHECK; + + + for(resetsupvis(vmask); nextsupvis(&vp); ) { + + colormap = makecolmap(display, vp->visual, AllocNone); + for(i=0; i< NELEM(list); i++) { + + color_name = list[i]; + status = XCALL; + + if(status == 0L) { + report("Colour name \"%s\" is not supported.", color_name); + FAIL; + } else + CHECK; + } + } + + CHECKPASS(nsupvis() * NELEM(list) + 1); + +>>ASSERTION Good A +When a colour name in the table which is in set M, V or X +is recognised on a call to xname, +then all other colour names in the table which are in set C, M, or V +are also recognised on another call to xname. +.tL "Set" "Color name(s)" +.tL "C" "blue" +.tL "C" "cyan" +.tL "C" "green" +.tL "C" "magenta" +.tL "C" "red" +.tL "C" "yellow" +.tL "M" "gray" "grey" +.tL "M" "dark gray" "dark grey" +.tL "V" "dark blue" +.tL "V" "brown" +.tL "V" "dark cyan" +.tL "V" "dark green" +.tL "V" "dark magenta" +.tL "V" "dark red" +.tL "X" "medium blue" +.tL "X" "midnight blue" +.tL "X" "navy blue" +.tL "X" "sky blue" +.tL "X" "coral" +.tL "X" "gold" +.tL "X" "dark slate gray" "dark slate grey" +.tL "X" "dim gray" "dim grey" +.tL "X" "light gray" "light grey" +.tL "X" "light green" +.tL "X" "forest green" +.tL "X" "lime green" +.tL "X" "pale green" +.tL "X" "spring green" +.tL "X" "maroon" +.tL "X" "orange" +.tL "X" "pink" +.tL "X" "indian red" +.tL "X" "orange red" +.tL "X" "violet red" +.tL "X" "salmon" +.tL "X" "sienna" +.tL "X" "tan" +.tL "X" "turquoise" +.tL "X" "violet" +.tL "X" "blue violet" +.tL "X" "wheat" +>>STRATEGY +If a colourname in sets M, V or X causes xname to return non-zero: + For each supported visual: + Verify that all the colour names in C, M and V also cause xname to return non-zero: +>>CODE +XVisualInfo *vp; +unsigned long vmask; +int i; +int j; +int supported = 0; +int unsupported = 0; +Status status; +static char *MVX[] = { "gray", "grey", "dark gray","dark grey","dark blue","brown","dark cyan","dark green","dark magenta", + "dark red","medium blue","midnight blue","navy blue","sky blue","coral","gold","dark slate gray", + "dark slate grey","dim gray","dim grey","light gray","light grey","light green","forest green", + "lime green","pale green","spring green","maroon","orange","pink","indian red","orange red", + "violet red","salmon","sienna","tan","turquoise","violet","blue violet","wheat" }; +static char *CMV[] = { "blue","cyan","green","magenta","red","yellow","gray","grey","dark gray","dark grey", + "dark blue","brown","dark cyan","dark green","dark magenta","dark red"}; + + if( (vmask = visualsupported(display, 0L)) == 0L) { + delete("No visuals reported as valid."); + return; + } else + CHECK; + + for(resetsupvis(vmask); nextsupvis(&vp); ) { + + colormap = makecolmap(display, vp->visual, AllocNone); + i = 0; + supported = 0; + color_name = MVX[i]; + status = XCALL; + + if(status != 0) { + supported++; + break; + } else + unsupported++; + } + + if(unsupported == NELEM(MVX) && supported == 0) { + PASS; + return; + } + + for(resetsupvis(vmask); nextsupvis(&vp); ) { + colormap = makecolmap(display, vp->visual, AllocNone); + for(j=0; j<NELEM(CMV); j++) { + color_name = CMV[j]; + status = XCALL; + if(status == (Status) 0) { + report("Colour name \"%s\" is not supported.", color_name); + FAIL; + } else + CHECK; + } + } + + CHECKPASS(NELEM(CMV) * nsupvis() + 1); + diff --git a/xts5/Xopen/XStringToKeysym/Test1.c b/xts5/Xopen/XStringToKeysym/Test1.c new file mode 100644 index 00000000..1c434f94 --- /dev/null +++ b/xts5/Xopen/XStringToKeysym/Test1.c @@ -0,0 +1,2083 @@ +/* +Copyright (c) 2005 X.Org Foundation L.L.C. + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies +of the Software, and to permit persons to whom the Software is furnished to do +so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. +*/ +/* +* $Header: /cvs/xtest/xtest/xts5/tset/Xopen/XStringToKeysym/Test1.c,v 1.2 2005-11-03 08:44:01 jmichael Exp $ +* +* Project: VSW5 +* +* File: xts5/tset/Xopen/XStringToKeysym/Test1.c +* +* Description: +* Tests for XStringToKeysym() +* +* Modifications: +* $Log: Test1.c,v $ +* Revision 1.2 2005-11-03 08:44:01 jmichael +* clean up all vsw5 paths to use xts5 instead. +* +* Revision 1.1.1.2 2005/04/15 14:05:40 anderson +* Reimport of the base with the legal name in the copyright fixed. +* +* Revision 8.0 1998/12/23 23:35:53 mar +* Branch point for Release 5.0.2 +* +* Revision 7.0 1998/10/30 22:58:35 mar +* Branch point for Release 5.0.2b1 +* +* Revision 6.0 1998/03/02 05:27:06 tbr +* Branch point for Release 5.0.1 +* +* Revision 5.0 1998/01/26 03:23:39 tbr +* Branch point for Release 5.0.1b1 +* +* Revision 4.1 1996/05/09 21:19:34 andy +* Fixed X includes +* +* Revision 4.0 1995/12/15 09:14:31 tbr +* Branch point for Release 5.0.0 +* +* Revision 3.1 1995/12/15 01:17:55 andy +* Prepare for GA Release +* +*/ +/* + * SCCS: @(#) Test1.c Rel 1.1 (11/28/91) + * + * UniSoft Ltd., London, England + * + * (C) Copyright 1991 X/Open Company Limited + * + * All rights reserved. No part of this source code may be reproduced, + * stored in a retrieval system, or transmitted, in any form or by any + * means, electronic, mechanical, photocopying, recording or otherwise, + * except as stated in the end-user licence agreement, without the prior + * permission of the copyright owners. + * + * X/Open and the 'X' symbol are trademarks of X/Open Company Limited in + * the UK and other countries. + */ + +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif + +#include <stdlib.h> +#include "xtest.h" +#include "X11/Xlib.h" +#include "X11/Xutil.h" +#include "X11/Xresource.h" +#include "tet_api.h" +#include "xtestlib.h" +#include "pixval.h" + +extern char *TestName; + +static int +test(symbol, str) +KeySym symbol; +char *str; +{ +KeySym rsym; + + rsym = XStringToKeysym(str); + + if(rsym == NoSymbol) { + report("XStringToKeysym() returned NoSymbol for string \"%s\".", str); + return(0); + } + + if(rsym != symbol) { + report("XStringToKeysym() returned KeySym 0x%lx instead of 0x%lx.", (long) rsym, (long) symbol); + return(0); + } + return(1); +} + +static void +reporterr(s) +char *s; +{ + report("Symbol \"%s\" is not defined.", s); +} +#define XK_LATIN1 +#include <X11/keysymdef.h> +#undef XK_LATIN1 + +strtsym1() +{ +int pass = 0, fail = 0; +char *symstr; +KeySym rsym; + + +#ifdef XK_space + if(test(XK_space, "space") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_space"); + FAIL; +#endif + +#ifdef XK_exclam + if(test(XK_exclam, "exclam") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_exclam"); + FAIL; +#endif + +#ifdef XK_quotedbl + if(test(XK_quotedbl, "quotedbl") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_quotedbl"); + FAIL; +#endif + +#ifdef XK_numbersign + if(test(XK_numbersign, "numbersign") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_numbersign"); + FAIL; +#endif + +#ifdef XK_dollar + if(test(XK_dollar, "dollar") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_dollar"); + FAIL; +#endif + +#ifdef XK_percent + if(test(XK_percent, "percent") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_percent"); + FAIL; +#endif + +#ifdef XK_ampersand + if(test(XK_ampersand, "ampersand") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_ampersand"); + FAIL; +#endif + +#ifdef XK_apostrophe + if(test(XK_apostrophe, "apostrophe") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_apostrophe"); + FAIL; +#endif + +#ifdef XK_quoteright + if(test(XK_quoteright, "quoteright") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_quoteright"); + FAIL; +#endif + +#ifdef XK_parenleft + if(test(XK_parenleft, "parenleft") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_parenleft"); + FAIL; +#endif + +#ifdef XK_parenright + if(test(XK_parenright, "parenright") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_parenright"); + FAIL; +#endif + +#ifdef XK_asterisk + if(test(XK_asterisk, "asterisk") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_asterisk"); + FAIL; +#endif + +#ifdef XK_plus + if(test(XK_plus, "plus") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_plus"); + FAIL; +#endif + +#ifdef XK_comma + if(test(XK_comma, "comma") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_comma"); + FAIL; +#endif + +#ifdef XK_minus + if(test(XK_minus, "minus") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_minus"); + FAIL; +#endif + +#ifdef XK_period + if(test(XK_period, "period") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_period"); + FAIL; +#endif + +#ifdef XK_slash + if(test(XK_slash, "slash") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_slash"); + FAIL; +#endif + +#ifdef XK_0 + if(test(XK_0, "0") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_0"); + FAIL; +#endif + +#ifdef XK_1 + if(test(XK_1, "1") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_1"); + FAIL; +#endif + +#ifdef XK_2 + if(test(XK_2, "2") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_2"); + FAIL; +#endif + +#ifdef XK_3 + if(test(XK_3, "3") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_3"); + FAIL; +#endif + +#ifdef XK_4 + if(test(XK_4, "4") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_4"); + FAIL; +#endif + +#ifdef XK_5 + if(test(XK_5, "5") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_5"); + FAIL; +#endif + +#ifdef XK_6 + if(test(XK_6, "6") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_6"); + FAIL; +#endif + +#ifdef XK_7 + if(test(XK_7, "7") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_7"); + FAIL; +#endif + +#ifdef XK_8 + if(test(XK_8, "8") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_8"); + FAIL; +#endif + +#ifdef XK_9 + if(test(XK_9, "9") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_9"); + FAIL; +#endif + +#ifdef XK_colon + if(test(XK_colon, "colon") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_colon"); + FAIL; +#endif + +#ifdef XK_semicolon + if(test(XK_semicolon, "semicolon") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_semicolon"); + FAIL; +#endif + +#ifdef XK_less + if(test(XK_less, "less") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_less"); + FAIL; +#endif + +#ifdef XK_equal + if(test(XK_equal, "equal") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_equal"); + FAIL; +#endif + +#ifdef XK_greater + if(test(XK_greater, "greater") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_greater"); + FAIL; +#endif + +#ifdef XK_question + if(test(XK_question, "question") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_question"); + FAIL; +#endif + +#ifdef XK_at + if(test(XK_at, "at") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_at"); + FAIL; +#endif + +#ifdef XK_A + if(test(XK_A, "A") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_A"); + FAIL; +#endif + +#ifdef XK_B + if(test(XK_B, "B") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_B"); + FAIL; +#endif + +#ifdef XK_C + if(test(XK_C, "C") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_C"); + FAIL; +#endif + +#ifdef XK_D + if(test(XK_D, "D") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_D"); + FAIL; +#endif + +#ifdef XK_E + if(test(XK_E, "E") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_E"); + FAIL; +#endif + +#ifdef XK_F + if(test(XK_F, "F") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_F"); + FAIL; +#endif + +#ifdef XK_G + if(test(XK_G, "G") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_G"); + FAIL; +#endif + +#ifdef XK_H + if(test(XK_H, "H") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_H"); + FAIL; +#endif + +#ifdef XK_I + if(test(XK_I, "I") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_I"); + FAIL; +#endif + +#ifdef XK_J + if(test(XK_J, "J") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_J"); + FAIL; +#endif + +#ifdef XK_K + if(test(XK_K, "K") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_K"); + FAIL; +#endif + +#ifdef XK_L + if(test(XK_L, "L") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_L"); + FAIL; +#endif + +#ifdef XK_M + if(test(XK_M, "M") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_M"); + FAIL; +#endif + +#ifdef XK_N + if(test(XK_N, "N") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_N"); + FAIL; +#endif + +#ifdef XK_O + if(test(XK_O, "O") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_O"); + FAIL; +#endif + +#ifdef XK_P + if(test(XK_P, "P") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_P"); + FAIL; +#endif + +#ifdef XK_Q + if(test(XK_Q, "Q") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Q"); + FAIL; +#endif + +#ifdef XK_R + if(test(XK_R, "R") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_R"); + FAIL; +#endif + +#ifdef XK_S + if(test(XK_S, "S") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_S"); + FAIL; +#endif + +#ifdef XK_T + if(test(XK_T, "T") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_T"); + FAIL; +#endif + +#ifdef XK_U + if(test(XK_U, "U") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_U"); + FAIL; +#endif + +#ifdef XK_V + if(test(XK_V, "V") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_V"); + FAIL; +#endif + +#ifdef XK_W + if(test(XK_W, "W") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_W"); + FAIL; +#endif + +#ifdef XK_X + if(test(XK_X, "X") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_X"); + FAIL; +#endif + +#ifdef XK_Y + if(test(XK_Y, "Y") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Y"); + FAIL; +#endif + +#ifdef XK_Z + if(test(XK_Z, "Z") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Z"); + FAIL; +#endif + +#ifdef XK_bracketleft + if(test(XK_bracketleft, "bracketleft") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_bracketleft"); + FAIL; +#endif + +#ifdef XK_backslash + if(test(XK_backslash, "backslash") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_backslash"); + FAIL; +#endif + +#ifdef XK_bracketright + if(test(XK_bracketright, "bracketright") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_bracketright"); + FAIL; +#endif + +#ifdef XK_asciicircum + if(test(XK_asciicircum, "asciicircum") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_asciicircum"); + FAIL; +#endif + +#ifdef XK_underscore + if(test(XK_underscore, "underscore") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_underscore"); + FAIL; +#endif + +#ifdef XK_grave + if(test(XK_grave, "grave") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_grave"); + FAIL; +#endif + +#ifdef XK_quoteleft + if(test(XK_quoteleft, "quoteleft") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_quoteleft"); + FAIL; +#endif + +#ifdef XK_a + if(test(XK_a, "a") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_a"); + FAIL; +#endif + +#ifdef XK_b + if(test(XK_b, "b") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_b"); + FAIL; +#endif + +#ifdef XK_c + if(test(XK_c, "c") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_c"); + FAIL; +#endif + +#ifdef XK_d + if(test(XK_d, "d") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_d"); + FAIL; +#endif + +#ifdef XK_e + if(test(XK_e, "e") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_e"); + FAIL; +#endif + +#ifdef XK_f + if(test(XK_f, "f") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_f"); + FAIL; +#endif + +#ifdef XK_g + if(test(XK_g, "g") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_g"); + FAIL; +#endif + +#ifdef XK_h + if(test(XK_h, "h") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_h"); + FAIL; +#endif + +#ifdef XK_i + if(test(XK_i, "i") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_i"); + FAIL; +#endif + +#ifdef XK_j + if(test(XK_j, "j") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_j"); + FAIL; +#endif + +#ifdef XK_k + if(test(XK_k, "k") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_k"); + FAIL; +#endif + +#ifdef XK_l + if(test(XK_l, "l") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_l"); + FAIL; +#endif + +#ifdef XK_m + if(test(XK_m, "m") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_m"); + FAIL; +#endif + +#ifdef XK_n + if(test(XK_n, "n") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_n"); + FAIL; +#endif + +#ifdef XK_o + if(test(XK_o, "o") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_o"); + FAIL; +#endif + +#ifdef XK_p + if(test(XK_p, "p") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_p"); + FAIL; +#endif + +#ifdef XK_q + if(test(XK_q, "q") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_q"); + FAIL; +#endif + +#ifdef XK_r + if(test(XK_r, "r") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_r"); + FAIL; +#endif + +#ifdef XK_s + if(test(XK_s, "s") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_s"); + FAIL; +#endif + +#ifdef XK_t + if(test(XK_t, "t") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_t"); + FAIL; +#endif + +#ifdef XK_u + if(test(XK_u, "u") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_u"); + FAIL; +#endif + +#ifdef XK_v + if(test(XK_v, "v") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_v"); + FAIL; +#endif + +#ifdef XK_w + if(test(XK_w, "w") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_w"); + FAIL; +#endif + +#ifdef XK_x + if(test(XK_x, "x") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_x"); + FAIL; +#endif + +#ifdef XK_y + if(test(XK_y, "y") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_y"); + FAIL; +#endif + +#ifdef XK_z + if(test(XK_z, "z") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_z"); + FAIL; +#endif + +#ifdef XK_braceleft + if(test(XK_braceleft, "braceleft") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_braceleft"); + FAIL; +#endif + +#ifdef XK_bar + if(test(XK_bar, "bar") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_bar"); + FAIL; +#endif + +#ifdef XK_braceright + if(test(XK_braceright, "braceright") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_braceright"); + FAIL; +#endif + +#ifdef XK_asciitilde + if(test(XK_asciitilde, "asciitilde") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_asciitilde"); + FAIL; +#endif + +#ifdef XK_nobreakspace + if(test(XK_nobreakspace, "nobreakspace") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_nobreakspace"); + FAIL; +#endif + +#ifdef XK_exclamdown + if(test(XK_exclamdown, "exclamdown") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_exclamdown"); + FAIL; +#endif + +#ifdef XK_cent + if(test(XK_cent, "cent") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_cent"); + FAIL; +#endif + +#ifdef XK_sterling + if(test(XK_sterling, "sterling") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_sterling"); + FAIL; +#endif + +#ifdef XK_currency + if(test(XK_currency, "currency") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_currency"); + FAIL; +#endif + +#ifdef XK_yen + if(test(XK_yen, "yen") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_yen"); + FAIL; +#endif + +#ifdef XK_brokenbar + if(test(XK_brokenbar, "brokenbar") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_brokenbar"); + FAIL; +#endif + +#ifdef XK_section + if(test(XK_section, "section") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_section"); + FAIL; +#endif + +#ifdef XK_diaeresis + if(test(XK_diaeresis, "diaeresis") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_diaeresis"); + FAIL; +#endif + +#ifdef XK_copyright + if(test(XK_copyright, "copyright") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_copyright"); + FAIL; +#endif + +#ifdef XK_ordfeminine + if(test(XK_ordfeminine, "ordfeminine") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_ordfeminine"); + FAIL; +#endif + +#ifdef XK_guillemotleft + if(test(XK_guillemotleft, "guillemotleft") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_guillemotleft"); + FAIL; +#endif + +#ifdef XK_notsign + if(test(XK_notsign, "notsign") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_notsign"); + FAIL; +#endif + +#ifdef XK_hyphen + if(test(XK_hyphen, "hyphen") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_hyphen"); + FAIL; +#endif + +#ifdef XK_registered + if(test(XK_registered, "registered") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_registered"); + FAIL; +#endif + +#ifdef XK_macron + if(test(XK_macron, "macron") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_macron"); + FAIL; +#endif + +#ifdef XK_degree + if(test(XK_degree, "degree") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_degree"); + FAIL; +#endif + +#ifdef XK_plusminus + if(test(XK_plusminus, "plusminus") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_plusminus"); + FAIL; +#endif + +#ifdef XK_twosuperior + if(test(XK_twosuperior, "twosuperior") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_twosuperior"); + FAIL; +#endif + +#ifdef XK_threesuperior + if(test(XK_threesuperior, "threesuperior") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_threesuperior"); + FAIL; +#endif + +#ifdef XK_acute + if(test(XK_acute, "acute") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_acute"); + FAIL; +#endif + +#ifdef XK_mu + if(test(XK_mu, "mu") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_mu"); + FAIL; +#endif + +#ifdef XK_paragraph + if(test(XK_paragraph, "paragraph") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_paragraph"); + FAIL; +#endif + +#ifdef XK_periodcentered + if(test(XK_periodcentered, "periodcentered") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_periodcentered"); + FAIL; +#endif + +#ifdef XK_cedilla + if(test(XK_cedilla, "cedilla") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_cedilla"); + FAIL; +#endif + +#ifdef XK_onesuperior + if(test(XK_onesuperior, "onesuperior") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_onesuperior"); + FAIL; +#endif + +#ifdef XK_masculine + if(test(XK_masculine, "masculine") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_masculine"); + FAIL; +#endif + +#ifdef XK_guillemotright + if(test(XK_guillemotright, "guillemotright") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_guillemotright"); + FAIL; +#endif + +#ifdef XK_onequarter + if(test(XK_onequarter, "onequarter") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_onequarter"); + FAIL; +#endif + +#ifdef XK_onehalf + if(test(XK_onehalf, "onehalf") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_onehalf"); + FAIL; +#endif + +#ifdef XK_threequarters + if(test(XK_threequarters, "threequarters") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_threequarters"); + FAIL; +#endif + +#ifdef XK_questiondown + if(test(XK_questiondown, "questiondown") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_questiondown"); + FAIL; +#endif + +#ifdef XK_Agrave + if(test(XK_Agrave, "Agrave") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Agrave"); + FAIL; +#endif + +#ifdef XK_Aacute + if(test(XK_Aacute, "Aacute") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Aacute"); + FAIL; +#endif + +#ifdef XK_Acircumflex + if(test(XK_Acircumflex, "Acircumflex") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Acircumflex"); + FAIL; +#endif + +#ifdef XK_Atilde + if(test(XK_Atilde, "Atilde") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Atilde"); + FAIL; +#endif + +#ifdef XK_Adiaeresis + if(test(XK_Adiaeresis, "Adiaeresis") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Adiaeresis"); + FAIL; +#endif + +#ifdef XK_Aring + if(test(XK_Aring, "Aring") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Aring"); + FAIL; +#endif + +#ifdef XK_AE + if(test(XK_AE, "AE") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_AE"); + FAIL; +#endif + +#ifdef XK_Ccedilla + if(test(XK_Ccedilla, "Ccedilla") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Ccedilla"); + FAIL; +#endif + +#ifdef XK_Egrave + if(test(XK_Egrave, "Egrave") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Egrave"); + FAIL; +#endif + +#ifdef XK_Eacute + if(test(XK_Eacute, "Eacute") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Eacute"); + FAIL; +#endif + +#ifdef XK_Ecircumflex + if(test(XK_Ecircumflex, "Ecircumflex") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Ecircumflex"); + FAIL; +#endif + +#ifdef XK_Ediaeresis + if(test(XK_Ediaeresis, "Ediaeresis") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Ediaeresis"); + FAIL; +#endif + +#ifdef XK_Igrave + if(test(XK_Igrave, "Igrave") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Igrave"); + FAIL; +#endif + +#ifdef XK_Iacute + if(test(XK_Iacute, "Iacute") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Iacute"); + FAIL; +#endif + +#ifdef XK_Icircumflex + if(test(XK_Icircumflex, "Icircumflex") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Icircumflex"); + FAIL; +#endif + +#ifdef XK_Idiaeresis + if(test(XK_Idiaeresis, "Idiaeresis") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Idiaeresis"); + FAIL; +#endif + +#ifdef XK_ETH + if(test(XK_ETH, "ETH") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_ETH"); + FAIL; +#endif + +#ifdef XK_Eth + if(test(XK_Eth, "Eth") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Eth"); + FAIL; +#endif + +#ifdef XK_Ntilde + if(test(XK_Ntilde, "Ntilde") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Ntilde"); + FAIL; +#endif + +#ifdef XK_Ograve + if(test(XK_Ograve, "Ograve") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Ograve"); + FAIL; +#endif + +#ifdef XK_Oacute + if(test(XK_Oacute, "Oacute") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Oacute"); + FAIL; +#endif + +#ifdef XK_Ocircumflex + if(test(XK_Ocircumflex, "Ocircumflex") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Ocircumflex"); + FAIL; +#endif + +#ifdef XK_Otilde + if(test(XK_Otilde, "Otilde") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Otilde"); + FAIL; +#endif + +#ifdef XK_Odiaeresis + if(test(XK_Odiaeresis, "Odiaeresis") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Odiaeresis"); + FAIL; +#endif + +#ifdef XK_multiply + if(test(XK_multiply, "multiply") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_multiply"); + FAIL; +#endif + +#ifdef XK_Ooblique + if(test(XK_Ooblique, "Ooblique") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Ooblique"); + FAIL; +#endif + +#ifdef XK_Ugrave + if(test(XK_Ugrave, "Ugrave") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Ugrave"); + FAIL; +#endif + +#ifdef XK_Uacute + if(test(XK_Uacute, "Uacute") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Uacute"); + FAIL; +#endif + +#ifdef XK_Ucircumflex + if(test(XK_Ucircumflex, "Ucircumflex") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Ucircumflex"); + FAIL; +#endif + +#ifdef XK_Udiaeresis + if(test(XK_Udiaeresis, "Udiaeresis") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Udiaeresis"); + FAIL; +#endif + +#ifdef XK_Yacute + if(test(XK_Yacute, "Yacute") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Yacute"); + FAIL; +#endif + +#ifdef XK_THORN + if(test(XK_THORN, "THORN") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_THORN"); + FAIL; +#endif + +#ifdef XK_Thorn + if(test(XK_Thorn, "Thorn") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Thorn"); + FAIL; +#endif + +#ifdef XK_ssharp + if(test(XK_ssharp, "ssharp") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_ssharp"); + FAIL; +#endif + +#ifdef XK_agrave + if(test(XK_agrave, "agrave") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_agrave"); + FAIL; +#endif + +#ifdef XK_aacute + if(test(XK_aacute, "aacute") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_aacute"); + FAIL; +#endif + +#ifdef XK_acircumflex + if(test(XK_acircumflex, "acircumflex") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_acircumflex"); + FAIL; +#endif + +#ifdef XK_atilde + if(test(XK_atilde, "atilde") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_atilde"); + FAIL; +#endif + +#ifdef XK_adiaeresis + if(test(XK_adiaeresis, "adiaeresis") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_adiaeresis"); + FAIL; +#endif + +#ifdef XK_aring + if(test(XK_aring, "aring") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_aring"); + FAIL; +#endif + +#ifdef XK_ae + if(test(XK_ae, "ae") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_ae"); + FAIL; +#endif + +#ifdef XK_ccedilla + if(test(XK_ccedilla, "ccedilla") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_ccedilla"); + FAIL; +#endif + +#ifdef XK_egrave + if(test(XK_egrave, "egrave") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_egrave"); + FAIL; +#endif + +#ifdef XK_eacute + if(test(XK_eacute, "eacute") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_eacute"); + FAIL; +#endif + +#ifdef XK_ecircumflex + if(test(XK_ecircumflex, "ecircumflex") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_ecircumflex"); + FAIL; +#endif + +#ifdef XK_ediaeresis + if(test(XK_ediaeresis, "ediaeresis") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_ediaeresis"); + FAIL; +#endif + +#ifdef XK_igrave + if(test(XK_igrave, "igrave") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_igrave"); + FAIL; +#endif + +#ifdef XK_iacute + if(test(XK_iacute, "iacute") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_iacute"); + FAIL; +#endif + +#ifdef XK_icircumflex + if(test(XK_icircumflex, "icircumflex") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_icircumflex"); + FAIL; +#endif + +#ifdef XK_idiaeresis + if(test(XK_idiaeresis, "idiaeresis") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_idiaeresis"); + FAIL; +#endif + +#ifdef XK_eth + if(test(XK_eth, "eth") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_eth"); + FAIL; +#endif + +#ifdef XK_ntilde + if(test(XK_ntilde, "ntilde") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_ntilde"); + FAIL; +#endif + +#ifdef XK_ograve + if(test(XK_ograve, "ograve") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_ograve"); + FAIL; +#endif + +#ifdef XK_oacute + if(test(XK_oacute, "oacute") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_oacute"); + FAIL; +#endif + +#ifdef XK_ocircumflex + if(test(XK_ocircumflex, "ocircumflex") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_ocircumflex"); + FAIL; +#endif + +#ifdef XK_otilde + if(test(XK_otilde, "otilde") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_otilde"); + FAIL; +#endif + +#ifdef XK_odiaeresis + if(test(XK_odiaeresis, "odiaeresis") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_odiaeresis"); + FAIL; +#endif + +#ifdef XK_division + if(test(XK_division, "division") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_division"); + FAIL; +#endif + +#ifdef XK_oslash + if(test(XK_oslash, "oslash") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_oslash"); + FAIL; +#endif + +#ifdef XK_ugrave + if(test(XK_ugrave, "ugrave") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_ugrave"); + FAIL; +#endif + +#ifdef XK_uacute + if(test(XK_uacute, "uacute") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_uacute"); + FAIL; +#endif + +#ifdef XK_ucircumflex + if(test(XK_ucircumflex, "ucircumflex") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_ucircumflex"); + FAIL; +#endif + +#ifdef XK_udiaeresis + if(test(XK_udiaeresis, "udiaeresis") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_udiaeresis"); + FAIL; +#endif + +#ifdef XK_yacute + if(test(XK_yacute, "yacute") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_yacute"); + FAIL; +#endif + +#ifdef XK_thorn + if(test(XK_thorn, "thorn") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_thorn"); + FAIL; +#endif + +#ifdef XK_ydiaeresis + if(test(XK_ydiaeresis, "ydiaeresis") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_ydiaeresis"); + FAIL; +#endif + + CHECKPASS(195); +} diff --git a/xts5/Xopen/XStringToKeysym/Test2.c b/xts5/Xopen/XStringToKeysym/Test2.c new file mode 100644 index 00000000..dab2770b --- /dev/null +++ b/xts5/Xopen/XStringToKeysym/Test2.c @@ -0,0 +1,703 @@ +/* +Copyright (c) 2005 X.Org Foundation L.L.C. + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies +of the Software, and to permit persons to whom the Software is furnished to do +so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. +*/ +/* +* $Header: /cvs/xtest/xtest/xts5/tset/Xopen/XStringToKeysym/Test2.c,v 1.2 2005-11-03 08:44:01 jmichael Exp $ +* +* Project: VSW5 +* +* File: xts5/tset/Xopen/XStringToKeysym/Test2.c +* +* Description: +* Tests for XStringToKeysym() +* +* Modifications: +* $Log: Test2.c,v $ +* Revision 1.2 2005-11-03 08:44:01 jmichael +* clean up all vsw5 paths to use xts5 instead. +* +* Revision 1.1.1.2 2005/04/15 14:05:40 anderson +* Reimport of the base with the legal name in the copyright fixed. +* +* Revision 8.0 1998/12/23 23:35:53 mar +* Branch point for Release 5.0.2 +* +* Revision 7.0 1998/10/30 22:58:35 mar +* Branch point for Release 5.0.2b1 +* +* Revision 6.0 1998/03/02 05:27:06 tbr +* Branch point for Release 5.0.1 +* +* Revision 5.0 1998/01/26 03:23:40 tbr +* Branch point for Release 5.0.1b1 +* +* Revision 4.1 1996/05/09 21:19:34 andy +* Fixed X includes +* +* Revision 4.0 1995/12/15 09:14:33 tbr +* Branch point for Release 5.0.0 +* +* Revision 3.1 1995/12/15 01:17:57 andy +* Prepare for GA Release +* +*/ +/* + * SCCS: @(#) Test2.c Rel 1.1 (11/28/91) + * + * UniSoft Ltd., London, England + * + * (C) Copyright 1991 X/Open Company Limited + * + * All rights reserved. No part of this source code may be reproduced, + * stored in a retrieval system, or transmitted, in any form or by any + * means, electronic, mechanical, photocopying, recording or otherwise, + * except as stated in the end-user licence agreement, without the prior + * permission of the copyright owners. + * + * X/Open and the 'X' symbol are trademarks of X/Open Company Limited in + * the UK and other countries. + */ + +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif + +#include <stdlib.h> +#include "xtest.h" +#include "X11/Xlib.h" +#include "X11/Xutil.h" +#include "X11/Xresource.h" +#include "tet_api.h" +#include "xtestlib.h" +#include "pixval.h" + +extern char *TestName; + +static int +test(symbol, str) +KeySym symbol; +char *str; +{ +KeySym rsym; + + rsym = XStringToKeysym(str); + + if(rsym == NoSymbol) { + report("XStringToKeysym() returned NoSymbol for string \"%s\".", str); + return(0); + } + + if(rsym != symbol) { + report("XStringToKeysym() returned KeySym 0x%lx instead of 0x%lx.", (long) rsym, (long) symbol); + return(0); + } + return(1); +} + +static void +reporterr(s) +char *s; +{ + report("Symbol \"%s\" is not defined.", s); +} +#define XK_LATIN2 +#include <X11/keysymdef.h> +#undef XK_LATIN2 + +strtsym2() +{ +int pass = 0, fail = 0; +char *symstr; +KeySym rsym; + + +#ifdef XK_Aogonek + if(test(XK_Aogonek, "Aogonek") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Aogonek"); + FAIL; +#endif + +#ifdef XK_breve + if(test(XK_breve, "breve") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_breve"); + FAIL; +#endif + +#ifdef XK_Lstroke + if(test(XK_Lstroke, "Lstroke") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Lstroke"); + FAIL; +#endif + +#ifdef XK_Lcaron + if(test(XK_Lcaron, "Lcaron") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Lcaron"); + FAIL; +#endif + +#ifdef XK_Sacute + if(test(XK_Sacute, "Sacute") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Sacute"); + FAIL; +#endif + +#ifdef XK_Scaron + if(test(XK_Scaron, "Scaron") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Scaron"); + FAIL; +#endif + +#ifdef XK_Scedilla + if(test(XK_Scedilla, "Scedilla") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Scedilla"); + FAIL; +#endif + +#ifdef XK_Tcaron + if(test(XK_Tcaron, "Tcaron") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Tcaron"); + FAIL; +#endif + +#ifdef XK_Zacute + if(test(XK_Zacute, "Zacute") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Zacute"); + FAIL; +#endif + +#ifdef XK_Zcaron + if(test(XK_Zcaron, "Zcaron") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Zcaron"); + FAIL; +#endif + +#ifdef XK_Zabovedot + if(test(XK_Zabovedot, "Zabovedot") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Zabovedot"); + FAIL; +#endif + +#ifdef XK_aogonek + if(test(XK_aogonek, "aogonek") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_aogonek"); + FAIL; +#endif + +#ifdef XK_ogonek + if(test(XK_ogonek, "ogonek") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_ogonek"); + FAIL; +#endif + +#ifdef XK_lstroke + if(test(XK_lstroke, "lstroke") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_lstroke"); + FAIL; +#endif + +#ifdef XK_lcaron + if(test(XK_lcaron, "lcaron") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_lcaron"); + FAIL; +#endif + +#ifdef XK_sacute + if(test(XK_sacute, "sacute") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_sacute"); + FAIL; +#endif + +#ifdef XK_caron + if(test(XK_caron, "caron") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_caron"); + FAIL; +#endif + +#ifdef XK_scaron + if(test(XK_scaron, "scaron") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_scaron"); + FAIL; +#endif + +#ifdef XK_scedilla + if(test(XK_scedilla, "scedilla") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_scedilla"); + FAIL; +#endif + +#ifdef XK_tcaron + if(test(XK_tcaron, "tcaron") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_tcaron"); + FAIL; +#endif + +#ifdef XK_zacute + if(test(XK_zacute, "zacute") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_zacute"); + FAIL; +#endif + +#ifdef XK_doubleacute + if(test(XK_doubleacute, "doubleacute") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_doubleacute"); + FAIL; +#endif + +#ifdef XK_zcaron + if(test(XK_zcaron, "zcaron") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_zcaron"); + FAIL; +#endif + +#ifdef XK_zabovedot + if(test(XK_zabovedot, "zabovedot") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_zabovedot"); + FAIL; +#endif + +#ifdef XK_Racute + if(test(XK_Racute, "Racute") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Racute"); + FAIL; +#endif + +#ifdef XK_Abreve + if(test(XK_Abreve, "Abreve") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Abreve"); + FAIL; +#endif + +#ifdef XK_Lacute + if(test(XK_Lacute, "Lacute") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Lacute"); + FAIL; +#endif + +#ifdef XK_Cacute + if(test(XK_Cacute, "Cacute") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Cacute"); + FAIL; +#endif + +#ifdef XK_Ccaron + if(test(XK_Ccaron, "Ccaron") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Ccaron"); + FAIL; +#endif + +#ifdef XK_Eogonek + if(test(XK_Eogonek, "Eogonek") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Eogonek"); + FAIL; +#endif + +#ifdef XK_Ecaron + if(test(XK_Ecaron, "Ecaron") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Ecaron"); + FAIL; +#endif + +#ifdef XK_Dcaron + if(test(XK_Dcaron, "Dcaron") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Dcaron"); + FAIL; +#endif + +#ifdef XK_Dstroke + if(test(XK_Dstroke, "Dstroke") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Dstroke"); + FAIL; +#endif + +#ifdef XK_Nacute + if(test(XK_Nacute, "Nacute") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Nacute"); + FAIL; +#endif + +#ifdef XK_Ncaron + if(test(XK_Ncaron, "Ncaron") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Ncaron"); + FAIL; +#endif + +#ifdef XK_Odoubleacute + if(test(XK_Odoubleacute, "Odoubleacute") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Odoubleacute"); + FAIL; +#endif + +#ifdef XK_Rcaron + if(test(XK_Rcaron, "Rcaron") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Rcaron"); + FAIL; +#endif + +#ifdef XK_Uring + if(test(XK_Uring, "Uring") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Uring"); + FAIL; +#endif + +#ifdef XK_Udoubleacute + if(test(XK_Udoubleacute, "Udoubleacute") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Udoubleacute"); + FAIL; +#endif + +#ifdef XK_Tcedilla + if(test(XK_Tcedilla, "Tcedilla") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Tcedilla"); + FAIL; +#endif + +#ifdef XK_racute + if(test(XK_racute, "racute") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_racute"); + FAIL; +#endif + +#ifdef XK_abreve + if(test(XK_abreve, "abreve") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_abreve"); + FAIL; +#endif + +#ifdef XK_lacute + if(test(XK_lacute, "lacute") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_lacute"); + FAIL; +#endif + +#ifdef XK_cacute + if(test(XK_cacute, "cacute") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_cacute"); + FAIL; +#endif + +#ifdef XK_ccaron + if(test(XK_ccaron, "ccaron") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_ccaron"); + FAIL; +#endif + +#ifdef XK_eogonek + if(test(XK_eogonek, "eogonek") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_eogonek"); + FAIL; +#endif + +#ifdef XK_ecaron + if(test(XK_ecaron, "ecaron") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_ecaron"); + FAIL; +#endif + +#ifdef XK_dcaron + if(test(XK_dcaron, "dcaron") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_dcaron"); + FAIL; +#endif + +#ifdef XK_dstroke + if(test(XK_dstroke, "dstroke") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_dstroke"); + FAIL; +#endif + +#ifdef XK_nacute + if(test(XK_nacute, "nacute") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_nacute"); + FAIL; +#endif + +#ifdef XK_ncaron + if(test(XK_ncaron, "ncaron") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_ncaron"); + FAIL; +#endif + +#ifdef XK_odoubleacute + if(test(XK_odoubleacute, "odoubleacute") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_odoubleacute"); + FAIL; +#endif + +#ifdef XK_rcaron + if(test(XK_rcaron, "rcaron") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_rcaron"); + FAIL; +#endif + +#ifdef XK_uring + if(test(XK_uring, "uring") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_uring"); + FAIL; +#endif + +#ifdef XK_udoubleacute + if(test(XK_udoubleacute, "udoubleacute") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_udoubleacute"); + FAIL; +#endif + +#ifdef XK_tcedilla + if(test(XK_tcedilla, "tcedilla") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_tcedilla"); + FAIL; +#endif + +#ifdef XK_abovedot + if(test(XK_abovedot, "abovedot") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_abovedot"); + FAIL; +#endif + + CHECKPASS(57); +} diff --git a/xts5/Xopen/XStringToKeysym/Test3.c b/xts5/Xopen/XStringToKeysym/Test3.c new file mode 100644 index 00000000..b4d82fea --- /dev/null +++ b/xts5/Xopen/XStringToKeysym/Test3.c @@ -0,0 +1,353 @@ +/* +Copyright (c) 2005 X.Org Foundation L.L.C. + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies +of the Software, and to permit persons to whom the Software is furnished to do +so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. +*/ +/* +* $Header: /cvs/xtest/xtest/xts5/tset/Xopen/XStringToKeysym/Test3.c,v 1.2 2005-11-03 08:44:01 jmichael Exp $ +* +* Project: VSW5 +* +* File: xts5/tset/Xopen/XStringToKeysym/Test3.c +* +* Description: +* Tests for XStringToKeysym() +* +* Modifications: +* $Log: Test3.c,v $ +* Revision 1.2 2005-11-03 08:44:01 jmichael +* clean up all vsw5 paths to use xts5 instead. +* +* Revision 1.1.1.2 2005/04/15 14:05:40 anderson +* Reimport of the base with the legal name in the copyright fixed. +* +* Revision 8.0 1998/12/23 23:35:54 mar +* Branch point for Release 5.0.2 +* +* Revision 7.0 1998/10/30 22:58:36 mar +* Branch point for Release 5.0.2b1 +* +* Revision 6.0 1998/03/02 05:27:07 tbr +* Branch point for Release 5.0.1 +* +* Revision 5.0 1998/01/26 03:23:40 tbr +* Branch point for Release 5.0.1b1 +* +* Revision 4.1 1996/05/09 21:19:34 andy +* Fixed X includes +* +* Revision 4.0 1995/12/15 09:14:34 tbr +* Branch point for Release 5.0.0 +* +* Revision 3.1 1995/12/15 01:17:58 andy +* Prepare for GA Release +* +*/ +/* + * SCCS: @(#) Test3.c Rel 1.1 (11/28/91) + * + * UniSoft Ltd., London, England + * + * (C) Copyright 1991 X/Open Company Limited + * + * All rights reserved. No part of this source code may be reproduced, + * stored in a retrieval system, or transmitted, in any form or by any + * means, electronic, mechanical, photocopying, recording or otherwise, + * except as stated in the end-user licence agreement, without the prior + * permission of the copyright owners. + * + * X/Open and the 'X' symbol are trademarks of X/Open Company Limited in + * the UK and other countries. + */ + +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif + +#include <stdlib.h> +#include "xtest.h" +#include "X11/Xlib.h" +#include "X11/Xutil.h" +#include "X11/Xresource.h" +#include "tet_api.h" +#include "xtestlib.h" +#include "pixval.h" + +extern char *TestName; + +static int +test(symbol, str) +KeySym symbol; +char *str; +{ +KeySym rsym; + + rsym = XStringToKeysym(str); + + if(rsym == NoSymbol) { + report("XStringToKeysym() returned NoSymbol for string \"%s\".", str); + return(0); + } + + if(rsym != symbol) { + report("XStringToKeysym() returned KeySym 0x%lx instead of 0x%lx.", (long) rsym, (long) symbol); + return(0); + } + return(1); +} + +static void +reporterr(s) +char *s; +{ + report("Symbol \"%s\" is not defined.", s); +} +#define XK_LATIN3 +#include <X11/keysymdef.h> +#undef XK_LATIN3 + +strtsym3() +{ +int pass = 0, fail = 0; +char *symstr; +KeySym rsym; + + +#ifdef XK_Hstroke + if(test(XK_Hstroke, "Hstroke") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Hstroke"); + FAIL; +#endif + +#ifdef XK_Hcircumflex + if(test(XK_Hcircumflex, "Hcircumflex") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Hcircumflex"); + FAIL; +#endif + +#ifdef XK_Iabovedot + if(test(XK_Iabovedot, "Iabovedot") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Iabovedot"); + FAIL; +#endif + +#ifdef XK_Gbreve + if(test(XK_Gbreve, "Gbreve") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Gbreve"); + FAIL; +#endif + +#ifdef XK_Jcircumflex + if(test(XK_Jcircumflex, "Jcircumflex") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Jcircumflex"); + FAIL; +#endif + +#ifdef XK_hstroke + if(test(XK_hstroke, "hstroke") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_hstroke"); + FAIL; +#endif + +#ifdef XK_hcircumflex + if(test(XK_hcircumflex, "hcircumflex") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_hcircumflex"); + FAIL; +#endif + +#ifdef XK_idotless + if(test(XK_idotless, "idotless") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_idotless"); + FAIL; +#endif + +#ifdef XK_gbreve + if(test(XK_gbreve, "gbreve") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_gbreve"); + FAIL; +#endif + +#ifdef XK_jcircumflex + if(test(XK_jcircumflex, "jcircumflex") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_jcircumflex"); + FAIL; +#endif + +#ifdef XK_Cabovedot + if(test(XK_Cabovedot, "Cabovedot") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Cabovedot"); + FAIL; +#endif + +#ifdef XK_Ccircumflex + if(test(XK_Ccircumflex, "Ccircumflex") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Ccircumflex"); + FAIL; +#endif + +#ifdef XK_Gabovedot + if(test(XK_Gabovedot, "Gabovedot") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Gabovedot"); + FAIL; +#endif + +#ifdef XK_Gcircumflex + if(test(XK_Gcircumflex, "Gcircumflex") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Gcircumflex"); + FAIL; +#endif + +#ifdef XK_Ubreve + if(test(XK_Ubreve, "Ubreve") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Ubreve"); + FAIL; +#endif + +#ifdef XK_Scircumflex + if(test(XK_Scircumflex, "Scircumflex") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Scircumflex"); + FAIL; +#endif + +#ifdef XK_cabovedot + if(test(XK_cabovedot, "cabovedot") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_cabovedot"); + FAIL; +#endif + +#ifdef XK_ccircumflex + if(test(XK_ccircumflex, "ccircumflex") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_ccircumflex"); + FAIL; +#endif + +#ifdef XK_gabovedot + if(test(XK_gabovedot, "gabovedot") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_gabovedot"); + FAIL; +#endif + +#ifdef XK_gcircumflex + if(test(XK_gcircumflex, "gcircumflex") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_gcircumflex"); + FAIL; +#endif + +#ifdef XK_ubreve + if(test(XK_ubreve, "ubreve") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_ubreve"); + FAIL; +#endif + +#ifdef XK_scircumflex + if(test(XK_scircumflex, "scircumflex") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_scircumflex"); + FAIL; +#endif + + CHECKPASS(22); +} diff --git a/xts5/Xopen/XStringToKeysym/Test4.c b/xts5/Xopen/XStringToKeysym/Test4.c new file mode 100644 index 00000000..4e3db003 --- /dev/null +++ b/xts5/Xopen/XStringToKeysym/Test4.c @@ -0,0 +1,493 @@ +/* +Copyright (c) 2005 X.Org Foundation L.L.C. + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies +of the Software, and to permit persons to whom the Software is furnished to do +so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. +*/ +/* +* $Header: /cvs/xtest/xtest/xts5/tset/Xopen/XStringToKeysym/Test4.c,v 1.2 2005-11-03 08:44:01 jmichael Exp $ +* +* Project: VSW5 +* +* File: xts5/tset/Xopen/XStringToKeysym/Test4.c +* +* Description: +* Tests for XStringToKeysym() +* +* Modifications: +* $Log: Test4.c,v $ +* Revision 1.2 2005-11-03 08:44:01 jmichael +* clean up all vsw5 paths to use xts5 instead. +* +* Revision 1.1.1.2 2005/04/15 14:05:40 anderson +* Reimport of the base with the legal name in the copyright fixed. +* +* Revision 8.0 1998/12/23 23:35:54 mar +* Branch point for Release 5.0.2 +* +* Revision 7.0 1998/10/30 22:58:37 mar +* Branch point for Release 5.0.2b1 +* +* Revision 6.0 1998/03/02 05:27:07 tbr +* Branch point for Release 5.0.1 +* +* Revision 5.0 1998/01/26 03:23:41 tbr +* Branch point for Release 5.0.1b1 +* +* Revision 4.1 1996/05/09 21:19:34 andy +* Fixed X includes +* +* Revision 4.0 1995/12/15 09:14:35 tbr +* Branch point for Release 5.0.0 +* +* Revision 3.1 1995/12/15 01:18:00 andy +* Prepare for GA Release +* +*/ +/* + * SCCS: @(#) Test4.c Rel 1.1 (11/28/91) + * + * UniSoft Ltd., London, England + * + * (C) Copyright 1991 X/Open Company Limited + * + * All rights reserved. No part of this source code may be reproduced, + * stored in a retrieval system, or transmitted, in any form or by any + * means, electronic, mechanical, photocopying, recording or otherwise, + * except as stated in the end-user licence agreement, without the prior + * permission of the copyright owners. + * + * X/Open and the 'X' symbol are trademarks of X/Open Company Limited in + * the UK and other countries. + */ + +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif + +#include <stdlib.h> +#include "xtest.h" +#include "X11/Xlib.h" +#include "X11/Xutil.h" +#include "X11/Xresource.h" +#include "tet_api.h" +#include "xtestlib.h" +#include "pixval.h" + +extern char *TestName; + +static int +test(symbol, str) +KeySym symbol; +char *str; +{ +KeySym rsym; + + rsym = XStringToKeysym(str); + + if(rsym == NoSymbol) { + report("XStringToKeysym() returned NoSymbol for string \"%s\".", str); + return(0); + } + + if(rsym != symbol) { + report("XStringToKeysym() returned KeySym 0x%lx instead of 0x%lx.", (long) rsym, (long) symbol); + return(0); + } + return(1); +} + +static void +reporterr(s) +char *s; +{ + report("Symbol \"%s\" is not defined.", s); +} +#define XK_LATIN4 +#include <X11/keysymdef.h> +#undef XK_LATIN4 + +strtsym4() +{ +int pass = 0, fail = 0; +char *symstr; +KeySym rsym; + + +#ifdef XK_kra + if(test(XK_kra, "kra") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_kra"); + FAIL; +#endif + +#ifdef XK_kappa + if(test(XK_kappa, "kappa") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_kappa"); + FAIL; +#endif + +#ifdef XK_Rcedilla + if(test(XK_Rcedilla, "Rcedilla") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Rcedilla"); + FAIL; +#endif + +#ifdef XK_Itilde + if(test(XK_Itilde, "Itilde") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Itilde"); + FAIL; +#endif + +#ifdef XK_Lcedilla + if(test(XK_Lcedilla, "Lcedilla") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Lcedilla"); + FAIL; +#endif + +#ifdef XK_Emacron + if(test(XK_Emacron, "Emacron") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Emacron"); + FAIL; +#endif + +#ifdef XK_Gcedilla + if(test(XK_Gcedilla, "Gcedilla") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Gcedilla"); + FAIL; +#endif + +#ifdef XK_Tslash + if(test(XK_Tslash, "Tslash") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Tslash"); + FAIL; +#endif + +#ifdef XK_rcedilla + if(test(XK_rcedilla, "rcedilla") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_rcedilla"); + FAIL; +#endif + +#ifdef XK_itilde + if(test(XK_itilde, "itilde") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_itilde"); + FAIL; +#endif + +#ifdef XK_lcedilla + if(test(XK_lcedilla, "lcedilla") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_lcedilla"); + FAIL; +#endif + +#ifdef XK_emacron + if(test(XK_emacron, "emacron") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_emacron"); + FAIL; +#endif + +#ifdef XK_gcedilla + if(test(XK_gcedilla, "gcedilla") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_gcedilla"); + FAIL; +#endif + +#ifdef XK_tslash + if(test(XK_tslash, "tslash") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_tslash"); + FAIL; +#endif + +#ifdef XK_ENG + if(test(XK_ENG, "ENG") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_ENG"); + FAIL; +#endif + +#ifdef XK_eng + if(test(XK_eng, "eng") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_eng"); + FAIL; +#endif + +#ifdef XK_Amacron + if(test(XK_Amacron, "Amacron") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Amacron"); + FAIL; +#endif + +#ifdef XK_Iogonek + if(test(XK_Iogonek, "Iogonek") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Iogonek"); + FAIL; +#endif + +#ifdef XK_Eabovedot + if(test(XK_Eabovedot, "Eabovedot") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Eabovedot"); + FAIL; +#endif + +#ifdef XK_Imacron + if(test(XK_Imacron, "Imacron") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Imacron"); + FAIL; +#endif + +#ifdef XK_Ncedilla + if(test(XK_Ncedilla, "Ncedilla") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Ncedilla"); + FAIL; +#endif + +#ifdef XK_Omacron + if(test(XK_Omacron, "Omacron") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Omacron"); + FAIL; +#endif + +#ifdef XK_Kcedilla + if(test(XK_Kcedilla, "Kcedilla") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Kcedilla"); + FAIL; +#endif + +#ifdef XK_Uogonek + if(test(XK_Uogonek, "Uogonek") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Uogonek"); + FAIL; +#endif + +#ifdef XK_Utilde + if(test(XK_Utilde, "Utilde") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Utilde"); + FAIL; +#endif + +#ifdef XK_Umacron + if(test(XK_Umacron, "Umacron") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Umacron"); + FAIL; +#endif + +#ifdef XK_amacron + if(test(XK_amacron, "amacron") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_amacron"); + FAIL; +#endif + +#ifdef XK_iogonek + if(test(XK_iogonek, "iogonek") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_iogonek"); + FAIL; +#endif + +#ifdef XK_eabovedot + if(test(XK_eabovedot, "eabovedot") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_eabovedot"); + FAIL; +#endif + +#ifdef XK_imacron + if(test(XK_imacron, "imacron") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_imacron"); + FAIL; +#endif + +#ifdef XK_ncedilla + if(test(XK_ncedilla, "ncedilla") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_ncedilla"); + FAIL; +#endif + +#ifdef XK_omacron + if(test(XK_omacron, "omacron") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_omacron"); + FAIL; +#endif + +#ifdef XK_kcedilla + if(test(XK_kcedilla, "kcedilla") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_kcedilla"); + FAIL; +#endif + +#ifdef XK_uogonek + if(test(XK_uogonek, "uogonek") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_uogonek"); + FAIL; +#endif + +#ifdef XK_utilde + if(test(XK_utilde, "utilde") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_utilde"); + FAIL; +#endif + +#ifdef XK_umacron + if(test(XK_umacron, "umacron") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_umacron"); + FAIL; +#endif + + CHECKPASS(36); +} diff --git a/xts5/Xopen/XStringToKeysym/TestA.c b/xts5/Xopen/XStringToKeysym/TestA.c new file mode 100644 index 00000000..351a5c94 --- /dev/null +++ b/xts5/Xopen/XStringToKeysym/TestA.c @@ -0,0 +1,633 @@ +/* +Copyright (c) 2005 X.Org Foundation L.L.C. + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies +of the Software, and to permit persons to whom the Software is furnished to do +so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. +*/ +/* +* $Header: /cvs/xtest/xtest/xts5/tset/Xopen/XStringToKeysym/TestA.c,v 1.2 2005-11-03 08:44:01 jmichael Exp $ +* +* Project: VSW5 +* +* File: xts5/tset/Xopen/XStringToKeysym/TestA.c +* +* Description: +* Tests for XStringToKeysym() +* +* Modifications: +* $Log: TestA.c,v $ +* Revision 1.2 2005-11-03 08:44:01 jmichael +* clean up all vsw5 paths to use xts5 instead. +* +* Revision 1.1.1.2 2005/04/15 14:05:40 anderson +* Reimport of the base with the legal name in the copyright fixed. +* +* Revision 8.0 1998/12/23 23:35:55 mar +* Branch point for Release 5.0.2 +* +* Revision 7.0 1998/10/30 22:58:38 mar +* Branch point for Release 5.0.2b1 +* +* Revision 6.0 1998/03/02 05:27:08 tbr +* Branch point for Release 5.0.1 +* +* Revision 5.0 1998/01/26 03:23:41 tbr +* Branch point for Release 5.0.1b1 +* +* Revision 4.1 1996/05/09 21:19:34 andy +* Fixed X includes +* +* Revision 4.0 1995/12/15 09:14:36 tbr +* Branch point for Release 5.0.0 +* +* Revision 3.1 1995/12/15 01:18:01 andy +* Prepare for GA Release +* +*/ +/* + * SCCS: @(#) TestA.c Rel 1.1 (11/28/91) + * + * UniSoft Ltd., London, England + * + * (C) Copyright 1991 X/Open Company Limited + * + * All rights reserved. No part of this source code may be reproduced, + * stored in a retrieval system, or transmitted, in any form or by any + * means, electronic, mechanical, photocopying, recording or otherwise, + * except as stated in the end-user licence agreement, without the prior + * permission of the copyright owners. + * + * X/Open and the 'X' symbol are trademarks of X/Open Company Limited in + * the UK and other countries. + */ + +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif + +#include <stdlib.h> +#include "xtest.h" +#include "X11/Xlib.h" +#include "X11/Xutil.h" +#include "X11/Xresource.h" +#include "tet_api.h" +#include "xtestlib.h" +#include "pixval.h" + +extern char *TestName; + +static int +test(symbol, str) +KeySym symbol; +char *str; +{ +KeySym rsym; + + rsym = XStringToKeysym(str); + + if(rsym == NoSymbol) { + report("XStringToKeysym() returned NoSymbol for string \"%s\".", str); + return(0); + } + + if(rsym != symbol) { + report("XStringToKeysym() returned KeySym 0x%lx instead of 0x%lx.", (long) rsym, (long) symbol); + return(0); + } + return(1); +} + +static void +reporterr(s) +char *s; +{ + report("Symbol \"%s\" is not defined.", s); +} +#define XK_ARABIC +#include <X11/keysymdef.h> +#undef XK_ARABIC + +strtsymA() +{ +int pass = 0, fail = 0; +char *symstr; +KeySym rsym; + + +#ifdef XK_Arabic_comma + if(test(XK_Arabic_comma, "Arabic_comma") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Arabic_comma"); + FAIL; +#endif + +#ifdef XK_Arabic_semicolon + if(test(XK_Arabic_semicolon, "Arabic_semicolon") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Arabic_semicolon"); + FAIL; +#endif + +#ifdef XK_Arabic_question_mark + if(test(XK_Arabic_question_mark, "Arabic_question_mark") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Arabic_question_mark"); + FAIL; +#endif + +#ifdef XK_Arabic_hamza + if(test(XK_Arabic_hamza, "Arabic_hamza") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Arabic_hamza"); + FAIL; +#endif + +#ifdef XK_Arabic_maddaonalef + if(test(XK_Arabic_maddaonalef, "Arabic_maddaonalef") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Arabic_maddaonalef"); + FAIL; +#endif + +#ifdef XK_Arabic_hamzaonalef + if(test(XK_Arabic_hamzaonalef, "Arabic_hamzaonalef") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Arabic_hamzaonalef"); + FAIL; +#endif + +#ifdef XK_Arabic_hamzaonwaw + if(test(XK_Arabic_hamzaonwaw, "Arabic_hamzaonwaw") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Arabic_hamzaonwaw"); + FAIL; +#endif + +#ifdef XK_Arabic_hamzaunderalef + if(test(XK_Arabic_hamzaunderalef, "Arabic_hamzaunderalef") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Arabic_hamzaunderalef"); + FAIL; +#endif + +#ifdef XK_Arabic_hamzaonyeh + if(test(XK_Arabic_hamzaonyeh, "Arabic_hamzaonyeh") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Arabic_hamzaonyeh"); + FAIL; +#endif + +#ifdef XK_Arabic_alef + if(test(XK_Arabic_alef, "Arabic_alef") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Arabic_alef"); + FAIL; +#endif + +#ifdef XK_Arabic_beh + if(test(XK_Arabic_beh, "Arabic_beh") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Arabic_beh"); + FAIL; +#endif + +#ifdef XK_Arabic_tehmarbuta + if(test(XK_Arabic_tehmarbuta, "Arabic_tehmarbuta") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Arabic_tehmarbuta"); + FAIL; +#endif + +#ifdef XK_Arabic_teh + if(test(XK_Arabic_teh, "Arabic_teh") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Arabic_teh"); + FAIL; +#endif + +#ifdef XK_Arabic_theh + if(test(XK_Arabic_theh, "Arabic_theh") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Arabic_theh"); + FAIL; +#endif + +#ifdef XK_Arabic_jeem + if(test(XK_Arabic_jeem, "Arabic_jeem") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Arabic_jeem"); + FAIL; +#endif + +#ifdef XK_Arabic_hah + if(test(XK_Arabic_hah, "Arabic_hah") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Arabic_hah"); + FAIL; +#endif + +#ifdef XK_Arabic_khah + if(test(XK_Arabic_khah, "Arabic_khah") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Arabic_khah"); + FAIL; +#endif + +#ifdef XK_Arabic_dal + if(test(XK_Arabic_dal, "Arabic_dal") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Arabic_dal"); + FAIL; +#endif + +#ifdef XK_Arabic_thal + if(test(XK_Arabic_thal, "Arabic_thal") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Arabic_thal"); + FAIL; +#endif + +#ifdef XK_Arabic_ra + if(test(XK_Arabic_ra, "Arabic_ra") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Arabic_ra"); + FAIL; +#endif + +#ifdef XK_Arabic_zain + if(test(XK_Arabic_zain, "Arabic_zain") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Arabic_zain"); + FAIL; +#endif + +#ifdef XK_Arabic_seen + if(test(XK_Arabic_seen, "Arabic_seen") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Arabic_seen"); + FAIL; +#endif + +#ifdef XK_Arabic_sheen + if(test(XK_Arabic_sheen, "Arabic_sheen") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Arabic_sheen"); + FAIL; +#endif + +#ifdef XK_Arabic_sad + if(test(XK_Arabic_sad, "Arabic_sad") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Arabic_sad"); + FAIL; +#endif + +#ifdef XK_Arabic_dad + if(test(XK_Arabic_dad, "Arabic_dad") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Arabic_dad"); + FAIL; +#endif + +#ifdef XK_Arabic_tah + if(test(XK_Arabic_tah, "Arabic_tah") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Arabic_tah"); + FAIL; +#endif + +#ifdef XK_Arabic_zah + if(test(XK_Arabic_zah, "Arabic_zah") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Arabic_zah"); + FAIL; +#endif + +#ifdef XK_Arabic_ain + if(test(XK_Arabic_ain, "Arabic_ain") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Arabic_ain"); + FAIL; +#endif + +#ifdef XK_Arabic_ghain + if(test(XK_Arabic_ghain, "Arabic_ghain") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Arabic_ghain"); + FAIL; +#endif + +#ifdef XK_Arabic_tatweel + if(test(XK_Arabic_tatweel, "Arabic_tatweel") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Arabic_tatweel"); + FAIL; +#endif + +#ifdef XK_Arabic_feh + if(test(XK_Arabic_feh, "Arabic_feh") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Arabic_feh"); + FAIL; +#endif + +#ifdef XK_Arabic_qaf + if(test(XK_Arabic_qaf, "Arabic_qaf") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Arabic_qaf"); + FAIL; +#endif + +#ifdef XK_Arabic_kaf + if(test(XK_Arabic_kaf, "Arabic_kaf") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Arabic_kaf"); + FAIL; +#endif + +#ifdef XK_Arabic_lam + if(test(XK_Arabic_lam, "Arabic_lam") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Arabic_lam"); + FAIL; +#endif + +#ifdef XK_Arabic_meem + if(test(XK_Arabic_meem, "Arabic_meem") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Arabic_meem"); + FAIL; +#endif + +#ifdef XK_Arabic_noon + if(test(XK_Arabic_noon, "Arabic_noon") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Arabic_noon"); + FAIL; +#endif + +#ifdef XK_Arabic_ha + if(test(XK_Arabic_ha, "Arabic_ha") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Arabic_ha"); + FAIL; +#endif + +#ifdef XK_Arabic_heh + if(test(XK_Arabic_heh, "Arabic_heh") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Arabic_heh"); + FAIL; +#endif + +#ifdef XK_Arabic_waw + if(test(XK_Arabic_waw, "Arabic_waw") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Arabic_waw"); + FAIL; +#endif + +#ifdef XK_Arabic_alefmaksura + if(test(XK_Arabic_alefmaksura, "Arabic_alefmaksura") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Arabic_alefmaksura"); + FAIL; +#endif + +#ifdef XK_Arabic_yeh + if(test(XK_Arabic_yeh, "Arabic_yeh") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Arabic_yeh"); + FAIL; +#endif + +#ifdef XK_Arabic_fathatan + if(test(XK_Arabic_fathatan, "Arabic_fathatan") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Arabic_fathatan"); + FAIL; +#endif + +#ifdef XK_Arabic_dammatan + if(test(XK_Arabic_dammatan, "Arabic_dammatan") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Arabic_dammatan"); + FAIL; +#endif + +#ifdef XK_Arabic_kasratan + if(test(XK_Arabic_kasratan, "Arabic_kasratan") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Arabic_kasratan"); + FAIL; +#endif + +#ifdef XK_Arabic_fatha + if(test(XK_Arabic_fatha, "Arabic_fatha") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Arabic_fatha"); + FAIL; +#endif + +#ifdef XK_Arabic_damma + if(test(XK_Arabic_damma, "Arabic_damma") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Arabic_damma"); + FAIL; +#endif + +#ifdef XK_Arabic_kasra + if(test(XK_Arabic_kasra, "Arabic_kasra") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Arabic_kasra"); + FAIL; +#endif + +#ifdef XK_Arabic_shadda + if(test(XK_Arabic_shadda, "Arabic_shadda") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Arabic_shadda"); + FAIL; +#endif + +#ifdef XK_Arabic_sukun + if(test(XK_Arabic_sukun, "Arabic_sukun") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Arabic_sukun"); + FAIL; +#endif + +#ifdef XK_Arabic_switch + if(test(XK_Arabic_switch, "Arabic_switch") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Arabic_switch"); + FAIL; +#endif + + CHECKPASS(50); +} diff --git a/xts5/Xopen/XStringToKeysym/TestC.c b/xts5/Xopen/XStringToKeysym/TestC.c new file mode 100644 index 00000000..39063da7 --- /dev/null +++ b/xts5/Xopen/XStringToKeysym/TestC.c @@ -0,0 +1,1203 @@ +/* +Copyright (c) 2005 X.Org Foundation L.L.C. + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies +of the Software, and to permit persons to whom the Software is furnished to do +so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. +*/ +/* +* $Header: /cvs/xtest/xtest/xts5/tset/Xopen/XStringToKeysym/TestC.c,v 1.2 2005-11-03 08:44:01 jmichael Exp $ +* +* Project: VSW5 +* +* File: xts5/tset/Xopen/XStringToKeysym/TestC.c +* +* Description: +* Tests for XStringToKeysym() +* +* Modifications: +* $Log: TestC.c,v $ +* Revision 1.2 2005-11-03 08:44:01 jmichael +* clean up all vsw5 paths to use xts5 instead. +* +* Revision 1.1.1.2 2005/04/15 14:05:40 anderson +* Reimport of the base with the legal name in the copyright fixed. +* +* Revision 8.0 1998/12/23 23:35:55 mar +* Branch point for Release 5.0.2 +* +* Revision 7.0 1998/10/30 22:58:39 mar +* Branch point for Release 5.0.2b1 +* +* Revision 6.0 1998/03/02 05:27:08 tbr +* Branch point for Release 5.0.1 +* +* Revision 5.0 1998/01/26 03:23:42 tbr +* Branch point for Release 5.0.1b1 +* +* Revision 4.1 1996/05/09 21:19:34 andy +* Fixed X includes +* +* Revision 4.0 1995/12/15 09:14:38 tbr +* Branch point for Release 5.0.0 +* +* Revision 3.1 1995/12/15 01:18:03 andy +* Prepare for GA Release +* +*/ +/* + * SCCS: @(#) TestC.c Rel 1.1 (11/28/91) + * + * UniSoft Ltd., London, England + * + * (C) Copyright 1991 X/Open Company Limited + * + * All rights reserved. No part of this source code may be reproduced, + * stored in a retrieval system, or transmitted, in any form or by any + * means, electronic, mechanical, photocopying, recording or otherwise, + * except as stated in the end-user licence agreement, without the prior + * permission of the copyright owners. + * + * X/Open and the 'X' symbol are trademarks of X/Open Company Limited in + * the UK and other countries. + */ + +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif + +#include <stdlib.h> +#include "xtest.h" +#include "X11/Xlib.h" +#include "X11/Xutil.h" +#include "X11/Xresource.h" +#include "tet_api.h" +#include "xtestlib.h" +#include "pixval.h" + +extern char *TestName; + +static int +test(symbol, str) +KeySym symbol; +char *str; +{ +KeySym rsym; + + rsym = XStringToKeysym(str); + + if(rsym == NoSymbol) { + report("XStringToKeysym() returned NoSymbol for string \"%s\".", str); + return(0); + } + + if(rsym != symbol) { + report("XStringToKeysym() returned KeySym 0x%lx instead of 0x%lx.", (long) rsym, (long) symbol); + return(0); + } + return(1); +} + +static void +reporterr(s) +char *s; +{ + report("Symbol \"%s\" is not defined.", s); +} +#define XK_CYRILLIC +#include <X11/keysymdef.h> +#undef XK_CYRILLIC + +strtsymC() +{ +int pass = 0, fail = 0; +char *symstr; +KeySym rsym; + + +#ifdef XK_Serbian_dje + if(test(XK_Serbian_dje, "Serbian_dje") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Serbian_dje"); + FAIL; +#endif + +#ifdef XK_Macedonia_gje + if(test(XK_Macedonia_gje, "Macedonia_gje") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Macedonia_gje"); + FAIL; +#endif + +#ifdef XK_Cyrillic_io + if(test(XK_Cyrillic_io, "Cyrillic_io") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Cyrillic_io"); + FAIL; +#endif + +#ifdef XK_Ukrainian_ie + if(test(XK_Ukrainian_ie, "Ukrainian_ie") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Ukrainian_ie"); + FAIL; +#endif + +#ifdef XK_Ukranian_je + if(test(XK_Ukranian_je, "Ukranian_je") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Ukranian_je"); + FAIL; +#endif + +#ifdef XK_Macedonia_dse + if(test(XK_Macedonia_dse, "Macedonia_dse") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Macedonia_dse"); + FAIL; +#endif + +#ifdef XK_Ukrainian_i + if(test(XK_Ukrainian_i, "Ukrainian_i") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Ukrainian_i"); + FAIL; +#endif + +#ifdef XK_Ukranian_i + if(test(XK_Ukranian_i, "Ukranian_i") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Ukranian_i"); + FAIL; +#endif + +#ifdef XK_Ukrainian_yi + if(test(XK_Ukrainian_yi, "Ukrainian_yi") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Ukrainian_yi"); + FAIL; +#endif + +#ifdef XK_Ukranian_yi + if(test(XK_Ukranian_yi, "Ukranian_yi") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Ukranian_yi"); + FAIL; +#endif + +#ifdef XK_Cyrillic_je + if(test(XK_Cyrillic_je, "Cyrillic_je") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Cyrillic_je"); + FAIL; +#endif + +#ifdef XK_Serbian_je + if(test(XK_Serbian_je, "Serbian_je") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Serbian_je"); + FAIL; +#endif + +#ifdef XK_Cyrillic_lje + if(test(XK_Cyrillic_lje, "Cyrillic_lje") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Cyrillic_lje"); + FAIL; +#endif + +#ifdef XK_Serbian_lje + if(test(XK_Serbian_lje, "Serbian_lje") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Serbian_lje"); + FAIL; +#endif + +#ifdef XK_Cyrillic_nje + if(test(XK_Cyrillic_nje, "Cyrillic_nje") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Cyrillic_nje"); + FAIL; +#endif + +#ifdef XK_Serbian_nje + if(test(XK_Serbian_nje, "Serbian_nje") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Serbian_nje"); + FAIL; +#endif + +#ifdef XK_Serbian_tshe + if(test(XK_Serbian_tshe, "Serbian_tshe") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Serbian_tshe"); + FAIL; +#endif + +#ifdef XK_Macedonia_kje + if(test(XK_Macedonia_kje, "Macedonia_kje") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Macedonia_kje"); + FAIL; +#endif + +#ifdef XK_Byelorussian_shortu + if(test(XK_Byelorussian_shortu, "Byelorussian_shortu") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Byelorussian_shortu"); + FAIL; +#endif + +#ifdef XK_Cyrillic_dzhe + if(test(XK_Cyrillic_dzhe, "Cyrillic_dzhe") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Cyrillic_dzhe"); + FAIL; +#endif + +#ifdef XK_Serbian_dze + if(test(XK_Serbian_dze, "Serbian_dze") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Serbian_dze"); + FAIL; +#endif + +#ifdef XK_numerosign + if(test(XK_numerosign, "numerosign") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_numerosign"); + FAIL; +#endif + +#ifdef XK_Serbian_DJE + if(test(XK_Serbian_DJE, "Serbian_DJE") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Serbian_DJE"); + FAIL; +#endif + +#ifdef XK_Macedonia_GJE + if(test(XK_Macedonia_GJE, "Macedonia_GJE") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Macedonia_GJE"); + FAIL; +#endif + +#ifdef XK_Cyrillic_IO + if(test(XK_Cyrillic_IO, "Cyrillic_IO") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Cyrillic_IO"); + FAIL; +#endif + +#ifdef XK_Ukrainian_IE + if(test(XK_Ukrainian_IE, "Ukrainian_IE") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Ukrainian_IE"); + FAIL; +#endif + +#ifdef XK_Ukranian_JE + if(test(XK_Ukranian_JE, "Ukranian_JE") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Ukranian_JE"); + FAIL; +#endif + +#ifdef XK_Macedonia_DSE + if(test(XK_Macedonia_DSE, "Macedonia_DSE") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Macedonia_DSE"); + FAIL; +#endif + +#ifdef XK_Ukrainian_I + if(test(XK_Ukrainian_I, "Ukrainian_I") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Ukrainian_I"); + FAIL; +#endif + +#ifdef XK_Ukranian_I + if(test(XK_Ukranian_I, "Ukranian_I") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Ukranian_I"); + FAIL; +#endif + +#ifdef XK_Ukrainian_YI + if(test(XK_Ukrainian_YI, "Ukrainian_YI") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Ukrainian_YI"); + FAIL; +#endif + +#ifdef XK_Ukranian_YI + if(test(XK_Ukranian_YI, "Ukranian_YI") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Ukranian_YI"); + FAIL; +#endif + +#ifdef XK_Cyrillic_JE + if(test(XK_Cyrillic_JE, "Cyrillic_JE") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Cyrillic_JE"); + FAIL; +#endif + +#ifdef XK_Serbian_JE + if(test(XK_Serbian_JE, "Serbian_JE") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Serbian_JE"); + FAIL; +#endif + +#ifdef XK_Cyrillic_LJE + if(test(XK_Cyrillic_LJE, "Cyrillic_LJE") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Cyrillic_LJE"); + FAIL; +#endif + +#ifdef XK_Serbian_LJE + if(test(XK_Serbian_LJE, "Serbian_LJE") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Serbian_LJE"); + FAIL; +#endif + +#ifdef XK_Cyrillic_NJE + if(test(XK_Cyrillic_NJE, "Cyrillic_NJE") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Cyrillic_NJE"); + FAIL; +#endif + +#ifdef XK_Serbian_NJE + if(test(XK_Serbian_NJE, "Serbian_NJE") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Serbian_NJE"); + FAIL; +#endif + +#ifdef XK_Serbian_TSHE + if(test(XK_Serbian_TSHE, "Serbian_TSHE") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Serbian_TSHE"); + FAIL; +#endif + +#ifdef XK_Macedonia_KJE + if(test(XK_Macedonia_KJE, "Macedonia_KJE") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Macedonia_KJE"); + FAIL; +#endif + +#ifdef XK_Byelorussian_SHORTU + if(test(XK_Byelorussian_SHORTU, "Byelorussian_SHORTU") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Byelorussian_SHORTU"); + FAIL; +#endif + +#ifdef XK_Cyrillic_DZHE + if(test(XK_Cyrillic_DZHE, "Cyrillic_DZHE") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Cyrillic_DZHE"); + FAIL; +#endif + +#ifdef XK_Serbian_DZE + if(test(XK_Serbian_DZE, "Serbian_DZE") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Serbian_DZE"); + FAIL; +#endif + +#ifdef XK_Cyrillic_yu + if(test(XK_Cyrillic_yu, "Cyrillic_yu") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Cyrillic_yu"); + FAIL; +#endif + +#ifdef XK_Cyrillic_a + if(test(XK_Cyrillic_a, "Cyrillic_a") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Cyrillic_a"); + FAIL; +#endif + +#ifdef XK_Cyrillic_be + if(test(XK_Cyrillic_be, "Cyrillic_be") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Cyrillic_be"); + FAIL; +#endif + +#ifdef XK_Cyrillic_tse + if(test(XK_Cyrillic_tse, "Cyrillic_tse") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Cyrillic_tse"); + FAIL; +#endif + +#ifdef XK_Cyrillic_de + if(test(XK_Cyrillic_de, "Cyrillic_de") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Cyrillic_de"); + FAIL; +#endif + +#ifdef XK_Cyrillic_ie + if(test(XK_Cyrillic_ie, "Cyrillic_ie") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Cyrillic_ie"); + FAIL; +#endif + +#ifdef XK_Cyrillic_ef + if(test(XK_Cyrillic_ef, "Cyrillic_ef") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Cyrillic_ef"); + FAIL; +#endif + +#ifdef XK_Cyrillic_ghe + if(test(XK_Cyrillic_ghe, "Cyrillic_ghe") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Cyrillic_ghe"); + FAIL; +#endif + +#ifdef XK_Cyrillic_ha + if(test(XK_Cyrillic_ha, "Cyrillic_ha") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Cyrillic_ha"); + FAIL; +#endif + +#ifdef XK_Cyrillic_i + if(test(XK_Cyrillic_i, "Cyrillic_i") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Cyrillic_i"); + FAIL; +#endif + +#ifdef XK_Cyrillic_shorti + if(test(XK_Cyrillic_shorti, "Cyrillic_shorti") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Cyrillic_shorti"); + FAIL; +#endif + +#ifdef XK_Cyrillic_ka + if(test(XK_Cyrillic_ka, "Cyrillic_ka") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Cyrillic_ka"); + FAIL; +#endif + +#ifdef XK_Cyrillic_el + if(test(XK_Cyrillic_el, "Cyrillic_el") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Cyrillic_el"); + FAIL; +#endif + +#ifdef XK_Cyrillic_em + if(test(XK_Cyrillic_em, "Cyrillic_em") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Cyrillic_em"); + FAIL; +#endif + +#ifdef XK_Cyrillic_en + if(test(XK_Cyrillic_en, "Cyrillic_en") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Cyrillic_en"); + FAIL; +#endif + +#ifdef XK_Cyrillic_o + if(test(XK_Cyrillic_o, "Cyrillic_o") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Cyrillic_o"); + FAIL; +#endif + +#ifdef XK_Cyrillic_pe + if(test(XK_Cyrillic_pe, "Cyrillic_pe") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Cyrillic_pe"); + FAIL; +#endif + +#ifdef XK_Cyrillic_ya + if(test(XK_Cyrillic_ya, "Cyrillic_ya") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Cyrillic_ya"); + FAIL; +#endif + +#ifdef XK_Cyrillic_er + if(test(XK_Cyrillic_er, "Cyrillic_er") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Cyrillic_er"); + FAIL; +#endif + +#ifdef XK_Cyrillic_es + if(test(XK_Cyrillic_es, "Cyrillic_es") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Cyrillic_es"); + FAIL; +#endif + +#ifdef XK_Cyrillic_te + if(test(XK_Cyrillic_te, "Cyrillic_te") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Cyrillic_te"); + FAIL; +#endif + +#ifdef XK_Cyrillic_u + if(test(XK_Cyrillic_u, "Cyrillic_u") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Cyrillic_u"); + FAIL; +#endif + +#ifdef XK_Cyrillic_zhe + if(test(XK_Cyrillic_zhe, "Cyrillic_zhe") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Cyrillic_zhe"); + FAIL; +#endif + +#ifdef XK_Cyrillic_ve + if(test(XK_Cyrillic_ve, "Cyrillic_ve") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Cyrillic_ve"); + FAIL; +#endif + +#ifdef XK_Cyrillic_softsign + if(test(XK_Cyrillic_softsign, "Cyrillic_softsign") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Cyrillic_softsign"); + FAIL; +#endif + +#ifdef XK_Cyrillic_yeru + if(test(XK_Cyrillic_yeru, "Cyrillic_yeru") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Cyrillic_yeru"); + FAIL; +#endif + +#ifdef XK_Cyrillic_ze + if(test(XK_Cyrillic_ze, "Cyrillic_ze") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Cyrillic_ze"); + FAIL; +#endif + +#ifdef XK_Cyrillic_sha + if(test(XK_Cyrillic_sha, "Cyrillic_sha") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Cyrillic_sha"); + FAIL; +#endif + +#ifdef XK_Cyrillic_e + if(test(XK_Cyrillic_e, "Cyrillic_e") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Cyrillic_e"); + FAIL; +#endif + +#ifdef XK_Cyrillic_shcha + if(test(XK_Cyrillic_shcha, "Cyrillic_shcha") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Cyrillic_shcha"); + FAIL; +#endif + +#ifdef XK_Cyrillic_che + if(test(XK_Cyrillic_che, "Cyrillic_che") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Cyrillic_che"); + FAIL; +#endif + +#ifdef XK_Cyrillic_hardsign + if(test(XK_Cyrillic_hardsign, "Cyrillic_hardsign") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Cyrillic_hardsign"); + FAIL; +#endif + +#ifdef XK_Cyrillic_YU + if(test(XK_Cyrillic_YU, "Cyrillic_YU") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Cyrillic_YU"); + FAIL; +#endif + +#ifdef XK_Cyrillic_A + if(test(XK_Cyrillic_A, "Cyrillic_A") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Cyrillic_A"); + FAIL; +#endif + +#ifdef XK_Cyrillic_BE + if(test(XK_Cyrillic_BE, "Cyrillic_BE") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Cyrillic_BE"); + FAIL; +#endif + +#ifdef XK_Cyrillic_TSE + if(test(XK_Cyrillic_TSE, "Cyrillic_TSE") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Cyrillic_TSE"); + FAIL; +#endif + +#ifdef XK_Cyrillic_DE + if(test(XK_Cyrillic_DE, "Cyrillic_DE") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Cyrillic_DE"); + FAIL; +#endif + +#ifdef XK_Cyrillic_IE + if(test(XK_Cyrillic_IE, "Cyrillic_IE") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Cyrillic_IE"); + FAIL; +#endif + +#ifdef XK_Cyrillic_EF + if(test(XK_Cyrillic_EF, "Cyrillic_EF") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Cyrillic_EF"); + FAIL; +#endif + +#ifdef XK_Cyrillic_GHE + if(test(XK_Cyrillic_GHE, "Cyrillic_GHE") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Cyrillic_GHE"); + FAIL; +#endif + +#ifdef XK_Cyrillic_HA + if(test(XK_Cyrillic_HA, "Cyrillic_HA") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Cyrillic_HA"); + FAIL; +#endif + +#ifdef XK_Cyrillic_I + if(test(XK_Cyrillic_I, "Cyrillic_I") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Cyrillic_I"); + FAIL; +#endif + +#ifdef XK_Cyrillic_SHORTI + if(test(XK_Cyrillic_SHORTI, "Cyrillic_SHORTI") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Cyrillic_SHORTI"); + FAIL; +#endif + +#ifdef XK_Cyrillic_KA + if(test(XK_Cyrillic_KA, "Cyrillic_KA") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Cyrillic_KA"); + FAIL; +#endif + +#ifdef XK_Cyrillic_EL + if(test(XK_Cyrillic_EL, "Cyrillic_EL") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Cyrillic_EL"); + FAIL; +#endif + +#ifdef XK_Cyrillic_EM + if(test(XK_Cyrillic_EM, "Cyrillic_EM") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Cyrillic_EM"); + FAIL; +#endif + +#ifdef XK_Cyrillic_EN + if(test(XK_Cyrillic_EN, "Cyrillic_EN") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Cyrillic_EN"); + FAIL; +#endif + +#ifdef XK_Cyrillic_O + if(test(XK_Cyrillic_O, "Cyrillic_O") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Cyrillic_O"); + FAIL; +#endif + +#ifdef XK_Cyrillic_PE + if(test(XK_Cyrillic_PE, "Cyrillic_PE") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Cyrillic_PE"); + FAIL; +#endif + +#ifdef XK_Cyrillic_YA + if(test(XK_Cyrillic_YA, "Cyrillic_YA") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Cyrillic_YA"); + FAIL; +#endif + +#ifdef XK_Cyrillic_ER + if(test(XK_Cyrillic_ER, "Cyrillic_ER") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Cyrillic_ER"); + FAIL; +#endif + +#ifdef XK_Cyrillic_ES + if(test(XK_Cyrillic_ES, "Cyrillic_ES") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Cyrillic_ES"); + FAIL; +#endif + +#ifdef XK_Cyrillic_TE + if(test(XK_Cyrillic_TE, "Cyrillic_TE") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Cyrillic_TE"); + FAIL; +#endif + +#ifdef XK_Cyrillic_U + if(test(XK_Cyrillic_U, "Cyrillic_U") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Cyrillic_U"); + FAIL; +#endif + +#ifdef XK_Cyrillic_ZHE + if(test(XK_Cyrillic_ZHE, "Cyrillic_ZHE") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Cyrillic_ZHE"); + FAIL; +#endif + +#ifdef XK_Cyrillic_VE + if(test(XK_Cyrillic_VE, "Cyrillic_VE") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Cyrillic_VE"); + FAIL; +#endif + +#ifdef XK_Cyrillic_SOFTSIGN + if(test(XK_Cyrillic_SOFTSIGN, "Cyrillic_SOFTSIGN") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Cyrillic_SOFTSIGN"); + FAIL; +#endif + +#ifdef XK_Cyrillic_YERU + if(test(XK_Cyrillic_YERU, "Cyrillic_YERU") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Cyrillic_YERU"); + FAIL; +#endif + +#ifdef XK_Cyrillic_ZE + if(test(XK_Cyrillic_ZE, "Cyrillic_ZE") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Cyrillic_ZE"); + FAIL; +#endif + +#ifdef XK_Cyrillic_SHA + if(test(XK_Cyrillic_SHA, "Cyrillic_SHA") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Cyrillic_SHA"); + FAIL; +#endif + +#ifdef XK_Cyrillic_E + if(test(XK_Cyrillic_E, "Cyrillic_E") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Cyrillic_E"); + FAIL; +#endif + +#ifdef XK_Cyrillic_SHCHA + if(test(XK_Cyrillic_SHCHA, "Cyrillic_SHCHA") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Cyrillic_SHCHA"); + FAIL; +#endif + +#ifdef XK_Cyrillic_CHE + if(test(XK_Cyrillic_CHE, "Cyrillic_CHE") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Cyrillic_CHE"); + FAIL; +#endif + +#ifdef XK_Cyrillic_HARDSIGN + if(test(XK_Cyrillic_HARDSIGN, "Cyrillic_HARDSIGN") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Cyrillic_HARDSIGN"); + FAIL; +#endif + + CHECKPASS(107); +} diff --git a/xts5/Xopen/XStringToKeysym/TestG.c b/xts5/Xopen/XStringToKeysym/TestG.c new file mode 100644 index 00000000..b7914b5b --- /dev/null +++ b/xts5/Xopen/XStringToKeysym/TestG.c @@ -0,0 +1,873 @@ +/* +Copyright (c) 2005 X.Org Foundation L.L.C. + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies +of the Software, and to permit persons to whom the Software is furnished to do +so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. +*/ +/* +* $Header: /cvs/xtest/xtest/xts5/tset/Xopen/XStringToKeysym/TestG.c,v 1.2 2005-11-03 08:44:01 jmichael Exp $ +* +* Project: VSW5 +* +* File: xts5/tset/Xopen/XStringToKeysym/TestG.c +* +* Description: +* Tests for XStringToKeysym() +* +* Modifications: +* $Log: TestG.c,v $ +* Revision 1.2 2005-11-03 08:44:01 jmichael +* clean up all vsw5 paths to use xts5 instead. +* +* Revision 1.1.1.2 2005/04/15 14:05:40 anderson +* Reimport of the base with the legal name in the copyright fixed. +* +* Revision 8.0 1998/12/23 23:35:56 mar +* Branch point for Release 5.0.2 +* +* Revision 7.0 1998/10/30 22:58:39 mar +* Branch point for Release 5.0.2b1 +* +* Revision 6.0 1998/03/02 05:27:09 tbr +* Branch point for Release 5.0.1 +* +* Revision 5.0 1998/01/26 03:23:42 tbr +* Branch point for Release 5.0.1b1 +* +* Revision 4.1 1996/05/09 21:19:34 andy +* Fixed X includes +* +* Revision 4.0 1995/12/15 09:14:39 tbr +* Branch point for Release 5.0.0 +* +* Revision 3.1 1995/12/15 01:18:05 andy +* Prepare for GA Release +* +*/ +/* + * SCCS: @(#) TestG.c Rel 1.1 (11/28/91) + * + * UniSoft Ltd., London, England + * + * (C) Copyright 1991 X/Open Company Limited + * + * All rights reserved. No part of this source code may be reproduced, + * stored in a retrieval system, or transmitted, in any form or by any + * means, electronic, mechanical, photocopying, recording or otherwise, + * except as stated in the end-user licence agreement, without the prior + * permission of the copyright owners. + * + * X/Open and the 'X' symbol are trademarks of X/Open Company Limited in + * the UK and other countries. + */ + +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif + +#include <stdlib.h> +#include "xtest.h" +#include "X11/Xlib.h" +#include "X11/Xutil.h" +#include "X11/Xresource.h" +#include "tet_api.h" +#include "xtestlib.h" +#include "pixval.h" + +extern char *TestName; + +static int +test(symbol, str) +KeySym symbol; +char *str; +{ +KeySym rsym; + + rsym = XStringToKeysym(str); + + if(rsym == NoSymbol) { + report("XStringToKeysym() returned NoSymbol for string \"%s\".", str); + return(0); + } + + if(rsym != symbol) { + report("XStringToKeysym() returned KeySym 0x%lx instead of 0x%lx.", (long) rsym, (long) symbol); + return(0); + } + return(1); +} + +static void +reporterr(s) +char *s; +{ + report("Symbol \"%s\" is not defined.", s); +} +#define XK_GREEK +#include <X11/keysymdef.h> +#undef XK_GREEK + +strtsymG() +{ +int pass = 0, fail = 0; +char *symstr; +KeySym rsym; + + +#ifdef XK_Greek_ALPHAaccent + if(test(XK_Greek_ALPHAaccent, "Greek_ALPHAaccent") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Greek_ALPHAaccent"); + FAIL; +#endif + +#ifdef XK_Greek_EPSILONaccent + if(test(XK_Greek_EPSILONaccent, "Greek_EPSILONaccent") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Greek_EPSILONaccent"); + FAIL; +#endif + +#ifdef XK_Greek_ETAaccent + if(test(XK_Greek_ETAaccent, "Greek_ETAaccent") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Greek_ETAaccent"); + FAIL; +#endif + +#ifdef XK_Greek_IOTAaccent + if(test(XK_Greek_IOTAaccent, "Greek_IOTAaccent") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Greek_IOTAaccent"); + FAIL; +#endif + +#ifdef XK_Greek_IOTAdiaeresis + if(test(XK_Greek_IOTAdiaeresis, "Greek_IOTAdiaeresis") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Greek_IOTAdiaeresis"); + FAIL; +#endif + +#ifdef XK_Greek_OMICRONaccent + if(test(XK_Greek_OMICRONaccent, "Greek_OMICRONaccent") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Greek_OMICRONaccent"); + FAIL; +#endif + +#ifdef XK_Greek_UPSILONaccent + if(test(XK_Greek_UPSILONaccent, "Greek_UPSILONaccent") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Greek_UPSILONaccent"); + FAIL; +#endif + +#ifdef XK_Greek_UPSILONdieresis + if(test(XK_Greek_UPSILONdieresis, "Greek_UPSILONdieresis") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Greek_UPSILONdieresis"); + FAIL; +#endif + +#ifdef XK_Greek_OMEGAaccent + if(test(XK_Greek_OMEGAaccent, "Greek_OMEGAaccent") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Greek_OMEGAaccent"); + FAIL; +#endif + +#ifdef XK_Greek_accentdieresis + if(test(XK_Greek_accentdieresis, "Greek_accentdieresis") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Greek_accentdieresis"); + FAIL; +#endif + +#ifdef XK_Greek_horizbar + if(test(XK_Greek_horizbar, "Greek_horizbar") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Greek_horizbar"); + FAIL; +#endif + +#ifdef XK_Greek_alphaaccent + if(test(XK_Greek_alphaaccent, "Greek_alphaaccent") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Greek_alphaaccent"); + FAIL; +#endif + +#ifdef XK_Greek_epsilonaccent + if(test(XK_Greek_epsilonaccent, "Greek_epsilonaccent") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Greek_epsilonaccent"); + FAIL; +#endif + +#ifdef XK_Greek_etaaccent + if(test(XK_Greek_etaaccent, "Greek_etaaccent") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Greek_etaaccent"); + FAIL; +#endif + +#ifdef XK_Greek_iotaaccent + if(test(XK_Greek_iotaaccent, "Greek_iotaaccent") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Greek_iotaaccent"); + FAIL; +#endif + +#ifdef XK_Greek_iotadieresis + if(test(XK_Greek_iotadieresis, "Greek_iotadieresis") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Greek_iotadieresis"); + FAIL; +#endif + +#ifdef XK_Greek_iotaaccentdieresis + if(test(XK_Greek_iotaaccentdieresis, "Greek_iotaaccentdieresis") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Greek_iotaaccentdieresis"); + FAIL; +#endif + +#ifdef XK_Greek_omicronaccent + if(test(XK_Greek_omicronaccent, "Greek_omicronaccent") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Greek_omicronaccent"); + FAIL; +#endif + +#ifdef XK_Greek_upsilonaccent + if(test(XK_Greek_upsilonaccent, "Greek_upsilonaccent") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Greek_upsilonaccent"); + FAIL; +#endif + +#ifdef XK_Greek_upsilondieresis + if(test(XK_Greek_upsilondieresis, "Greek_upsilondieresis") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Greek_upsilondieresis"); + FAIL; +#endif + +#ifdef XK_Greek_upsilonaccentdieresis + if(test(XK_Greek_upsilonaccentdieresis, "Greek_upsilonaccentdieresis") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Greek_upsilonaccentdieresis"); + FAIL; +#endif + +#ifdef XK_Greek_omegaaccent + if(test(XK_Greek_omegaaccent, "Greek_omegaaccent") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Greek_omegaaccent"); + FAIL; +#endif + +#ifdef XK_Greek_ALPHA + if(test(XK_Greek_ALPHA, "Greek_ALPHA") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Greek_ALPHA"); + FAIL; +#endif + +#ifdef XK_Greek_BETA + if(test(XK_Greek_BETA, "Greek_BETA") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Greek_BETA"); + FAIL; +#endif + +#ifdef XK_Greek_GAMMA + if(test(XK_Greek_GAMMA, "Greek_GAMMA") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Greek_GAMMA"); + FAIL; +#endif + +#ifdef XK_Greek_DELTA + if(test(XK_Greek_DELTA, "Greek_DELTA") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Greek_DELTA"); + FAIL; +#endif + +#ifdef XK_Greek_EPSILON + if(test(XK_Greek_EPSILON, "Greek_EPSILON") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Greek_EPSILON"); + FAIL; +#endif + +#ifdef XK_Greek_ZETA + if(test(XK_Greek_ZETA, "Greek_ZETA") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Greek_ZETA"); + FAIL; +#endif + +#ifdef XK_Greek_ETA + if(test(XK_Greek_ETA, "Greek_ETA") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Greek_ETA"); + FAIL; +#endif + +#ifdef XK_Greek_THETA + if(test(XK_Greek_THETA, "Greek_THETA") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Greek_THETA"); + FAIL; +#endif + +#ifdef XK_Greek_IOTA + if(test(XK_Greek_IOTA, "Greek_IOTA") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Greek_IOTA"); + FAIL; +#endif + +#ifdef XK_Greek_KAPPA + if(test(XK_Greek_KAPPA, "Greek_KAPPA") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Greek_KAPPA"); + FAIL; +#endif + +#ifdef XK_Greek_LAMBDA + if(test(XK_Greek_LAMBDA, "Greek_LAMBDA") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Greek_LAMBDA"); + FAIL; +#endif + +#ifdef XK_Greek_LAMDA + if(test(XK_Greek_LAMDA, "Greek_LAMDA") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Greek_LAMDA"); + FAIL; +#endif + +#ifdef XK_Greek_MU + if(test(XK_Greek_MU, "Greek_MU") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Greek_MU"); + FAIL; +#endif + +#ifdef XK_Greek_NU + if(test(XK_Greek_NU, "Greek_NU") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Greek_NU"); + FAIL; +#endif + +#ifdef XK_Greek_XI + if(test(XK_Greek_XI, "Greek_XI") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Greek_XI"); + FAIL; +#endif + +#ifdef XK_Greek_OMICRON + if(test(XK_Greek_OMICRON, "Greek_OMICRON") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Greek_OMICRON"); + FAIL; +#endif + +#ifdef XK_Greek_PI + if(test(XK_Greek_PI, "Greek_PI") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Greek_PI"); + FAIL; +#endif + +#ifdef XK_Greek_RHO + if(test(XK_Greek_RHO, "Greek_RHO") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Greek_RHO"); + FAIL; +#endif + +#ifdef XK_Greek_SIGMA + if(test(XK_Greek_SIGMA, "Greek_SIGMA") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Greek_SIGMA"); + FAIL; +#endif + +#ifdef XK_Greek_TAU + if(test(XK_Greek_TAU, "Greek_TAU") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Greek_TAU"); + FAIL; +#endif + +#ifdef XK_Greek_UPSILON + if(test(XK_Greek_UPSILON, "Greek_UPSILON") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Greek_UPSILON"); + FAIL; +#endif + +#ifdef XK_Greek_PHI + if(test(XK_Greek_PHI, "Greek_PHI") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Greek_PHI"); + FAIL; +#endif + +#ifdef XK_Greek_CHI + if(test(XK_Greek_CHI, "Greek_CHI") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Greek_CHI"); + FAIL; +#endif + +#ifdef XK_Greek_PSI + if(test(XK_Greek_PSI, "Greek_PSI") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Greek_PSI"); + FAIL; +#endif + +#ifdef XK_Greek_OMEGA + if(test(XK_Greek_OMEGA, "Greek_OMEGA") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Greek_OMEGA"); + FAIL; +#endif + +#ifdef XK_Greek_alpha + if(test(XK_Greek_alpha, "Greek_alpha") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Greek_alpha"); + FAIL; +#endif + +#ifdef XK_Greek_beta + if(test(XK_Greek_beta, "Greek_beta") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Greek_beta"); + FAIL; +#endif + +#ifdef XK_Greek_gamma + if(test(XK_Greek_gamma, "Greek_gamma") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Greek_gamma"); + FAIL; +#endif + +#ifdef XK_Greek_delta + if(test(XK_Greek_delta, "Greek_delta") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Greek_delta"); + FAIL; +#endif + +#ifdef XK_Greek_epsilon + if(test(XK_Greek_epsilon, "Greek_epsilon") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Greek_epsilon"); + FAIL; +#endif + +#ifdef XK_Greek_zeta + if(test(XK_Greek_zeta, "Greek_zeta") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Greek_zeta"); + FAIL; +#endif + +#ifdef XK_Greek_eta + if(test(XK_Greek_eta, "Greek_eta") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Greek_eta"); + FAIL; +#endif + +#ifdef XK_Greek_theta + if(test(XK_Greek_theta, "Greek_theta") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Greek_theta"); + FAIL; +#endif + +#ifdef XK_Greek_iota + if(test(XK_Greek_iota, "Greek_iota") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Greek_iota"); + FAIL; +#endif + +#ifdef XK_Greek_kappa + if(test(XK_Greek_kappa, "Greek_kappa") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Greek_kappa"); + FAIL; +#endif + +#ifdef XK_Greek_lambda + if(test(XK_Greek_lambda, "Greek_lambda") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Greek_lambda"); + FAIL; +#endif + +#ifdef XK_Greek_lamda + if(test(XK_Greek_lamda, "Greek_lamda") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Greek_lamda"); + FAIL; +#endif + +#ifdef XK_Greek_mu + if(test(XK_Greek_mu, "Greek_mu") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Greek_mu"); + FAIL; +#endif + +#ifdef XK_Greek_nu + if(test(XK_Greek_nu, "Greek_nu") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Greek_nu"); + FAIL; +#endif + +#ifdef XK_Greek_xi + if(test(XK_Greek_xi, "Greek_xi") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Greek_xi"); + FAIL; +#endif + +#ifdef XK_Greek_omicron + if(test(XK_Greek_omicron, "Greek_omicron") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Greek_omicron"); + FAIL; +#endif + +#ifdef XK_Greek_pi + if(test(XK_Greek_pi, "Greek_pi") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Greek_pi"); + FAIL; +#endif + +#ifdef XK_Greek_rho + if(test(XK_Greek_rho, "Greek_rho") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Greek_rho"); + FAIL; +#endif + +#ifdef XK_Greek_sigma + if(test(XK_Greek_sigma, "Greek_sigma") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Greek_sigma"); + FAIL; +#endif + +#ifdef XK_Greek_finalsmallsigma + if(test(XK_Greek_finalsmallsigma, "Greek_finalsmallsigma") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Greek_finalsmallsigma"); + FAIL; +#endif + +#ifdef XK_Greek_tau + if(test(XK_Greek_tau, "Greek_tau") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Greek_tau"); + FAIL; +#endif + +#ifdef XK_Greek_upsilon + if(test(XK_Greek_upsilon, "Greek_upsilon") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Greek_upsilon"); + FAIL; +#endif + +#ifdef XK_Greek_phi + if(test(XK_Greek_phi, "Greek_phi") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Greek_phi"); + FAIL; +#endif + +#ifdef XK_Greek_chi + if(test(XK_Greek_chi, "Greek_chi") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Greek_chi"); + FAIL; +#endif + +#ifdef XK_Greek_psi + if(test(XK_Greek_psi, "Greek_psi") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Greek_psi"); + FAIL; +#endif + +#ifdef XK_Greek_omega + if(test(XK_Greek_omega, "Greek_omega") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Greek_omega"); + FAIL; +#endif + +#ifdef XK_Greek_switch + if(test(XK_Greek_switch, "Greek_switch") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Greek_switch"); + FAIL; +#endif + + CHECKPASS(74); +} diff --git a/xts5/Xopen/XStringToKeysym/TestH.c b/xts5/Xopen/XStringToKeysym/TestH.c new file mode 100644 index 00000000..482ab2b4 --- /dev/null +++ b/xts5/Xopen/XStringToKeysym/TestH.c @@ -0,0 +1,533 @@ +/* +Copyright (c) 2005 X.Org Foundation L.L.C. + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies +of the Software, and to permit persons to whom the Software is furnished to do +so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. +*/ +/* +* $Header: /cvs/xtest/xtest/xts5/tset/Xopen/XStringToKeysym/TestH.c,v 1.2 2005-11-03 08:44:01 jmichael Exp $ +* +* Project: VSW5 +* +* File: xts5/tset/Xopen/XStringToKeysym/TestH.c +* +* Description: +* Tests for XStringToKeysym() +* +* Modifications: +* $Log: TestH.c,v $ +* Revision 1.2 2005-11-03 08:44:01 jmichael +* clean up all vsw5 paths to use xts5 instead. +* +* Revision 1.1.1.2 2005/04/15 14:05:40 anderson +* Reimport of the base with the legal name in the copyright fixed. +* +* Revision 8.0 1998/12/23 23:35:56 mar +* Branch point for Release 5.0.2 +* +* Revision 7.0 1998/10/30 22:58:40 mar +* Branch point for Release 5.0.2b1 +* +* Revision 6.0 1998/03/02 05:27:09 tbr +* Branch point for Release 5.0.1 +* +* Revision 5.0 1998/01/26 03:23:43 tbr +* Branch point for Release 5.0.1b1 +* +* Revision 4.1 1996/05/09 21:19:34 andy +* Fixed X includes +* +* Revision 4.0 1995/12/15 09:14:41 tbr +* Branch point for Release 5.0.0 +* +* Revision 3.1 1995/12/15 01:18:06 andy +* Prepare for GA Release +* +*/ +/* + * SCCS: @(#) TestH.c Rel 1.1 (11/28/91) + * + * UniSoft Ltd., London, England + * + * (C) Copyright 1991 X/Open Company Limited + * + * All rights reserved. No part of this source code may be reproduced, + * stored in a retrieval system, or transmitted, in any form or by any + * means, electronic, mechanical, photocopying, recording or otherwise, + * except as stated in the end-user licence agreement, without the prior + * permission of the copyright owners. + * + * X/Open and the 'X' symbol are trademarks of X/Open Company Limited in + * the UK and other countries. + */ + +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif + +#include <stdlib.h> +#include "xtest.h" +#include "X11/Xlib.h" +#include "X11/Xutil.h" +#include "X11/Xresource.h" +#include "tet_api.h" +#include "xtestlib.h" +#include "pixval.h" + +extern char *TestName; + +static int +test(symbol, str) +KeySym symbol; +char *str; +{ +KeySym rsym; + + rsym = XStringToKeysym(str); + + if(rsym == NoSymbol) { + report("XStringToKeysym() returned NoSymbol for string \"%s\".", str); + return(0); + } + + if(rsym != symbol) { + report("XStringToKeysym() returned KeySym 0x%lx instead of 0x%lx.", (long) rsym, (long) symbol); + return(0); + } + return(1); +} + +static void +reporterr(s) +char *s; +{ + report("Symbol \"%s\" is not defined.", s); +} +#define XK_HEBREW +#include <X11/keysymdef.h> +#undef XK_HEBREW + +strtsymH() +{ +int pass = 0, fail = 0; +char *symstr; +KeySym rsym; + + +#ifdef XK_hebrew_doublelowline + if(test(XK_hebrew_doublelowline, "hebrew_doublelowline") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_hebrew_doublelowline"); + FAIL; +#endif + +#ifdef XK_hebrew_aleph + if(test(XK_hebrew_aleph, "hebrew_aleph") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_hebrew_aleph"); + FAIL; +#endif + +#ifdef XK_hebrew_bet + if(test(XK_hebrew_bet, "hebrew_bet") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_hebrew_bet"); + FAIL; +#endif + +#ifdef XK_hebrew_beth + if(test(XK_hebrew_beth, "hebrew_beth") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_hebrew_beth"); + FAIL; +#endif + +#ifdef XK_hebrew_gimel + if(test(XK_hebrew_gimel, "hebrew_gimel") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_hebrew_gimel"); + FAIL; +#endif + +#ifdef XK_hebrew_gimmel + if(test(XK_hebrew_gimmel, "hebrew_gimmel") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_hebrew_gimmel"); + FAIL; +#endif + +#ifdef XK_hebrew_dalet + if(test(XK_hebrew_dalet, "hebrew_dalet") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_hebrew_dalet"); + FAIL; +#endif + +#ifdef XK_hebrew_daleth + if(test(XK_hebrew_daleth, "hebrew_daleth") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_hebrew_daleth"); + FAIL; +#endif + +#ifdef XK_hebrew_he + if(test(XK_hebrew_he, "hebrew_he") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_hebrew_he"); + FAIL; +#endif + +#ifdef XK_hebrew_waw + if(test(XK_hebrew_waw, "hebrew_waw") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_hebrew_waw"); + FAIL; +#endif + +#ifdef XK_hebrew_zain + if(test(XK_hebrew_zain, "hebrew_zain") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_hebrew_zain"); + FAIL; +#endif + +#ifdef XK_hebrew_zayin + if(test(XK_hebrew_zayin, "hebrew_zayin") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_hebrew_zayin"); + FAIL; +#endif + +#ifdef XK_hebrew_chet + if(test(XK_hebrew_chet, "hebrew_chet") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_hebrew_chet"); + FAIL; +#endif + +#ifdef XK_hebrew_het + if(test(XK_hebrew_het, "hebrew_het") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_hebrew_het"); + FAIL; +#endif + +#ifdef XK_hebrew_tet + if(test(XK_hebrew_tet, "hebrew_tet") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_hebrew_tet"); + FAIL; +#endif + +#ifdef XK_hebrew_teth + if(test(XK_hebrew_teth, "hebrew_teth") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_hebrew_teth"); + FAIL; +#endif + +#ifdef XK_hebrew_yod + if(test(XK_hebrew_yod, "hebrew_yod") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_hebrew_yod"); + FAIL; +#endif + +#ifdef XK_hebrew_finalkaph + if(test(XK_hebrew_finalkaph, "hebrew_finalkaph") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_hebrew_finalkaph"); + FAIL; +#endif + +#ifdef XK_hebrew_kaph + if(test(XK_hebrew_kaph, "hebrew_kaph") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_hebrew_kaph"); + FAIL; +#endif + +#ifdef XK_hebrew_lamed + if(test(XK_hebrew_lamed, "hebrew_lamed") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_hebrew_lamed"); + FAIL; +#endif + +#ifdef XK_hebrew_finalmem + if(test(XK_hebrew_finalmem, "hebrew_finalmem") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_hebrew_finalmem"); + FAIL; +#endif + +#ifdef XK_hebrew_mem + if(test(XK_hebrew_mem, "hebrew_mem") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_hebrew_mem"); + FAIL; +#endif + +#ifdef XK_hebrew_finalnun + if(test(XK_hebrew_finalnun, "hebrew_finalnun") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_hebrew_finalnun"); + FAIL; +#endif + +#ifdef XK_hebrew_nun + if(test(XK_hebrew_nun, "hebrew_nun") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_hebrew_nun"); + FAIL; +#endif + +#ifdef XK_hebrew_samech + if(test(XK_hebrew_samech, "hebrew_samech") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_hebrew_samech"); + FAIL; +#endif + +#ifdef XK_hebrew_samekh + if(test(XK_hebrew_samekh, "hebrew_samekh") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_hebrew_samekh"); + FAIL; +#endif + +#ifdef XK_hebrew_ayin + if(test(XK_hebrew_ayin, "hebrew_ayin") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_hebrew_ayin"); + FAIL; +#endif + +#ifdef XK_hebrew_finalpe + if(test(XK_hebrew_finalpe, "hebrew_finalpe") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_hebrew_finalpe"); + FAIL; +#endif + +#ifdef XK_hebrew_pe + if(test(XK_hebrew_pe, "hebrew_pe") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_hebrew_pe"); + FAIL; +#endif + +#ifdef XK_hebrew_finalzade + if(test(XK_hebrew_finalzade, "hebrew_finalzade") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_hebrew_finalzade"); + FAIL; +#endif + +#ifdef XK_hebrew_finalzadi + if(test(XK_hebrew_finalzadi, "hebrew_finalzadi") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_hebrew_finalzadi"); + FAIL; +#endif + +#ifdef XK_hebrew_zade + if(test(XK_hebrew_zade, "hebrew_zade") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_hebrew_zade"); + FAIL; +#endif + +#ifdef XK_hebrew_zadi + if(test(XK_hebrew_zadi, "hebrew_zadi") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_hebrew_zadi"); + FAIL; +#endif + +#ifdef XK_hebrew_qoph + if(test(XK_hebrew_qoph, "hebrew_qoph") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_hebrew_qoph"); + FAIL; +#endif + +#ifdef XK_hebrew_kuf + if(test(XK_hebrew_kuf, "hebrew_kuf") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_hebrew_kuf"); + FAIL; +#endif + +#ifdef XK_hebrew_resh + if(test(XK_hebrew_resh, "hebrew_resh") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_hebrew_resh"); + FAIL; +#endif + +#ifdef XK_hebrew_shin + if(test(XK_hebrew_shin, "hebrew_shin") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_hebrew_shin"); + FAIL; +#endif + +#ifdef XK_hebrew_taw + if(test(XK_hebrew_taw, "hebrew_taw") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_hebrew_taw"); + FAIL; +#endif + +#ifdef XK_hebrew_taf + if(test(XK_hebrew_taf, "hebrew_taf") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_hebrew_taf"); + FAIL; +#endif + +#ifdef XK_Hebrew_switch + if(test(XK_Hebrew_switch, "Hebrew_switch") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Hebrew_switch"); + FAIL; +#endif + + CHECKPASS(40); +} diff --git a/xts5/Xopen/XStringToKeysym/TestK.c b/xts5/Xopen/XStringToKeysym/TestK.c new file mode 100644 index 00000000..4f51eb1e --- /dev/null +++ b/xts5/Xopen/XStringToKeysym/TestK.c @@ -0,0 +1,833 @@ +/* +Copyright (c) 2005 X.Org Foundation L.L.C. + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies +of the Software, and to permit persons to whom the Software is furnished to do +so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. +*/ +/* +* $Header: /cvs/xtest/xtest/xts5/tset/Xopen/XStringToKeysym/TestK.c,v 1.2 2005-11-03 08:44:01 jmichael Exp $ +* +* Project: VSW5 +* +* File: xts5/tset/Xopen/XStringToKeysym/TestK.c +* +* Description: +* Tests for XStringToKeysym() +* +* Modifications: +* $Log: TestK.c,v $ +* Revision 1.2 2005-11-03 08:44:01 jmichael +* clean up all vsw5 paths to use xts5 instead. +* +* Revision 1.1.1.2 2005/04/15 14:05:40 anderson +* Reimport of the base with the legal name in the copyright fixed. +* +* Revision 8.0 1998/12/23 23:35:57 mar +* Branch point for Release 5.0.2 +* +* Revision 7.0 1998/10/30 22:58:41 mar +* Branch point for Release 5.0.2b1 +* +* Revision 6.0 1998/03/02 05:27:10 tbr +* Branch point for Release 5.0.1 +* +* Revision 5.0 1998/01/26 03:23:43 tbr +* Branch point for Release 5.0.1b1 +* +* Revision 4.1 1996/05/09 21:19:34 andy +* Fixed X includes +* +* Revision 4.0 1995/12/15 09:14:42 tbr +* Branch point for Release 5.0.0 +* +* Revision 3.1 1995/12/15 01:18:08 andy +* Prepare for GA Release +* +*/ +/* + * SCCS: @(#) TestK.c Rel 1.1 (11/28/91) + * + * UniSoft Ltd., London, England + * + * (C) Copyright 1991 X/Open Company Limited + * + * All rights reserved. No part of this source code may be reproduced, + * stored in a retrieval system, or transmitted, in any form or by any + * means, electronic, mechanical, photocopying, recording or otherwise, + * except as stated in the end-user licence agreement, without the prior + * permission of the copyright owners. + * + * X/Open and the 'X' symbol are trademarks of X/Open Company Limited in + * the UK and other countries. + */ + +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif + +#include <stdlib.h> +#include "xtest.h" +#include "X11/Xlib.h" +#include "X11/Xutil.h" +#include "X11/Xresource.h" +#include "tet_api.h" +#include "xtestlib.h" +#include "pixval.h" + +extern char *TestName; + +static int +test(symbol, str) +KeySym symbol; +char *str; +{ +KeySym rsym; + + rsym = XStringToKeysym(str); + + if(rsym == NoSymbol) { + report("XStringToKeysym() returned NoSymbol for string \"%s\".", str); + return(0); + } + + if(rsym != symbol) { + report("XStringToKeysym() returned KeySym 0x%lx instead of 0x%lx.", (long) rsym, (long) symbol); + return(0); + } + return(1); +} + +static void +reporterr(s) +char *s; +{ + report("Symbol \"%s\" is not defined.", s); +} +#define XK_KATAKANA +#include <X11/keysymdef.h> +#undef XK_KATAKANA + +strtsymK() +{ +int pass = 0, fail = 0; +char *symstr; +KeySym rsym; + + +#ifdef XK_overline + if(test(XK_overline, "overline") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_overline"); + FAIL; +#endif + +#ifdef XK_kana_fullstop + if(test(XK_kana_fullstop, "kana_fullstop") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_kana_fullstop"); + FAIL; +#endif + +#ifdef XK_kana_openingbracket + if(test(XK_kana_openingbracket, "kana_openingbracket") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_kana_openingbracket"); + FAIL; +#endif + +#ifdef XK_kana_closingbracket + if(test(XK_kana_closingbracket, "kana_closingbracket") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_kana_closingbracket"); + FAIL; +#endif + +#ifdef XK_kana_comma + if(test(XK_kana_comma, "kana_comma") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_kana_comma"); + FAIL; +#endif + +#ifdef XK_kana_conjunctive + if(test(XK_kana_conjunctive, "kana_conjunctive") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_kana_conjunctive"); + FAIL; +#endif + +#ifdef XK_kana_middledot + if(test(XK_kana_middledot, "kana_middledot") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_kana_middledot"); + FAIL; +#endif + +#ifdef XK_kana_WO + if(test(XK_kana_WO, "kana_WO") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_kana_WO"); + FAIL; +#endif + +#ifdef XK_kana_a + if(test(XK_kana_a, "kana_a") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_kana_a"); + FAIL; +#endif + +#ifdef XK_kana_i + if(test(XK_kana_i, "kana_i") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_kana_i"); + FAIL; +#endif + +#ifdef XK_kana_u + if(test(XK_kana_u, "kana_u") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_kana_u"); + FAIL; +#endif + +#ifdef XK_kana_e + if(test(XK_kana_e, "kana_e") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_kana_e"); + FAIL; +#endif + +#ifdef XK_kana_o + if(test(XK_kana_o, "kana_o") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_kana_o"); + FAIL; +#endif + +#ifdef XK_kana_ya + if(test(XK_kana_ya, "kana_ya") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_kana_ya"); + FAIL; +#endif + +#ifdef XK_kana_yu + if(test(XK_kana_yu, "kana_yu") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_kana_yu"); + FAIL; +#endif + +#ifdef XK_kana_yo + if(test(XK_kana_yo, "kana_yo") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_kana_yo"); + FAIL; +#endif + +#ifdef XK_kana_tsu + if(test(XK_kana_tsu, "kana_tsu") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_kana_tsu"); + FAIL; +#endif + +#ifdef XK_kana_tu + if(test(XK_kana_tu, "kana_tu") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_kana_tu"); + FAIL; +#endif + +#ifdef XK_prolongedsound + if(test(XK_prolongedsound, "prolongedsound") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_prolongedsound"); + FAIL; +#endif + +#ifdef XK_kana_A + if(test(XK_kana_A, "kana_A") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_kana_A"); + FAIL; +#endif + +#ifdef XK_kana_I + if(test(XK_kana_I, "kana_I") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_kana_I"); + FAIL; +#endif + +#ifdef XK_kana_U + if(test(XK_kana_U, "kana_U") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_kana_U"); + FAIL; +#endif + +#ifdef XK_kana_E + if(test(XK_kana_E, "kana_E") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_kana_E"); + FAIL; +#endif + +#ifdef XK_kana_O + if(test(XK_kana_O, "kana_O") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_kana_O"); + FAIL; +#endif + +#ifdef XK_kana_KA + if(test(XK_kana_KA, "kana_KA") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_kana_KA"); + FAIL; +#endif + +#ifdef XK_kana_KI + if(test(XK_kana_KI, "kana_KI") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_kana_KI"); + FAIL; +#endif + +#ifdef XK_kana_KU + if(test(XK_kana_KU, "kana_KU") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_kana_KU"); + FAIL; +#endif + +#ifdef XK_kana_KE + if(test(XK_kana_KE, "kana_KE") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_kana_KE"); + FAIL; +#endif + +#ifdef XK_kana_KO + if(test(XK_kana_KO, "kana_KO") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_kana_KO"); + FAIL; +#endif + +#ifdef XK_kana_SA + if(test(XK_kana_SA, "kana_SA") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_kana_SA"); + FAIL; +#endif + +#ifdef XK_kana_SHI + if(test(XK_kana_SHI, "kana_SHI") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_kana_SHI"); + FAIL; +#endif + +#ifdef XK_kana_SU + if(test(XK_kana_SU, "kana_SU") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_kana_SU"); + FAIL; +#endif + +#ifdef XK_kana_SE + if(test(XK_kana_SE, "kana_SE") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_kana_SE"); + FAIL; +#endif + +#ifdef XK_kana_SO + if(test(XK_kana_SO, "kana_SO") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_kana_SO"); + FAIL; +#endif + +#ifdef XK_kana_TA + if(test(XK_kana_TA, "kana_TA") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_kana_TA"); + FAIL; +#endif + +#ifdef XK_kana_CHI + if(test(XK_kana_CHI, "kana_CHI") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_kana_CHI"); + FAIL; +#endif + +#ifdef XK_kana_TI + if(test(XK_kana_TI, "kana_TI") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_kana_TI"); + FAIL; +#endif + +#ifdef XK_kana_TSU + if(test(XK_kana_TSU, "kana_TSU") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_kana_TSU"); + FAIL; +#endif + +#ifdef XK_kana_TU + if(test(XK_kana_TU, "kana_TU") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_kana_TU"); + FAIL; +#endif + +#ifdef XK_kana_TE + if(test(XK_kana_TE, "kana_TE") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_kana_TE"); + FAIL; +#endif + +#ifdef XK_kana_TO + if(test(XK_kana_TO, "kana_TO") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_kana_TO"); + FAIL; +#endif + +#ifdef XK_kana_NA + if(test(XK_kana_NA, "kana_NA") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_kana_NA"); + FAIL; +#endif + +#ifdef XK_kana_NI + if(test(XK_kana_NI, "kana_NI") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_kana_NI"); + FAIL; +#endif + +#ifdef XK_kana_NU + if(test(XK_kana_NU, "kana_NU") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_kana_NU"); + FAIL; +#endif + +#ifdef XK_kana_NE + if(test(XK_kana_NE, "kana_NE") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_kana_NE"); + FAIL; +#endif + +#ifdef XK_kana_NO + if(test(XK_kana_NO, "kana_NO") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_kana_NO"); + FAIL; +#endif + +#ifdef XK_kana_HA + if(test(XK_kana_HA, "kana_HA") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_kana_HA"); + FAIL; +#endif + +#ifdef XK_kana_HI + if(test(XK_kana_HI, "kana_HI") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_kana_HI"); + FAIL; +#endif + +#ifdef XK_kana_FU + if(test(XK_kana_FU, "kana_FU") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_kana_FU"); + FAIL; +#endif + +#ifdef XK_kana_HU + if(test(XK_kana_HU, "kana_HU") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_kana_HU"); + FAIL; +#endif + +#ifdef XK_kana_HE + if(test(XK_kana_HE, "kana_HE") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_kana_HE"); + FAIL; +#endif + +#ifdef XK_kana_HO + if(test(XK_kana_HO, "kana_HO") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_kana_HO"); + FAIL; +#endif + +#ifdef XK_kana_MA + if(test(XK_kana_MA, "kana_MA") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_kana_MA"); + FAIL; +#endif + +#ifdef XK_kana_MI + if(test(XK_kana_MI, "kana_MI") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_kana_MI"); + FAIL; +#endif + +#ifdef XK_kana_MU + if(test(XK_kana_MU, "kana_MU") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_kana_MU"); + FAIL; +#endif + +#ifdef XK_kana_ME + if(test(XK_kana_ME, "kana_ME") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_kana_ME"); + FAIL; +#endif + +#ifdef XK_kana_MO + if(test(XK_kana_MO, "kana_MO") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_kana_MO"); + FAIL; +#endif + +#ifdef XK_kana_YA + if(test(XK_kana_YA, "kana_YA") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_kana_YA"); + FAIL; +#endif + +#ifdef XK_kana_YU + if(test(XK_kana_YU, "kana_YU") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_kana_YU"); + FAIL; +#endif + +#ifdef XK_kana_YO + if(test(XK_kana_YO, "kana_YO") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_kana_YO"); + FAIL; +#endif + +#ifdef XK_kana_RA + if(test(XK_kana_RA, "kana_RA") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_kana_RA"); + FAIL; +#endif + +#ifdef XK_kana_RI + if(test(XK_kana_RI, "kana_RI") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_kana_RI"); + FAIL; +#endif + +#ifdef XK_kana_RU + if(test(XK_kana_RU, "kana_RU") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_kana_RU"); + FAIL; +#endif + +#ifdef XK_kana_RE + if(test(XK_kana_RE, "kana_RE") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_kana_RE"); + FAIL; +#endif + +#ifdef XK_kana_RO + if(test(XK_kana_RO, "kana_RO") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_kana_RO"); + FAIL; +#endif + +#ifdef XK_kana_WA + if(test(XK_kana_WA, "kana_WA") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_kana_WA"); + FAIL; +#endif + +#ifdef XK_kana_N + if(test(XK_kana_N, "kana_N") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_kana_N"); + FAIL; +#endif + +#ifdef XK_voicedsound + if(test(XK_voicedsound, "voicedsound") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_voicedsound"); + FAIL; +#endif + +#ifdef XK_semivoicedsound + if(test(XK_semivoicedsound, "semivoicedsound") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_semivoicedsound"); + FAIL; +#endif + +#ifdef XK_kana_switch + if(test(XK_kana_switch, "kana_switch") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_kana_switch"); + FAIL; +#endif + + CHECKPASS(70); +} diff --git a/xts5/Xopen/XStringToKeysym/TestL.c b/xts5/Xopen/XStringToKeysym/TestL.c new file mode 100644 index 00000000..f6d94f7d --- /dev/null +++ b/xts5/Xopen/XStringToKeysym/TestL.c @@ -0,0 +1,323 @@ +/* +Copyright (c) 2005 X.Org Foundation L.L.C. + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies +of the Software, and to permit persons to whom the Software is furnished to do +so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. +*/ +/* +* $Header: /cvs/xtest/xtest/xts5/tset/Xopen/XStringToKeysym/TestL.c,v 1.2 2005-11-03 08:44:01 jmichael Exp $ +* +* Project: VSW5 +* +* File: xts5/tset/Xopen/XStringToKeysym/TestL.c +* +* Description: +* Tests for XStringToKeysym() +* +* Modifications: +* $Log: TestL.c,v $ +* Revision 1.2 2005-11-03 08:44:01 jmichael +* clean up all vsw5 paths to use xts5 instead. +* +* Revision 1.1.1.2 2005/04/15 14:05:40 anderson +* Reimport of the base with the legal name in the copyright fixed. +* +* Revision 8.0 1998/12/23 23:35:57 mar +* Branch point for Release 5.0.2 +* +* Revision 7.0 1998/10/30 22:58:42 mar +* Branch point for Release 5.0.2b1 +* +* Revision 6.0 1998/03/02 05:27:10 tbr +* Branch point for Release 5.0.1 +* +* Revision 5.0 1998/01/26 03:23:43 tbr +* Branch point for Release 5.0.1b1 +* +* Revision 4.1 1996/05/09 21:19:34 andy +* Fixed X includes +* +* Revision 4.0 1995/12/15 09:14:43 tbr +* Branch point for Release 5.0.0 +* +* Revision 3.1 1995/12/15 01:18:09 andy +* Prepare for GA Release +* +*/ +/* + * SCCS: @(#) TestL.c Rel 1.1 (11/28/91) + * + * UniSoft Ltd., London, England + * + * (C) Copyright 1991 X/Open Company Limited + * + * All rights reserved. No part of this source code may be reproduced, + * stored in a retrieval system, or transmitted, in any form or by any + * means, electronic, mechanical, photocopying, recording or otherwise, + * except as stated in the end-user licence agreement, without the prior + * permission of the copyright owners. + * + * X/Open and the 'X' symbol are trademarks of X/Open Company Limited in + * the UK and other countries. + */ + +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif + +#include <stdlib.h> +#include "xtest.h" +#include "X11/Xlib.h" +#include "X11/Xutil.h" +#include "X11/Xresource.h" +#include "tet_api.h" +#include "xtestlib.h" +#include "pixval.h" + +extern char *TestName; + +static int +test(symbol, str) +KeySym symbol; +char *str; +{ +KeySym rsym; + + rsym = XStringToKeysym(str); + + if(rsym == NoSymbol) { + report("XStringToKeysym() returned NoSymbol for string \"%s\".", str); + return(0); + } + + if(rsym != symbol) { + report("XStringToKeysym() returned KeySym 0x%lx instead of 0x%lx.", (long) rsym, (long) symbol); + return(0); + } + return(1); +} + +static void +reporterr(s) +char *s; +{ + report("Symbol \"%s\" is not defined.", s); +} +#define XK_APL +#include <X11/keysymdef.h> +#undef XK_APL + +strtsymL() +{ +int pass = 0, fail = 0; +char *symstr; +KeySym rsym; + + +#ifdef XK_leftcaret + if(test(XK_leftcaret, "leftcaret") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_leftcaret"); + FAIL; +#endif + +#ifdef XK_rightcaret + if(test(XK_rightcaret, "rightcaret") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_rightcaret"); + FAIL; +#endif + +#ifdef XK_downcaret + if(test(XK_downcaret, "downcaret") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_downcaret"); + FAIL; +#endif + +#ifdef XK_upcaret + if(test(XK_upcaret, "upcaret") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_upcaret"); + FAIL; +#endif + +#ifdef XK_overbar + if(test(XK_overbar, "overbar") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_overbar"); + FAIL; +#endif + +#ifdef XK_downtack + if(test(XK_downtack, "downtack") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_downtack"); + FAIL; +#endif + +#ifdef XK_upshoe + if(test(XK_upshoe, "upshoe") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_upshoe"); + FAIL; +#endif + +#ifdef XK_downstile + if(test(XK_downstile, "downstile") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_downstile"); + FAIL; +#endif + +#ifdef XK_underbar + if(test(XK_underbar, "underbar") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_underbar"); + FAIL; +#endif + +#ifdef XK_jot + if(test(XK_jot, "jot") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_jot"); + FAIL; +#endif + +#ifdef XK_quad + if(test(XK_quad, "quad") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_quad"); + FAIL; +#endif + +#ifdef XK_uptack + if(test(XK_uptack, "uptack") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_uptack"); + FAIL; +#endif + +#ifdef XK_circle + if(test(XK_circle, "circle") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_circle"); + FAIL; +#endif + +#ifdef XK_upstile + if(test(XK_upstile, "upstile") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_upstile"); + FAIL; +#endif + +#ifdef XK_downshoe + if(test(XK_downshoe, "downshoe") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_downshoe"); + FAIL; +#endif + +#ifdef XK_rightshoe + if(test(XK_rightshoe, "rightshoe") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_rightshoe"); + FAIL; +#endif + +#ifdef XK_leftshoe + if(test(XK_leftshoe, "leftshoe") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_leftshoe"); + FAIL; +#endif + +#ifdef XK_lefttack + if(test(XK_lefttack, "lefttack") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_lefttack"); + FAIL; +#endif + +#ifdef XK_righttack + if(test(XK_righttack, "righttack") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_righttack"); + FAIL; +#endif + + CHECKPASS(19); +} diff --git a/xts5/Xopen/XStringToKeysym/TestM.c b/xts5/Xopen/XStringToKeysym/TestM.c new file mode 100644 index 00000000..b5482f0f --- /dev/null +++ b/xts5/Xopen/XStringToKeysym/TestM.c @@ -0,0 +1,1613 @@ +/* +Copyright (c) 2005 X.Org Foundation L.L.C. + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies +of the Software, and to permit persons to whom the Software is furnished to do +so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. +*/ +/* +* $Header: /cvs/xtest/xtest/xts5/tset/Xopen/XStringToKeysym/TestM.c,v 1.2 2005-11-03 08:44:01 jmichael Exp $ +* +* Project: VSW5 +* +* File: xts5/tset/Xopen/XStringToKeysym/TestM.c +* +* Description: +* Tests for XStringToKeysym() +* +* Modifications: +* $Log: TestM.c,v $ +* Revision 1.2 2005-11-03 08:44:01 jmichael +* clean up all vsw5 paths to use xts5 instead. +* +* Revision 1.1.1.2 2005/04/15 14:05:40 anderson +* Reimport of the base with the legal name in the copyright fixed. +* +* Revision 8.0 1998/12/23 23:35:58 mar +* Branch point for Release 5.0.2 +* +* Revision 7.0 1998/10/30 22:58:42 mar +* Branch point for Release 5.0.2b1 +* +* Revision 6.0 1998/03/02 05:27:11 tbr +* Branch point for Release 5.0.1 +* +* Revision 5.0 1998/01/26 03:23:44 tbr +* Branch point for Release 5.0.1b1 +* +* Revision 4.1 1996/05/09 21:19:34 andy +* Fixed X includes +* +* Revision 4.0 1995/12/15 09:14:45 tbr +* Branch point for Release 5.0.0 +* +* Revision 3.1 1995/12/15 01:18:11 andy +* Prepare for GA Release +* +*/ +/* + * SCCS: @(#) TestM.c Rel 1.1 (11/28/91) + * + * UniSoft Ltd., London, England + * + * (C) Copyright 1991 X/Open Company Limited + * + * All rights reserved. No part of this source code may be reproduced, + * stored in a retrieval system, or transmitted, in any form or by any + * means, electronic, mechanical, photocopying, recording or otherwise, + * except as stated in the end-user licence agreement, without the prior + * permission of the copyright owners. + * + * X/Open and the 'X' symbol are trademarks of X/Open Company Limited in + * the UK and other countries. + */ + +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif + +#include <stdlib.h> +#include "xtest.h" +#include "X11/Xlib.h" +#include "X11/Xutil.h" +#include "X11/Xresource.h" +#include "tet_api.h" +#include "xtestlib.h" +#include "pixval.h" + +extern char *TestName; + +static int +test(symbol, str) +KeySym symbol; +char *str; +{ +KeySym rsym; + + rsym = XStringToKeysym(str); + + if(rsym == NoSymbol) { + report("XStringToKeysym() returned NoSymbol for string \"%s\".", str); + return(0); + } + + if(rsym != symbol) { + report("XStringToKeysym() returned KeySym 0x%lx instead of 0x%lx.", (long) rsym, (long) symbol); + return(0); + } + return(1); +} + +static void +reporterr(s) +char *s; +{ + report("Symbol \"%s\" is not defined.", s); +} +#define XK_MISCELLANY +#include <X11/keysymdef.h> +#undef XK_MISCELLANY + +strtsymM() +{ +int pass = 0, fail = 0; +char *symstr; +KeySym rsym; + + +#ifdef XK_BackSpace + if(test(XK_BackSpace, "BackSpace") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_BackSpace"); + FAIL; +#endif + +#ifdef XK_Tab + if(test(XK_Tab, "Tab") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Tab"); + FAIL; +#endif + +#ifdef XK_Linefeed + if(test(XK_Linefeed, "Linefeed") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Linefeed"); + FAIL; +#endif + +#ifdef XK_Clear + if(test(XK_Clear, "Clear") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Clear"); + FAIL; +#endif + +#ifdef XK_Return + if(test(XK_Return, "Return") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Return"); + FAIL; +#endif + +#ifdef XK_Pause + if(test(XK_Pause, "Pause") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Pause"); + FAIL; +#endif + +#ifdef XK_Scroll_Lock + if(test(XK_Scroll_Lock, "Scroll_Lock") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Scroll_Lock"); + FAIL; +#endif + +#ifdef XK_Escape + if(test(XK_Escape, "Escape") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Escape"); + FAIL; +#endif + +#ifdef XK_Multi_key + if(test(XK_Multi_key, "Multi_key") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Multi_key"); + FAIL; +#endif + +#ifdef XK_Kanji + if(test(XK_Kanji, "Kanji") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Kanji"); + FAIL; +#endif + +#ifdef XK_Muhenkan + if(test(XK_Muhenkan, "Muhenkan") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Muhenkan"); + FAIL; +#endif + +#ifdef XK_Henkan + if(test(XK_Henkan, "Henkan") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Henkan"); + FAIL; +#endif + +#ifdef XK_Henkan_Mode + if(test(XK_Henkan_Mode, "Henkan_Mode") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Henkan_Mode"); + FAIL; +#endif + +#ifdef XK_Romaji + if(test(XK_Romaji, "Romaji") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Romaji"); + FAIL; +#endif + +#ifdef XK_Hiragana + if(test(XK_Hiragana, "Hiragana") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Hiragana"); + FAIL; +#endif + +#ifdef XK_Katakana + if(test(XK_Katakana, "Katakana") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Katakana"); + FAIL; +#endif + +#ifdef XK_Hiragana_Katakana + if(test(XK_Hiragana_Katakana, "Hiragana_Katakana") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Hiragana_Katakana"); + FAIL; +#endif + +#ifdef XK_Zenkaku + if(test(XK_Zenkaku, "Zenkaku") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Zenkaku"); + FAIL; +#endif + +#ifdef XK_Hankaku + if(test(XK_Hankaku, "Hankaku") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Hankaku"); + FAIL; +#endif + +#ifdef XK_Zenkaku_Hankaku + if(test(XK_Zenkaku_Hankaku, "Zenkaku_Hankaku") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Zenkaku_Hankaku"); + FAIL; +#endif + +#ifdef XK_Touroku + if(test(XK_Touroku, "Touroku") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Touroku"); + FAIL; +#endif + +#ifdef XK_Massyo + if(test(XK_Massyo, "Massyo") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Massyo"); + FAIL; +#endif + +#ifdef XK_Kana_Lock + if(test(XK_Kana_Lock, "Kana_Lock") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Kana_Lock"); + FAIL; +#endif + +#ifdef XK_Kana_Shift + if(test(XK_Kana_Shift, "Kana_Shift") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Kana_Shift"); + FAIL; +#endif + +#ifdef XK_Eisu_Shift + if(test(XK_Eisu_Shift, "Eisu_Shift") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Eisu_Shift"); + FAIL; +#endif + +#ifdef XK_Eisu_toggle + if(test(XK_Eisu_toggle, "Eisu_toggle") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Eisu_toggle"); + FAIL; +#endif + +#ifdef XK_Home + if(test(XK_Home, "Home") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Home"); + FAIL; +#endif + +#ifdef XK_Left + if(test(XK_Left, "Left") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Left"); + FAIL; +#endif + +#ifdef XK_Up + if(test(XK_Up, "Up") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Up"); + FAIL; +#endif + +#ifdef XK_Right + if(test(XK_Right, "Right") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Right"); + FAIL; +#endif + +#ifdef XK_Down + if(test(XK_Down, "Down") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Down"); + FAIL; +#endif + +#ifdef XK_Prior + if(test(XK_Prior, "Prior") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Prior"); + FAIL; +#endif + +#ifdef XK_Next + if(test(XK_Next, "Next") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Next"); + FAIL; +#endif + +#ifdef XK_End + if(test(XK_End, "End") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_End"); + FAIL; +#endif + +#ifdef XK_Begin + if(test(XK_Begin, "Begin") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Begin"); + FAIL; +#endif + +#ifdef XK_Select + if(test(XK_Select, "Select") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Select"); + FAIL; +#endif + +#ifdef XK_Print + if(test(XK_Print, "Print") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Print"); + FAIL; +#endif + +#ifdef XK_Execute + if(test(XK_Execute, "Execute") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Execute"); + FAIL; +#endif + +#ifdef XK_Insert + if(test(XK_Insert, "Insert") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Insert"); + FAIL; +#endif + +#ifdef XK_Undo + if(test(XK_Undo, "Undo") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Undo"); + FAIL; +#endif + +#ifdef XK_Redo + if(test(XK_Redo, "Redo") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Redo"); + FAIL; +#endif + +#ifdef XK_Menu + if(test(XK_Menu, "Menu") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Menu"); + FAIL; +#endif + +#ifdef XK_Find + if(test(XK_Find, "Find") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Find"); + FAIL; +#endif + +#ifdef XK_Cancel + if(test(XK_Cancel, "Cancel") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Cancel"); + FAIL; +#endif + +#ifdef XK_Help + if(test(XK_Help, "Help") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Help"); + FAIL; +#endif + +#ifdef XK_Break + if(test(XK_Break, "Break") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Break"); + FAIL; +#endif + +#ifdef XK_Mode_switch + if(test(XK_Mode_switch, "Mode_switch") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Mode_switch"); + FAIL; +#endif + +#ifdef XK_script_switch + if(test(XK_script_switch, "script_switch") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_script_switch"); + FAIL; +#endif + +#ifdef XK_Num_Lock + if(test(XK_Num_Lock, "Num_Lock") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Num_Lock"); + FAIL; +#endif + +#ifdef XK_KP_Space + if(test(XK_KP_Space, "KP_Space") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_KP_Space"); + FAIL; +#endif + +#ifdef XK_KP_Tab + if(test(XK_KP_Tab, "KP_Tab") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_KP_Tab"); + FAIL; +#endif + +#ifdef XK_KP_Enter + if(test(XK_KP_Enter, "KP_Enter") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_KP_Enter"); + FAIL; +#endif + +#ifdef XK_KP_F1 + if(test(XK_KP_F1, "KP_F1") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_KP_F1"); + FAIL; +#endif + +#ifdef XK_KP_F2 + if(test(XK_KP_F2, "KP_F2") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_KP_F2"); + FAIL; +#endif + +#ifdef XK_KP_F3 + if(test(XK_KP_F3, "KP_F3") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_KP_F3"); + FAIL; +#endif + +#ifdef XK_KP_F4 + if(test(XK_KP_F4, "KP_F4") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_KP_F4"); + FAIL; +#endif + +#ifdef XK_KP_Multiply + if(test(XK_KP_Multiply, "KP_Multiply") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_KP_Multiply"); + FAIL; +#endif + +#ifdef XK_KP_Add + if(test(XK_KP_Add, "KP_Add") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_KP_Add"); + FAIL; +#endif + +#ifdef XK_KP_Separator + if(test(XK_KP_Separator, "KP_Separator") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_KP_Separator"); + FAIL; +#endif + +#ifdef XK_KP_Subtract + if(test(XK_KP_Subtract, "KP_Subtract") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_KP_Subtract"); + FAIL; +#endif + +#ifdef XK_KP_Decimal + if(test(XK_KP_Decimal, "KP_Decimal") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_KP_Decimal"); + FAIL; +#endif + +#ifdef XK_KP_Divide + if(test(XK_KP_Divide, "KP_Divide") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_KP_Divide"); + FAIL; +#endif + +#ifdef XK_KP_0 + if(test(XK_KP_0, "KP_0") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_KP_0"); + FAIL; +#endif + +#ifdef XK_KP_1 + if(test(XK_KP_1, "KP_1") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_KP_1"); + FAIL; +#endif + +#ifdef XK_KP_2 + if(test(XK_KP_2, "KP_2") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_KP_2"); + FAIL; +#endif + +#ifdef XK_KP_3 + if(test(XK_KP_3, "KP_3") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_KP_3"); + FAIL; +#endif + +#ifdef XK_KP_4 + if(test(XK_KP_4, "KP_4") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_KP_4"); + FAIL; +#endif + +#ifdef XK_KP_5 + if(test(XK_KP_5, "KP_5") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_KP_5"); + FAIL; +#endif + +#ifdef XK_KP_6 + if(test(XK_KP_6, "KP_6") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_KP_6"); + FAIL; +#endif + +#ifdef XK_KP_7 + if(test(XK_KP_7, "KP_7") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_KP_7"); + FAIL; +#endif + +#ifdef XK_KP_8 + if(test(XK_KP_8, "KP_8") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_KP_8"); + FAIL; +#endif + +#ifdef XK_KP_9 + if(test(XK_KP_9, "KP_9") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_KP_9"); + FAIL; +#endif + +#ifdef XK_KP_Equal + if(test(XK_KP_Equal, "KP_Equal") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_KP_Equal"); + FAIL; +#endif + +#ifdef XK_F1 + if(test(XK_F1, "F1") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_F1"); + FAIL; +#endif + +#ifdef XK_F2 + if(test(XK_F2, "F2") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_F2"); + FAIL; +#endif + +#ifdef XK_F3 + if(test(XK_F3, "F3") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_F3"); + FAIL; +#endif + +#ifdef XK_F4 + if(test(XK_F4, "F4") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_F4"); + FAIL; +#endif + +#ifdef XK_F5 + if(test(XK_F5, "F5") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_F5"); + FAIL; +#endif + +#ifdef XK_F6 + if(test(XK_F6, "F6") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_F6"); + FAIL; +#endif + +#ifdef XK_F7 + if(test(XK_F7, "F7") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_F7"); + FAIL; +#endif + +#ifdef XK_F8 + if(test(XK_F8, "F8") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_F8"); + FAIL; +#endif + +#ifdef XK_F9 + if(test(XK_F9, "F9") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_F9"); + FAIL; +#endif + +#ifdef XK_F10 + if(test(XK_F10, "F10") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_F10"); + FAIL; +#endif + +#ifdef XK_F11 + if(test(XK_F11, "F11") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_F11"); + FAIL; +#endif + +#ifdef XK_L1 + if(test(XK_L1, "L1") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_L1"); + FAIL; +#endif + +#ifdef XK_F12 + if(test(XK_F12, "F12") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_F12"); + FAIL; +#endif + +#ifdef XK_L2 + if(test(XK_L2, "L2") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_L2"); + FAIL; +#endif + +#ifdef XK_F13 + if(test(XK_F13, "F13") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_F13"); + FAIL; +#endif + +#ifdef XK_L3 + if(test(XK_L3, "L3") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_L3"); + FAIL; +#endif + +#ifdef XK_F14 + if(test(XK_F14, "F14") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_F14"); + FAIL; +#endif + +#ifdef XK_L4 + if(test(XK_L4, "L4") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_L4"); + FAIL; +#endif + +#ifdef XK_F15 + if(test(XK_F15, "F15") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_F15"); + FAIL; +#endif + +#ifdef XK_L5 + if(test(XK_L5, "L5") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_L5"); + FAIL; +#endif + +#ifdef XK_F16 + if(test(XK_F16, "F16") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_F16"); + FAIL; +#endif + +#ifdef XK_L6 + if(test(XK_L6, "L6") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_L6"); + FAIL; +#endif + +#ifdef XK_F17 + if(test(XK_F17, "F17") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_F17"); + FAIL; +#endif + +#ifdef XK_L7 + if(test(XK_L7, "L7") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_L7"); + FAIL; +#endif + +#ifdef XK_F18 + if(test(XK_F18, "F18") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_F18"); + FAIL; +#endif + +#ifdef XK_L8 + if(test(XK_L8, "L8") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_L8"); + FAIL; +#endif + +#ifdef XK_F19 + if(test(XK_F19, "F19") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_F19"); + FAIL; +#endif + +#ifdef XK_L9 + if(test(XK_L9, "L9") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_L9"); + FAIL; +#endif + +#ifdef XK_F20 + if(test(XK_F20, "F20") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_F20"); + FAIL; +#endif + +#ifdef XK_L10 + if(test(XK_L10, "L10") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_L10"); + FAIL; +#endif + +#ifdef XK_F21 + if(test(XK_F21, "F21") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_F21"); + FAIL; +#endif + +#ifdef XK_R1 + if(test(XK_R1, "R1") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_R1"); + FAIL; +#endif + +#ifdef XK_F22 + if(test(XK_F22, "F22") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_F22"); + FAIL; +#endif + +#ifdef XK_R2 + if(test(XK_R2, "R2") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_R2"); + FAIL; +#endif + +#ifdef XK_F23 + if(test(XK_F23, "F23") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_F23"); + FAIL; +#endif + +#ifdef XK_R3 + if(test(XK_R3, "R3") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_R3"); + FAIL; +#endif + +#ifdef XK_F24 + if(test(XK_F24, "F24") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_F24"); + FAIL; +#endif + +#ifdef XK_R4 + if(test(XK_R4, "R4") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_R4"); + FAIL; +#endif + +#ifdef XK_F25 + if(test(XK_F25, "F25") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_F25"); + FAIL; +#endif + +#ifdef XK_R5 + if(test(XK_R5, "R5") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_R5"); + FAIL; +#endif + +#ifdef XK_F26 + if(test(XK_F26, "F26") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_F26"); + FAIL; +#endif + +#ifdef XK_R6 + if(test(XK_R6, "R6") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_R6"); + FAIL; +#endif + +#ifdef XK_F27 + if(test(XK_F27, "F27") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_F27"); + FAIL; +#endif + +#ifdef XK_R7 + if(test(XK_R7, "R7") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_R7"); + FAIL; +#endif + +#ifdef XK_F28 + if(test(XK_F28, "F28") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_F28"); + FAIL; +#endif + +#ifdef XK_R8 + if(test(XK_R8, "R8") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_R8"); + FAIL; +#endif + +#ifdef XK_F29 + if(test(XK_F29, "F29") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_F29"); + FAIL; +#endif + +#ifdef XK_R9 + if(test(XK_R9, "R9") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_R9"); + FAIL; +#endif + +#ifdef XK_F30 + if(test(XK_F30, "F30") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_F30"); + FAIL; +#endif + +#ifdef XK_R10 + if(test(XK_R10, "R10") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_R10"); + FAIL; +#endif + +#ifdef XK_F31 + if(test(XK_F31, "F31") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_F31"); + FAIL; +#endif + +#ifdef XK_R11 + if(test(XK_R11, "R11") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_R11"); + FAIL; +#endif + +#ifdef XK_F32 + if(test(XK_F32, "F32") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_F32"); + FAIL; +#endif + +#ifdef XK_R12 + if(test(XK_R12, "R12") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_R12"); + FAIL; +#endif + +#ifdef XK_F33 + if(test(XK_F33, "F33") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_F33"); + FAIL; +#endif + +#ifdef XK_R13 + if(test(XK_R13, "R13") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_R13"); + FAIL; +#endif + +#ifdef XK_F34 + if(test(XK_F34, "F34") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_F34"); + FAIL; +#endif + +#ifdef XK_R14 + if(test(XK_R14, "R14") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_R14"); + FAIL; +#endif + +#ifdef XK_F35 + if(test(XK_F35, "F35") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_F35"); + FAIL; +#endif + +#ifdef XK_R15 + if(test(XK_R15, "R15") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_R15"); + FAIL; +#endif + +#ifdef XK_Shift_L + if(test(XK_Shift_L, "Shift_L") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Shift_L"); + FAIL; +#endif + +#ifdef XK_Shift_R + if(test(XK_Shift_R, "Shift_R") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Shift_R"); + FAIL; +#endif + +#ifdef XK_Control_L + if(test(XK_Control_L, "Control_L") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Control_L"); + FAIL; +#endif + +#ifdef XK_Control_R + if(test(XK_Control_R, "Control_R") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Control_R"); + FAIL; +#endif + +#ifdef XK_Caps_Lock + if(test(XK_Caps_Lock, "Caps_Lock") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Caps_Lock"); + FAIL; +#endif + +#ifdef XK_Shift_Lock + if(test(XK_Shift_Lock, "Shift_Lock") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Shift_Lock"); + FAIL; +#endif + +#ifdef XK_Meta_L + if(test(XK_Meta_L, "Meta_L") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Meta_L"); + FAIL; +#endif + +#ifdef XK_Meta_R + if(test(XK_Meta_R, "Meta_R") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Meta_R"); + FAIL; +#endif + +#ifdef XK_Alt_L + if(test(XK_Alt_L, "Alt_L") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Alt_L"); + FAIL; +#endif + +#ifdef XK_Alt_R + if(test(XK_Alt_R, "Alt_R") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Alt_R"); + FAIL; +#endif + +#ifdef XK_Super_L + if(test(XK_Super_L, "Super_L") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Super_L"); + FAIL; +#endif + +#ifdef XK_Super_R + if(test(XK_Super_R, "Super_R") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Super_R"); + FAIL; +#endif + +#ifdef XK_Hyper_L + if(test(XK_Hyper_L, "Hyper_L") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Hyper_L"); + FAIL; +#endif + +#ifdef XK_Hyper_R + if(test(XK_Hyper_R, "Hyper_R") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Hyper_R"); + FAIL; +#endif + +#ifdef XK_Delete + if(test(XK_Delete, "Delete") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_Delete"); + FAIL; +#endif + + CHECKPASS(148); +} diff --git a/xts5/Xopen/XStringToKeysym/TestP.c b/xts5/Xopen/XStringToKeysym/TestP.c new file mode 100644 index 00000000..253ffc09 --- /dev/null +++ b/xts5/Xopen/XStringToKeysym/TestP.c @@ -0,0 +1,963 @@ +/* +Copyright (c) 2005 X.Org Foundation L.L.C. + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies +of the Software, and to permit persons to whom the Software is furnished to do +so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. +*/ +/* +* $Header: /cvs/xtest/xtest/xts5/tset/Xopen/XStringToKeysym/TestP.c,v 1.2 2005-11-03 08:44:01 jmichael Exp $ +* +* Project: VSW5 +* +* File: xts5/tset/Xopen/XStringToKeysym/TestP.c +* +* Description: +* Tests for XStringToKeysym() +* +* Modifications: +* $Log: TestP.c,v $ +* Revision 1.2 2005-11-03 08:44:01 jmichael +* clean up all vsw5 paths to use xts5 instead. +* +* Revision 1.1.1.2 2005/04/15 14:05:40 anderson +* Reimport of the base with the legal name in the copyright fixed. +* +* Revision 8.0 1998/12/23 23:35:58 mar +* Branch point for Release 5.0.2 +* +* Revision 7.0 1998/10/30 22:58:43 mar +* Branch point for Release 5.0.2b1 +* +* Revision 6.0 1998/03/02 05:27:11 tbr +* Branch point for Release 5.0.1 +* +* Revision 5.0 1998/01/26 03:23:44 tbr +* Branch point for Release 5.0.1b1 +* +* Revision 4.1 1996/05/09 21:19:34 andy +* Fixed X includes +* +* Revision 4.0 1995/12/15 09:14:46 tbr +* Branch point for Release 5.0.0 +* +* Revision 3.1 1995/12/15 01:18:12 andy +* Prepare for GA Release +* +*/ +/* + * SCCS: @(#) TestP.c Rel 1.1 (11/28/91) + * + * UniSoft Ltd., London, England + * + * (C) Copyright 1991 X/Open Company Limited + * + * All rights reserved. No part of this source code may be reproduced, + * stored in a retrieval system, or transmitted, in any form or by any + * means, electronic, mechanical, photocopying, recording or otherwise, + * except as stated in the end-user licence agreement, without the prior + * permission of the copyright owners. + * + * X/Open and the 'X' symbol are trademarks of X/Open Company Limited in + * the UK and other countries. + */ + +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif + +#include <stdlib.h> +#include "xtest.h" +#include "X11/Xlib.h" +#include "X11/Xutil.h" +#include "X11/Xresource.h" +#include "tet_api.h" +#include "xtestlib.h" +#include "pixval.h" + +extern char *TestName; + +static int +test(symbol, str) +KeySym symbol; +char *str; +{ +KeySym rsym; + + rsym = XStringToKeysym(str); + + if(rsym == NoSymbol) { + report("XStringToKeysym() returned NoSymbol for string \"%s\".", str); + return(0); + } + + if(rsym != symbol) { + report("XStringToKeysym() returned KeySym 0x%lx instead of 0x%lx.", (long) rsym, (long) symbol); + return(0); + } + return(1); +} + +static void +reporterr(s) +char *s; +{ + report("Symbol \"%s\" is not defined.", s); +} +#define XK_PUBLISHING +#include <X11/keysymdef.h> +#undef XK_PUBLISHING + +strtsymP() +{ +int pass = 0, fail = 0; +char *symstr; +KeySym rsym; + + +#ifdef XK_emspace + if(test(XK_emspace, "emspace") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_emspace"); + FAIL; +#endif + +#ifdef XK_enspace + if(test(XK_enspace, "enspace") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_enspace"); + FAIL; +#endif + +#ifdef XK_em3space + if(test(XK_em3space, "em3space") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_em3space"); + FAIL; +#endif + +#ifdef XK_em4space + if(test(XK_em4space, "em4space") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_em4space"); + FAIL; +#endif + +#ifdef XK_digitspace + if(test(XK_digitspace, "digitspace") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_digitspace"); + FAIL; +#endif + +#ifdef XK_punctspace + if(test(XK_punctspace, "punctspace") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_punctspace"); + FAIL; +#endif + +#ifdef XK_thinspace + if(test(XK_thinspace, "thinspace") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_thinspace"); + FAIL; +#endif + +#ifdef XK_hairspace + if(test(XK_hairspace, "hairspace") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_hairspace"); + FAIL; +#endif + +#ifdef XK_emdash + if(test(XK_emdash, "emdash") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_emdash"); + FAIL; +#endif + +#ifdef XK_endash + if(test(XK_endash, "endash") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_endash"); + FAIL; +#endif + +#ifdef XK_signifblank + if(test(XK_signifblank, "signifblank") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_signifblank"); + FAIL; +#endif + +#ifdef XK_ellipsis + if(test(XK_ellipsis, "ellipsis") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_ellipsis"); + FAIL; +#endif + +#ifdef XK_doubbaselinedot + if(test(XK_doubbaselinedot, "doubbaselinedot") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_doubbaselinedot"); + FAIL; +#endif + +#ifdef XK_onethird + if(test(XK_onethird, "onethird") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_onethird"); + FAIL; +#endif + +#ifdef XK_twothirds + if(test(XK_twothirds, "twothirds") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_twothirds"); + FAIL; +#endif + +#ifdef XK_onefifth + if(test(XK_onefifth, "onefifth") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_onefifth"); + FAIL; +#endif + +#ifdef XK_twofifths + if(test(XK_twofifths, "twofifths") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_twofifths"); + FAIL; +#endif + +#ifdef XK_threefifths + if(test(XK_threefifths, "threefifths") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_threefifths"); + FAIL; +#endif + +#ifdef XK_fourfifths + if(test(XK_fourfifths, "fourfifths") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_fourfifths"); + FAIL; +#endif + +#ifdef XK_onesixth + if(test(XK_onesixth, "onesixth") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_onesixth"); + FAIL; +#endif + +#ifdef XK_fivesixths + if(test(XK_fivesixths, "fivesixths") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_fivesixths"); + FAIL; +#endif + +#ifdef XK_careof + if(test(XK_careof, "careof") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_careof"); + FAIL; +#endif + +#ifdef XK_figdash + if(test(XK_figdash, "figdash") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_figdash"); + FAIL; +#endif + +#ifdef XK_leftanglebracket + if(test(XK_leftanglebracket, "leftanglebracket") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_leftanglebracket"); + FAIL; +#endif + +#ifdef XK_decimalpoint + if(test(XK_decimalpoint, "decimalpoint") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_decimalpoint"); + FAIL; +#endif + +#ifdef XK_rightanglebracket + if(test(XK_rightanglebracket, "rightanglebracket") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_rightanglebracket"); + FAIL; +#endif + +#ifdef XK_marker + if(test(XK_marker, "marker") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_marker"); + FAIL; +#endif + +#ifdef XK_oneeighth + if(test(XK_oneeighth, "oneeighth") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_oneeighth"); + FAIL; +#endif + +#ifdef XK_threeeighths + if(test(XK_threeeighths, "threeeighths") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_threeeighths"); + FAIL; +#endif + +#ifdef XK_fiveeighths + if(test(XK_fiveeighths, "fiveeighths") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_fiveeighths"); + FAIL; +#endif + +#ifdef XK_seveneighths + if(test(XK_seveneighths, "seveneighths") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_seveneighths"); + FAIL; +#endif + +#ifdef XK_trademark + if(test(XK_trademark, "trademark") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_trademark"); + FAIL; +#endif + +#ifdef XK_signaturemark + if(test(XK_signaturemark, "signaturemark") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_signaturemark"); + FAIL; +#endif + +#ifdef XK_trademarkincircle + if(test(XK_trademarkincircle, "trademarkincircle") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_trademarkincircle"); + FAIL; +#endif + +#ifdef XK_leftopentriangle + if(test(XK_leftopentriangle, "leftopentriangle") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_leftopentriangle"); + FAIL; +#endif + +#ifdef XK_rightopentriangle + if(test(XK_rightopentriangle, "rightopentriangle") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_rightopentriangle"); + FAIL; +#endif + +#ifdef XK_emopencircle + if(test(XK_emopencircle, "emopencircle") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_emopencircle"); + FAIL; +#endif + +#ifdef XK_emopenrectangle + if(test(XK_emopenrectangle, "emopenrectangle") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_emopenrectangle"); + FAIL; +#endif + +#ifdef XK_leftsinglequotemark + if(test(XK_leftsinglequotemark, "leftsinglequotemark") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_leftsinglequotemark"); + FAIL; +#endif + +#ifdef XK_rightsinglequotemark + if(test(XK_rightsinglequotemark, "rightsinglequotemark") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_rightsinglequotemark"); + FAIL; +#endif + +#ifdef XK_leftdoublequotemark + if(test(XK_leftdoublequotemark, "leftdoublequotemark") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_leftdoublequotemark"); + FAIL; +#endif + +#ifdef XK_rightdoublequotemark + if(test(XK_rightdoublequotemark, "rightdoublequotemark") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_rightdoublequotemark"); + FAIL; +#endif + +#ifdef XK_prescription + if(test(XK_prescription, "prescription") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_prescription"); + FAIL; +#endif + +#ifdef XK_minutes + if(test(XK_minutes, "minutes") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_minutes"); + FAIL; +#endif + +#ifdef XK_seconds + if(test(XK_seconds, "seconds") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_seconds"); + FAIL; +#endif + +#ifdef XK_latincross + if(test(XK_latincross, "latincross") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_latincross"); + FAIL; +#endif + +#ifdef XK_hexagram + if(test(XK_hexagram, "hexagram") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_hexagram"); + FAIL; +#endif + +#ifdef XK_filledrectbullet + if(test(XK_filledrectbullet, "filledrectbullet") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_filledrectbullet"); + FAIL; +#endif + +#ifdef XK_filledlefttribullet + if(test(XK_filledlefttribullet, "filledlefttribullet") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_filledlefttribullet"); + FAIL; +#endif + +#ifdef XK_filledrighttribullet + if(test(XK_filledrighttribullet, "filledrighttribullet") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_filledrighttribullet"); + FAIL; +#endif + +#ifdef XK_emfilledcircle + if(test(XK_emfilledcircle, "emfilledcircle") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_emfilledcircle"); + FAIL; +#endif + +#ifdef XK_emfilledrect + if(test(XK_emfilledrect, "emfilledrect") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_emfilledrect"); + FAIL; +#endif + +#ifdef XK_enopencircbullet + if(test(XK_enopencircbullet, "enopencircbullet") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_enopencircbullet"); + FAIL; +#endif + +#ifdef XK_enopensquarebullet + if(test(XK_enopensquarebullet, "enopensquarebullet") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_enopensquarebullet"); + FAIL; +#endif + +#ifdef XK_openrectbullet + if(test(XK_openrectbullet, "openrectbullet") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_openrectbullet"); + FAIL; +#endif + +#ifdef XK_opentribulletup + if(test(XK_opentribulletup, "opentribulletup") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_opentribulletup"); + FAIL; +#endif + +#ifdef XK_opentribulletdown + if(test(XK_opentribulletdown, "opentribulletdown") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_opentribulletdown"); + FAIL; +#endif + +#ifdef XK_openstar + if(test(XK_openstar, "openstar") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_openstar"); + FAIL; +#endif + +#ifdef XK_enfilledcircbullet + if(test(XK_enfilledcircbullet, "enfilledcircbullet") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_enfilledcircbullet"); + FAIL; +#endif + +#ifdef XK_enfilledsqbullet + if(test(XK_enfilledsqbullet, "enfilledsqbullet") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_enfilledsqbullet"); + FAIL; +#endif + +#ifdef XK_filledtribulletup + if(test(XK_filledtribulletup, "filledtribulletup") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_filledtribulletup"); + FAIL; +#endif + +#ifdef XK_filledtribulletdown + if(test(XK_filledtribulletdown, "filledtribulletdown") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_filledtribulletdown"); + FAIL; +#endif + +#ifdef XK_leftpointer + if(test(XK_leftpointer, "leftpointer") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_leftpointer"); + FAIL; +#endif + +#ifdef XK_rightpointer + if(test(XK_rightpointer, "rightpointer") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_rightpointer"); + FAIL; +#endif + +#ifdef XK_club + if(test(XK_club, "club") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_club"); + FAIL; +#endif + +#ifdef XK_diamond + if(test(XK_diamond, "diamond") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_diamond"); + FAIL; +#endif + +#ifdef XK_heart + if(test(XK_heart, "heart") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_heart"); + FAIL; +#endif + +#ifdef XK_maltesecross + if(test(XK_maltesecross, "maltesecross") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_maltesecross"); + FAIL; +#endif + +#ifdef XK_dagger + if(test(XK_dagger, "dagger") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_dagger"); + FAIL; +#endif + +#ifdef XK_doubledagger + if(test(XK_doubledagger, "doubledagger") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_doubledagger"); + FAIL; +#endif + +#ifdef XK_checkmark + if(test(XK_checkmark, "checkmark") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_checkmark"); + FAIL; +#endif + +#ifdef XK_ballotcross + if(test(XK_ballotcross, "ballotcross") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_ballotcross"); + FAIL; +#endif + +#ifdef XK_musicalsharp + if(test(XK_musicalsharp, "musicalsharp") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_musicalsharp"); + FAIL; +#endif + +#ifdef XK_musicalflat + if(test(XK_musicalflat, "musicalflat") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_musicalflat"); + FAIL; +#endif + +#ifdef XK_malesymbol + if(test(XK_malesymbol, "malesymbol") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_malesymbol"); + FAIL; +#endif + +#ifdef XK_femalesymbol + if(test(XK_femalesymbol, "femalesymbol") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_femalesymbol"); + FAIL; +#endif + +#ifdef XK_telephone + if(test(XK_telephone, "telephone") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_telephone"); + FAIL; +#endif + +#ifdef XK_telephonerecorder + if(test(XK_telephonerecorder, "telephonerecorder") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_telephonerecorder"); + FAIL; +#endif + +#ifdef XK_phonographcopyright + if(test(XK_phonographcopyright, "phonographcopyright") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_phonographcopyright"); + FAIL; +#endif + +#ifdef XK_caret + if(test(XK_caret, "caret") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_caret"); + FAIL; +#endif + +#ifdef XK_singlelowquotemark + if(test(XK_singlelowquotemark, "singlelowquotemark") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_singlelowquotemark"); + FAIL; +#endif + +#ifdef XK_doublelowquotemark + if(test(XK_doublelowquotemark, "doublelowquotemark") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_doublelowquotemark"); + FAIL; +#endif + +#ifdef XK_cursor + if(test(XK_cursor, "cursor") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_cursor"); + FAIL; +#endif + + CHECKPASS(83); +} diff --git a/xts5/Xopen/XStringToKeysym/TestS.c b/xts5/Xopen/XStringToKeysym/TestS.c new file mode 100644 index 00000000..6957dc81 --- /dev/null +++ b/xts5/Xopen/XStringToKeysym/TestS.c @@ -0,0 +1,373 @@ +/* +Copyright (c) 2005 X.Org Foundation L.L.C. + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies +of the Software, and to permit persons to whom the Software is furnished to do +so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. +*/ +/* +* $Header: /cvs/xtest/xtest/xts5/tset/Xopen/XStringToKeysym/TestS.c,v 1.2 2005-11-03 08:44:01 jmichael Exp $ +* +* Project: VSW5 +* +* File: xts5/tset/Xopen/XStringToKeysym/TestS.c +* +* Description: +* Tests for XStringToKeysym() +* +* Modifications: +* $Log: TestS.c,v $ +* Revision 1.2 2005-11-03 08:44:01 jmichael +* clean up all vsw5 paths to use xts5 instead. +* +* Revision 1.1.1.2 2005/04/15 14:05:40 anderson +* Reimport of the base with the legal name in the copyright fixed. +* +* Revision 8.0 1998/12/23 23:35:59 mar +* Branch point for Release 5.0.2 +* +* Revision 7.0 1998/10/30 22:58:44 mar +* Branch point for Release 5.0.2b1 +* +* Revision 6.0 1998/03/02 05:27:12 tbr +* Branch point for Release 5.0.1 +* +* Revision 5.0 1998/01/26 03:23:45 tbr +* Branch point for Release 5.0.1b1 +* +* Revision 4.1 1996/05/09 21:19:34 andy +* Fixed X includes +* +* Revision 4.0 1995/12/15 09:14:48 tbr +* Branch point for Release 5.0.0 +* +* Revision 3.1 1995/12/15 01:18:14 andy +* Prepare for GA Release +* +*/ +/* + * SCCS: @(#) TestS.c Rel 1.1 (11/28/91) + * + * UniSoft Ltd., London, England + * + * (C) Copyright 1991 X/Open Company Limited + * + * All rights reserved. No part of this source code may be reproduced, + * stored in a retrieval system, or transmitted, in any form or by any + * means, electronic, mechanical, photocopying, recording or otherwise, + * except as stated in the end-user licence agreement, without the prior + * permission of the copyright owners. + * + * X/Open and the 'X' symbol are trademarks of X/Open Company Limited in + * the UK and other countries. + */ + +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif + +#include <stdlib.h> +#include "xtest.h" +#include "X11/Xlib.h" +#include "X11/Xutil.h" +#include "X11/Xresource.h" +#include "tet_api.h" +#include "xtestlib.h" +#include "pixval.h" + +extern char *TestName; + +static int +test(symbol, str) +KeySym symbol; +char *str; +{ +KeySym rsym; + + rsym = XStringToKeysym(str); + + if(rsym == NoSymbol) { + report("XStringToKeysym() returned NoSymbol for string \"%s\".", str); + return(0); + } + + if(rsym != symbol) { + report("XStringToKeysym() returned KeySym 0x%lx instead of 0x%lx.", (long) rsym, (long) symbol); + return(0); + } + return(1); +} + +static void +reporterr(s) +char *s; +{ + report("Symbol \"%s\" is not defined.", s); +} +#define XK_SPECIAL +#include <X11/keysymdef.h> +#undef XK_SPECIAL + +strtsymS() +{ +int pass = 0, fail = 0; +char *symstr; +KeySym rsym; + + +#ifdef XK_blank + if(test(XK_blank, "blank") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_blank"); + FAIL; +#endif + +#ifdef XK_soliddiamond + if(test(XK_soliddiamond, "soliddiamond") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_soliddiamond"); + FAIL; +#endif + +#ifdef XK_checkerboard + if(test(XK_checkerboard, "checkerboard") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_checkerboard"); + FAIL; +#endif + +#ifdef XK_ht + if(test(XK_ht, "ht") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_ht"); + FAIL; +#endif + +#ifdef XK_ff + if(test(XK_ff, "ff") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_ff"); + FAIL; +#endif + +#ifdef XK_cr + if(test(XK_cr, "cr") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_cr"); + FAIL; +#endif + +#ifdef XK_lf + if(test(XK_lf, "lf") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_lf"); + FAIL; +#endif + +#ifdef XK_nl + if(test(XK_nl, "nl") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_nl"); + FAIL; +#endif + +#ifdef XK_vt + if(test(XK_vt, "vt") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_vt"); + FAIL; +#endif + +#ifdef XK_lowrightcorner + if(test(XK_lowrightcorner, "lowrightcorner") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_lowrightcorner"); + FAIL; +#endif + +#ifdef XK_uprightcorner + if(test(XK_uprightcorner, "uprightcorner") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_uprightcorner"); + FAIL; +#endif + +#ifdef XK_upleftcorner + if(test(XK_upleftcorner, "upleftcorner") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_upleftcorner"); + FAIL; +#endif + +#ifdef XK_lowleftcorner + if(test(XK_lowleftcorner, "lowleftcorner") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_lowleftcorner"); + FAIL; +#endif + +#ifdef XK_crossinglines + if(test(XK_crossinglines, "crossinglines") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_crossinglines"); + FAIL; +#endif + +#ifdef XK_horizlinescan1 + if(test(XK_horizlinescan1, "horizlinescan1") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_horizlinescan1"); + FAIL; +#endif + +#ifdef XK_horizlinescan3 + if(test(XK_horizlinescan3, "horizlinescan3") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_horizlinescan3"); + FAIL; +#endif + +#ifdef XK_horizlinescan5 + if(test(XK_horizlinescan5, "horizlinescan5") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_horizlinescan5"); + FAIL; +#endif + +#ifdef XK_horizlinescan7 + if(test(XK_horizlinescan7, "horizlinescan7") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_horizlinescan7"); + FAIL; +#endif + +#ifdef XK_horizlinescan9 + if(test(XK_horizlinescan9, "horizlinescan9") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_horizlinescan9"); + FAIL; +#endif + +#ifdef XK_leftt + if(test(XK_leftt, "leftt") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_leftt"); + FAIL; +#endif + +#ifdef XK_rightt + if(test(XK_rightt, "rightt") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_rightt"); + FAIL; +#endif + +#ifdef XK_bott + if(test(XK_bott, "bott") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_bott"); + FAIL; +#endif + +#ifdef XK_topt + if(test(XK_topt, "topt") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_topt"); + FAIL; +#endif + +#ifdef XK_vertbar + if(test(XK_vertbar, "vertbar") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_vertbar"); + FAIL; +#endif + + CHECKPASS(24); +} diff --git a/xts5/Xopen/XStringToKeysym/TestT.c b/xts5/Xopen/XStringToKeysym/TestT.c new file mode 100644 index 00000000..36d69cc2 --- /dev/null +++ b/xts5/Xopen/XStringToKeysym/TestT.c @@ -0,0 +1,623 @@ +/* +Copyright (c) 2005 X.Org Foundation L.L.C. + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies +of the Software, and to permit persons to whom the Software is furnished to do +so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. +*/ +/* +* $Header: /cvs/xtest/xtest/xts5/tset/Xopen/XStringToKeysym/TestT.c,v 1.2 2005-11-03 08:44:01 jmichael Exp $ +* +* Project: VSW5 +* +* File: xts5/tset/Xopen/XStringToKeysym/TestT.c +* +* Description: +* Tests for XStringToKeysym() +* +* Modifications: +* $Log: TestT.c,v $ +* Revision 1.2 2005-11-03 08:44:01 jmichael +* clean up all vsw5 paths to use xts5 instead. +* +* Revision 1.1.1.2 2005/04/15 14:05:40 anderson +* Reimport of the base with the legal name in the copyright fixed. +* +* Revision 8.0 1998/12/23 23:35:59 mar +* Branch point for Release 5.0.2 +* +* Revision 7.0 1998/10/30 22:58:45 mar +* Branch point for Release 5.0.2b1 +* +* Revision 6.0 1998/03/02 05:27:12 tbr +* Branch point for Release 5.0.1 +* +* Revision 5.0 1998/01/26 03:23:45 tbr +* Branch point for Release 5.0.1b1 +* +* Revision 4.1 1996/05/09 21:19:34 andy +* Fixed X includes +* +* Revision 4.0 1995/12/15 09:14:49 tbr +* Branch point for Release 5.0.0 +* +* Revision 3.1 1995/12/15 01:18:15 andy +* Prepare for GA Release +* +*/ +/* + * SCCS: @(#) TestT.c Rel 1.1 (11/28/91) + * + * UniSoft Ltd., London, England + * + * (C) Copyright 1991 X/Open Company Limited + * + * All rights reserved. No part of this source code may be reproduced, + * stored in a retrieval system, or transmitted, in any form or by any + * means, electronic, mechanical, photocopying, recording or otherwise, + * except as stated in the end-user licence agreement, without the prior + * permission of the copyright owners. + * + * X/Open and the 'X' symbol are trademarks of X/Open Company Limited in + * the UK and other countries. + */ + +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif + +#include <stdlib.h> +#include "xtest.h" +#include "X11/Xlib.h" +#include "X11/Xutil.h" +#include "X11/Xresource.h" +#include "tet_api.h" +#include "xtestlib.h" +#include "pixval.h" + +extern char *TestName; + +static int +test(symbol, str) +KeySym symbol; +char *str; +{ +KeySym rsym; + + rsym = XStringToKeysym(str); + + if(rsym == NoSymbol) { + report("XStringToKeysym() returned NoSymbol for string \"%s\".", str); + return(0); + } + + if(rsym != symbol) { + report("XStringToKeysym() returned KeySym 0x%lx instead of 0x%lx.", (long) rsym, (long) symbol); + return(0); + } + return(1); +} + +static void +reporterr(s) +char *s; +{ + report("Symbol \"%s\" is not defined.", s); +} +#define XK_TECHNICAL +#include <X11/keysymdef.h> +#undef XK_TECHNICAL + +strtsymT() +{ +int pass = 0, fail = 0; +char *symstr; +KeySym rsym; + + +#ifdef XK_leftradical + if(test(XK_leftradical, "leftradical") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_leftradical"); + FAIL; +#endif + +#ifdef XK_topleftradical + if(test(XK_topleftradical, "topleftradical") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_topleftradical"); + FAIL; +#endif + +#ifdef XK_horizconnector + if(test(XK_horizconnector, "horizconnector") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_horizconnector"); + FAIL; +#endif + +#ifdef XK_topintegral + if(test(XK_topintegral, "topintegral") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_topintegral"); + FAIL; +#endif + +#ifdef XK_botintegral + if(test(XK_botintegral, "botintegral") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_botintegral"); + FAIL; +#endif + +#ifdef XK_vertconnector + if(test(XK_vertconnector, "vertconnector") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_vertconnector"); + FAIL; +#endif + +#ifdef XK_topleftsqbracket + if(test(XK_topleftsqbracket, "topleftsqbracket") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_topleftsqbracket"); + FAIL; +#endif + +#ifdef XK_botleftsqbracket + if(test(XK_botleftsqbracket, "botleftsqbracket") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_botleftsqbracket"); + FAIL; +#endif + +#ifdef XK_toprightsqbracket + if(test(XK_toprightsqbracket, "toprightsqbracket") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_toprightsqbracket"); + FAIL; +#endif + +#ifdef XK_botrightsqbracket + if(test(XK_botrightsqbracket, "botrightsqbracket") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_botrightsqbracket"); + FAIL; +#endif + +#ifdef XK_topleftparens + if(test(XK_topleftparens, "topleftparens") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_topleftparens"); + FAIL; +#endif + +#ifdef XK_botleftparens + if(test(XK_botleftparens, "botleftparens") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_botleftparens"); + FAIL; +#endif + +#ifdef XK_toprightparens + if(test(XK_toprightparens, "toprightparens") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_toprightparens"); + FAIL; +#endif + +#ifdef XK_botrightparens + if(test(XK_botrightparens, "botrightparens") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_botrightparens"); + FAIL; +#endif + +#ifdef XK_leftmiddlecurlybrace + if(test(XK_leftmiddlecurlybrace, "leftmiddlecurlybrace") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_leftmiddlecurlybrace"); + FAIL; +#endif + +#ifdef XK_rightmiddlecurlybrace + if(test(XK_rightmiddlecurlybrace, "rightmiddlecurlybrace") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_rightmiddlecurlybrace"); + FAIL; +#endif + +#ifdef XK_topleftsummation + if(test(XK_topleftsummation, "topleftsummation") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_topleftsummation"); + FAIL; +#endif + +#ifdef XK_botleftsummation + if(test(XK_botleftsummation, "botleftsummation") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_botleftsummation"); + FAIL; +#endif + +#ifdef XK_topvertsummationconnector + if(test(XK_topvertsummationconnector, "topvertsummationconnector") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_topvertsummationconnector"); + FAIL; +#endif + +#ifdef XK_botvertsummationconnector + if(test(XK_botvertsummationconnector, "botvertsummationconnector") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_botvertsummationconnector"); + FAIL; +#endif + +#ifdef XK_toprightsummation + if(test(XK_toprightsummation, "toprightsummation") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_toprightsummation"); + FAIL; +#endif + +#ifdef XK_botrightsummation + if(test(XK_botrightsummation, "botrightsummation") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_botrightsummation"); + FAIL; +#endif + +#ifdef XK_rightmiddlesummation + if(test(XK_rightmiddlesummation, "rightmiddlesummation") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_rightmiddlesummation"); + FAIL; +#endif + +#ifdef XK_lessthanequal + if(test(XK_lessthanequal, "lessthanequal") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_lessthanequal"); + FAIL; +#endif + +#ifdef XK_notequal + if(test(XK_notequal, "notequal") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_notequal"); + FAIL; +#endif + +#ifdef XK_greaterthanequal + if(test(XK_greaterthanequal, "greaterthanequal") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_greaterthanequal"); + FAIL; +#endif + +#ifdef XK_integral + if(test(XK_integral, "integral") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_integral"); + FAIL; +#endif + +#ifdef XK_therefore + if(test(XK_therefore, "therefore") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_therefore"); + FAIL; +#endif + +#ifdef XK_variation + if(test(XK_variation, "variation") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_variation"); + FAIL; +#endif + +#ifdef XK_infinity + if(test(XK_infinity, "infinity") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_infinity"); + FAIL; +#endif + +#ifdef XK_nabla + if(test(XK_nabla, "nabla") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_nabla"); + FAIL; +#endif + +#ifdef XK_approximate + if(test(XK_approximate, "approximate") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_approximate"); + FAIL; +#endif + +#ifdef XK_similarequal + if(test(XK_similarequal, "similarequal") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_similarequal"); + FAIL; +#endif + +#ifdef XK_ifonlyif + if(test(XK_ifonlyif, "ifonlyif") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_ifonlyif"); + FAIL; +#endif + +#ifdef XK_implies + if(test(XK_implies, "implies") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_implies"); + FAIL; +#endif + +#ifdef XK_identical + if(test(XK_identical, "identical") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_identical"); + FAIL; +#endif + +#ifdef XK_radical + if(test(XK_radical, "radical") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_radical"); + FAIL; +#endif + +#ifdef XK_includedin + if(test(XK_includedin, "includedin") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_includedin"); + FAIL; +#endif + +#ifdef XK_includes + if(test(XK_includes, "includes") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_includes"); + FAIL; +#endif + +#ifdef XK_intersection + if(test(XK_intersection, "intersection") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_intersection"); + FAIL; +#endif + +#ifdef XK_union + if(test(XK_union, "union") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_union"); + FAIL; +#endif + +#ifdef XK_logicaland + if(test(XK_logicaland, "logicaland") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_logicaland"); + FAIL; +#endif + +#ifdef XK_logicalor + if(test(XK_logicalor, "logicalor") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_logicalor"); + FAIL; +#endif + +#ifdef XK_partialderivative + if(test(XK_partialderivative, "partialderivative") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_partialderivative"); + FAIL; +#endif + +#ifdef XK_function + if(test(XK_function, "function") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_function"); + FAIL; +#endif + +#ifdef XK_leftarrow + if(test(XK_leftarrow, "leftarrow") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_leftarrow"); + FAIL; +#endif + +#ifdef XK_uparrow + if(test(XK_uparrow, "uparrow") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_uparrow"); + FAIL; +#endif + +#ifdef XK_rightarrow + if(test(XK_rightarrow, "rightarrow") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_rightarrow"); + FAIL; +#endif + +#ifdef XK_downarrow + if(test(XK_downarrow, "downarrow") == 1) + CHECK; + else + FAIL; +#else + reporterr("XK_downarrow"); + FAIL; +#endif + + CHECKPASS(49); +} diff --git a/xts5/Xopen/XStringToKeysym/XStringToKeysym.m b/xts5/Xopen/XStringToKeysym/XStringToKeysym.m new file mode 100644 index 00000000..8d994f4a --- /dev/null +++ b/xts5/Xopen/XStringToKeysym/XStringToKeysym.m @@ -0,0 +1,1340 @@ +Copyright (c) 2005 X.Org Foundation L.L.C. + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies +of the Software, and to permit persons to whom the Software is furnished to do +so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. +$Header: /cvs/xtest/xtest/xts5/tset/Xopen/XStringToKeysym/XStringToKeysym.m,v 1.2 2005-11-03 08:44:01 jmichael Exp $ + +>># Project: VSW5 +>># +>># File: xts5/tset/Xopen/XStringToKeysym/XStringToKeysym.m +>># +>># Description: +>># Tests for XStringToKeysym() +>># +>># Modifications: +>># $Log: strtkysym.m,v $ +>># Revision 1.2 2005-11-03 08:44:01 jmichael +>># clean up all vsw5 paths to use xts5 instead. +>># +>># Revision 1.1.1.2 2005/04/15 14:05:40 anderson +>># Reimport of the base with the legal name in the copyright fixed. +>># +>># Revision 8.0 1998/12/23 23:36:00 mar +>># Branch point for Release 5.0.2 +>># +>># Revision 7.0 1998/10/30 22:58:46 mar +>># Branch point for Release 5.0.2b1 +>># +>># Revision 6.0 1998/03/02 05:27:13 tbr +>># Branch point for Release 5.0.1 +>># +>># Revision 5.0 1998/01/26 03:23:46 tbr +>># Branch point for Release 5.0.1b1 +>># +>># Revision 4.0 1995/12/15 09:14:50 tbr +>># Branch point for Release 5.0.0 +>># +>># Revision 3.1 1995/12/15 01:18:19 andy +>># Prepare for GA Release +>># +/* + * SCCS: @(#) strtkysym.m Rel 1.8 (11/28/91) + * + * UniSoft Ltd., London, England + * + * (C) Copyright 1991 X/Open Company Limited + * + * All rights reserved. No part of this source code may be reproduced, + * stored in a retrieval system, or transmitted, in any form or by any + * means, electronic, mechanical, photocopying, recording or otherwise, + * except as stated in the end-user licence agreement, without the prior + * permission of the copyright owners. + * + * X/Open and the 'X' symbol are trademarks of X/Open Company Limited in + * the UK and other countries. + */ +>>TITLE XStringToKeysym Xopen +>>CFILES Test1.c Test2.c Test3.c Test4.c TestA.c TestC.c TestG.c TestH.c TestK.c TestL.c TestM.c TestP.c TestS.c TestT.c +>>ASSERTION Good A +When the +.A string +argument is the name of a +.S KeySym +in the table +with the prefix +.S XK_ +removed, +then a call to xname returns that +.S KeySym . +.tL "Code" "Value" "Name" +.tL "1" "20" "XK_space" +.tL "1" "21" "XK_exclam" +.tL "1" "22" "XK_quotedbl" +.tL "1" "23" "XK_numbersign" +.tL "1" "24" "XK_dollar" +.tL "1" "25" "XK_percent" +.tL "1" "26" "XK_ampersand" +.tL "1" "27" "XK_apostrophe" +.tL "1" "27" "XK_quoteright" +.tL "1" "28" "XK_parenleft" +.tL "1" "29" "XK_parenright" +.tL "1" "2A" "XK_asterisk" +.tL "1" "2B" "XK_plus" +.tL "1" "2C" "XK_comma" +.tL "1" "2D" "XK_minus" +.tL "1" "2E" "XK_period" +.tL "1" "2F" "XK_slash" +.tL "1" "30" "XK_0" +.tL "1" "31" "XK_1" +.tL "1" "32" "XK_2" +.tL "1" "33" "XK_3" +.tL "1" "34" "XK_4" +.tL "1" "35" "XK_5" +.tL "1" "36" "XK_6" +.tL "1" "37" "XK_7" +.tL "1" "38" "XK_8" +.tL "1" "39" "XK_9" +.tL "1" "3A" "XK_colon" +.tL "1" "3B" "XK_semicolon" +.tL "1" "3C" "XK_less" +.tL "1" "3D" "XK_equal" +.tL "1" "3E" "XK_greater" +.tL "1" "3F" "XK_question" +.tL "1" "40" "XK_at" +.tL "1" "41" "XK_A" +.tL "1" "42" "XK_B" +.tL "1" "43" "XK_C" +.tL "1" "44" "XK_D" +.tL "1" "45" "XK_E" +.tL "1" "46" "XK_F" +.tL "1" "47" "XK_G" +.tL "1" "48" "XK_H" +.tL "1" "49" "XK_I" +.tL "1" "4A" "XK_J" +.tL "1" "4B" "XK_K" +.tL "1" "4C" "XK_L" +.tL "1" "4D" "XK_M" +.tL "1" "4E" "XK_N" +.tL "1" "4F" "XK_O" +.tL "1" "50" "XK_P" +.tL "1" "51" "XK_Q" +.tL "1" "52" "XK_R" +.tL "1" "53" "XK_S" +.tL "1" "54" "XK_T" +.tL "1" "55" "XK_U" +.tL "1" "56" "XK_V" +.tL "1" "57" "XK_W" +.tL "1" "58" "XK_X" +.tL "1" "59" "XK_Y" +.tL "1" "5A" "XK_Z" +.tL "1" "5B" "XK_bracketleft" +.tL "1" "5C" "XK_backslash" +.tL "1" "5D" "XK_bracketright" +.tL "1" "5E" "XK_asciicircum" +.tL "1" "5F" "XK_underscore" +.tL "1" "60" "XK_grave" +.tL "1" "60" "XK_quoteleft" +.tL "1" "61" "XK_a" +.tL "1" "62" "XK_b" +.tL "1" "63" "XK_c" +.tL "1" "64" "XK_d" +.tL "1" "65" "XK_e" +.tL "1" "66" "XK_f" +.tL "1" "67" "XK_g" +.tL "1" "68" "XK_h" +.tL "1" "69" "XK_i" +.tL "1" "6A" "XK_j" +.tL "1" "6B" "XK_k" +.tL "1" "6C" "XK_l" +.tL "1" "6D" "XK_m" +.tL "1" "6E" "XK_n" +.tL "1" "6F" "XK_o" +.tL "1" "70" "XK_p" +.tL "1" "71" "XK_q" +.tL "1" "72" "XK_r" +.tL "1" "73" "XK_s" +.tL "1" "74" "XK_t" +.tL "1" "75" "XK_u" +.tL "1" "76" "XK_v" +.tL "1" "77" "XK_w" +.tL "1" "78" "XK_x" +.tL "1" "79" "XK_y" +.tL "1" "7A" "XK_z" +.tL "1" "7B" "XK_braceleft" +.tL "1" "7C" "XK_bar" +.tL "1" "7D" "XK_braceright" +.tL "1" "7E" "XK_asciitilde" +.tL "1" "A0" "XK_nobreakspace" +.tL "1" "A1" "XK_exclamdown" +.tL "1" "A2" "XK_cent" +.tL "1" "A3" "XK_sterling" +.tL "1" "A4" "XK_currency" +.tL "1" "A5" "XK_yen" +.tL "1" "A6" "XK_brokenbar" +.tL "1" "A7" "XK_section" +.tL "1" "A8" "XK_diaeresis" +.tL "1" "A9" "XK_copyright" +.tL "1" "AA" "XK_ordfeminine" +.tL "1" "AB" "XK_guillemotleft" +.tL "1" "AC" "XK_notsign" +.tL "1" "AD" "XK_hyphen" +.tL "1" "AE" "XK_registered" +.tL "1" "AF" "XK_macron" +.tL "1" "B0" "XK_degree" +.tL "1" "B1" "XK_plusminus" +.tL "1" "B2" "XK_twosuperior" +.tL "1" "B3" "XK_threesuperior" +.tL "1" "B4" "XK_acute" +.tL "1" "B5" "XK_mu" +.tL "1" "B6" "XK_paragraph" +.tL "1" "B7" "XK_periodcentered" +.tL "1" "B8" "XK_cedilla" +.tL "1" "B9" "XK_onesuperior" +.tL "1" "BA" "XK_masculine" +.tL "1" "BB" "XK_guillemotright" +.tL "1" "BC" "XK_onequarter" +.tL "1" "BD" "XK_onehalf" +.tL "1" "BE" "XK_threequarters" +.tL "1" "BF" "XK_questiondown" +.tL "1" "C0" "XK_Agrave" +.tL "1" "C1" "XK_Aacute" +.tL "1" "C2" "XK_Acircumflex" +.tL "1" "C3" "XK_Atilde" +.tL "1" "C4" "XK_Adiaeresis" +.tL "1" "C5" "XK_Aring" +.tL "1" "C6" "XK_AE" +.tL "1" "C7" "XK_Ccedilla" +.tL "1" "C8" "XK_Egrave" +.tL "1" "C9" "XK_Eacute" +.tL "1" "CA" "XK_Ecircumflex" +.tL "1" "CB" "XK_Ediaeresis" +.tL "1" "CC" "XK_Igrave" +.tL "1" "CD" "XK_Iacute" +.tL "1" "CE" "XK_Icircumflex" +.tL "1" "CF" "XK_Idiaeresis" +.tL "1" "D0" "XK_ETH" +.tL "1" "D0" "XK_Eth" +.tL "1" "D1" "XK_Ntilde" +.tL "1" "D2" "XK_Ograve" +.tL "1" "D3" "XK_Oacute" +.tL "1" "D4" "XK_Ocircumflex" +.tL "1" "D5" "XK_Otilde" +.tL "1" "D6" "XK_Odiaeresis" +.tL "1" "D7" "XK_multiply" +.tL "1" "D8" "XK_Ooblique" +.tL "1" "D9" "XK_Ugrave" +.tL "1" "DA" "XK_Uacute" +.tL "1" "DB" "XK_Ucircumflex" +.tL "1" "DC" "XK_Udiaeresis" +.tL "1" "DD" "XK_Yacute" +.tL "1" "DE" "XK_THORN" +.tL "1" "DE" "XK_Thorn" +.tL "1" "DF" "XK_ssharp" +.tL "1" "E0" "XK_agrave" +.tL "1" "E1" "XK_aacute" +.tL "1" "E2" "XK_acircumflex" +.tL "1" "E3" "XK_atilde" +.tL "1" "E4" "XK_adiaeresis" +.tL "1" "E5" "XK_aring" +.tL "1" "E6" "XK_ae" +.tL "1" "E7" "XK_ccedilla" +.tL "1" "E8" "XK_egrave" +.tL "1" "E9" "XK_eacute" +.tL "1" "EA" "XK_ecircumflex" +.tL "1" "EB" "XK_ediaeresis" +.tL "1" "EC" "XK_igrave" +.tL "1" "ED" "XK_iacute" +.tL "1" "EE" "XK_icircumflex" +.tL "1" "EF" "XK_idiaeresis" +.tL "1" "F0" "XK_eth" +.tL "1" "F1" "XK_ntilde" +.tL "1" "F2" "XK_ograve" +.tL "1" "F3" "XK_oacute" +.tL "1" "F4" "XK_ocircumflex" +.tL "1" "F5" "XK_otilde" +.tL "1" "F6" "XK_odiaeresis" +.tL "1" "F7" "XK_division" +.tL "1" "F8" "XK_oslash" +.tL "1" "F9" "XK_ugrave" +.tL "1" "FA" "XK_uacute" +.tL "1" "FB" "XK_ucircumflex" +.tL "1" "FC" "XK_udiaeresis" +.tL "1" "FD" "XK_yacute" +.tL "1" "FE" "XK_thorn" +.tL "1" "FF" "XK_ydiaeresis" +>>STRATEGY +For each KeySym name in table with code 1: + Call XStringToKeysym to obtain the KeySym defined for that string. + Verify that XStringToKeysym did not return NoSymbol. + Verify that the returned string is correct. +>>CODE + + strtsym1(); + +>>ASSERTION Good A +When the +.A string +argument is the name of a +.S KeySym +in the table +with the prefix +.S XK_ +removed, +then a call to xname returns that +.S KeySym . +.tL "Code" "Value" "Name" +.tL "2" "1A1" "XK_Aogonek" +.tL "2" "1A2" "XK_breve" +.tL "2" "1A3" "XK_Lstroke" +.tL "2" "1A5" "XK_Lcaron" +.tL "2" "1A6" "XK_Sacute" +.tL "2" "1A9" "XK_Scaron" +.tL "2" "1AA" "XK_Scedilla" +.tL "2" "1AB" "XK_Tcaron" +.tL "2" "1AC" "XK_Zacute" +.tL "2" "1AE" "XK_Zcaron" +.tL "2" "1AF" "XK_Zabovedot" +.tL "2" "1B1" "XK_aogonek" +.tL "2" "1B2" "XK_ogonek" +.tL "2" "1B3" "XK_lstroke" +.tL "2" "1B5" "XK_lcaron" +.tL "2" "1B6" "XK_sacute" +.tL "2" "1B7" "XK_caron" +.tL "2" "1B9" "XK_scaron" +.tL "2" "1BA" "XK_scedilla" +.tL "2" "1BB" "XK_tcaron" +.tL "2" "1BC" "XK_zacute" +.tL "2" "1BD" "XK_doubleacute" +.tL "2" "1BE" "XK_zcaron" +.tL "2" "1BF" "XK_zabovedot" +.tL "2" "1C0" "XK_Racute" +.tL "2" "1C3" "XK_Abreve" +.tL "2" "1C5" "XK_Lacute" +.tL "2" "1C6" "XK_Cacute" +.tL "2" "1C8" "XK_Ccaron" +.tL "2" "1CA" "XK_Eogonek" +.tL "2" "1CC" "XK_Ecaron" +.tL "2" "1CF" "XK_Dcaron" +.tL "2" "1D0" "XK_Dstroke" +.tL "2" "1D1" "XK_Nacute" +.tL "2" "1D2" "XK_Ncaron" +.tL "2" "1D5" "XK_Odoubleacute" +.tL "2" "1D8" "XK_Rcaron" +.tL "2" "1D9" "XK_Uring" +.tL "2" "1DB" "XK_Udoubleacute" +.tL "2" "1DE" "XK_Tcedilla" +.tL "2" "1E0" "XK_racute" +.tL "2" "1E3" "XK_abreve" +.tL "2" "1E5" "XK_lacute" +.tL "2" "1E6" "XK_cacute" +.tL "2" "1E8" "XK_ccaron" +.tL "2" "1EA" "XK_eogonek" +.tL "2" "1EC" "XK_ecaron" +.tL "2" "1EF" "XK_dcaron" +.tL "2" "1F0" "XK_dstroke" +.tL "2" "1F1" "XK_nacute" +.tL "2" "1F2" "XK_ncaron" +.tL "2" "1F5" "XK_odoubleacute" +.tL "2" "1F8" "XK_rcaron" +.tL "2" "1F9" "XK_uring" +.tL "2" "1FB" "XK_udoubleacute" +.tL "2" "1FE" "XK_tcedilla" +.tL "2" "1FF" "XK_abovedot" +>>STRATEGY +For each KeySym name in table with code 2: + Call XStringToKeysym to obtain the KeySym defined for that string. + Verify that XStringToKeysym did not return NoSymbol. + Verify that the returned string is correct. +>>CODE + + strtsym2(); + +>>ASSERTION Good A +When the +.A string +argument is the name of a +.S KeySym +in the table +with the prefix +.S XK_ +removed, +then a call to xname returns that +.S KeySym . +.tL "Code" "Value" "Name" +.tL "3" "2A1" "XK_Hstroke" +.tL "3" "2A6" "XK_Hcircumflex" +.tL "3" "2A9" "XK_Iabovedot" +.tL "3" "2AB" "XK_Gbreve" +.tL "3" "2AC" "XK_Jcircumflex" +.tL "3" "2B1" "XK_hstroke" +.tL "3" "2B6" "XK_hcircumflex" +.tL "3" "2B9" "XK_idotless" +.tL "3" "2BB" "XK_gbreve" +.tL "3" "2BC" "XK_jcircumflex" +.tL "3" "2C5" "XK_Cabovedot" +.tL "3" "2C6" "XK_Ccircumflex" +.tL "3" "2D5" "XK_Gabovedot" +.tL "3" "2D8" "XK_Gcircumflex" +.tL "3" "2DD" "XK_Ubreve" +.tL "3" "2DE" "XK_Scircumflex" +.tL "3" "2E5" "XK_cabovedot" +.tL "3" "2E6" "XK_ccircumflex" +.tL "3" "2F5" "XK_gabovedot" +.tL "3" "2F8" "XK_gcircumflex" +.tL "3" "2FD" "XK_ubreve" +.tL "3" "2FE" "XK_scircumflex" +>>STRATEGY +For each KeySym name in table with code 3: + Call XStringToKeysym to obtain the KeySym defined for that string. + Verify that XStringToKeysym did not return NoSymbol. + Verify that the returned string is correct. +>>CODE + + strtsym3(); + +>>ASSERTION Good A +When the +.A string +argument is the name of a +.S KeySym +in the table +with the prefix +.S XK_ +removed, +then a call to xname returns that +.S KeySym . +.tL "Code" "Value" "Name" +.tL "4" "3A2" "XK_kra" +.tL "4" "3A2" "XK_kappa" +.tL "4" "3A3" "XK_Rcedilla" +.tL "4" "3A5" "XK_Itilde" +.tL "4" "3A6" "XK_Lcedilla" +.tL "4" "3AA" "XK_Emacron" +.tL "4" "3AB" "XK_Gcedilla" +.tL "4" "3AC" "XK_Tslash" +.tL "4" "3B3" "XK_rcedilla" +.tL "4" "3B5" "XK_itilde" +.tL "4" "3B6" "XK_lcedilla" +.tL "4" "3BA" "XK_emacron" +.tL "4" "3BB" "XK_gcedilla" +.tL "4" "3BC" "XK_tslash" +.tL "4" "3BD" "XK_ENG" +.tL "4" "3BF" "XK_eng" +.tL "4" "3C0" "XK_Amacron" +.tL "4" "3C7" "XK_Iogonek" +.tL "4" "3CC" "XK_Eabovedot" +.tL "4" "3CF" "XK_Imacron" +.tL "4" "3D1" "XK_Ncedilla" +.tL "4" "3D2" "XK_Omacron" +.tL "4" "3D3" "XK_Kcedilla" +.tL "4" "3D9" "XK_Uogonek" +.tL "4" "3DD" "XK_Utilde" +.tL "4" "3DE" "XK_Umacron" +.tL "4" "3E0" "XK_amacron" +.tL "4" "3E7" "XK_iogonek" +.tL "4" "3EC" "XK_eabovedot" +.tL "4" "3EF" "XK_imacron" +.tL "4" "3F1" "XK_ncedilla" +.tL "4" "3F2" "XK_omacron" +.tL "4" "3F3" "XK_kcedilla" +.tL "4" "3F9" "XK_uogonek" +.tL "4" "3FD" "XK_utilde" +.tL "4" "3FE" "XK_umacron" +>>STRATEGY +For each KeySym name in table with code 4: + Call XStringToKeysym to obtain the KeySym defined for that string. + Verify that XStringToKeysym did not return NoSymbol. + Verify that the returned string is correct. +>>CODE + + strtsym4(); + +>>ASSERTION Good A +When the +.A string +argument is the name of a +.S KeySym +in the table +with the prefix +.S XK_ +removed, +then a call to xname returns that +.S KeySym . +.tL "Code" "Value" "Name" +.tL "A" "5AC" "XK_Arabic_comma" +.tL "A" "5BB" "XK_Arabic_semicolon" +.tL "A" "5BF" "XK_Arabic_question_mark" +.tL "A" "5C1" "XK_Arabic_hamza" +.tL "A" "5C2" "XK_Arabic_maddaonalef" +.tL "A" "5C3" "XK_Arabic_hamzaonalef" +.tL "A" "5C4" "XK_Arabic_hamzaonwaw" +.tL "A" "5C5" "XK_Arabic_hamzaunderalef" +.tL "A" "5C6" "XK_Arabic_hamzaonyeh" +.tL "A" "5C7" "XK_Arabic_alef" +.tL "A" "5C8" "XK_Arabic_beh" +.tL "A" "5C9" "XK_Arabic_tehmarbuta" +.tL "A" "5CA" "XK_Arabic_teh" +.tL "A" "5CB" "XK_Arabic_theh" +.tL "A" "5CC" "XK_Arabic_jeem" +.tL "A" "5CD" "XK_Arabic_hah" +.tL "A" "5CE" "XK_Arabic_khah" +.tL "A" "5CF" "XK_Arabic_dal" +.tL "A" "5D0" "XK_Arabic_thal" +.tL "A" "5D1" "XK_Arabic_ra" +.tL "A" "5D2" "XK_Arabic_zain" +.tL "A" "5D3" "XK_Arabic_seen" +.tL "A" "5D4" "XK_Arabic_sheen" +.tL "A" "5D5" "XK_Arabic_sad" +.tL "A" "5D6" "XK_Arabic_dad" +.tL "A" "5D7" "XK_Arabic_tah" +.tL "A" "5D8" "XK_Arabic_zah" +.tL "A" "5D9" "XK_Arabic_ain" +.tL "A" "5DA" "XK_Arabic_ghain" +.tL "A" "5E0" "XK_Arabic_tatweel" +.tL "A" "5E1" "XK_Arabic_feh" +.tL "A" "5E2" "XK_Arabic_qaf" +.tL "A" "5E3" "XK_Arabic_kaf" +.tL "A" "5E4" "XK_Arabic_lam" +.tL "A" "5E5" "XK_Arabic_meem" +.tL "A" "5E6" "XK_Arabic_noon" +.tL "A" "5E7" "XK_Arabic_ha" +.tL "A" "5E7" "XK_Arabic_heh" +.tL "A" "5E8" "XK_Arabic_waw" +.tL "A" "5E9" "XK_Arabic_alefmaksura" +.tL "A" "5EA" "XK_Arabic_yeh" +.tL "A" "5EB" "XK_Arabic_fathatan" +.tL "A" "5EC" "XK_Arabic_dammatan" +.tL "A" "5ED" "XK_Arabic_kasratan" +.tL "A" "5EE" "XK_Arabic_fatha" +.tL "A" "5EF" "XK_Arabic_damma" +.tL "A" "5F0" "XK_Arabic_kasra" +.tL "A" "5F1" "XK_Arabic_shadda" +.tL "A" "5F2" "XK_Arabic_sukun" +.tL "A" "FF7E" "XK_Arabic_switch" +>>STRATEGY +For each KeySym name in table with code A: + Call XStringToKeysym to obtain the KeySym defined for that string. + Verify that XStringToKeysym did not return NoSymbol. + Verify that the returned string is correct. +>>CODE + + strtsymA(); + +>>ASSERTION Good A +When the +.A string +argument is the name of a +.S KeySym +in the table +with the prefix +.S XK_ +removed, +then a call to xname returns that +.S KeySym . +.tL "Code" "Value" "Name" +.tL "C" "6A1" "XK_Serbian_dje" +.tL "C" "6A2" "XK_Macedonia_gje" +.tL "C" "6A3" "XK_Cyrillic_io" +.tL "C" "6A4" "XK_Ukrainian_ie" +.tL "C" "6A4" "XK_Ukranian_je" +.tL "C" "6A5" "XK_Macedonia_dse" +.tL "C" "6A6" "XK_Ukrainian_i" +.tL "C" "6A6" "XK_Ukranian_i" +.tL "C" "6A7" "XK_Ukrainian_yi" +.tL "C" "6A7" "XK_Ukranian_yi" +.tL "C" "6A8" "XK_Cyrillic_je" +.tL "C" "6A8" "XK_Serbian_je" +.tL "C" "6A9" "XK_Cyrillic_lje" +.tL "C" "6A9" "XK_Serbian_lje" +.tL "C" "6AA" "XK_Cyrillic_nje" +.tL "C" "6AA" "XK_Serbian_nje" +.tL "C" "6AB" "XK_Serbian_tshe" +.tL "C" "6AC" "XK_Macedonia_kje" +.tL "C" "6AE" "XK_Byelorussian_shortu" +.tL "C" "6AF" "XK_Cyrillic_dzhe" +.tL "C" "6AF" "XK_Serbian_dze" +.tL "C" "6B0" "XK_numerosign" +.tL "C" "6B1" "XK_Serbian_DJE" +.tL "C" "6B2" "XK_Macedonia_GJE" +.tL "C" "6B3" "XK_Cyrillic_IO" +.tL "C" "6B4" "XK_Ukrainian_IE" +.tL "C" "6B4" "XK_Ukranian_JE" +.tL "C" "6B5" "XK_Macedonia_DSE" +.tL "C" "6B6" "XK_Ukrainian_I" +.tL "C" "6B6" "XK_Ukranian_I" +.tL "C" "6B7" "XK_Ukrainian_YI" +.tL "C" "6B7" "XK_Ukranian_YI" +.tL "C" "6B8" "XK_Cyrillic_JE" +.tL "C" "6B8" "XK_Serbian_JE" +.tL "C" "6B9" "XK_Cyrillic_LJE" +.tL "C" "6B9" "XK_Serbian_LJE" +.tL "C" "6BA" "XK_Cyrillic_NJE" +.tL "C" "6BA" "XK_Serbian_NJE" +.tL "C" "6BB" "XK_Serbian_TSHE" +.tL "C" "6BC" "XK_Macedonia_KJE" +.tL "C" "6BE" "XK_Byelorussian_SHORTU" +.tL "C" "6BF" "XK_Cyrillic_DZHE" +.tL "C" "6BF" "XK_Serbian_DZE" +.tL "C" "6C0" "XK_Cyrillic_yu" +.tL "C" "6C1" "XK_Cyrillic_a" +.tL "C" "6C2" "XK_Cyrillic_be" +.tL "C" "6C3" "XK_Cyrillic_tse" +.tL "C" "6C4" "XK_Cyrillic_de" +.tL "C" "6C5" "XK_Cyrillic_ie" +.tL "C" "6C6" "XK_Cyrillic_ef" +.tL "C" "6C7" "XK_Cyrillic_ghe" +.tL "C" "6C8" "XK_Cyrillic_ha" +.tL "C" "6C9" "XK_Cyrillic_i" +.tL "C" "6CA" "XK_Cyrillic_shorti" +.tL "C" "6CB" "XK_Cyrillic_ka" +.tL "C" "6CC" "XK_Cyrillic_el" +.tL "C" "6CD" "XK_Cyrillic_em" +.tL "C" "6CE" "XK_Cyrillic_en" +.tL "C" "6CF" "XK_Cyrillic_o" +.tL "C" "6D0" "XK_Cyrillic_pe" +.tL "C" "6D1" "XK_Cyrillic_ya" +.tL "C" "6D2" "XK_Cyrillic_er" +.tL "C" "6D3" "XK_Cyrillic_es" +.tL "C" "6D4" "XK_Cyrillic_te" +.tL "C" "6D5" "XK_Cyrillic_u" +.tL "C" "6D6" "XK_Cyrillic_zhe" +.tL "C" "6D7" "XK_Cyrillic_ve" +.tL "C" "6D8" "XK_Cyrillic_softsign" +.tL "C" "6D9" "XK_Cyrillic_yeru" +.tL "C" "6DA" "XK_Cyrillic_ze" +.tL "C" "6DB" "XK_Cyrillic_sha" +.tL "C" "6DC" "XK_Cyrillic_e" +.tL "C" "6DD" "XK_Cyrillic_shcha" +.tL "C" "6DE" "XK_Cyrillic_che" +.tL "C" "6DF" "XK_Cyrillic_hardsign" +.tL "C" "6E0" "XK_Cyrillic_YU" +.tL "C" "6E1" "XK_Cyrillic_A" +.tL "C" "6E2" "XK_Cyrillic_BE" +.tL "C" "6E3" "XK_Cyrillic_TSE" +.tL "C" "6E4" "XK_Cyrillic_DE" +.tL "C" "6E5" "XK_Cyrillic_IE" +.tL "C" "6E6" "XK_Cyrillic_EF" +.tL "C" "6E7" "XK_Cyrillic_GHE" +.tL "C" "6E8" "XK_Cyrillic_HA" +.tL "C" "6E9" "XK_Cyrillic_I" +.tL "C" "6EA" "XK_Cyrillic_SHORTI" +.tL "C" "6EB" "XK_Cyrillic_KA" +.tL "C" "6EC" "XK_Cyrillic_EL" +.tL "C" "6ED" "XK_Cyrillic_EM" +.tL "C" "6EE" "XK_Cyrillic_EN" +.tL "C" "6EF" "XK_Cyrillic_O" +.tL "C" "6F0" "XK_Cyrillic_PE" +.tL "C" "6F1" "XK_Cyrillic_YA" +.tL "C" "6F2" "XK_Cyrillic_ER" +.tL "C" "6F3" "XK_Cyrillic_ES" +.tL "C" "6F4" "XK_Cyrillic_TE" +.tL "C" "6F5" "XK_Cyrillic_U" +.tL "C" "6F6" "XK_Cyrillic_ZHE" +.tL "C" "6F7" "XK_Cyrillic_VE" +.tL "C" "6F8" "XK_Cyrillic_SOFTSIGN" +.tL "C" "6F9" "XK_Cyrillic_YERU" +.tL "C" "6FA" "XK_Cyrillic_ZE" +.tL "C" "6FB" "XK_Cyrillic_SHA" +.tL "C" "6FC" "XK_Cyrillic_E" +.tL "C" "6FD" "XK_Cyrillic_SHCHA" +.tL "C" "6FE" "XK_Cyrillic_CHE" +.tL "C" "6FF" "XK_Cyrillic_HARDSIGN" +>>STRATEGY +For each KeySym name in table with code C: + Call XStringToKeysym to obtain the KeySym defined for that string. + Verify that XStringToKeysym did not return NoSymbol. + Verify that the returned string is correct. +>>CODE + + strtsymC(); + +>>ASSERTION Good A +When the +.A string +argument is the name of a +.S KeySym +in the table +with the prefix +.S XK_ +removed, +then a call to xname returns that +.S KeySym . +.tL "Code" "Value" "Name" +.tL "G" "7A1" "XK_Greek_ALPHAaccent" +.tL "G" "7A2" "XK_Greek_EPSILONaccent" +.tL "G" "7A3" "XK_Greek_ETAaccent" +.tL "G" "7A4" "XK_Greek_IOTAaccent" +.tL "G" "7A5" "XK_Greek_IOTAdiaeresis" +.tL "G" "7A7" "XK_Greek_OMICRONaccent" +.tL "G" "7A8" "XK_Greek_UPSILONaccent" +.tL "G" "7A9" "XK_Greek_UPSILONdieresis" +.tL "G" "7AB" "XK_Greek_OMEGAaccent" +.tL "G" "7AE" "XK_Greek_accentdieresis" +.tL "G" "7AF" "XK_Greek_horizbar" +.tL "G" "7B1" "XK_Greek_alphaaccent" +.tL "G" "7B2" "XK_Greek_epsilonaccent" +.tL "G" "7B3" "XK_Greek_etaaccent" +.tL "G" "7B4" "XK_Greek_iotaaccent" +.tL "G" "7B5" "XK_Greek_iotadieresis" +.tL "G" "7B6" "XK_Greek_iotaaccentdieresis" +.tL "G" "7B7" "XK_Greek_omicronaccent" +.tL "G" "7B8" "XK_Greek_upsilonaccent" +.tL "G" "7B9" "XK_Greek_upsilondieresis" +.tL "G" "7BA" "XK_Greek_upsilonaccentdieresis" +.tL "G" "7BB" "XK_Greek_omegaaccent" +.tL "G" "7C1" "XK_Greek_ALPHA" +.tL "G" "7C2" "XK_Greek_BETA" +.tL "G" "7C3" "XK_Greek_GAMMA" +.tL "G" "7C4" "XK_Greek_DELTA" +.tL "G" "7C5" "XK_Greek_EPSILON" +.tL "G" "7C6" "XK_Greek_ZETA" +.tL "G" "7C7" "XK_Greek_ETA" +.tL "G" "7C8" "XK_Greek_THETA" +.tL "G" "7C9" "XK_Greek_IOTA" +.tL "G" "7CA" "XK_Greek_KAPPA" +.tL "G" "7CB" "XK_Greek_LAMBDA" +.tL "G" "7CB" "XK_Greek_LAMDA" +.tL "G" "7CC" "XK_Greek_MU" +.tL "G" "7CD" "XK_Greek_NU" +.tL "G" "7CE" "XK_Greek_XI" +.tL "G" "7CF" "XK_Greek_OMICRON" +.tL "G" "7D0" "XK_Greek_PI" +.tL "G" "7D1" "XK_Greek_RHO" +.tL "G" "7D2" "XK_Greek_SIGMA" +.tL "G" "7D4" "XK_Greek_TAU" +.tL "G" "7D5" "XK_Greek_UPSILON" +.tL "G" "7D6" "XK_Greek_PHI" +.tL "G" "7D7" "XK_Greek_CHI" +.tL "G" "7D8" "XK_Greek_PSI" +.tL "G" "7D9" "XK_Greek_OMEGA" +.tL "G" "7E1" "XK_Greek_alpha" +.tL "G" "7E2" "XK_Greek_beta" +.tL "G" "7E3" "XK_Greek_gamma" +.tL "G" "7E4" "XK_Greek_delta" +.tL "G" "7E5" "XK_Greek_epsilon" +.tL "G" "7E6" "XK_Greek_zeta" +.tL "G" "7E7" "XK_Greek_eta" +.tL "G" "7E8" "XK_Greek_theta" +.tL "G" "7E9" "XK_Greek_iota" +.tL "G" "7EA" "XK_Greek_kappa" +.tL "G" "7EB" "XK_Greek_lambda" +.tL "G" "7EB" "XK_Greek_lamda" +.tL "G" "7EC" "XK_Greek_mu" +.tL "G" "7ED" "XK_Greek_nu" +.tL "G" "7EE" "XK_Greek_xi" +.tL "G" "7EF" "XK_Greek_omicron" +.tL "G" "7F0" "XK_Greek_pi" +.tL "G" "7F1" "XK_Greek_rho" +.tL "G" "7F2" "XK_Greek_sigma" +.tL "G" "7F3" "XK_Greek_finalsmallsigma" +.tL "G" "7F4" "XK_Greek_tau" +.tL "G" "7F5" "XK_Greek_upsilon" +.tL "G" "7F6" "XK_Greek_phi" +.tL "G" "7F7" "XK_Greek_chi" +.tL "G" "7F8" "XK_Greek_psi" +.tL "G" "7F9" "XK_Greek_omega" +.tL "G" "FF7E" "XK_Greek_switch" +>>STRATEGY +For each KeySym name in table with code G: + Call XStringToKeysym to obtain the KeySym defined for that string. + Verify that XStringToKeysym did not return NoSymbol. + Verify that the returned string is correct. +>>CODE + + strtsymG(); + +>>ASSERTION Good A +When the +.A string +argument is the name of a +.S KeySym +in the table +with the prefix +.S XK_ +removed, +then a call to xname returns that +.S KeySym . +.tL "Code" "Value" "Name" +.tL "H" "CDF" "XK_hebrew_doublelowline" +.tL "H" "CE0" "XK_hebrew_aleph" +.tL "H" "CE1" "XK_hebrew_bet" +.tL "H" "CE1" "XK_hebrew_beth" +.tL "H" "CE2" "XK_hebrew_gimel" +.tL "H" "CE2" "XK_hebrew_gimmel" +.tL "H" "CE3" "XK_hebrew_dalet" +.tL "H" "CE3" "XK_hebrew_daleth" +.tL "H" "CE4" "XK_hebrew_he" +.tL "H" "CE5" "XK_hebrew_waw" +.tL "H" "CE6" "XK_hebrew_zain" +.tL "H" "CE6" "XK_hebrew_zayin" +.tL "H" "CE7" "XK_hebrew_chet" +.tL "H" "CE7" "XK_hebrew_het" +.tL "H" "CE8" "XK_hebrew_tet" +.tL "H" "CE8" "XK_hebrew_teth" +.tL "H" "CE9" "XK_hebrew_yod" +.tL "H" "CEA" "XK_hebrew_finalkaph" +.tL "H" "CEB" "XK_hebrew_kaph" +.tL "H" "CEC" "XK_hebrew_lamed" +.tL "H" "CED" "XK_hebrew_finalmem" +.tL "H" "CEE" "XK_hebrew_mem" +.tL "H" "CEF" "XK_hebrew_finalnun" +.tL "H" "CF0" "XK_hebrew_nun" +.tL "H" "CF1" "XK_hebrew_samech" +.tL "H" "CF1" "XK_hebrew_samekh" +.tL "H" "CF2" "XK_hebrew_ayin" +.tL "H" "CF3" "XK_hebrew_finalpe" +.tL "H" "CF4" "XK_hebrew_pe" +.tL "H" "CF5" "XK_hebrew_finalzade" +.tL "H" "CF5" "XK_hebrew_finalzadi" +.tL "H" "CF6" "XK_hebrew_zade" +.tL "H" "CF6" "XK_hebrew_zadi" +.tL "H" "CF7" "XK_hebrew_qoph" +.tL "H" "CF7" "XK_hebrew_kuf" +.tL "H" "CF8" "XK_hebrew_resh" +.tL "H" "CF9" "XK_hebrew_shin" +.tL "H" "CFA" "XK_hebrew_taw" +.tL "H" "CFA" "XK_hebrew_taf" +.tL "H" "FF7E" "XK_Hebrew_switch" +>>STRATEGY +For each KeySym name in table with code H: + Call XStringToKeysym to obtain the KeySym defined for that string. + Verify that XStringToKeysym did not return NoSymbol. + Verify that the returned string is correct. +>>CODE + + strtsymH(); + +>>ASSERTION Good A +When the +.A string +argument is the name of a +.S KeySym +in the table +with the prefix +.S XK_ +removed, +then a call to xname returns that +.S KeySym . +.tL "Code" "Value" "Name" +.tL "K" "47E" "XK_overline" +.tL "K" "4A1" "XK_kana_fullstop" +.tL "K" "4A2" "XK_kana_openingbracket" +.tL "K" "4A3" "XK_kana_closingbracket" +.tL "K" "4A4" "XK_kana_comma" +.tL "K" "4A5" "XK_kana_conjunctive" +.tL "K" "4A5" "XK_kana_middledot" +.tL "K" "4A6" "XK_kana_WO" +.tL "K" "4A7" "XK_kana_a" +.tL "K" "4A8" "XK_kana_i" +.tL "K" "4A9" "XK_kana_u" +.tL "K" "4AA" "XK_kana_e" +.tL "K" "4AB" "XK_kana_o" +.tL "K" "4AC" "XK_kana_ya" +.tL "K" "4AD" "XK_kana_yu" +.tL "K" "4AE" "XK_kana_yo" +.tL "K" "4AF" "XK_kana_tsu" +.tL "K" "4AF" "XK_kana_tu" +.tL "K" "4B0" "XK_prolongedsound" +.tL "K" "4B1" "XK_kana_A" +.tL "K" "4B2" "XK_kana_I" +.tL "K" "4B3" "XK_kana_U" +.tL "K" "4B4" "XK_kana_E" +.tL "K" "4B5" "XK_kana_O" +.tL "K" "4B6" "XK_kana_KA" +.tL "K" "4B7" "XK_kana_KI" +.tL "K" "4B8" "XK_kana_KU" +.tL "K" "4B9" "XK_kana_KE" +.tL "K" "4BA" "XK_kana_KO" +.tL "K" "4BB" "XK_kana_SA" +.tL "K" "4BC" "XK_kana_SHI" +.tL "K" "4BD" "XK_kana_SU" +.tL "K" "4BE" "XK_kana_SE" +.tL "K" "4BF" "XK_kana_SO" +.tL "K" "4C0" "XK_kana_TA" +.tL "K" "4C1" "XK_kana_CHI" +.tL "K" "4C1" "XK_kana_TI" +.tL "K" "4C2" "XK_kana_TSU" +.tL "K" "4C2" "XK_kana_TU" +.tL "K" "4C3" "XK_kana_TE" +.tL "K" "4C4" "XK_kana_TO" +.tL "K" "4C5" "XK_kana_NA" +.tL "K" "4C6" "XK_kana_NI" +.tL "K" "4C7" "XK_kana_NU" +.tL "K" "4C8" "XK_kana_NE" +.tL "K" "4C9" "XK_kana_NO" +.tL "K" "4CA" "XK_kana_HA" +.tL "K" "4CB" "XK_kana_HI" +.tL "K" "4CC" "XK_kana_FU" +.tL "K" "4CC" "XK_kana_HU" +.tL "K" "4CD" "XK_kana_HE" +.tL "K" "4CE" "XK_kana_HO" +.tL "K" "4CF" "XK_kana_MA" +.tL "K" "4D0" "XK_kana_MI" +.tL "K" "4D1" "XK_kana_MU" +.tL "K" "4D2" "XK_kana_ME" +.tL "K" "4D3" "XK_kana_MO" +.tL "K" "4D4" "XK_kana_YA" +.tL "K" "4D5" "XK_kana_YU" +.tL "K" "4D6" "XK_kana_YO" +.tL "K" "4D7" "XK_kana_RA" +.tL "K" "4D8" "XK_kana_RI" +.tL "K" "4D9" "XK_kana_RU" +.tL "K" "4DA" "XK_kana_RE" +.tL "K" "4DB" "XK_kana_RO" +.tL "K" "4DC" "XK_kana_WA" +.tL "K" "4DD" "XK_kana_N" +.tL "K" "4DE" "XK_voicedsound" +.tL "K" "4DF" "XK_semivoicedsound" +.tL "K" "FF7E" "XK_kana_switch" +>>STRATEGY +For each KeySym name in table with code K: + Call XStringToKeysym to obtain the KeySym defined for that string. + Verify that XStringToKeysym did not return NoSymbol. + Verify that the returned string is correct. +>>CODE + + strtsymK(); + +>>ASSERTION Good A +When the +.A string +argument is the name of a +.S KeySym +in the table +with the prefix +.S XK_ +removed, +then a call to xname returns that +.S KeySym . +.tL "Code" "Value" "Name" +.tL "L" "BA3" "XK_leftcaret" +.tL "L" "BA6" "XK_rightcaret" +.tL "L" "BA8" "XK_downcaret" +.tL "L" "BA9" "XK_upcaret" +.tL "L" "BC0" "XK_overbar" +.tL "L" "BC2" "XK_downtack" +.tL "L" "BC3" "XK_upshoe" +.tL "L" "BC4" "XK_downstile" +.tL "L" "BC6" "XK_underbar" +.tL "L" "BCA" "XK_jot" +.tL "L" "BCC" "XK_quad" +.tL "L" "BCE" "XK_uptack" +.tL "L" "BCF" "XK_circle" +.tL "L" "BD3" "XK_upstile" +.tL "L" "BD6" "XK_downshoe" +.tL "L" "BD8" "XK_rightshoe" +.tL "L" "BDA" "XK_leftshoe" +.tL "L" "BDC" "XK_lefttack" +.tL "L" "BFC" "XK_righttack" +>>STRATEGY +For each KeySym name in table with code L: + Call XStringToKeysym to obtain the KeySym defined for that string. + Verify that XStringToKeysym did not return NoSymbol. + Verify that the returned string is correct. +>>CODE + + strtsymL(); + +>>ASSERTION Good A +When the +.A string +argument is the name of a +.S KeySym +in the table +with the prefix +.S XK_ +removed, +then a call to xname returns that +.S KeySym . +.tL "Code" "Value" "Name" +.tL "M" "FF08" "XK_BackSpace" +.tL "M" "FF09" "XK_Tab" +.tL "M" "FF0A" "XK_Linefeed" +.tL "M" "FF0B" "XK_Clear" +.tL "M" "FF0D" "XK_Return" +.tL "M" "FF13" "XK_Pause" +.tL "M" "FF14" "XK_Scroll_Lock" +.tL "M" "FF1B" "XK_Escape" +.tL "M" "FF20" "XK_Multi_key" +.tL "M" "FF21" "XK_Kanji" +.tL "M" "FF22" "XK_Muhenkan" +.tL "M" "FF23" "XK_Henkan" +.tL "M" "FF23" "XK_Henkan_Mode" +.tL "M" "FF24" "XK_Romaji" +.tL "M" "FF25" "XK_Hiragana" +.tL "M" "FF26" "XK_Katakana" +.tL "M" "FF27" "XK_Hiragana_Katakana" +.tL "M" "FF28" "XK_Zenkaku" +.tL "M" "FF29" "XK_Hankaku" +.tL "M" "FF2A" "XK_Zenkaku_Hankaku" +.tL "M" "FF2B" "XK_Touroku" +.tL "M" "FF2C" "XK_Massyo" +.tL "M" "FF2D" "XK_Kana_Lock" +.tL "M" "FF2E" "XK_Kana_Shift" +.tL "M" "FF2F" "XK_Eisu_Shift" +.tL "M" "FF30" "XK_Eisu_toggle" +.tL "M" "FF50" "XK_Home" +.tL "M" "FF51" "XK_Left" +.tL "M" "FF52" "XK_Up" +.tL "M" "FF53" "XK_Right" +.tL "M" "FF54" "XK_Down" +.tL "M" "FF55" "XK_Prior" +.tL "M" "FF56" "XK_Next" +.tL "M" "FF57" "XK_End" +.tL "M" "FF58" "XK_Begin" +.tL "M" "FF60" "XK_Select" +.tL "M" "FF61" "XK_Print" +.tL "M" "FF62" "XK_Execute" +.tL "M" "FF63" "XK_Insert" +.tL "M" "FF65" "XK_Undo" +.tL "M" "FF66" "XK_Redo" +.tL "M" "FF67" "XK_Menu" +.tL "M" "FF68" "XK_Find" +.tL "M" "FF69" "XK_Cancel" +.tL "M" "FF6A" "XK_Help" +.tL "M" "FF6B" "XK_Break" +.tL "M" "FF7E" "XK_Mode_switch" +.tL "M" "FF7E" "XK_script_switch" +.tL "M" "FF7F" "XK_Num_Lock" +.tL "M" "FF80" "XK_KP_Space" +.tL "M" "FF89" "XK_KP_Tab" +.tL "M" "FF8D" "XK_KP_Enter" +.tL "M" "FF91" "XK_KP_F1" +.tL "M" "FF92" "XK_KP_F2" +.tL "M" "FF93" "XK_KP_F3" +.tL "M" "FF94" "XK_KP_F4" +.tL "M" "FFAA" "XK_KP_Multiply" +.tL "M" "FFAB" "XK_KP_Add" +.tL "M" "FFAC" "XK_KP_Separator" +.tL "M" "FFAD" "XK_KP_Subtract" +.tL "M" "FFAE" "XK_KP_Decimal" +.tL "M" "FFAF" "XK_KP_Divide" +.tL "M" "FFB0" "XK_KP_0" +.tL "M" "FFB1" "XK_KP_1" +.tL "M" "FFB2" "XK_KP_2" +.tL "M" "FFB3" "XK_KP_3" +.tL "M" "FFB4" "XK_KP_4" +.tL "M" "FFB5" "XK_KP_5" +.tL "M" "FFB6" "XK_KP_6" +.tL "M" "FFB7" "XK_KP_7" +.tL "M" "FFB8" "XK_KP_8" +.tL "M" "FFB9" "XK_KP_9" +.tL "M" "FFBD" "XK_KP_Equal" +.tL "M" "FFBE" "XK_F1" +.tL "M" "FFBF" "XK_F2" +.tL "M" "FFC0" "XK_F3" +.tL "M" "FFC1" "XK_F4" +.tL "M" "FFC2" "XK_F5" +.tL "M" "FFC3" "XK_F6" +.tL "M" "FFC4" "XK_F7" +.tL "M" "FFC5" "XK_F8" +.tL "M" "FFC6" "XK_F9" +.tL "M" "FFC7" "XK_F10" +.tL "M" "FFC8" "XK_F11" +.tL "M" "FFC8" "XK_L1" +.tL "M" "FFC9" "XK_F12" +.tL "M" "FFC9" "XK_L2" +.tL "M" "FFCA" "XK_F13" +.tL "M" "FFCA" "XK_L3" +.tL "M" "FFCB" "XK_F14" +.tL "M" "FFCB" "XK_L4" +.tL "M" "FFCC" "XK_F15" +.tL "M" "FFCC" "XK_L5" +.tL "M" "FFCD" "XK_F16" +.tL "M" "FFCD" "XK_L6" +.tL "M" "FFCE" "XK_F17" +.tL "M" "FFCE" "XK_L7" +.tL "M" "FFCF" "XK_F18" +.tL "M" "FFCF" "XK_L8" +.tL "M" "FFD0" "XK_F19" +.tL "M" "FFD0" "XK_L9" +.tL "M" "FFD1" "XK_F20" +.tL "M" "FFD1" "XK_L10" +.tL "M" "FFD2" "XK_F21" +.tL "M" "FFD2" "XK_R1" +.tL "M" "FFD3" "XK_F22" +.tL "M" "FFD3" "XK_R2" +.tL "M" "FFD4" "XK_F23" +.tL "M" "FFD4" "XK_R3" +.tL "M" "FFD5" "XK_F24" +.tL "M" "FFD5" "XK_R4" +.tL "M" "FFD6" "XK_F25" +.tL "M" "FFD6" "XK_R5" +.tL "M" "FFD7" "XK_F26" +.tL "M" "FFD7" "XK_R6" +.tL "M" "FFD8" "XK_F27" +.tL "M" "FFD8" "XK_R7" +.tL "M" "FFD9" "XK_F28" +.tL "M" "FFD9" "XK_R8" +.tL "M" "FFDA" "XK_F29" +.tL "M" "FFDA" "XK_R9" +.tL "M" "FFDB" "XK_F30" +.tL "M" "FFDB" "XK_R10" +.tL "M" "FFDC" "XK_F31" +.tL "M" "FFDC" "XK_R11" +.tL "M" "FFDD" "XK_F32" +.tL "M" "FFDD" "XK_R12" +.tL "M" "FFDE" "XK_F33" +.tL "M" "FFDE" "XK_R13" +.tL "M" "FFDF" "XK_F34" +.tL "M" "FFDF" "XK_R14" +.tL "M" "FFE0" "XK_F35" +.tL "M" "FFE0" "XK_R15" +.tL "M" "FFE1" "XK_Shift_L" +.tL "M" "FFE2" "XK_Shift_R" +.tL "M" "FFE3" "XK_Control_L" +.tL "M" "FFE4" "XK_Control_R" +.tL "M" "FFE5" "XK_Caps_Lock" +.tL "M" "FFE6" "XK_Shift_Lock" +.tL "M" "FFE7" "XK_Meta_L" +.tL "M" "FFE8" "XK_Meta_R" +.tL "M" "FFE9" "XK_Alt_L" +.tL "M" "FFEA" "XK_Alt_R" +.tL "M" "FFEB" "XK_Super_L" +.tL "M" "FFEC" "XK_Super_R" +.tL "M" "FFED" "XK_Hyper_L" +.tL "M" "FFEE" "XK_Hyper_R" +.tL "M" "FFFF" "XK_Delete" +>>STRATEGY +For each KeySym name in table with code M: + Call XStringToKeysym to obtain the KeySym defined for that string. + Verify that XStringToKeysym did not return NoSymbol. + Verify that the returned string is correct. +>>CODE + + strtsymM(); + +>>ASSERTION Good A +When the +.A string +argument is the name of a +.S KeySym +in the table +with the prefix +.S XK_ +removed, +then a call to xname returns that +.S KeySym . +.tL "Code" "Value" "Name" +.tL "P" "AA1" "XK_emspace" +.tL "P" "AA2" "XK_enspace" +.tL "P" "AA3" "XK_em3space" +.tL "P" "AA4" "XK_em4space" +.tL "P" "AA5" "XK_digitspace" +.tL "P" "AA6" "XK_punctspace" +.tL "P" "AA7" "XK_thinspace" +.tL "P" "AA8" "XK_hairspace" +.tL "P" "AA9" "XK_emdash" +.tL "P" "AAA" "XK_endash" +.tL "P" "AAC" "XK_signifblank" +.tL "P" "AAE" "XK_ellipsis" +.tL "P" "AAF" "XK_doubbaselinedot" +.tL "P" "AB0" "XK_onethird" +.tL "P" "AB1" "XK_twothirds" +.tL "P" "AB2" "XK_onefifth" +.tL "P" "AB3" "XK_twofifths" +.tL "P" "AB4" "XK_threefifths" +.tL "P" "AB5" "XK_fourfifths" +.tL "P" "AB6" "XK_onesixth" +.tL "P" "AB7" "XK_fivesixths" +.tL "P" "AB8" "XK_careof" +.tL "P" "ABB" "XK_figdash" +.tL "P" "ABC" "XK_leftanglebracket" +.tL "P" "ABD" "XK_decimalpoint" +.tL "P" "ABE" "XK_rightanglebracket" +.tL "P" "ABF" "XK_marker" +.tL "P" "AC3" "XK_oneeighth" +.tL "P" "AC4" "XK_threeeighths" +.tL "P" "AC5" "XK_fiveeighths" +.tL "P" "AC6" "XK_seveneighths" +.tL "P" "AC9" "XK_trademark" +.tL "P" "ACA" "XK_signaturemark" +.tL "P" "ACB" "XK_trademarkincircle" +.tL "P" "ACC" "XK_leftopentriangle" +.tL "P" "ACD" "XK_rightopentriangle" +.tL "P" "ACE" "XK_emopencircle" +.tL "P" "ACF" "XK_emopenrectangle" +.tL "P" "AD0" "XK_leftsinglequotemark" +.tL "P" "AD1" "XK_rightsinglequotemark" +.tL "P" "AD2" "XK_leftdoublequotemark" +.tL "P" "AD3" "XK_rightdoublequotemark" +.tL "P" "AD4" "XK_prescription" +.tL "P" "AD6" "XK_minutes" +.tL "P" "AD7" "XK_seconds" +.tL "P" "AD9" "XK_latincross" +.tL "P" "ADA" "XK_hexagram" +.tL "P" "ADB" "XK_filledrectbullet" +.tL "P" "ADC" "XK_filledlefttribullet" +.tL "P" "ADD" "XK_filledrighttribullet" +.tL "P" "ADE" "XK_emfilledcircle" +.tL "P" "ADF" "XK_emfilledrect" +.tL "P" "AE0" "XK_enopencircbullet" +.tL "P" "AE1" "XK_enopensquarebullet" +.tL "P" "AE2" "XK_openrectbullet" +.tL "P" "AE3" "XK_opentribulletup" +.tL "P" "AE4" "XK_opentribulletdown" +.tL "P" "AE5" "XK_openstar" +.tL "P" "AE6" "XK_enfilledcircbullet" +.tL "P" "AE7" "XK_enfilledsqbullet" +.tL "P" "AE8" "XK_filledtribulletup" +.tL "P" "AE9" "XK_filledtribulletdown" +.tL "P" "AEA" "XK_leftpointer" +.tL "P" "AEB" "XK_rightpointer" +.tL "P" "AEC" "XK_club" +.tL "P" "AED" "XK_diamond" +.tL "P" "AEE" "XK_heart" +.tL "P" "AF0" "XK_maltesecross" +.tL "P" "AF1" "XK_dagger" +.tL "P" "AF2" "XK_doubledagger" +.tL "P" "AF3" "XK_checkmark" +.tL "P" "AF4" "XK_ballotcross" +.tL "P" "AF5" "XK_musicalsharp" +.tL "P" "AF6" "XK_musicalflat" +.tL "P" "AF7" "XK_malesymbol" +.tL "P" "AF8" "XK_femalesymbol" +.tL "P" "AF9" "XK_telephone" +.tL "P" "AFA" "XK_telephonerecorder" +.tL "P" "AFB" "XK_phonographcopyright" +.tL "P" "AFC" "XK_caret" +.tL "P" "AFD" "XK_singlelowquotemark" +.tL "P" "AFE" "XK_doublelowquotemark" +.tL "P" "AFF" "XK_cursor" +>>STRATEGY +For each KeySym name in table with code P: + Call XStringToKeysym to obtain the KeySym defined for that string. + Verify that XStringToKeysym did not return NoSymbol. + Verify that the returned string is correct. +>>CODE + + strtsymP(); + +>>ASSERTION Good A +When the +.A string +argument is the name of a +.S KeySym +in the table +with the prefix +.S XK_ +removed, +then a call to xname returns that +.S KeySym . +.tL "Code" "Value" "Name" +.tL "S" "9DF" "XK_blank" +.tL "S" "9E0" "XK_soliddiamond" +.tL "S" "9E1" "XK_checkerboard" +.tL "S" "9E2" "XK_ht" +.tL "S" "9E3" "XK_ff" +.tL "S" "9E4" "XK_cr" +.tL "S" "9E5" "XK_lf" +.tL "S" "9E8" "XK_nl" +.tL "S" "9E9" "XK_vt" +.tL "S" "9EA" "XK_lowrightcorner" +.tL "S" "9EB" "XK_uprightcorner" +.tL "S" "9EC" "XK_upleftcorner" +.tL "S" "9ED" "XK_lowleftcorner" +.tL "S" "9EE" "XK_crossinglines" +.tL "S" "9EF" "XK_horizlinescan1" +.tL "S" "9F0" "XK_horizlinescan3" +.tL "S" "9F1" "XK_horizlinescan5" +.tL "S" "9F2" "XK_horizlinescan7" +.tL "S" "9F3" "XK_horizlinescan9" +.tL "S" "9F4" "XK_leftt" +.tL "S" "9F5" "XK_rightt" +.tL "S" "9F6" "XK_bott" +.tL "S" "9F7" "XK_topt" +.tL "S" "9F8" "XK_vertbar" +>>STRATEGY +For each KeySym name in table with code S: + Call XStringToKeysym to obtain the KeySym defined for that string. + Verify that XStringToKeysym did not return NoSymbol. + Verify that the returned string is correct. +>>CODE + + strtsymS(); + +>>ASSERTION Good A +When the +.A string +argument is the name of a +.S KeySym +in the table +with the prefix +.S XK_ +removed, +then a call to xname returns that +.S KeySym . +.tL "Code" "Value" "Name" +.tL "T" "8A1" "XK_leftradical" +.tL "T" "8A2" "XK_topleftradical" +.tL "T" "8A3" "XK_horizconnector" +.tL "T" "8A4" "XK_topintegral" +.tL "T" "8A5" "XK_botintegral" +.tL "T" "8A6" "XK_vertconnector" +.tL "T" "8A7" "XK_topleftsqbracket" +.tL "T" "8A8" "XK_botleftsqbracket" +.tL "T" "8A9" "XK_toprightsqbracket" +.tL "T" "8AA" "XK_botrightsqbracket" +.tL "T" "8AB" "XK_topleftparens" +.tL "T" "8AC" "XK_botleftparens" +.tL "T" "8AD" "XK_toprightparens" +.tL "T" "8AE" "XK_botrightparens" +.tL "T" "8AF" "XK_leftmiddlecurlybrace" +.tL "T" "8B0" "XK_rightmiddlecurlybrace" +.tL "T" "8B1" "XK_topleftsummation" +.tL "T" "8B2" "XK_botleftsummation" +.tL "T" "8B3" "XK_topvertsummationconnector" +.tL "T" "8B4" "XK_botvertsummationconnector" +.tL "T" "8B5" "XK_toprightsummation" +.tL "T" "8B6" "XK_botrightsummation" +.tL "T" "8B7" "XK_rightmiddlesummation" +.tL "T" "8BC" "XK_lessthanequal" +.tL "T" "8BD" "XK_notequal" +.tL "T" "8BE" "XK_greaterthanequal" +.tL "T" "8BF" "XK_integral" +.tL "T" "8C0" "XK_therefore" +.tL "T" "8C1" "XK_variation" +.tL "T" "8C2" "XK_infinity" +.tL "T" "8C5" "XK_nabla" +.tL "T" "8C8" "XK_approximate" +.tL "T" "8C9" "XK_similarequal" +.tL "T" "8CD" "XK_ifonlyif" +.tL "T" "8CE" "XK_implies" +.tL "T" "8CF" "XK_identical" +.tL "T" "8D6" "XK_radical" +.tL "T" "8DA" "XK_includedin" +.tL "T" "8DB" "XK_includes" +.tL "T" "8DC" "XK_intersection" +.tL "T" "8DD" "XK_union" +.tL "T" "8DE" "XK_logicaland" +.tL "T" "8DF" "XK_logicalor" +.tL "T" "8EF" "XK_partialderivative" +.tL "T" "8F6" "XK_function" +.tL "T" "8FB" "XK_leftarrow" +.tL "T" "8FC" "XK_uparrow" +.tL "T" "8FD" "XK_rightarrow" +.tL "T" "8FE" "XK_downarrow" +>>STRATEGY +For each KeySym name in table with code T: + Call XStringToKeysym to obtain the KeySym defined for that string. + Verify that XStringToKeysym did not return NoSymbol. + Verify that the returned string is correct. +>>CODE + + strtsymT(); + diff --git a/xts5/Xopen/cursorfont/cursorfont.m b/xts5/Xopen/cursorfont/cursorfont.m new file mode 100644 index 00000000..edad5c83 --- /dev/null +++ b/xts5/Xopen/cursorfont/cursorfont.m @@ -0,0 +1,880 @@ +Copyright (c) 2005 X.Org Foundation L.L.C. + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies +of the Software, and to permit persons to whom the Software is furnished to do +so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. +$Header: /cvs/xtest/xtest/xts5/tset/Xopen/cursorfont/cursorfont.m,v 1.2 2005-11-03 08:44:00 jmichael Exp $ + +>># Project: VSW5 +>># +>># File: xts5/tset/XOPEN/cursorfont/cursorfont.m +>># +>># Description: +>># Tests for cursorfont() +>># +>># Modifications: +>># $Log: crsrfnt.m,v $ +>># Revision 1.2 2005-11-03 08:44:00 jmichael +>># clean up all vsw5 paths to use xts5 instead. +>># +>># Revision 1.1.1.2 2005/04/15 14:05:39 anderson +>># Reimport of the base with the legal name in the copyright fixed. +>># +>># Revision 8.0 1998/12/23 23:35:28 mar +>># Branch point for Release 5.0.2 +>># +>># Revision 7.0 1998/10/30 22:57:57 mar +>># Branch point for Release 5.0.2b1 +>># +>># Revision 6.0 1998/03/02 05:26:43 tbr +>># Branch point for Release 5.0.1 +>># +>># Revision 5.0 1998/01/26 03:23:16 tbr +>># Branch point for Release 5.0.1b1 +>># +>># Revision 4.0 1995/12/15 09:13:18 tbr +>># Branch point for Release 5.0.0 +>># +>># Revision 3.1 1995/12/15 01:16:33 andy +>># Prepare for GA Release +>># +/* + SCCS: @(#) crsrfnt.m Rel 1.6 (11/25/91) + + UniSoft Ltd., London, England + +(C) Copyright 1991 X/Open Company Limited + +All rights reserved. No part of this source code may be reproduced, +stored in a retrieval system, or transmitted, in any form or by any +means, electronic, mechanical, photocopying, recording or otherwise, +except as stated in the end-user licence agreement, without the prior +permission of the copyright owners. + +X/Open and the 'X' symbol are trademarks of X/Open Company Limited in +the UK and other countries. +*/ +>>TITLE cursorfont XOPEN +>>EXTERN +#include <X11/cursorfont.h> +>>ASSERTION Good A +When the header file <X11/cursorfont.h> is included, +then the symbol +.S XC_X_cursor +is defined with the value 0. +>>STRATEGY +Include the file <X11/cursorfont.h> +Verify that the symbol XC_X_cursor is defined. +Verify that the symbol is defined to have value 0. +>>CODE + +#ifdef XC_X_cursor + +# if (XC_X_cursor == 0) + PASS; +# else + report("XC_X_cursor was defined to have value %ld instead of 0.", (long) XC_X_cursor); + FAIL; +# endif + +#else + report("XC_X_cursor is not defined."); + FAIL; +#endif + +>>ASSERTION Good A +When the header file <X11/cursorfont.h> is included, +then the symbol +.S XC_bottom_left_corner +is defined with the value 12. +>>STRATEGY +Include the file <X11/cursorfont.h> +Verify that the symbol XC_bottom_left_corner is defined. +Verify that the symbol is defined to have value 12. +>>CODE + +#ifdef XC_bottom_left_corner + +# if (XC_bottom_left_corner == 12) + PASS; +# else + report("XC_bottom_left_corner was defined to have value %ld instead of 12.", (long) XC_bottom_left_corner); + FAIL; +# endif + +#else + report("XC_bottom_left_corner is not defined."); + FAIL; +#endif + +>>ASSERTION Good A +When the header file <X11/cursorfont.h> is included, +then the symbol +.S XC_bottom_right_corner +is defined with the value 14. +>>STRATEGY +Include the file <X11/cursorfont.h> +Verify that the symbol XC_bottom_right_corner is defined. +Verify that the symbol is defined to have value 14. +>>CODE + +#ifdef XC_bottom_right_corner + +# if (XC_bottom_right_corner == 14) + PASS; +# else + report("XC_bottom_right_corner was defined to have value %ld instead of 14.", (long) XC_bottom_right_corner); + FAIL; +# endif + +#else + report("XC_bottom_right_corner is not defined."); + FAIL; +#endif + +>>ASSERTION Good A +When the header file <X11/cursorfont.h> is included, +then the symbol +.S XC_top_left_corner +is defined with the value 134. +>>STRATEGY +Include the file <X11/cursorfont.h> +Verify that the symbol XC_top_left_corner is defined. +Verify that the symbol is defined to have value 134. +>>CODE + +#ifdef XC_top_left_corner + +# if (XC_top_left_corner == 134) + PASS; +# else + report("XC_top_left_corner was defined to have value %ld instead of 134.", (long) XC_top_left_corner); + FAIL; +# endif + +#else + report("XC_top_left_corner is not defined."); + FAIL; +#endif + +>>ASSERTION Good A +When the header file <X11/cursorfont.h> is included, +then the symbol +.S XC_top_right_corner +is defined with the value 136. +>>STRATEGY +Include the file <X11/cursorfont.h> +Verify that the symbol XC_top_right_corner is defined. +Verify that the symbol is defined to have value 136. +>>CODE + +#ifdef XC_top_right_corner + +# if (XC_top_right_corner == 136) + PASS; +# else + report("XC_top_right_corner was defined to have value %ld instead of 136.", (long) XC_top_right_corner); + FAIL; +# endif + +#else + report("XC_top_right_corner is not defined."); + FAIL; +#endif + +>>ASSERTION Good A +When the header file <X11/cursorfont.h> is included, +then the symbol +.S XC_arrow +is defined with the value 2. +>>STRATEGY +Include the file <X11/cursorfont.h> +Verify that the symbol XC_arrow is defined. +Verify that the symbol is defined to have value 2. +>>CODE + +#ifdef XC_arrow + +# if (XC_arrow == 2) + PASS; +# else + report("XC_arrow was defined to have value %ld instead of 2.", (long) XC_arrow); + FAIL; +# endif + +#else + report("XC_arrow is not defined."); + FAIL; +#endif + +>>ASSERTION Good A +When the header file <X11/cursorfont.h> is included, +then the symbol +.S XC_based_arrow_down +is defined with the value 4. +>>STRATEGY +Include the file <X11/cursorfont.h> +Verify that the symbol XC_based_arrow_down is defined. +Verify that the symbol is defined to have value 4. +>>CODE + +#ifdef XC_based_arrow_down + +# if (XC_based_arrow_down == 4) + PASS; +# else + report("XC_based_arrow_down was defined to have value %ld instead of 4.", (long) XC_based_arrow_down); + FAIL; +# endif + +#else + report("XC_based_arrow_down is not defined."); + FAIL; +#endif + +>>ASSERTION Good A +When the header file <X11/cursorfont.h> is included, +then the symbol +.S XC_based_arrow_up +is defined with the value 6. +>>STRATEGY +Include the file <X11/cursorfont.h> +Verify that the symbol XC_based_arrow_up is defined. +Verify that the symbol is defined to have value 6. +>>CODE + +#ifdef XC_based_arrow_up + +# if (XC_based_arrow_up == 6) + PASS; +# else + report("XC_based_arrow_up was defined to have value %ld instead of 6.", (long) XC_based_arrow_up); + FAIL; +# endif + +#else + report("XC_based_arrow_up is not defined."); + FAIL; +#endif + +>>ASSERTION Good A +When the header file <X11/cursorfont.h> is included, +then the symbol +.S XC_double_arrow +is defined with the value 42. +>>STRATEGY +Include the file <X11/cursorfont.h> +Verify that the symbol XC_double_arrow is defined. +Verify that the symbol is defined to have value 42. +>>CODE + +#ifdef XC_double_arrow + +# if (XC_double_arrow == 42) + PASS; +# else + report("XC_double_arrow was defined to have value %ld instead of 42.", (long) XC_double_arrow); + FAIL; +# endif + +#else + report("XC_double_arrow is not defined."); + FAIL; +#endif + +>>ASSERTION Good A +When the header file <X11/cursorfont.h> is included, +then the symbol +.S XC_question_arrow +is defined with the value 92. +>>STRATEGY +Include the file <X11/cursorfont.h> +Verify that the symbol XC_question_arrow is defined. +Verify that the symbol is defined to have value 92. +>>CODE + +#ifdef XC_question_arrow + +# if (XC_question_arrow == 92) + PASS; +# else + report("XC_question_arrow was defined to have value %ld instead of 92.", (long) XC_question_arrow); + FAIL; +# endif + +#else + report("XC_question_arrow is not defined."); + FAIL; +#endif + +>>ASSERTION Good A +When the header file <X11/cursorfont.h> is included, +then the symbol +.S XC_sb_h_double_arrow +is defined with the value 108. +>>STRATEGY +Include the file <X11/cursorfont.h> +Verify that the symbol XC_sb_h_double_arrow is defined. +Verify that the symbol is defined to have value 108. +>>CODE + +#ifdef XC_sb_h_double_arrow + +# if (XC_sb_h_double_arrow == 108) + PASS; +# else + report("XC_sb_h_double_arrow was defined to have value %ld instead of 108.", (long) XC_sb_h_double_arrow); + FAIL; +# endif + +#else + report("XC_sb_h_double_arrow is not defined."); + FAIL; +#endif + +>>ASSERTION Good A +When the header file <X11/cursorfont.h> is included, +then the symbol +.S XC_sb_v_double_arrow +is defined with the value 116. +>>STRATEGY +Include the file <X11/cursorfont.h> +Verify that the symbol XC_sb_v_double_arrow is defined. +Verify that the symbol is defined to have value 116. +>>CODE + +#ifdef XC_sb_v_double_arrow + +# if (XC_sb_v_double_arrow == 116) + PASS; +# else + report("XC_sb_v_double_arrow was defined to have value %ld instead of 116.", (long) XC_sb_v_double_arrow); + FAIL; +# endif + +#else + report("XC_sb_v_double_arrow is not defined."); + FAIL; +#endif + +>>ASSERTION Good A +When the header file <X11/cursorfont.h> is included, +then the symbol +.S XC_top_left_arrow +is defined with the value 132. +>>STRATEGY +Include the file <X11/cursorfont.h> +Verify that the symbol XC_top_left_arrow is defined. +Verify that the symbol is defined to have value 132. +>>CODE + +#ifdef XC_top_left_arrow + +# if (XC_top_left_arrow == 132) + PASS; +# else + report("XC_top_left_arrow was defined to have value %ld instead of 132.", (long) XC_top_left_arrow); + FAIL; +# endif + +#else + report("XC_top_left_arrow is not defined."); + FAIL; +#endif + +>>ASSERTION Good A +When the header file <X11/cursorfont.h> is included, +then the symbol +.S XC_bottom_tee +is defined with the value 18. +>>STRATEGY +Include the file <X11/cursorfont.h> +Verify that the symbol XC_bottom_tee is defined. +Verify that the symbol is defined to have value 18. +>>CODE + +#ifdef XC_bottom_tee + +# if (XC_bottom_tee == 18) + PASS; +# else + report("XC_bottom_tee was defined to have value %ld instead of 18.", (long) XC_bottom_tee); + FAIL; +# endif + +#else + report("XC_bottom_tee is not defined."); + FAIL; +#endif + +>>ASSERTION Good A +When the header file <X11/cursorfont.h> is included, +then the symbol +.S XC_left_tee +is defined with the value 72. +>>STRATEGY +Include the file <X11/cursorfont.h> +Verify that the symbol XC_left_tee is defined. +Verify that the symbol is defined to have value 72. +>>CODE + +#ifdef XC_left_tee + +# if (XC_left_tee == 72) + PASS; +# else + report("XC_left_tee was defined to have value %ld instead of 72.", (long) XC_left_tee); + FAIL; +# endif + +#else + report("XC_left_tee is not defined."); + FAIL; +#endif + +>>ASSERTION Good A +When the header file <X11/cursorfont.h> is included, +then the symbol +.S XC_right_tee +is defined with the value 98. +>>STRATEGY +Include the file <X11/cursorfont.h> +Verify that the symbol XC_right_tee is defined. +Verify that the symbol is defined to have value 98. +>>CODE + +#ifdef XC_right_tee + +# if (XC_right_tee == 98) + PASS; +# else + report("XC_right_tee was defined to have value %ld instead of 98.", (long) XC_right_tee); + FAIL; +# endif + +#else + report("XC_right_tee is not defined."); + FAIL; +#endif + +>>ASSERTION Good A +When the header file <X11/cursorfont.h> is included, +then the symbol +.S XC_top_tee +is defined with the value 140. +>>STRATEGY +Include the file <X11/cursorfont.h> +Verify that the symbol XC_top_tee is defined. +Verify that the symbol is defined to have value 140. +>>CODE + +#ifdef XC_top_tee + +# if (XC_top_tee == 140) + PASS; +# else + report("XC_top_tee was defined to have value %ld instead of 140.", (long) XC_top_tee); + FAIL; +# endif + +#else + report("XC_top_tee is not defined."); + FAIL; +#endif + +>>ASSERTION Good A +When the header file <X11/cursorfont.h> is included, +then the symbol +.S XC_bottom_side +is defined with the value 16. +>>STRATEGY +Include the file <X11/cursorfont.h> +Verify that the symbol XC_bottom_side is defined. +Verify that the symbol is defined to have value 16. +>>CODE + +#ifdef XC_bottom_side + +# if (XC_bottom_side == 16) + PASS; +# else + report("XC_bottom_side was defined to have value %ld instead of 16.", (long) XC_bottom_side); + FAIL; +# endif + +#else + report("XC_bottom_side is not defined."); + FAIL; +#endif + +>>ASSERTION Good A +When the header file <X11/cursorfont.h> is included, +then the symbol +.S XC_left_side +is defined with the value 70. +>>STRATEGY +Include the file <X11/cursorfont.h> +Verify that the symbol XC_left_side is defined. +Verify that the symbol is defined to have value 70. +>>CODE + +#ifdef XC_left_side + +# if (XC_left_side == 70) + PASS; +# else + report("XC_left_side was defined to have value %ld instead of 70.", (long) XC_left_side); + FAIL; +# endif + +#else + report("XC_left_side is not defined."); + FAIL; +#endif + +>>ASSERTION Good A +When the header file <X11/cursorfont.h> is included, +then the symbol +.S XC_right_side +is defined with the value 96. +>>STRATEGY +Include the file <X11/cursorfont.h> +Verify that the symbol XC_right_side is defined. +Verify that the symbol is defined to have value 96. +>>CODE + +#ifdef XC_right_side + +# if (XC_right_side == 96) + PASS; +# else + report("XC_right_side was defined to have value %ld instead of 96.", (long) XC_right_side); + FAIL; +# endif + +#else + report("XC_right_side is not defined."); + FAIL; +#endif + +>>ASSERTION Good A +When the header file <X11/cursorfont.h> is included, +then the symbol +.S XC_top_side +is defined with the value 138. +>>STRATEGY +Include the file <X11/cursorfont.h> +Verify that the symbol XC_top_side is defined. +Verify that the symbol is defined to have value 138. +>>CODE + +#ifdef XC_top_side + +# if (XC_top_side == 138) + PASS; +# else + report("XC_top_side was defined to have value %ld instead of 138.", (long) XC_top_side); + FAIL; +# endif + +#else + report("XC_top_side is not defined."); + FAIL; +#endif + +>>ASSERTION Good A +When the header file <X11/cursorfont.h> is included, +then the symbol +.S XC_ll_angle +is defined with the value 76. +>>STRATEGY +Include the file <X11/cursorfont.h> +Verify that the symbol XC_ll_angle is defined. +Verify that the symbol is defined to have value 76. +>>CODE + +#ifdef XC_ll_angle + +# if (XC_ll_angle == 76) + PASS; +# else + report("XC_ll_angle was defined to have value %ld instead of 76.", (long) XC_ll_angle); + FAIL; +# endif + +#else + report("XC_ll_angle is not defined."); + FAIL; +#endif + +>>ASSERTION Good A +When the header file <X11/cursorfont.h> is included, +then the symbol +.S XC_lr_angle +is defined with the value 78. +>>STRATEGY +Include the file <X11/cursorfont.h> +Verify that the symbol XC_lr_angle is defined. +Verify that the symbol is defined to have value 78. +>>CODE + +#ifdef XC_lr_angle + +# if (XC_lr_angle == 78) + PASS; +# else + report("XC_lr_angle was defined to have value %ld instead of 78.", (long) XC_lr_angle); + FAIL; +# endif + +#else + report("XC_lr_angle is not defined."); + FAIL; +#endif + +>>ASSERTION Good A +When the header file <X11/cursorfont.h> is included, +then the symbol +.S XC_ul_angle +is defined with the value 144. +>>STRATEGY +Include the file <X11/cursorfont.h> +Verify that the symbol XC_ul_angle is defined. +Verify that the symbol is defined to have value 144. +>>CODE + +#ifdef XC_ul_angle + +# if (XC_ul_angle == 144) + PASS; +# else + report("XC_ul_angle was defined to have value %ld instead of 144.", (long) XC_ul_angle); + FAIL; +# endif + +#else + report("XC_ul_angle is not defined."); + FAIL; +#endif + +>>ASSERTION Good A +When the header file <X11/cursorfont.h> is included, +then the symbol +.S XC_ur_angle +is defined with the value 148. +>>STRATEGY +Include the file <X11/cursorfont.h> +Verify that the symbol XC_ur_angle is defined. +Verify that the symbol is defined to have value 148. +>>CODE + +#ifdef XC_ur_angle + +# if (XC_ur_angle == 148) + PASS; +# else + report("XC_ur_angle was defined to have value %ld instead of 148.", (long) XC_ur_angle); + FAIL; +# endif + +#else + report("XC_ur_angle is not defined."); + FAIL; +#endif + +>>ASSERTION Good A +When the header file <X11/cursorfont.h> is included, +then the symbol +.S XC_circle +is defined with the value 24. +>>STRATEGY +Include the file <X11/cursorfont.h> +Verify that the symbol XC_circle is defined. +Verify that the symbol is defined to have value 24. +>>CODE + +#ifdef XC_circle + +# if (XC_circle == 24) + PASS; +# else + report("XC_circle was defined to have value %ld instead of 24.", (long) XC_circle); + FAIL; +# endif + +#else + report("XC_circle is not defined."); + FAIL; +#endif + +>>ASSERTION Good A +When the header file <X11/cursorfont.h> is included, +then the symbol +.S XC_cross +is defined with the value 30. +>>STRATEGY +Include the file <X11/cursorfont.h> +Verify that the symbol XC_cross is defined. +Verify that the symbol is defined to have value 30. +>>CODE + +#ifdef XC_cross + +# if (XC_cross == 30) + PASS; +# else + report("XC_cross was defined to have value %ld instead of 30.", (long) XC_cross); + FAIL; +# endif + +#else + report("XC_cross is not defined."); + FAIL; +#endif + +>>ASSERTION Good A +When the header file <X11/cursorfont.h> is included, +then the symbol +.S XC_crosshair +is defined with the value 34. +>>STRATEGY +Include the file <X11/cursorfont.h> +Verify that the symbol XC_crosshair is defined. +Verify that the symbol is defined to have value 34. +>>CODE + +#ifdef XC_crosshair + +# if (XC_crosshair == 34) + PASS; +# else + report("XC_crosshair was defined to have value %ld instead of 34.", (long) XC_crosshair); + FAIL; +# endif + +#else + report("XC_crosshair is not defined."); + FAIL; +#endif + +>>ASSERTION Good A +When the header file <X11/cursorfont.h> is included, +then the symbol +.S XC_center_ptr +is defined with the value 22. +>>STRATEGY +Include the file <X11/cursorfont.h> +Verify that the symbol XC_center_ptr is defined. +Verify that the symbol is defined to have value 22. +>>CODE + +#ifdef XC_center_ptr + +# if (XC_center_ptr == 22) + PASS; +# else + report("XC_center_ptr was defined to have value %ld instead of 22.", (long) XC_center_ptr); + FAIL; +# endif + +#else + report("XC_center_ptr is not defined."); + FAIL; +#endif + +>>ASSERTION Good A +When the header file <X11/cursorfont.h> is included, +then the symbol +.S XC_left_ptr +is defined with the value 68. +>>STRATEGY +Include the file <X11/cursorfont.h> +Verify that the symbol XC_left_ptr is defined. +Verify that the symbol is defined to have value 68. +>>CODE + +#ifdef XC_left_ptr + +# if (XC_left_ptr == 68) + PASS; +# else + report("XC_left_ptr was defined to have value %ld instead of 68.", (long) XC_left_ptr); + FAIL; +# endif + +#else + report("XC_left_ptr is not defined."); + FAIL; +#endif + +>>ASSERTION Good A +When the header file <X11/cursorfont.h> is included, +then the symbol +.S XC_right_ptr +is defined with the value 94. +>>STRATEGY +Include the file <X11/cursorfont.h> +Verify that the symbol XC_right_ptr is defined. +Verify that the symbol is defined to have value 94. +>>CODE + +#ifdef XC_right_ptr + +# if (XC_right_ptr == 94) + PASS; +# else + report("XC_right_ptr was defined to have value %ld instead of 94.", (long) XC_right_ptr); + FAIL; +# endif + +#else + report("XC_right_ptr is not defined."); + FAIL; +#endif + +>>ASSERTION Good A +When the header file <X11/cursorfont.h> is included, +then the symbol +.S XC_num_glyphs +is defined with a value which is even and is not less than 150. +>>STRATEGY +Include the file <X11/cursorfont.h> +Verify that the symbol XC_num_glyphs is defined. +Verify that the sumbol value is even. +Verify that the symbol is defined to have value not less than 150. +>>CODE + +#ifdef XC_num_glyphs + + if(XC_num_glyphs < 150) { + report("XC_num_glyphs (value %ld) is less than 150.", (long) XC_num_glyphs); + FAIL; + } else + CHECK; + + if(XC_num_glyphs % 2 != 0) { + report("XC_num_glyphs (value %ld) is not even.", (long) XC_num_glyphs); + FAIL; + } else + CHECK; + + CHECKPASS(2); +#else + report("XC_num_glyphs is not defined."); + FAIL; +#endif + diff --git a/xts5/Xopen/keysym/Test0.c b/xts5/Xopen/keysym/Test0.c new file mode 100644 index 00000000..1e43903b --- /dev/null +++ b/xts5/Xopen/keysym/Test0.c @@ -0,0 +1,133 @@ +/* +Copyright (c) 2005 X.Org Foundation L.L.C. + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies +of the Software, and to permit persons to whom the Software is furnished to do +so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. +*/ +/* +* $Header: /cvs/xtest/xtest/xts5/tset/Xopen/keysym/Test0.c,v 1.2 2005-11-03 08:44:00 jmichael Exp $ +* +* Project: VSW5 +* +* File: xts5/tset/Xopen/keysym/Test0.c +* +* Description: +* Tests for keysym() +* +* Modifications: +* $Log: Test0.c,v $ +* Revision 1.2 2005-11-03 08:44:00 jmichael +* clean up all vsw5 paths to use xts5 instead. +* +* Revision 1.1.1.2 2005/04/15 14:05:40 anderson +* Reimport of the base with the legal name in the copyright fixed. +* +* Revision 8.0 1998/12/23 23:35:30 mar +* Branch point for Release 5.0.2 +* +* Revision 7.0 1998/10/30 22:57:59 mar +* Branch point for Release 5.0.2b1 +* +* Revision 6.0 1998/03/02 05:26:44 tbr +* Branch point for Release 5.0.1 +* +* Revision 5.0 1998/01/26 03:23:18 tbr +* Branch point for Release 5.0.1b1 +* +* Revision 4.1 1996/05/09 21:14:55 andy +* Fixed X includes +* +* Revision 4.0 1995/12/15 09:13:25 tbr +* Branch point for Release 5.0.0 +* +* Revision 3.1 1995/12/15 01:16:40 andy +* Prepare for GA Release +* +*/ +/* + * SCCS: @(#) Test0.c Rel 1.1 (5/12/92) + * + * UniSoft Ltd., London, England + * + * (C) Copyright 1991 X/Open Company Limited + * + * All rights reserved. No part of this source code may be reproduced, + * stored in a retrieval system, or transmitted, in any form or by any + * means, electronic, mechanical, photocopying, recording or otherwise, + * except as stated in the end-user licence agreement, without the prior + * permission of the copyright owners. + * + * X/Open and the 'X' symbol are trademarks of X/Open Company Limited in + * the UK and other countries. + */ + +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif + +#include <stdlib.h> +#include "xtest.h" +#include "X11/Xlib.h" +#include "X11/Xutil.h" +#include "X11/Xresource.h" +#include "tet_api.h" +#include "xtestlib.h" +#include "pixval.h" + +extern char *TestName; + +static int +test(name, val, aval) +char *name; +int val; +int aval; +{ + + if(val != aval) { + report("KeySym \"%s\" is defined to have value 0x%x instead of 0x%x.", name, val, aval); + return(0); + } + return(1); +} + + + +static void +reporterr(s) +char *s; +{ + report("Keysym \"%s\" is not defined.", s); +} + +#include <X11/keysym.h> + +kysym0() +{ +int pass = 0, fail = 0; +#ifdef XK_VoidSymbol + if(test("XK_VoidSymbol", XK_VoidSymbol, 0xFFFFFF) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_VoidSymbol"); + FAIL; +#endif + + CHECKPASS(1); +} diff --git a/xts5/Xopen/keysym/Test1.c b/xts5/Xopen/keysym/Test1.c new file mode 100644 index 00000000..90e18c71 --- /dev/null +++ b/xts5/Xopen/keysym/Test1.c @@ -0,0 +1,2074 @@ +/* +Copyright (c) 2005 X.Org Foundation L.L.C. + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies +of the Software, and to permit persons to whom the Software is furnished to do +so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. +*/ +/* +* $Header: /cvs/xtest/xtest/xts5/tset/Xopen/keysym/Test1.c,v 1.2 2005-11-03 08:44:00 jmichael Exp $ +* +* Project: VSW5 +* +* File: xts5/tset/Xopen/keysym/Test1.c +* +* Description: +* Tests for keysym() +* +* Modifications: +* $Log: Test1.c,v $ +* Revision 1.2 2005-11-03 08:44:00 jmichael +* clean up all vsw5 paths to use xts5 instead. +* +* Revision 1.1.1.2 2005/04/15 14:05:40 anderson +* Reimport of the base with the legal name in the copyright fixed. +* +* Revision 8.0 1998/12/23 23:35:31 mar +* Branch point for Release 5.0.2 +* +* Revision 7.0 1998/10/30 22:58:00 mar +* Branch point for Release 5.0.2b1 +* +* Revision 6.0 1998/03/02 05:26:45 tbr +* Branch point for Release 5.0.1 +* +* Revision 5.0 1998/01/26 03:23:18 tbr +* Branch point for Release 5.0.1b1 +* +* Revision 4.1 1996/05/09 21:14:55 andy +* Fixed X includes +* +* Revision 4.0 1995/12/15 09:13:27 tbr +* Branch point for Release 5.0.0 +* +* Revision 3.1 1995/12/15 01:16:42 andy +* Prepare for GA Release +* +*/ +/* + * SCCS: @(#) Test1.c Rel 1.1 (11/28/91) + * + * UniSoft Ltd., London, England + * + * (C) Copyright 1991 X/Open Company Limited + * + * All rights reserved. No part of this source code may be reproduced, + * stored in a retrieval system, or transmitted, in any form or by any + * means, electronic, mechanical, photocopying, recording or otherwise, + * except as stated in the end-user licence agreement, without the prior + * permission of the copyright owners. + * + * X/Open and the 'X' symbol are trademarks of X/Open Company Limited in + * the UK and other countries. + */ + +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif + +#include <stdlib.h> +#include "xtest.h" +#include "X11/Xlib.h" +#include "X11/Xutil.h" +#include "X11/Xresource.h" +#include "tet_api.h" +#include "xtestlib.h" +#include "pixval.h" + +extern char *TestName; + +static int +test(name, val, aval) +char *name; +int val; +int aval; +{ + + if(val != aval) { + report("KeySym \"%s\" is defined to have value 0x%x instead of 0x%x.", name, val, aval); + return(0); + } + return(1); +} + + + +static void +reporterr(s) +char *s; +{ + report("Keysym \"%s\" is not defined.", s); +} + +#include <X11/keysym.h> + +kysym1() +{ +int pass = 0, fail = 0; +#ifdef XK_space + if(test("XK_space", XK_space, 0x20) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_space"); + FAIL; +#endif + +#ifdef XK_exclam + if(test("XK_exclam", XK_exclam, 0x21) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_exclam"); + FAIL; +#endif + +#ifdef XK_quotedbl + if(test("XK_quotedbl", XK_quotedbl, 0x22) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_quotedbl"); + FAIL; +#endif + +#ifdef XK_numbersign + if(test("XK_numbersign", XK_numbersign, 0x23) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_numbersign"); + FAIL; +#endif + +#ifdef XK_dollar + if(test("XK_dollar", XK_dollar, 0x24) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_dollar"); + FAIL; +#endif + +#ifdef XK_percent + if(test("XK_percent", XK_percent, 0x25) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_percent"); + FAIL; +#endif + +#ifdef XK_ampersand + if(test("XK_ampersand", XK_ampersand, 0x26) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_ampersand"); + FAIL; +#endif + +#ifdef XK_apostrophe + if(test("XK_apostrophe", XK_apostrophe, 0x27) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_apostrophe"); + FAIL; +#endif + +#ifdef XK_quoteright + if(test("XK_quoteright", XK_quoteright, 0x27) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_quoteright"); + FAIL; +#endif + +#ifdef XK_parenleft + if(test("XK_parenleft", XK_parenleft, 0x28) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_parenleft"); + FAIL; +#endif + +#ifdef XK_parenright + if(test("XK_parenright", XK_parenright, 0x29) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_parenright"); + FAIL; +#endif + +#ifdef XK_asterisk + if(test("XK_asterisk", XK_asterisk, 0x2A) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_asterisk"); + FAIL; +#endif + +#ifdef XK_plus + if(test("XK_plus", XK_plus, 0x2B) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_plus"); + FAIL; +#endif + +#ifdef XK_comma + if(test("XK_comma", XK_comma, 0x2C) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_comma"); + FAIL; +#endif + +#ifdef XK_minus + if(test("XK_minus", XK_minus, 0x2D) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_minus"); + FAIL; +#endif + +#ifdef XK_period + if(test("XK_period", XK_period, 0x2E) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_period"); + FAIL; +#endif + +#ifdef XK_slash + if(test("XK_slash", XK_slash, 0x2F) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_slash"); + FAIL; +#endif + +#ifdef XK_0 + if(test("XK_0", XK_0, 0x30) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_0"); + FAIL; +#endif + +#ifdef XK_1 + if(test("XK_1", XK_1, 0x31) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_1"); + FAIL; +#endif + +#ifdef XK_2 + if(test("XK_2", XK_2, 0x32) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_2"); + FAIL; +#endif + +#ifdef XK_3 + if(test("XK_3", XK_3, 0x33) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_3"); + FAIL; +#endif + +#ifdef XK_4 + if(test("XK_4", XK_4, 0x34) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_4"); + FAIL; +#endif + +#ifdef XK_5 + if(test("XK_5", XK_5, 0x35) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_5"); + FAIL; +#endif + +#ifdef XK_6 + if(test("XK_6", XK_6, 0x36) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_6"); + FAIL; +#endif + +#ifdef XK_7 + if(test("XK_7", XK_7, 0x37) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_7"); + FAIL; +#endif + +#ifdef XK_8 + if(test("XK_8", XK_8, 0x38) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_8"); + FAIL; +#endif + +#ifdef XK_9 + if(test("XK_9", XK_9, 0x39) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_9"); + FAIL; +#endif + +#ifdef XK_colon + if(test("XK_colon", XK_colon, 0x3A) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_colon"); + FAIL; +#endif + +#ifdef XK_semicolon + if(test("XK_semicolon", XK_semicolon, 0x3B) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_semicolon"); + FAIL; +#endif + +#ifdef XK_less + if(test("XK_less", XK_less, 0x3C) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_less"); + FAIL; +#endif + +#ifdef XK_equal + if(test("XK_equal", XK_equal, 0x3D) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_equal"); + FAIL; +#endif + +#ifdef XK_greater + if(test("XK_greater", XK_greater, 0x3E) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_greater"); + FAIL; +#endif + +#ifdef XK_question + if(test("XK_question", XK_question, 0x3F) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_question"); + FAIL; +#endif + +#ifdef XK_at + if(test("XK_at", XK_at, 0x40) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_at"); + FAIL; +#endif + +#ifdef XK_A + if(test("XK_A", XK_A, 0x41) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_A"); + FAIL; +#endif + +#ifdef XK_B + if(test("XK_B", XK_B, 0x42) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_B"); + FAIL; +#endif + +#ifdef XK_C + if(test("XK_C", XK_C, 0x43) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_C"); + FAIL; +#endif + +#ifdef XK_D + if(test("XK_D", XK_D, 0x44) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_D"); + FAIL; +#endif + +#ifdef XK_E + if(test("XK_E", XK_E, 0x45) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_E"); + FAIL; +#endif + +#ifdef XK_F + if(test("XK_F", XK_F, 0x46) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_F"); + FAIL; +#endif + +#ifdef XK_G + if(test("XK_G", XK_G, 0x47) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_G"); + FAIL; +#endif + +#ifdef XK_H + if(test("XK_H", XK_H, 0x48) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_H"); + FAIL; +#endif + +#ifdef XK_I + if(test("XK_I", XK_I, 0x49) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_I"); + FAIL; +#endif + +#ifdef XK_J + if(test("XK_J", XK_J, 0x4A) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_J"); + FAIL; +#endif + +#ifdef XK_K + if(test("XK_K", XK_K, 0x4B) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_K"); + FAIL; +#endif + +#ifdef XK_L + if(test("XK_L", XK_L, 0x4C) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_L"); + FAIL; +#endif + +#ifdef XK_M + if(test("XK_M", XK_M, 0x4D) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_M"); + FAIL; +#endif + +#ifdef XK_N + if(test("XK_N", XK_N, 0x4E) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_N"); + FAIL; +#endif + +#ifdef XK_O + if(test("XK_O", XK_O, 0x4F) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_O"); + FAIL; +#endif + +#ifdef XK_P + if(test("XK_P", XK_P, 0x50) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_P"); + FAIL; +#endif + +#ifdef XK_Q + if(test("XK_Q", XK_Q, 0x51) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Q"); + FAIL; +#endif + +#ifdef XK_R + if(test("XK_R", XK_R, 0x52) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_R"); + FAIL; +#endif + +#ifdef XK_S + if(test("XK_S", XK_S, 0x53) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_S"); + FAIL; +#endif + +#ifdef XK_T + if(test("XK_T", XK_T, 0x54) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_T"); + FAIL; +#endif + +#ifdef XK_U + if(test("XK_U", XK_U, 0x55) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_U"); + FAIL; +#endif + +#ifdef XK_V + if(test("XK_V", XK_V, 0x56) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_V"); + FAIL; +#endif + +#ifdef XK_W + if(test("XK_W", XK_W, 0x57) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_W"); + FAIL; +#endif + +#ifdef XK_X + if(test("XK_X", XK_X, 0x58) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_X"); + FAIL; +#endif + +#ifdef XK_Y + if(test("XK_Y", XK_Y, 0x59) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Y"); + FAIL; +#endif + +#ifdef XK_Z + if(test("XK_Z", XK_Z, 0x5A) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Z"); + FAIL; +#endif + +#ifdef XK_bracketleft + if(test("XK_bracketleft", XK_bracketleft, 0x5B) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_bracketleft"); + FAIL; +#endif + +#ifdef XK_backslash + if(test("XK_backslash", XK_backslash, 0x5C) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_backslash"); + FAIL; +#endif + +#ifdef XK_bracketright + if(test("XK_bracketright", XK_bracketright, 0x5D) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_bracketright"); + FAIL; +#endif + +#ifdef XK_asciicircum + if(test("XK_asciicircum", XK_asciicircum, 0x5E) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_asciicircum"); + FAIL; +#endif + +#ifdef XK_underscore + if(test("XK_underscore", XK_underscore, 0x5F) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_underscore"); + FAIL; +#endif + +#ifdef XK_grave + if(test("XK_grave", XK_grave, 0x60) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_grave"); + FAIL; +#endif + +#ifdef XK_quoteleft + if(test("XK_quoteleft", XK_quoteleft, 0x60) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_quoteleft"); + FAIL; +#endif + +#ifdef XK_a + if(test("XK_a", XK_a, 0x61) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_a"); + FAIL; +#endif + +#ifdef XK_b + if(test("XK_b", XK_b, 0x62) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_b"); + FAIL; +#endif + +#ifdef XK_c + if(test("XK_c", XK_c, 0x63) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_c"); + FAIL; +#endif + +#ifdef XK_d + if(test("XK_d", XK_d, 0x64) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_d"); + FAIL; +#endif + +#ifdef XK_e + if(test("XK_e", XK_e, 0x65) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_e"); + FAIL; +#endif + +#ifdef XK_f + if(test("XK_f", XK_f, 0x66) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_f"); + FAIL; +#endif + +#ifdef XK_g + if(test("XK_g", XK_g, 0x67) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_g"); + FAIL; +#endif + +#ifdef XK_h + if(test("XK_h", XK_h, 0x68) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_h"); + FAIL; +#endif + +#ifdef XK_i + if(test("XK_i", XK_i, 0x69) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_i"); + FAIL; +#endif + +#ifdef XK_j + if(test("XK_j", XK_j, 0x6A) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_j"); + FAIL; +#endif + +#ifdef XK_k + if(test("XK_k", XK_k, 0x6B) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_k"); + FAIL; +#endif + +#ifdef XK_l + if(test("XK_l", XK_l, 0x6C) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_l"); + FAIL; +#endif + +#ifdef XK_m + if(test("XK_m", XK_m, 0x6D) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_m"); + FAIL; +#endif + +#ifdef XK_n + if(test("XK_n", XK_n, 0x6E) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_n"); + FAIL; +#endif + +#ifdef XK_o + if(test("XK_o", XK_o, 0x6F) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_o"); + FAIL; +#endif + +#ifdef XK_p + if(test("XK_p", XK_p, 0x70) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_p"); + FAIL; +#endif + +#ifdef XK_q + if(test("XK_q", XK_q, 0x71) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_q"); + FAIL; +#endif + +#ifdef XK_r + if(test("XK_r", XK_r, 0x72) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_r"); + FAIL; +#endif + +#ifdef XK_s + if(test("XK_s", XK_s, 0x73) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_s"); + FAIL; +#endif + +#ifdef XK_t + if(test("XK_t", XK_t, 0x74) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_t"); + FAIL; +#endif + +#ifdef XK_u + if(test("XK_u", XK_u, 0x75) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_u"); + FAIL; +#endif + +#ifdef XK_v + if(test("XK_v", XK_v, 0x76) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_v"); + FAIL; +#endif + +#ifdef XK_w + if(test("XK_w", XK_w, 0x77) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_w"); + FAIL; +#endif + +#ifdef XK_x + if(test("XK_x", XK_x, 0x78) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_x"); + FAIL; +#endif + +#ifdef XK_y + if(test("XK_y", XK_y, 0x79) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_y"); + FAIL; +#endif + +#ifdef XK_z + if(test("XK_z", XK_z, 0x7A) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_z"); + FAIL; +#endif + +#ifdef XK_braceleft + if(test("XK_braceleft", XK_braceleft, 0x7B) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_braceleft"); + FAIL; +#endif + +#ifdef XK_bar + if(test("XK_bar", XK_bar, 0x7C) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_bar"); + FAIL; +#endif + +#ifdef XK_braceright + if(test("XK_braceright", XK_braceright, 0x7D) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_braceright"); + FAIL; +#endif + +#ifdef XK_asciitilde + if(test("XK_asciitilde", XK_asciitilde, 0x7E) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_asciitilde"); + FAIL; +#endif + +#ifdef XK_nobreakspace + if(test("XK_nobreakspace", XK_nobreakspace, 0xA0) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_nobreakspace"); + FAIL; +#endif + +#ifdef XK_exclamdown + if(test("XK_exclamdown", XK_exclamdown, 0xA1) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_exclamdown"); + FAIL; +#endif + +#ifdef XK_cent + if(test("XK_cent", XK_cent, 0xA2) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_cent"); + FAIL; +#endif + +#ifdef XK_sterling + if(test("XK_sterling", XK_sterling, 0xA3) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_sterling"); + FAIL; +#endif + +#ifdef XK_currency + if(test("XK_currency", XK_currency, 0xA4) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_currency"); + FAIL; +#endif + +#ifdef XK_yen + if(test("XK_yen", XK_yen, 0xA5) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_yen"); + FAIL; +#endif + +#ifdef XK_brokenbar + if(test("XK_brokenbar", XK_brokenbar, 0xA6) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_brokenbar"); + FAIL; +#endif + +#ifdef XK_section + if(test("XK_section", XK_section, 0xA7) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_section"); + FAIL; +#endif + +#ifdef XK_diaeresis + if(test("XK_diaeresis", XK_diaeresis, 0xA8) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_diaeresis"); + FAIL; +#endif + +#ifdef XK_copyright + if(test("XK_copyright", XK_copyright, 0xA9) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_copyright"); + FAIL; +#endif + +#ifdef XK_ordfeminine + if(test("XK_ordfeminine", XK_ordfeminine, 0xAA) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_ordfeminine"); + FAIL; +#endif + +#ifdef XK_guillemotleft + if(test("XK_guillemotleft", XK_guillemotleft, 0xAB) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_guillemotleft"); + FAIL; +#endif + +#ifdef XK_notsign + if(test("XK_notsign", XK_notsign, 0xAC) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_notsign"); + FAIL; +#endif + +#ifdef XK_hyphen + if(test("XK_hyphen", XK_hyphen, 0xAD) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_hyphen"); + FAIL; +#endif + +#ifdef XK_registered + if(test("XK_registered", XK_registered, 0xAE) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_registered"); + FAIL; +#endif + +#ifdef XK_macron + if(test("XK_macron", XK_macron, 0xAF) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_macron"); + FAIL; +#endif + +#ifdef XK_degree + if(test("XK_degree", XK_degree, 0xB0) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_degree"); + FAIL; +#endif + +#ifdef XK_plusminus + if(test("XK_plusminus", XK_plusminus, 0xB1) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_plusminus"); + FAIL; +#endif + +#ifdef XK_twosuperior + if(test("XK_twosuperior", XK_twosuperior, 0xB2) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_twosuperior"); + FAIL; +#endif + +#ifdef XK_threesuperior + if(test("XK_threesuperior", XK_threesuperior, 0xB3) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_threesuperior"); + FAIL; +#endif + +#ifdef XK_acute + if(test("XK_acute", XK_acute, 0xB4) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_acute"); + FAIL; +#endif + +#ifdef XK_mu + if(test("XK_mu", XK_mu, 0xB5) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_mu"); + FAIL; +#endif + +#ifdef XK_paragraph + if(test("XK_paragraph", XK_paragraph, 0xB6) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_paragraph"); + FAIL; +#endif + +#ifdef XK_periodcentered + if(test("XK_periodcentered", XK_periodcentered, 0xB7) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_periodcentered"); + FAIL; +#endif + +#ifdef XK_cedilla + if(test("XK_cedilla", XK_cedilla, 0xB8) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_cedilla"); + FAIL; +#endif + +#ifdef XK_onesuperior + if(test("XK_onesuperior", XK_onesuperior, 0xB9) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_onesuperior"); + FAIL; +#endif + +#ifdef XK_masculine + if(test("XK_masculine", XK_masculine, 0xBA) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_masculine"); + FAIL; +#endif + +#ifdef XK_guillemotright + if(test("XK_guillemotright", XK_guillemotright, 0xBB) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_guillemotright"); + FAIL; +#endif + +#ifdef XK_onequarter + if(test("XK_onequarter", XK_onequarter, 0xBC) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_onequarter"); + FAIL; +#endif + +#ifdef XK_onehalf + if(test("XK_onehalf", XK_onehalf, 0xBD) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_onehalf"); + FAIL; +#endif + +#ifdef XK_threequarters + if(test("XK_threequarters", XK_threequarters, 0xBE) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_threequarters"); + FAIL; +#endif + +#ifdef XK_questiondown + if(test("XK_questiondown", XK_questiondown, 0xBF) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_questiondown"); + FAIL; +#endif + +#ifdef XK_Agrave + if(test("XK_Agrave", XK_Agrave, 0xC0) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Agrave"); + FAIL; +#endif + +#ifdef XK_Aacute + if(test("XK_Aacute", XK_Aacute, 0xC1) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Aacute"); + FAIL; +#endif + +#ifdef XK_Acircumflex + if(test("XK_Acircumflex", XK_Acircumflex, 0xC2) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Acircumflex"); + FAIL; +#endif + +#ifdef XK_Atilde + if(test("XK_Atilde", XK_Atilde, 0xC3) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Atilde"); + FAIL; +#endif + +#ifdef XK_Adiaeresis + if(test("XK_Adiaeresis", XK_Adiaeresis, 0xC4) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Adiaeresis"); + FAIL; +#endif + +#ifdef XK_Aring + if(test("XK_Aring", XK_Aring, 0xC5) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Aring"); + FAIL; +#endif + +#ifdef XK_AE + if(test("XK_AE", XK_AE, 0xC6) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_AE"); + FAIL; +#endif + +#ifdef XK_Ccedilla + if(test("XK_Ccedilla", XK_Ccedilla, 0xC7) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Ccedilla"); + FAIL; +#endif + +#ifdef XK_Egrave + if(test("XK_Egrave", XK_Egrave, 0xC8) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Egrave"); + FAIL; +#endif + +#ifdef XK_Eacute + if(test("XK_Eacute", XK_Eacute, 0xC9) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Eacute"); + FAIL; +#endif + +#ifdef XK_Ecircumflex + if(test("XK_Ecircumflex", XK_Ecircumflex, 0xCA) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Ecircumflex"); + FAIL; +#endif + +#ifdef XK_Ediaeresis + if(test("XK_Ediaeresis", XK_Ediaeresis, 0xCB) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Ediaeresis"); + FAIL; +#endif + +#ifdef XK_Igrave + if(test("XK_Igrave", XK_Igrave, 0xCC) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Igrave"); + FAIL; +#endif + +#ifdef XK_Iacute + if(test("XK_Iacute", XK_Iacute, 0xCD) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Iacute"); + FAIL; +#endif + +#ifdef XK_Icircumflex + if(test("XK_Icircumflex", XK_Icircumflex, 0xCE) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Icircumflex"); + FAIL; +#endif + +#ifdef XK_Idiaeresis + if(test("XK_Idiaeresis", XK_Idiaeresis, 0xCF) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Idiaeresis"); + FAIL; +#endif + +#ifdef XK_ETH + if(test("XK_ETH", XK_ETH, 0xD0) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_ETH"); + FAIL; +#endif + +#ifdef XK_Eth + if(test("XK_Eth", XK_Eth, 0xD0) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Eth"); + FAIL; +#endif + +#ifdef XK_Ntilde + if(test("XK_Ntilde", XK_Ntilde, 0xD1) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Ntilde"); + FAIL; +#endif + +#ifdef XK_Ograve + if(test("XK_Ograve", XK_Ograve, 0xD2) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Ograve"); + FAIL; +#endif + +#ifdef XK_Oacute + if(test("XK_Oacute", XK_Oacute, 0xD3) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Oacute"); + FAIL; +#endif + +#ifdef XK_Ocircumflex + if(test("XK_Ocircumflex", XK_Ocircumflex, 0xD4) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Ocircumflex"); + FAIL; +#endif + +#ifdef XK_Otilde + if(test("XK_Otilde", XK_Otilde, 0xD5) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Otilde"); + FAIL; +#endif + +#ifdef XK_Odiaeresis + if(test("XK_Odiaeresis", XK_Odiaeresis, 0xD6) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Odiaeresis"); + FAIL; +#endif + +#ifdef XK_multiply + if(test("XK_multiply", XK_multiply, 0xD7) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_multiply"); + FAIL; +#endif + +#ifdef XK_Ooblique + if(test("XK_Ooblique", XK_Ooblique, 0xD8) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Ooblique"); + FAIL; +#endif + +#ifdef XK_Ugrave + if(test("XK_Ugrave", XK_Ugrave, 0xD9) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Ugrave"); + FAIL; +#endif + +#ifdef XK_Uacute + if(test("XK_Uacute", XK_Uacute, 0xDA) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Uacute"); + FAIL; +#endif + +#ifdef XK_Ucircumflex + if(test("XK_Ucircumflex", XK_Ucircumflex, 0xDB) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Ucircumflex"); + FAIL; +#endif + +#ifdef XK_Udiaeresis + if(test("XK_Udiaeresis", XK_Udiaeresis, 0xDC) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Udiaeresis"); + FAIL; +#endif + +#ifdef XK_Yacute + if(test("XK_Yacute", XK_Yacute, 0xDD) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Yacute"); + FAIL; +#endif + +#ifdef XK_THORN + if(test("XK_THORN", XK_THORN, 0xDE) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_THORN"); + FAIL; +#endif + +#ifdef XK_Thorn + if(test("XK_Thorn", XK_Thorn, 0xDE) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Thorn"); + FAIL; +#endif + +#ifdef XK_ssharp + if(test("XK_ssharp", XK_ssharp, 0xDF) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_ssharp"); + FAIL; +#endif + +#ifdef XK_agrave + if(test("XK_agrave", XK_agrave, 0xE0) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_agrave"); + FAIL; +#endif + +#ifdef XK_aacute + if(test("XK_aacute", XK_aacute, 0xE1) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_aacute"); + FAIL; +#endif + +#ifdef XK_acircumflex + if(test("XK_acircumflex", XK_acircumflex, 0xE2) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_acircumflex"); + FAIL; +#endif + +#ifdef XK_atilde + if(test("XK_atilde", XK_atilde, 0xE3) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_atilde"); + FAIL; +#endif + +#ifdef XK_adiaeresis + if(test("XK_adiaeresis", XK_adiaeresis, 0xE4) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_adiaeresis"); + FAIL; +#endif + +#ifdef XK_aring + if(test("XK_aring", XK_aring, 0xE5) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_aring"); + FAIL; +#endif + +#ifdef XK_ae + if(test("XK_ae", XK_ae, 0xE6) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_ae"); + FAIL; +#endif + +#ifdef XK_ccedilla + if(test("XK_ccedilla", XK_ccedilla, 0xE7) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_ccedilla"); + FAIL; +#endif + +#ifdef XK_egrave + if(test("XK_egrave", XK_egrave, 0xE8) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_egrave"); + FAIL; +#endif + +#ifdef XK_eacute + if(test("XK_eacute", XK_eacute, 0xE9) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_eacute"); + FAIL; +#endif + +#ifdef XK_ecircumflex + if(test("XK_ecircumflex", XK_ecircumflex, 0xEA) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_ecircumflex"); + FAIL; +#endif + +#ifdef XK_ediaeresis + if(test("XK_ediaeresis", XK_ediaeresis, 0xEB) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_ediaeresis"); + FAIL; +#endif + +#ifdef XK_igrave + if(test("XK_igrave", XK_igrave, 0xEC) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_igrave"); + FAIL; +#endif + +#ifdef XK_iacute + if(test("XK_iacute", XK_iacute, 0xED) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_iacute"); + FAIL; +#endif + +#ifdef XK_icircumflex + if(test("XK_icircumflex", XK_icircumflex, 0xEE) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_icircumflex"); + FAIL; +#endif + +#ifdef XK_idiaeresis + if(test("XK_idiaeresis", XK_idiaeresis, 0xEF) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_idiaeresis"); + FAIL; +#endif + +#ifdef XK_eth + if(test("XK_eth", XK_eth, 0xF0) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_eth"); + FAIL; +#endif + +#ifdef XK_ntilde + if(test("XK_ntilde", XK_ntilde, 0xF1) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_ntilde"); + FAIL; +#endif + +#ifdef XK_ograve + if(test("XK_ograve", XK_ograve, 0xF2) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_ograve"); + FAIL; +#endif + +#ifdef XK_oacute + if(test("XK_oacute", XK_oacute, 0xF3) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_oacute"); + FAIL; +#endif + +#ifdef XK_ocircumflex + if(test("XK_ocircumflex", XK_ocircumflex, 0xF4) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_ocircumflex"); + FAIL; +#endif + +#ifdef XK_otilde + if(test("XK_otilde", XK_otilde, 0xF5) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_otilde"); + FAIL; +#endif + +#ifdef XK_odiaeresis + if(test("XK_odiaeresis", XK_odiaeresis, 0xF6) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_odiaeresis"); + FAIL; +#endif + +#ifdef XK_division + if(test("XK_division", XK_division, 0xF7) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_division"); + FAIL; +#endif + +#ifdef XK_oslash + if(test("XK_oslash", XK_oslash, 0xF8) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_oslash"); + FAIL; +#endif + +#ifdef XK_ugrave + if(test("XK_ugrave", XK_ugrave, 0xF9) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_ugrave"); + FAIL; +#endif + +#ifdef XK_uacute + if(test("XK_uacute", XK_uacute, 0xFA) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_uacute"); + FAIL; +#endif + +#ifdef XK_ucircumflex + if(test("XK_ucircumflex", XK_ucircumflex, 0xFB) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_ucircumflex"); + FAIL; +#endif + +#ifdef XK_udiaeresis + if(test("XK_udiaeresis", XK_udiaeresis, 0xFC) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_udiaeresis"); + FAIL; +#endif + +#ifdef XK_yacute + if(test("XK_yacute", XK_yacute, 0xFD) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_yacute"); + FAIL; +#endif + +#ifdef XK_thorn + if(test("XK_thorn", XK_thorn, 0xFE) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_thorn"); + FAIL; +#endif + +#ifdef XK_ydiaeresis + if(test("XK_ydiaeresis", XK_ydiaeresis, 0xFF) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_ydiaeresis"); + FAIL; +#endif + + + CHECKPASS(195); +} diff --git a/xts5/Xopen/keysym/Test2.c b/xts5/Xopen/keysym/Test2.c new file mode 100644 index 00000000..96dc639c --- /dev/null +++ b/xts5/Xopen/keysym/Test2.c @@ -0,0 +1,694 @@ +/* +Copyright (c) 2005 X.Org Foundation L.L.C. + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies +of the Software, and to permit persons to whom the Software is furnished to do +so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. +*/ +/* +* $Header: /cvs/xtest/xtest/xts5/tset/Xopen/keysym/Test2.c,v 1.2 2005-11-03 08:44:00 jmichael Exp $ +* +* Project: VSW5 +* +* File: xts5/tset/Xopen/keysym/Test2.c +* +* Description: +* Tests for keysym() +* +* Modifications: +* $Log: Test2.c,v $ +* Revision 1.2 2005-11-03 08:44:00 jmichael +* clean up all vsw5 paths to use xts5 instead. +* +* Revision 1.1.1.2 2005/04/15 14:05:40 anderson +* Reimport of the base with the legal name in the copyright fixed. +* +* Revision 8.0 1998/12/23 23:35:31 mar +* Branch point for Release 5.0.2 +* +* Revision 7.0 1998/10/30 22:58:01 mar +* Branch point for Release 5.0.2b1 +* +* Revision 6.0 1998/03/02 05:26:45 tbr +* Branch point for Release 5.0.1 +* +* Revision 5.0 1998/01/26 03:23:19 tbr +* Branch point for Release 5.0.1b1 +* +* Revision 4.1 1996/05/09 21:14:55 andy +* Fixed X includes +* +* Revision 4.0 1995/12/15 09:13:28 tbr +* Branch point for Release 5.0.0 +* +* Revision 3.1 1995/12/15 01:16:43 andy +* Prepare for GA Release +* +*/ +/* + * SCCS: @(#) Test2.c Rel 1.1 (11/28/91) + * + * UniSoft Ltd., London, England + * + * (C) Copyright 1991 X/Open Company Limited + * + * All rights reserved. No part of this source code may be reproduced, + * stored in a retrieval system, or transmitted, in any form or by any + * means, electronic, mechanical, photocopying, recording or otherwise, + * except as stated in the end-user licence agreement, without the prior + * permission of the copyright owners. + * + * X/Open and the 'X' symbol are trademarks of X/Open Company Limited in + * the UK and other countries. + */ + +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif + +#include <stdlib.h> +#include "xtest.h" +#include "X11/Xlib.h" +#include "X11/Xutil.h" +#include "X11/Xresource.h" +#include "tet_api.h" +#include "xtestlib.h" +#include "pixval.h" + +extern char *TestName; + +static int +test(name, val, aval) +char *name; +int val; +int aval; +{ + + if(val != aval) { + report("KeySym \"%s\" is defined to have value 0x%x instead of 0x%x.", name, val, aval); + return(0); + } + return(1); +} + + + +static void +reporterr(s) +char *s; +{ + report("Keysym \"%s\" is not defined.", s); +} + +#include <X11/keysym.h> + +kysym2() +{ +int pass = 0, fail = 0; +#ifdef XK_Aogonek + if(test("XK_Aogonek", XK_Aogonek, 0x1A1) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Aogonek"); + FAIL; +#endif + +#ifdef XK_breve + if(test("XK_breve", XK_breve, 0x1A2) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_breve"); + FAIL; +#endif + +#ifdef XK_Lstroke + if(test("XK_Lstroke", XK_Lstroke, 0x1A3) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Lstroke"); + FAIL; +#endif + +#ifdef XK_Lcaron + if(test("XK_Lcaron", XK_Lcaron, 0x1A5) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Lcaron"); + FAIL; +#endif + +#ifdef XK_Sacute + if(test("XK_Sacute", XK_Sacute, 0x1A6) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Sacute"); + FAIL; +#endif + +#ifdef XK_Scaron + if(test("XK_Scaron", XK_Scaron, 0x1A9) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Scaron"); + FAIL; +#endif + +#ifdef XK_Scedilla + if(test("XK_Scedilla", XK_Scedilla, 0x1AA) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Scedilla"); + FAIL; +#endif + +#ifdef XK_Tcaron + if(test("XK_Tcaron", XK_Tcaron, 0x1AB) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Tcaron"); + FAIL; +#endif + +#ifdef XK_Zacute + if(test("XK_Zacute", XK_Zacute, 0x1AC) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Zacute"); + FAIL; +#endif + +#ifdef XK_Zcaron + if(test("XK_Zcaron", XK_Zcaron, 0x1AE) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Zcaron"); + FAIL; +#endif + +#ifdef XK_Zabovedot + if(test("XK_Zabovedot", XK_Zabovedot, 0x1AF) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Zabovedot"); + FAIL; +#endif + +#ifdef XK_aogonek + if(test("XK_aogonek", XK_aogonek, 0x1B1) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_aogonek"); + FAIL; +#endif + +#ifdef XK_ogonek + if(test("XK_ogonek", XK_ogonek, 0x1B2) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_ogonek"); + FAIL; +#endif + +#ifdef XK_lstroke + if(test("XK_lstroke", XK_lstroke, 0x1B3) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_lstroke"); + FAIL; +#endif + +#ifdef XK_lcaron + if(test("XK_lcaron", XK_lcaron, 0x1B5) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_lcaron"); + FAIL; +#endif + +#ifdef XK_sacute + if(test("XK_sacute", XK_sacute, 0x1B6) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_sacute"); + FAIL; +#endif + +#ifdef XK_caron + if(test("XK_caron", XK_caron, 0x1B7) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_caron"); + FAIL; +#endif + +#ifdef XK_scaron + if(test("XK_scaron", XK_scaron, 0x1B9) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_scaron"); + FAIL; +#endif + +#ifdef XK_scedilla + if(test("XK_scedilla", XK_scedilla, 0x1BA) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_scedilla"); + FAIL; +#endif + +#ifdef XK_tcaron + if(test("XK_tcaron", XK_tcaron, 0x1BB) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_tcaron"); + FAIL; +#endif + +#ifdef XK_zacute + if(test("XK_zacute", XK_zacute, 0x1BC) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_zacute"); + FAIL; +#endif + +#ifdef XK_doubleacute + if(test("XK_doubleacute", XK_doubleacute, 0x1BD) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_doubleacute"); + FAIL; +#endif + +#ifdef XK_zcaron + if(test("XK_zcaron", XK_zcaron, 0x1BE) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_zcaron"); + FAIL; +#endif + +#ifdef XK_zabovedot + if(test("XK_zabovedot", XK_zabovedot, 0x1BF) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_zabovedot"); + FAIL; +#endif + +#ifdef XK_Racute + if(test("XK_Racute", XK_Racute, 0x1C0) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Racute"); + FAIL; +#endif + +#ifdef XK_Abreve + if(test("XK_Abreve", XK_Abreve, 0x1C3) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Abreve"); + FAIL; +#endif + +#ifdef XK_Lacute + if(test("XK_Lacute", XK_Lacute, 0x1C5) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Lacute"); + FAIL; +#endif + +#ifdef XK_Cacute + if(test("XK_Cacute", XK_Cacute, 0x1C6) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Cacute"); + FAIL; +#endif + +#ifdef XK_Ccaron + if(test("XK_Ccaron", XK_Ccaron, 0x1C8) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Ccaron"); + FAIL; +#endif + +#ifdef XK_Eogonek + if(test("XK_Eogonek", XK_Eogonek, 0x1CA) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Eogonek"); + FAIL; +#endif + +#ifdef XK_Ecaron + if(test("XK_Ecaron", XK_Ecaron, 0x1CC) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Ecaron"); + FAIL; +#endif + +#ifdef XK_Dcaron + if(test("XK_Dcaron", XK_Dcaron, 0x1CF) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Dcaron"); + FAIL; +#endif + +#ifdef XK_Dstroke + if(test("XK_Dstroke", XK_Dstroke, 0x1D0) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Dstroke"); + FAIL; +#endif + +#ifdef XK_Nacute + if(test("XK_Nacute", XK_Nacute, 0x1D1) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Nacute"); + FAIL; +#endif + +#ifdef XK_Ncaron + if(test("XK_Ncaron", XK_Ncaron, 0x1D2) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Ncaron"); + FAIL; +#endif + +#ifdef XK_Odoubleacute + if(test("XK_Odoubleacute", XK_Odoubleacute, 0x1D5) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Odoubleacute"); + FAIL; +#endif + +#ifdef XK_Rcaron + if(test("XK_Rcaron", XK_Rcaron, 0x1D8) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Rcaron"); + FAIL; +#endif + +#ifdef XK_Uring + if(test("XK_Uring", XK_Uring, 0x1D9) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Uring"); + FAIL; +#endif + +#ifdef XK_Udoubleacute + if(test("XK_Udoubleacute", XK_Udoubleacute, 0x1DB) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Udoubleacute"); + FAIL; +#endif + +#ifdef XK_Tcedilla + if(test("XK_Tcedilla", XK_Tcedilla, 0x1DE) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Tcedilla"); + FAIL; +#endif + +#ifdef XK_racute + if(test("XK_racute", XK_racute, 0x1E0) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_racute"); + FAIL; +#endif + +#ifdef XK_abreve + if(test("XK_abreve", XK_abreve, 0x1E3) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_abreve"); + FAIL; +#endif + +#ifdef XK_lacute + if(test("XK_lacute", XK_lacute, 0x1E5) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_lacute"); + FAIL; +#endif + +#ifdef XK_cacute + if(test("XK_cacute", XK_cacute, 0x1E6) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_cacute"); + FAIL; +#endif + +#ifdef XK_ccaron + if(test("XK_ccaron", XK_ccaron, 0x1E8) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_ccaron"); + FAIL; +#endif + +#ifdef XK_eogonek + if(test("XK_eogonek", XK_eogonek, 0x1EA) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_eogonek"); + FAIL; +#endif + +#ifdef XK_ecaron + if(test("XK_ecaron", XK_ecaron, 0x1EC) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_ecaron"); + FAIL; +#endif + +#ifdef XK_dcaron + if(test("XK_dcaron", XK_dcaron, 0x1EF) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_dcaron"); + FAIL; +#endif + +#ifdef XK_dstroke + if(test("XK_dstroke", XK_dstroke, 0x1F0) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_dstroke"); + FAIL; +#endif + +#ifdef XK_nacute + if(test("XK_nacute", XK_nacute, 0x1F1) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_nacute"); + FAIL; +#endif + +#ifdef XK_ncaron + if(test("XK_ncaron", XK_ncaron, 0x1F2) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_ncaron"); + FAIL; +#endif + +#ifdef XK_odoubleacute + if(test("XK_odoubleacute", XK_odoubleacute, 0x1F5) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_odoubleacute"); + FAIL; +#endif + +#ifdef XK_rcaron + if(test("XK_rcaron", XK_rcaron, 0x1F8) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_rcaron"); + FAIL; +#endif + +#ifdef XK_uring + if(test("XK_uring", XK_uring, 0x1F9) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_uring"); + FAIL; +#endif + +#ifdef XK_udoubleacute + if(test("XK_udoubleacute", XK_udoubleacute, 0x1FB) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_udoubleacute"); + FAIL; +#endif + +#ifdef XK_tcedilla + if(test("XK_tcedilla", XK_tcedilla, 0x1FE) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_tcedilla"); + FAIL; +#endif + +#ifdef XK_abovedot + if(test("XK_abovedot", XK_abovedot, 0x1FF) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_abovedot"); + FAIL; +#endif + + + CHECKPASS(57); +} diff --git a/xts5/Xopen/keysym/Test3.c b/xts5/Xopen/keysym/Test3.c new file mode 100644 index 00000000..61f2fe70 --- /dev/null +++ b/xts5/Xopen/keysym/Test3.c @@ -0,0 +1,344 @@ +/* +Copyright (c) 2005 X.Org Foundation L.L.C. + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies +of the Software, and to permit persons to whom the Software is furnished to do +so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. +*/ +/* +* $Header: /cvs/xtest/xtest/xts5/tset/Xopen/keysym/Test3.c,v 1.2 2005-11-03 08:44:00 jmichael Exp $ +* +* Project: VSW5 +* +* File: xts5/tset/Xopen/keysym/Test3.c +* +* Description: +* Tests for keysym() +* +* Modifications: +* $Log: Test3.c,v $ +* Revision 1.2 2005-11-03 08:44:00 jmichael +* clean up all vsw5 paths to use xts5 instead. +* +* Revision 1.1.1.2 2005/04/15 14:05:40 anderson +* Reimport of the base with the legal name in the copyright fixed. +* +* Revision 8.0 1998/12/23 23:35:32 mar +* Branch point for Release 5.0.2 +* +* Revision 7.0 1998/10/30 22:58:01 mar +* Branch point for Release 5.0.2b1 +* +* Revision 6.0 1998/03/02 05:26:46 tbr +* Branch point for Release 5.0.1 +* +* Revision 5.0 1998/01/26 03:23:19 tbr +* Branch point for Release 5.0.1b1 +* +* Revision 4.1 1996/05/09 21:14:55 andy +* Fixed X includes +* +* Revision 4.0 1995/12/15 09:13:30 tbr +* Branch point for Release 5.0.0 +* +* Revision 3.1 1995/12/15 01:16:45 andy +* Prepare for GA Release +* +*/ +/* + * SCCS: @(#) Test3.c Rel 1.1 (11/28/91) + * + * UniSoft Ltd., London, England + * + * (C) Copyright 1991 X/Open Company Limited + * + * All rights reserved. No part of this source code may be reproduced, + * stored in a retrieval system, or transmitted, in any form or by any + * means, electronic, mechanical, photocopying, recording or otherwise, + * except as stated in the end-user licence agreement, without the prior + * permission of the copyright owners. + * + * X/Open and the 'X' symbol are trademarks of X/Open Company Limited in + * the UK and other countries. + */ + +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif + +#include <stdlib.h> +#include "xtest.h" +#include "X11/Xlib.h" +#include "X11/Xutil.h" +#include "X11/Xresource.h" +#include "tet_api.h" +#include "xtestlib.h" +#include "pixval.h" + +extern char *TestName; + +static int +test(name, val, aval) +char *name; +int val; +int aval; +{ + + if(val != aval) { + report("KeySym \"%s\" is defined to have value 0x%x instead of 0x%x.", name, val, aval); + return(0); + } + return(1); +} + + + +static void +reporterr(s) +char *s; +{ + report("Keysym \"%s\" is not defined.", s); +} + +#include <X11/keysym.h> + +kysym3() +{ +int pass = 0, fail = 0; +#ifdef XK_Hstroke + if(test("XK_Hstroke", XK_Hstroke, 0x2A1) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Hstroke"); + FAIL; +#endif + +#ifdef XK_Hcircumflex + if(test("XK_Hcircumflex", XK_Hcircumflex, 0x2A6) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Hcircumflex"); + FAIL; +#endif + +#ifdef XK_Iabovedot + if(test("XK_Iabovedot", XK_Iabovedot, 0x2A9) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Iabovedot"); + FAIL; +#endif + +#ifdef XK_Gbreve + if(test("XK_Gbreve", XK_Gbreve, 0x2AB) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Gbreve"); + FAIL; +#endif + +#ifdef XK_Jcircumflex + if(test("XK_Jcircumflex", XK_Jcircumflex, 0x2AC) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Jcircumflex"); + FAIL; +#endif + +#ifdef XK_hstroke + if(test("XK_hstroke", XK_hstroke, 0x2B1) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_hstroke"); + FAIL; +#endif + +#ifdef XK_hcircumflex + if(test("XK_hcircumflex", XK_hcircumflex, 0x2B6) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_hcircumflex"); + FAIL; +#endif + +#ifdef XK_idotless + if(test("XK_idotless", XK_idotless, 0x2B9) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_idotless"); + FAIL; +#endif + +#ifdef XK_gbreve + if(test("XK_gbreve", XK_gbreve, 0x2BB) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_gbreve"); + FAIL; +#endif + +#ifdef XK_jcircumflex + if(test("XK_jcircumflex", XK_jcircumflex, 0x2BC) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_jcircumflex"); + FAIL; +#endif + +#ifdef XK_Cabovedot + if(test("XK_Cabovedot", XK_Cabovedot, 0x2C5) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Cabovedot"); + FAIL; +#endif + +#ifdef XK_Ccircumflex + if(test("XK_Ccircumflex", XK_Ccircumflex, 0x2C6) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Ccircumflex"); + FAIL; +#endif + +#ifdef XK_Gabovedot + if(test("XK_Gabovedot", XK_Gabovedot, 0x2D5) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Gabovedot"); + FAIL; +#endif + +#ifdef XK_Gcircumflex + if(test("XK_Gcircumflex", XK_Gcircumflex, 0x2D8) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Gcircumflex"); + FAIL; +#endif + +#ifdef XK_Ubreve + if(test("XK_Ubreve", XK_Ubreve, 0x2DD) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Ubreve"); + FAIL; +#endif + +#ifdef XK_Scircumflex + if(test("XK_Scircumflex", XK_Scircumflex, 0x2DE) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Scircumflex"); + FAIL; +#endif + +#ifdef XK_cabovedot + if(test("XK_cabovedot", XK_cabovedot, 0x2E5) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_cabovedot"); + FAIL; +#endif + +#ifdef XK_ccircumflex + if(test("XK_ccircumflex", XK_ccircumflex, 0x2E6) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_ccircumflex"); + FAIL; +#endif + +#ifdef XK_gabovedot + if(test("XK_gabovedot", XK_gabovedot, 0x2F5) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_gabovedot"); + FAIL; +#endif + +#ifdef XK_gcircumflex + if(test("XK_gcircumflex", XK_gcircumflex, 0x2F8) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_gcircumflex"); + FAIL; +#endif + +#ifdef XK_ubreve + if(test("XK_ubreve", XK_ubreve, 0x2FD) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_ubreve"); + FAIL; +#endif + +#ifdef XK_scircumflex + if(test("XK_scircumflex", XK_scircumflex, 0x2FE) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_scircumflex"); + FAIL; +#endif + + + CHECKPASS(22); +} diff --git a/xts5/Xopen/keysym/Test4.c b/xts5/Xopen/keysym/Test4.c new file mode 100644 index 00000000..aaeb634e --- /dev/null +++ b/xts5/Xopen/keysym/Test4.c @@ -0,0 +1,484 @@ +/* +Copyright (c) 2005 X.Org Foundation L.L.C. + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies +of the Software, and to permit persons to whom the Software is furnished to do +so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. +*/ +/* +* $Header: /cvs/xtest/xtest/xts5/tset/Xopen/keysym/Test4.c,v 1.2 2005-11-03 08:44:00 jmichael Exp $ +* +* Project: VSW5 +* +* File: xts5/tset/Xopen/keysym/Test4.c +* +* Description: +* Tests for keysym() +* +* Modifications: +* $Log: Test4.c,v $ +* Revision 1.2 2005-11-03 08:44:00 jmichael +* clean up all vsw5 paths to use xts5 instead. +* +* Revision 1.1.1.2 2005/04/15 14:05:40 anderson +* Reimport of the base with the legal name in the copyright fixed. +* +* Revision 8.0 1998/12/23 23:35:32 mar +* Branch point for Release 5.0.2 +* +* Revision 7.0 1998/10/30 22:58:02 mar +* Branch point for Release 5.0.2b1 +* +* Revision 6.0 1998/03/02 05:26:46 tbr +* Branch point for Release 5.0.1 +* +* Revision 5.0 1998/01/26 03:23:20 tbr +* Branch point for Release 5.0.1b1 +* +* Revision 4.1 1996/05/09 21:14:55 andy +* Fixed X includes +* +* Revision 4.0 1995/12/15 09:13:31 tbr +* Branch point for Release 5.0.0 +* +* Revision 3.1 1995/12/15 01:16:46 andy +* Prepare for GA Release +* +*/ +/* + * SCCS: @(#) Test4.c Rel 1.1 (11/28/91) + * + * UniSoft Ltd., London, England + * + * (C) Copyright 1991 X/Open Company Limited + * + * All rights reserved. No part of this source code may be reproduced, + * stored in a retrieval system, or transmitted, in any form or by any + * means, electronic, mechanical, photocopying, recording or otherwise, + * except as stated in the end-user licence agreement, without the prior + * permission of the copyright owners. + * + * X/Open and the 'X' symbol are trademarks of X/Open Company Limited in + * the UK and other countries. + */ + +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif + +#include <stdlib.h> +#include "xtest.h" +#include "X11/Xlib.h" +#include "X11/Xutil.h" +#include "X11/Xresource.h" +#include "tet_api.h" +#include "xtestlib.h" +#include "pixval.h" + +extern char *TestName; + +static int +test(name, val, aval) +char *name; +int val; +int aval; +{ + + if(val != aval) { + report("KeySym \"%s\" is defined to have value 0x%x instead of 0x%x.", name, val, aval); + return(0); + } + return(1); +} + + + +static void +reporterr(s) +char *s; +{ + report("Keysym \"%s\" is not defined.", s); +} + +#include <X11/keysym.h> + +kysym4() +{ +int pass = 0, fail = 0; +#ifdef XK_kra + if(test("XK_kra", XK_kra, 0x3A2) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_kra"); + FAIL; +#endif + +#ifdef XK_kappa + if(test("XK_kappa", XK_kappa, 0x3A2) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_kappa"); + FAIL; +#endif + +#ifdef XK_Rcedilla + if(test("XK_Rcedilla", XK_Rcedilla, 0x3A3) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Rcedilla"); + FAIL; +#endif + +#ifdef XK_Itilde + if(test("XK_Itilde", XK_Itilde, 0x3A5) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Itilde"); + FAIL; +#endif + +#ifdef XK_Lcedilla + if(test("XK_Lcedilla", XK_Lcedilla, 0x3A6) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Lcedilla"); + FAIL; +#endif + +#ifdef XK_Emacron + if(test("XK_Emacron", XK_Emacron, 0x3AA) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Emacron"); + FAIL; +#endif + +#ifdef XK_Gcedilla + if(test("XK_Gcedilla", XK_Gcedilla, 0x3AB) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Gcedilla"); + FAIL; +#endif + +#ifdef XK_Tslash + if(test("XK_Tslash", XK_Tslash, 0x3AC) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Tslash"); + FAIL; +#endif + +#ifdef XK_rcedilla + if(test("XK_rcedilla", XK_rcedilla, 0x3B3) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_rcedilla"); + FAIL; +#endif + +#ifdef XK_itilde + if(test("XK_itilde", XK_itilde, 0x3B5) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_itilde"); + FAIL; +#endif + +#ifdef XK_lcedilla + if(test("XK_lcedilla", XK_lcedilla, 0x3B6) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_lcedilla"); + FAIL; +#endif + +#ifdef XK_emacron + if(test("XK_emacron", XK_emacron, 0x3BA) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_emacron"); + FAIL; +#endif + +#ifdef XK_gcedilla + if(test("XK_gcedilla", XK_gcedilla, 0x3BB) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_gcedilla"); + FAIL; +#endif + +#ifdef XK_tslash + if(test("XK_tslash", XK_tslash, 0x3BC) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_tslash"); + FAIL; +#endif + +#ifdef XK_ENG + if(test("XK_ENG", XK_ENG, 0x3BD) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_ENG"); + FAIL; +#endif + +#ifdef XK_eng + if(test("XK_eng", XK_eng, 0x3BF) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_eng"); + FAIL; +#endif + +#ifdef XK_Amacron + if(test("XK_Amacron", XK_Amacron, 0x3C0) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Amacron"); + FAIL; +#endif + +#ifdef XK_Iogonek + if(test("XK_Iogonek", XK_Iogonek, 0x3C7) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Iogonek"); + FAIL; +#endif + +#ifdef XK_Eabovedot + if(test("XK_Eabovedot", XK_Eabovedot, 0x3CC) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Eabovedot"); + FAIL; +#endif + +#ifdef XK_Imacron + if(test("XK_Imacron", XK_Imacron, 0x3CF) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Imacron"); + FAIL; +#endif + +#ifdef XK_Ncedilla + if(test("XK_Ncedilla", XK_Ncedilla, 0x3D1) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Ncedilla"); + FAIL; +#endif + +#ifdef XK_Omacron + if(test("XK_Omacron", XK_Omacron, 0x3D2) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Omacron"); + FAIL; +#endif + +#ifdef XK_Kcedilla + if(test("XK_Kcedilla", XK_Kcedilla, 0x3D3) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Kcedilla"); + FAIL; +#endif + +#ifdef XK_Uogonek + if(test("XK_Uogonek", XK_Uogonek, 0x3D9) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Uogonek"); + FAIL; +#endif + +#ifdef XK_Utilde + if(test("XK_Utilde", XK_Utilde, 0x3DD) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Utilde"); + FAIL; +#endif + +#ifdef XK_Umacron + if(test("XK_Umacron", XK_Umacron, 0x3DE) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Umacron"); + FAIL; +#endif + +#ifdef XK_amacron + if(test("XK_amacron", XK_amacron, 0x3E0) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_amacron"); + FAIL; +#endif + +#ifdef XK_iogonek + if(test("XK_iogonek", XK_iogonek, 0x3E7) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_iogonek"); + FAIL; +#endif + +#ifdef XK_eabovedot + if(test("XK_eabovedot", XK_eabovedot, 0x3EC) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_eabovedot"); + FAIL; +#endif + +#ifdef XK_imacron + if(test("XK_imacron", XK_imacron, 0x3EF) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_imacron"); + FAIL; +#endif + +#ifdef XK_ncedilla + if(test("XK_ncedilla", XK_ncedilla, 0x3F1) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_ncedilla"); + FAIL; +#endif + +#ifdef XK_omacron + if(test("XK_omacron", XK_omacron, 0x3F2) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_omacron"); + FAIL; +#endif + +#ifdef XK_kcedilla + if(test("XK_kcedilla", XK_kcedilla, 0x3F3) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_kcedilla"); + FAIL; +#endif + +#ifdef XK_uogonek + if(test("XK_uogonek", XK_uogonek, 0x3F9) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_uogonek"); + FAIL; +#endif + +#ifdef XK_utilde + if(test("XK_utilde", XK_utilde, 0x3FD) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_utilde"); + FAIL; +#endif + +#ifdef XK_umacron + if(test("XK_umacron", XK_umacron, 0x3FE) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_umacron"); + FAIL; +#endif + + + CHECKPASS(36); +} diff --git a/xts5/Xopen/keysym/TestG.c b/xts5/Xopen/keysym/TestG.c new file mode 100644 index 00000000..9b45e33a --- /dev/null +++ b/xts5/Xopen/keysym/TestG.c @@ -0,0 +1,864 @@ +/* +Copyright (c) 2005 X.Org Foundation L.L.C. + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies +of the Software, and to permit persons to whom the Software is furnished to do +so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. +*/ +/* +* $Header: /cvs/xtest/xtest/xts5/tset/Xopen/keysym/TestG.c,v 1.2 2005-11-03 08:44:00 jmichael Exp $ +* +* Project: VSW5 +* +* File: xts5/tset/Xopen/keysym/TestG.c +* +* Description: +* Tests for keysym() +* +* Modifications: +* $Log: TestG.c,v $ +* Revision 1.2 2005-11-03 08:44:00 jmichael +* clean up all vsw5 paths to use xts5 instead. +* +* Revision 1.1.1.2 2005/04/15 14:05:40 anderson +* Reimport of the base with the legal name in the copyright fixed. +* +* Revision 8.0 1998/12/23 23:35:33 mar +* Branch point for Release 5.0.2 +* +* Revision 7.0 1998/10/30 22:58:04 mar +* Branch point for Release 5.0.2b1 +* +* Revision 6.0 1998/03/02 05:26:47 tbr +* Branch point for Release 5.0.1 +* +* Revision 5.0 1998/01/26 03:23:20 tbr +* Branch point for Release 5.0.1b1 +* +* Revision 4.1 1996/05/09 21:14:55 andy +* Fixed X includes +* +* Revision 4.0 1995/12/15 09:13:32 tbr +* Branch point for Release 5.0.0 +* +* Revision 3.1 1995/12/15 01:16:48 andy +* Prepare for GA Release +* +*/ +/* + * SCCS: @(#) TestG.c Rel 1.1 (11/28/91) + * + * UniSoft Ltd., London, England + * + * (C) Copyright 1991 X/Open Company Limited + * + * All rights reserved. No part of this source code may be reproduced, + * stored in a retrieval system, or transmitted, in any form or by any + * means, electronic, mechanical, photocopying, recording or otherwise, + * except as stated in the end-user licence agreement, without the prior + * permission of the copyright owners. + * + * X/Open and the 'X' symbol are trademarks of X/Open Company Limited in + * the UK and other countries. + */ + +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif + +#include <stdlib.h> +#include "xtest.h" +#include "X11/Xlib.h" +#include "X11/Xutil.h" +#include "X11/Xresource.h" +#include "tet_api.h" +#include "xtestlib.h" +#include "pixval.h" + +extern char *TestName; + +static int +test(name, val, aval) +char *name; +int val; +int aval; +{ + + if(val != aval) { + report("KeySym \"%s\" is defined to have value 0x%x instead of 0x%x.", name, val, aval); + return(0); + } + return(1); +} + + + +static void +reporterr(s) +char *s; +{ + report("Keysym \"%s\" is not defined.", s); +} + +#include <X11/keysym.h> + +kysymG() +{ +int pass = 0, fail = 0; +#ifdef XK_Greek_ALPHAaccent + if(test("XK_Greek_ALPHAaccent", XK_Greek_ALPHAaccent, 0x7A1) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_ALPHAaccent"); + FAIL; +#endif + +#ifdef XK_Greek_EPSILONaccent + if(test("XK_Greek_EPSILONaccent", XK_Greek_EPSILONaccent, 0x7A2) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_EPSILONaccent"); + FAIL; +#endif + +#ifdef XK_Greek_ETAaccent + if(test("XK_Greek_ETAaccent", XK_Greek_ETAaccent, 0x7A3) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_ETAaccent"); + FAIL; +#endif + +#ifdef XK_Greek_IOTAaccent + if(test("XK_Greek_IOTAaccent", XK_Greek_IOTAaccent, 0x7A4) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_IOTAaccent"); + FAIL; +#endif + +#ifdef XK_Greek_IOTAdiaeresis + if(test("XK_Greek_IOTAdiaeresis", XK_Greek_IOTAdiaeresis, 0x7A5) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_IOTAdiaeresis"); + FAIL; +#endif + +#ifdef XK_Greek_OMICRONaccent + if(test("XK_Greek_OMICRONaccent", XK_Greek_OMICRONaccent, 0x7A7) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_OMICRONaccent"); + FAIL; +#endif + +#ifdef XK_Greek_UPSILONaccent + if(test("XK_Greek_UPSILONaccent", XK_Greek_UPSILONaccent, 0x7A8) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_UPSILONaccent"); + FAIL; +#endif + +#ifdef XK_Greek_UPSILONdieresis + if(test("XK_Greek_UPSILONdieresis", XK_Greek_UPSILONdieresis, 0x7A9) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_UPSILONdieresis"); + FAIL; +#endif + +#ifdef XK_Greek_OMEGAaccent + if(test("XK_Greek_OMEGAaccent", XK_Greek_OMEGAaccent, 0x7AB) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_OMEGAaccent"); + FAIL; +#endif + +#ifdef XK_Greek_accentdieresis + if(test("XK_Greek_accentdieresis", XK_Greek_accentdieresis, 0x7AE) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_accentdieresis"); + FAIL; +#endif + +#ifdef XK_Greek_horizbar + if(test("XK_Greek_horizbar", XK_Greek_horizbar, 0x7AF) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_horizbar"); + FAIL; +#endif + +#ifdef XK_Greek_alphaaccent + if(test("XK_Greek_alphaaccent", XK_Greek_alphaaccent, 0x7B1) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_alphaaccent"); + FAIL; +#endif + +#ifdef XK_Greek_epsilonaccent + if(test("XK_Greek_epsilonaccent", XK_Greek_epsilonaccent, 0x7B2) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_epsilonaccent"); + FAIL; +#endif + +#ifdef XK_Greek_etaaccent + if(test("XK_Greek_etaaccent", XK_Greek_etaaccent, 0x7B3) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_etaaccent"); + FAIL; +#endif + +#ifdef XK_Greek_iotaaccent + if(test("XK_Greek_iotaaccent", XK_Greek_iotaaccent, 0x7B4) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_iotaaccent"); + FAIL; +#endif + +#ifdef XK_Greek_iotadieresis + if(test("XK_Greek_iotadieresis", XK_Greek_iotadieresis, 0x7B5) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_iotadieresis"); + FAIL; +#endif + +#ifdef XK_Greek_iotaaccentdieresis + if(test("XK_Greek_iotaaccentdieresis", XK_Greek_iotaaccentdieresis, 0x7B6) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_iotaaccentdieresis"); + FAIL; +#endif + +#ifdef XK_Greek_omicronaccent + if(test("XK_Greek_omicronaccent", XK_Greek_omicronaccent, 0x7B7) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_omicronaccent"); + FAIL; +#endif + +#ifdef XK_Greek_upsilonaccent + if(test("XK_Greek_upsilonaccent", XK_Greek_upsilonaccent, 0x7B8) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_upsilonaccent"); + FAIL; +#endif + +#ifdef XK_Greek_upsilondieresis + if(test("XK_Greek_upsilondieresis", XK_Greek_upsilondieresis, 0x7B9) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_upsilondieresis"); + FAIL; +#endif + +#ifdef XK_Greek_upsilonaccentdieresis + if(test("XK_Greek_upsilonaccentdieresis", XK_Greek_upsilonaccentdieresis, 0x7BA) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_upsilonaccentdieresis"); + FAIL; +#endif + +#ifdef XK_Greek_omegaaccent + if(test("XK_Greek_omegaaccent", XK_Greek_omegaaccent, 0x7BB) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_omegaaccent"); + FAIL; +#endif + +#ifdef XK_Greek_ALPHA + if(test("XK_Greek_ALPHA", XK_Greek_ALPHA, 0x7C1) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_ALPHA"); + FAIL; +#endif + +#ifdef XK_Greek_BETA + if(test("XK_Greek_BETA", XK_Greek_BETA, 0x7C2) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_BETA"); + FAIL; +#endif + +#ifdef XK_Greek_GAMMA + if(test("XK_Greek_GAMMA", XK_Greek_GAMMA, 0x7C3) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_GAMMA"); + FAIL; +#endif + +#ifdef XK_Greek_DELTA + if(test("XK_Greek_DELTA", XK_Greek_DELTA, 0x7C4) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_DELTA"); + FAIL; +#endif + +#ifdef XK_Greek_EPSILON + if(test("XK_Greek_EPSILON", XK_Greek_EPSILON, 0x7C5) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_EPSILON"); + FAIL; +#endif + +#ifdef XK_Greek_ZETA + if(test("XK_Greek_ZETA", XK_Greek_ZETA, 0x7C6) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_ZETA"); + FAIL; +#endif + +#ifdef XK_Greek_ETA + if(test("XK_Greek_ETA", XK_Greek_ETA, 0x7C7) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_ETA"); + FAIL; +#endif + +#ifdef XK_Greek_THETA + if(test("XK_Greek_THETA", XK_Greek_THETA, 0x7C8) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_THETA"); + FAIL; +#endif + +#ifdef XK_Greek_IOTA + if(test("XK_Greek_IOTA", XK_Greek_IOTA, 0x7C9) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_IOTA"); + FAIL; +#endif + +#ifdef XK_Greek_KAPPA + if(test("XK_Greek_KAPPA", XK_Greek_KAPPA, 0x7CA) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_KAPPA"); + FAIL; +#endif + +#ifdef XK_Greek_LAMBDA + if(test("XK_Greek_LAMBDA", XK_Greek_LAMBDA, 0x7CB) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_LAMBDA"); + FAIL; +#endif + +#ifdef XK_Greek_LAMDA + if(test("XK_Greek_LAMDA", XK_Greek_LAMDA, 0x7CB) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_LAMDA"); + FAIL; +#endif + +#ifdef XK_Greek_MU + if(test("XK_Greek_MU", XK_Greek_MU, 0x7CC) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_MU"); + FAIL; +#endif + +#ifdef XK_Greek_NU + if(test("XK_Greek_NU", XK_Greek_NU, 0x7CD) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_NU"); + FAIL; +#endif + +#ifdef XK_Greek_XI + if(test("XK_Greek_XI", XK_Greek_XI, 0x7CE) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_XI"); + FAIL; +#endif + +#ifdef XK_Greek_OMICRON + if(test("XK_Greek_OMICRON", XK_Greek_OMICRON, 0x7CF) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_OMICRON"); + FAIL; +#endif + +#ifdef XK_Greek_PI + if(test("XK_Greek_PI", XK_Greek_PI, 0x7D0) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_PI"); + FAIL; +#endif + +#ifdef XK_Greek_RHO + if(test("XK_Greek_RHO", XK_Greek_RHO, 0x7D1) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_RHO"); + FAIL; +#endif + +#ifdef XK_Greek_SIGMA + if(test("XK_Greek_SIGMA", XK_Greek_SIGMA, 0x7D2) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_SIGMA"); + FAIL; +#endif + +#ifdef XK_Greek_TAU + if(test("XK_Greek_TAU", XK_Greek_TAU, 0x7D4) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_TAU"); + FAIL; +#endif + +#ifdef XK_Greek_UPSILON + if(test("XK_Greek_UPSILON", XK_Greek_UPSILON, 0x7D5) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_UPSILON"); + FAIL; +#endif + +#ifdef XK_Greek_PHI + if(test("XK_Greek_PHI", XK_Greek_PHI, 0x7D6) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_PHI"); + FAIL; +#endif + +#ifdef XK_Greek_CHI + if(test("XK_Greek_CHI", XK_Greek_CHI, 0x7D7) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_CHI"); + FAIL; +#endif + +#ifdef XK_Greek_PSI + if(test("XK_Greek_PSI", XK_Greek_PSI, 0x7D8) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_PSI"); + FAIL; +#endif + +#ifdef XK_Greek_OMEGA + if(test("XK_Greek_OMEGA", XK_Greek_OMEGA, 0x7D9) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_OMEGA"); + FAIL; +#endif + +#ifdef XK_Greek_alpha + if(test("XK_Greek_alpha", XK_Greek_alpha, 0x7E1) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_alpha"); + FAIL; +#endif + +#ifdef XK_Greek_beta + if(test("XK_Greek_beta", XK_Greek_beta, 0x7E2) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_beta"); + FAIL; +#endif + +#ifdef XK_Greek_gamma + if(test("XK_Greek_gamma", XK_Greek_gamma, 0x7E3) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_gamma"); + FAIL; +#endif + +#ifdef XK_Greek_delta + if(test("XK_Greek_delta", XK_Greek_delta, 0x7E4) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_delta"); + FAIL; +#endif + +#ifdef XK_Greek_epsilon + if(test("XK_Greek_epsilon", XK_Greek_epsilon, 0x7E5) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_epsilon"); + FAIL; +#endif + +#ifdef XK_Greek_zeta + if(test("XK_Greek_zeta", XK_Greek_zeta, 0x7E6) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_zeta"); + FAIL; +#endif + +#ifdef XK_Greek_eta + if(test("XK_Greek_eta", XK_Greek_eta, 0x7E7) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_eta"); + FAIL; +#endif + +#ifdef XK_Greek_theta + if(test("XK_Greek_theta", XK_Greek_theta, 0x7E8) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_theta"); + FAIL; +#endif + +#ifdef XK_Greek_iota + if(test("XK_Greek_iota", XK_Greek_iota, 0x7E9) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_iota"); + FAIL; +#endif + +#ifdef XK_Greek_kappa + if(test("XK_Greek_kappa", XK_Greek_kappa, 0x7EA) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_kappa"); + FAIL; +#endif + +#ifdef XK_Greek_lambda + if(test("XK_Greek_lambda", XK_Greek_lambda, 0x7EB) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_lambda"); + FAIL; +#endif + +#ifdef XK_Greek_lamda + if(test("XK_Greek_lamda", XK_Greek_lamda, 0x7EB) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_lamda"); + FAIL; +#endif + +#ifdef XK_Greek_mu + if(test("XK_Greek_mu", XK_Greek_mu, 0x7EC) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_mu"); + FAIL; +#endif + +#ifdef XK_Greek_nu + if(test("XK_Greek_nu", XK_Greek_nu, 0x7ED) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_nu"); + FAIL; +#endif + +#ifdef XK_Greek_xi + if(test("XK_Greek_xi", XK_Greek_xi, 0x7EE) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_xi"); + FAIL; +#endif + +#ifdef XK_Greek_omicron + if(test("XK_Greek_omicron", XK_Greek_omicron, 0x7EF) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_omicron"); + FAIL; +#endif + +#ifdef XK_Greek_pi + if(test("XK_Greek_pi", XK_Greek_pi, 0x7F0) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_pi"); + FAIL; +#endif + +#ifdef XK_Greek_rho + if(test("XK_Greek_rho", XK_Greek_rho, 0x7F1) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_rho"); + FAIL; +#endif + +#ifdef XK_Greek_sigma + if(test("XK_Greek_sigma", XK_Greek_sigma, 0x7F2) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_sigma"); + FAIL; +#endif + +#ifdef XK_Greek_finalsmallsigma + if(test("XK_Greek_finalsmallsigma", XK_Greek_finalsmallsigma, 0x7F3) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_finalsmallsigma"); + FAIL; +#endif + +#ifdef XK_Greek_tau + if(test("XK_Greek_tau", XK_Greek_tau, 0x7F4) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_tau"); + FAIL; +#endif + +#ifdef XK_Greek_upsilon + if(test("XK_Greek_upsilon", XK_Greek_upsilon, 0x7F5) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_upsilon"); + FAIL; +#endif + +#ifdef XK_Greek_phi + if(test("XK_Greek_phi", XK_Greek_phi, 0x7F6) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_phi"); + FAIL; +#endif + +#ifdef XK_Greek_chi + if(test("XK_Greek_chi", XK_Greek_chi, 0x7F7) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_chi"); + FAIL; +#endif + +#ifdef XK_Greek_psi + if(test("XK_Greek_psi", XK_Greek_psi, 0x7F8) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_psi"); + FAIL; +#endif + +#ifdef XK_Greek_omega + if(test("XK_Greek_omega", XK_Greek_omega, 0x7F9) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_omega"); + FAIL; +#endif + +#ifdef XK_Greek_switch + if(test("XK_Greek_switch", XK_Greek_switch, 0xFF7E) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_switch"); + FAIL; +#endif + + + CHECKPASS(74); +} diff --git a/xts5/Xopen/keysym/TestM.c b/xts5/Xopen/keysym/TestM.c new file mode 100644 index 00000000..c6e0f847 --- /dev/null +++ b/xts5/Xopen/keysym/TestM.c @@ -0,0 +1,1604 @@ +/* +Copyright (c) 2005 X.Org Foundation L.L.C. + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies +of the Software, and to permit persons to whom the Software is furnished to do +so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. +*/ +/* +* $Header: /cvs/xtest/xtest/xts5/tset/Xopen/keysym/TestM.c,v 1.2 2005-11-03 08:44:00 jmichael Exp $ +* +* Project: VSW5 +* +* File: xts5/tset/Xopen/keysym/TestM.c +* +* Description: +* Tests for keysym() +* +* Modifications: +* $Log: TestM.c,v $ +* Revision 1.2 2005-11-03 08:44:00 jmichael +* clean up all vsw5 paths to use xts5 instead. +* +* Revision 1.1.1.2 2005/04/15 14:05:40 anderson +* Reimport of the base with the legal name in the copyright fixed. +* +* Revision 8.0 1998/12/23 23:35:33 mar +* Branch point for Release 5.0.2 +* +* Revision 7.0 1998/10/30 22:58:06 mar +* Branch point for Release 5.0.2b1 +* +* Revision 6.0 1998/03/02 05:26:47 tbr +* Branch point for Release 5.0.1 +* +* Revision 5.0 1998/01/26 03:23:21 tbr +* Branch point for Release 5.0.1b1 +* +* Revision 4.1 1996/05/09 21:14:55 andy +* Fixed X includes +* +* Revision 4.0 1995/12/15 09:13:34 tbr +* Branch point for Release 5.0.0 +* +* Revision 3.1 1995/12/15 01:16:50 andy +* Prepare for GA Release +* +*/ +/* + * SCCS: @(#) TestM.c Rel 1.1 (11/28/91) + * + * UniSoft Ltd., London, England + * + * (C) Copyright 1991 X/Open Company Limited + * + * All rights reserved. No part of this source code may be reproduced, + * stored in a retrieval system, or transmitted, in any form or by any + * means, electronic, mechanical, photocopying, recording or otherwise, + * except as stated in the end-user licence agreement, without the prior + * permission of the copyright owners. + * + * X/Open and the 'X' symbol are trademarks of X/Open Company Limited in + * the UK and other countries. + */ + +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif + +#include <stdlib.h> +#include "xtest.h" +#include "X11/Xlib.h" +#include "X11/Xutil.h" +#include "X11/Xresource.h" +#include "tet_api.h" +#include "xtestlib.h" +#include "pixval.h" + +extern char *TestName; + +static int +test(name, val, aval) +char *name; +int val; +int aval; +{ + + if(val != aval) { + report("KeySym \"%s\" is defined to have value 0x%x instead of 0x%x.", name, val, aval); + return(0); + } + return(1); +} + + + +static void +reporterr(s) +char *s; +{ + report("Keysym \"%s\" is not defined.", s); +} + +#include <X11/keysym.h> + +kysymM() +{ +int pass = 0, fail = 0; +#ifdef XK_BackSpace + if(test("XK_BackSpace", XK_BackSpace, 0xFF08) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_BackSpace"); + FAIL; +#endif + +#ifdef XK_Tab + if(test("XK_Tab", XK_Tab, 0xFF09) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Tab"); + FAIL; +#endif + +#ifdef XK_Linefeed + if(test("XK_Linefeed", XK_Linefeed, 0xFF0A) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Linefeed"); + FAIL; +#endif + +#ifdef XK_Clear + if(test("XK_Clear", XK_Clear, 0xFF0B) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Clear"); + FAIL; +#endif + +#ifdef XK_Return + if(test("XK_Return", XK_Return, 0xFF0D) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Return"); + FAIL; +#endif + +#ifdef XK_Pause + if(test("XK_Pause", XK_Pause, 0xFF13) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Pause"); + FAIL; +#endif + +#ifdef XK_Scroll_Lock + if(test("XK_Scroll_Lock", XK_Scroll_Lock, 0xFF14) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Scroll_Lock"); + FAIL; +#endif + +#ifdef XK_Escape + if(test("XK_Escape", XK_Escape, 0xFF1B) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Escape"); + FAIL; +#endif + +#ifdef XK_Multi_key + if(test("XK_Multi_key", XK_Multi_key, 0xFF20) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Multi_key"); + FAIL; +#endif + +#ifdef XK_Kanji + if(test("XK_Kanji", XK_Kanji, 0xFF21) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Kanji"); + FAIL; +#endif + +#ifdef XK_Muhenkan + if(test("XK_Muhenkan", XK_Muhenkan, 0xFF22) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Muhenkan"); + FAIL; +#endif + +#ifdef XK_Henkan + if(test("XK_Henkan", XK_Henkan, 0xFF23) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Henkan"); + FAIL; +#endif + +#ifdef XK_Henkan_Mode + if(test("XK_Henkan_Mode", XK_Henkan_Mode, 0xFF23) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Henkan_Mode"); + FAIL; +#endif + +#ifdef XK_Romaji + if(test("XK_Romaji", XK_Romaji, 0xFF24) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Romaji"); + FAIL; +#endif + +#ifdef XK_Hiragana + if(test("XK_Hiragana", XK_Hiragana, 0xFF25) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Hiragana"); + FAIL; +#endif + +#ifdef XK_Katakana + if(test("XK_Katakana", XK_Katakana, 0xFF26) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Katakana"); + FAIL; +#endif + +#ifdef XK_Hiragana_Katakana + if(test("XK_Hiragana_Katakana", XK_Hiragana_Katakana, 0xFF27) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Hiragana_Katakana"); + FAIL; +#endif + +#ifdef XK_Zenkaku + if(test("XK_Zenkaku", XK_Zenkaku, 0xFF28) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Zenkaku"); + FAIL; +#endif + +#ifdef XK_Hankaku + if(test("XK_Hankaku", XK_Hankaku, 0xFF29) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Hankaku"); + FAIL; +#endif + +#ifdef XK_Zenkaku_Hankaku + if(test("XK_Zenkaku_Hankaku", XK_Zenkaku_Hankaku, 0xFF2A) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Zenkaku_Hankaku"); + FAIL; +#endif + +#ifdef XK_Touroku + if(test("XK_Touroku", XK_Touroku, 0xFF2B) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Touroku"); + FAIL; +#endif + +#ifdef XK_Massyo + if(test("XK_Massyo", XK_Massyo, 0xFF2C) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Massyo"); + FAIL; +#endif + +#ifdef XK_Kana_Lock + if(test("XK_Kana_Lock", XK_Kana_Lock, 0xFF2D) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Kana_Lock"); + FAIL; +#endif + +#ifdef XK_Kana_Shift + if(test("XK_Kana_Shift", XK_Kana_Shift, 0xFF2E) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Kana_Shift"); + FAIL; +#endif + +#ifdef XK_Eisu_Shift + if(test("XK_Eisu_Shift", XK_Eisu_Shift, 0xFF2F) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Eisu_Shift"); + FAIL; +#endif + +#ifdef XK_Eisu_toggle + if(test("XK_Eisu_toggle", XK_Eisu_toggle, 0xFF30) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Eisu_toggle"); + FAIL; +#endif + +#ifdef XK_Home + if(test("XK_Home", XK_Home, 0xFF50) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Home"); + FAIL; +#endif + +#ifdef XK_Left + if(test("XK_Left", XK_Left, 0xFF51) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Left"); + FAIL; +#endif + +#ifdef XK_Up + if(test("XK_Up", XK_Up, 0xFF52) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Up"); + FAIL; +#endif + +#ifdef XK_Right + if(test("XK_Right", XK_Right, 0xFF53) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Right"); + FAIL; +#endif + +#ifdef XK_Down + if(test("XK_Down", XK_Down, 0xFF54) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Down"); + FAIL; +#endif + +#ifdef XK_Prior + if(test("XK_Prior", XK_Prior, 0xFF55) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Prior"); + FAIL; +#endif + +#ifdef XK_Next + if(test("XK_Next", XK_Next, 0xFF56) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Next"); + FAIL; +#endif + +#ifdef XK_End + if(test("XK_End", XK_End, 0xFF57) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_End"); + FAIL; +#endif + +#ifdef XK_Begin + if(test("XK_Begin", XK_Begin, 0xFF58) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Begin"); + FAIL; +#endif + +#ifdef XK_Select + if(test("XK_Select", XK_Select, 0xFF60) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Select"); + FAIL; +#endif + +#ifdef XK_Print + if(test("XK_Print", XK_Print, 0xFF61) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Print"); + FAIL; +#endif + +#ifdef XK_Execute + if(test("XK_Execute", XK_Execute, 0xFF62) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Execute"); + FAIL; +#endif + +#ifdef XK_Insert + if(test("XK_Insert", XK_Insert, 0xFF63) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Insert"); + FAIL; +#endif + +#ifdef XK_Undo + if(test("XK_Undo", XK_Undo, 0xFF65) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Undo"); + FAIL; +#endif + +#ifdef XK_Redo + if(test("XK_Redo", XK_Redo, 0xFF66) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Redo"); + FAIL; +#endif + +#ifdef XK_Menu + if(test("XK_Menu", XK_Menu, 0xFF67) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Menu"); + FAIL; +#endif + +#ifdef XK_Find + if(test("XK_Find", XK_Find, 0xFF68) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Find"); + FAIL; +#endif + +#ifdef XK_Cancel + if(test("XK_Cancel", XK_Cancel, 0xFF69) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Cancel"); + FAIL; +#endif + +#ifdef XK_Help + if(test("XK_Help", XK_Help, 0xFF6A) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Help"); + FAIL; +#endif + +#ifdef XK_Break + if(test("XK_Break", XK_Break, 0xFF6B) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Break"); + FAIL; +#endif + +#ifdef XK_Mode_switch + if(test("XK_Mode_switch", XK_Mode_switch, 0xFF7E) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Mode_switch"); + FAIL; +#endif + +#ifdef XK_script_switch + if(test("XK_script_switch", XK_script_switch, 0xFF7E) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_script_switch"); + FAIL; +#endif + +#ifdef XK_Num_Lock + if(test("XK_Num_Lock", XK_Num_Lock, 0xFF7F) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Num_Lock"); + FAIL; +#endif + +#ifdef XK_KP_Space + if(test("XK_KP_Space", XK_KP_Space, 0xFF80) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_KP_Space"); + FAIL; +#endif + +#ifdef XK_KP_Tab + if(test("XK_KP_Tab", XK_KP_Tab, 0xFF89) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_KP_Tab"); + FAIL; +#endif + +#ifdef XK_KP_Enter + if(test("XK_KP_Enter", XK_KP_Enter, 0xFF8D) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_KP_Enter"); + FAIL; +#endif + +#ifdef XK_KP_F1 + if(test("XK_KP_F1", XK_KP_F1, 0xFF91) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_KP_F1"); + FAIL; +#endif + +#ifdef XK_KP_F2 + if(test("XK_KP_F2", XK_KP_F2, 0xFF92) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_KP_F2"); + FAIL; +#endif + +#ifdef XK_KP_F3 + if(test("XK_KP_F3", XK_KP_F3, 0xFF93) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_KP_F3"); + FAIL; +#endif + +#ifdef XK_KP_F4 + if(test("XK_KP_F4", XK_KP_F4, 0xFF94) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_KP_F4"); + FAIL; +#endif + +#ifdef XK_KP_Multiply + if(test("XK_KP_Multiply", XK_KP_Multiply, 0xFFAA) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_KP_Multiply"); + FAIL; +#endif + +#ifdef XK_KP_Add + if(test("XK_KP_Add", XK_KP_Add, 0xFFAB) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_KP_Add"); + FAIL; +#endif + +#ifdef XK_KP_Separator + if(test("XK_KP_Separator", XK_KP_Separator, 0xFFAC) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_KP_Separator"); + FAIL; +#endif + +#ifdef XK_KP_Subtract + if(test("XK_KP_Subtract", XK_KP_Subtract, 0xFFAD) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_KP_Subtract"); + FAIL; +#endif + +#ifdef XK_KP_Decimal + if(test("XK_KP_Decimal", XK_KP_Decimal, 0xFFAE) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_KP_Decimal"); + FAIL; +#endif + +#ifdef XK_KP_Divide + if(test("XK_KP_Divide", XK_KP_Divide, 0xFFAF) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_KP_Divide"); + FAIL; +#endif + +#ifdef XK_KP_0 + if(test("XK_KP_0", XK_KP_0, 0xFFB0) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_KP_0"); + FAIL; +#endif + +#ifdef XK_KP_1 + if(test("XK_KP_1", XK_KP_1, 0xFFB1) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_KP_1"); + FAIL; +#endif + +#ifdef XK_KP_2 + if(test("XK_KP_2", XK_KP_2, 0xFFB2) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_KP_2"); + FAIL; +#endif + +#ifdef XK_KP_3 + if(test("XK_KP_3", XK_KP_3, 0xFFB3) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_KP_3"); + FAIL; +#endif + +#ifdef XK_KP_4 + if(test("XK_KP_4", XK_KP_4, 0xFFB4) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_KP_4"); + FAIL; +#endif + +#ifdef XK_KP_5 + if(test("XK_KP_5", XK_KP_5, 0xFFB5) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_KP_5"); + FAIL; +#endif + +#ifdef XK_KP_6 + if(test("XK_KP_6", XK_KP_6, 0xFFB6) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_KP_6"); + FAIL; +#endif + +#ifdef XK_KP_7 + if(test("XK_KP_7", XK_KP_7, 0xFFB7) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_KP_7"); + FAIL; +#endif + +#ifdef XK_KP_8 + if(test("XK_KP_8", XK_KP_8, 0xFFB8) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_KP_8"); + FAIL; +#endif + +#ifdef XK_KP_9 + if(test("XK_KP_9", XK_KP_9, 0xFFB9) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_KP_9"); + FAIL; +#endif + +#ifdef XK_KP_Equal + if(test("XK_KP_Equal", XK_KP_Equal, 0xFFBD) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_KP_Equal"); + FAIL; +#endif + +#ifdef XK_F1 + if(test("XK_F1", XK_F1, 0xFFBE) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_F1"); + FAIL; +#endif + +#ifdef XK_F2 + if(test("XK_F2", XK_F2, 0xFFBF) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_F2"); + FAIL; +#endif + +#ifdef XK_F3 + if(test("XK_F3", XK_F3, 0xFFC0) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_F3"); + FAIL; +#endif + +#ifdef XK_F4 + if(test("XK_F4", XK_F4, 0xFFC1) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_F4"); + FAIL; +#endif + +#ifdef XK_F5 + if(test("XK_F5", XK_F5, 0xFFC2) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_F5"); + FAIL; +#endif + +#ifdef XK_F6 + if(test("XK_F6", XK_F6, 0xFFC3) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_F6"); + FAIL; +#endif + +#ifdef XK_F7 + if(test("XK_F7", XK_F7, 0xFFC4) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_F7"); + FAIL; +#endif + +#ifdef XK_F8 + if(test("XK_F8", XK_F8, 0xFFC5) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_F8"); + FAIL; +#endif + +#ifdef XK_F9 + if(test("XK_F9", XK_F9, 0xFFC6) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_F9"); + FAIL; +#endif + +#ifdef XK_F10 + if(test("XK_F10", XK_F10, 0xFFC7) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_F10"); + FAIL; +#endif + +#ifdef XK_F11 + if(test("XK_F11", XK_F11, 0xFFC8) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_F11"); + FAIL; +#endif + +#ifdef XK_L1 + if(test("XK_L1", XK_L1, 0xFFC8) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_L1"); + FAIL; +#endif + +#ifdef XK_F12 + if(test("XK_F12", XK_F12, 0xFFC9) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_F12"); + FAIL; +#endif + +#ifdef XK_L2 + if(test("XK_L2", XK_L2, 0xFFC9) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_L2"); + FAIL; +#endif + +#ifdef XK_F13 + if(test("XK_F13", XK_F13, 0xFFCA) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_F13"); + FAIL; +#endif + +#ifdef XK_L3 + if(test("XK_L3", XK_L3, 0xFFCA) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_L3"); + FAIL; +#endif + +#ifdef XK_F14 + if(test("XK_F14", XK_F14, 0xFFCB) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_F14"); + FAIL; +#endif + +#ifdef XK_L4 + if(test("XK_L4", XK_L4, 0xFFCB) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_L4"); + FAIL; +#endif + +#ifdef XK_F15 + if(test("XK_F15", XK_F15, 0xFFCC) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_F15"); + FAIL; +#endif + +#ifdef XK_L5 + if(test("XK_L5", XK_L5, 0xFFCC) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_L5"); + FAIL; +#endif + +#ifdef XK_F16 + if(test("XK_F16", XK_F16, 0xFFCD) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_F16"); + FAIL; +#endif + +#ifdef XK_L6 + if(test("XK_L6", XK_L6, 0xFFCD) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_L6"); + FAIL; +#endif + +#ifdef XK_F17 + if(test("XK_F17", XK_F17, 0xFFCE) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_F17"); + FAIL; +#endif + +#ifdef XK_L7 + if(test("XK_L7", XK_L7, 0xFFCE) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_L7"); + FAIL; +#endif + +#ifdef XK_F18 + if(test("XK_F18", XK_F18, 0xFFCF) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_F18"); + FAIL; +#endif + +#ifdef XK_L8 + if(test("XK_L8", XK_L8, 0xFFCF) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_L8"); + FAIL; +#endif + +#ifdef XK_F19 + if(test("XK_F19", XK_F19, 0xFFD0) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_F19"); + FAIL; +#endif + +#ifdef XK_L9 + if(test("XK_L9", XK_L9, 0xFFD0) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_L9"); + FAIL; +#endif + +#ifdef XK_F20 + if(test("XK_F20", XK_F20, 0xFFD1) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_F20"); + FAIL; +#endif + +#ifdef XK_L10 + if(test("XK_L10", XK_L10, 0xFFD1) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_L10"); + FAIL; +#endif + +#ifdef XK_F21 + if(test("XK_F21", XK_F21, 0xFFD2) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_F21"); + FAIL; +#endif + +#ifdef XK_R1 + if(test("XK_R1", XK_R1, 0xFFD2) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_R1"); + FAIL; +#endif + +#ifdef XK_F22 + if(test("XK_F22", XK_F22, 0xFFD3) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_F22"); + FAIL; +#endif + +#ifdef XK_R2 + if(test("XK_R2", XK_R2, 0xFFD3) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_R2"); + FAIL; +#endif + +#ifdef XK_F23 + if(test("XK_F23", XK_F23, 0xFFD4) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_F23"); + FAIL; +#endif + +#ifdef XK_R3 + if(test("XK_R3", XK_R3, 0xFFD4) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_R3"); + FAIL; +#endif + +#ifdef XK_F24 + if(test("XK_F24", XK_F24, 0xFFD5) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_F24"); + FAIL; +#endif + +#ifdef XK_R4 + if(test("XK_R4", XK_R4, 0xFFD5) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_R4"); + FAIL; +#endif + +#ifdef XK_F25 + if(test("XK_F25", XK_F25, 0xFFD6) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_F25"); + FAIL; +#endif + +#ifdef XK_R5 + if(test("XK_R5", XK_R5, 0xFFD6) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_R5"); + FAIL; +#endif + +#ifdef XK_F26 + if(test("XK_F26", XK_F26, 0xFFD7) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_F26"); + FAIL; +#endif + +#ifdef XK_R6 + if(test("XK_R6", XK_R6, 0xFFD7) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_R6"); + FAIL; +#endif + +#ifdef XK_F27 + if(test("XK_F27", XK_F27, 0xFFD8) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_F27"); + FAIL; +#endif + +#ifdef XK_R7 + if(test("XK_R7", XK_R7, 0xFFD8) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_R7"); + FAIL; +#endif + +#ifdef XK_F28 + if(test("XK_F28", XK_F28, 0xFFD9) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_F28"); + FAIL; +#endif + +#ifdef XK_R8 + if(test("XK_R8", XK_R8, 0xFFD9) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_R8"); + FAIL; +#endif + +#ifdef XK_F29 + if(test("XK_F29", XK_F29, 0xFFDA) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_F29"); + FAIL; +#endif + +#ifdef XK_R9 + if(test("XK_R9", XK_R9, 0xFFDA) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_R9"); + FAIL; +#endif + +#ifdef XK_F30 + if(test("XK_F30", XK_F30, 0xFFDB) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_F30"); + FAIL; +#endif + +#ifdef XK_R10 + if(test("XK_R10", XK_R10, 0xFFDB) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_R10"); + FAIL; +#endif + +#ifdef XK_F31 + if(test("XK_F31", XK_F31, 0xFFDC) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_F31"); + FAIL; +#endif + +#ifdef XK_R11 + if(test("XK_R11", XK_R11, 0xFFDC) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_R11"); + FAIL; +#endif + +#ifdef XK_F32 + if(test("XK_F32", XK_F32, 0xFFDD) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_F32"); + FAIL; +#endif + +#ifdef XK_R12 + if(test("XK_R12", XK_R12, 0xFFDD) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_R12"); + FAIL; +#endif + +#ifdef XK_F33 + if(test("XK_F33", XK_F33, 0xFFDE) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_F33"); + FAIL; +#endif + +#ifdef XK_R13 + if(test("XK_R13", XK_R13, 0xFFDE) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_R13"); + FAIL; +#endif + +#ifdef XK_F34 + if(test("XK_F34", XK_F34, 0xFFDF) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_F34"); + FAIL; +#endif + +#ifdef XK_R14 + if(test("XK_R14", XK_R14, 0xFFDF) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_R14"); + FAIL; +#endif + +#ifdef XK_F35 + if(test("XK_F35", XK_F35, 0xFFE0) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_F35"); + FAIL; +#endif + +#ifdef XK_R15 + if(test("XK_R15", XK_R15, 0xFFE0) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_R15"); + FAIL; +#endif + +#ifdef XK_Shift_L + if(test("XK_Shift_L", XK_Shift_L, 0xFFE1) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Shift_L"); + FAIL; +#endif + +#ifdef XK_Shift_R + if(test("XK_Shift_R", XK_Shift_R, 0xFFE2) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Shift_R"); + FAIL; +#endif + +#ifdef XK_Control_L + if(test("XK_Control_L", XK_Control_L, 0xFFE3) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Control_L"); + FAIL; +#endif + +#ifdef XK_Control_R + if(test("XK_Control_R", XK_Control_R, 0xFFE4) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Control_R"); + FAIL; +#endif + +#ifdef XK_Caps_Lock + if(test("XK_Caps_Lock", XK_Caps_Lock, 0xFFE5) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Caps_Lock"); + FAIL; +#endif + +#ifdef XK_Shift_Lock + if(test("XK_Shift_Lock", XK_Shift_Lock, 0xFFE6) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Shift_Lock"); + FAIL; +#endif + +#ifdef XK_Meta_L + if(test("XK_Meta_L", XK_Meta_L, 0xFFE7) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Meta_L"); + FAIL; +#endif + +#ifdef XK_Meta_R + if(test("XK_Meta_R", XK_Meta_R, 0xFFE8) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Meta_R"); + FAIL; +#endif + +#ifdef XK_Alt_L + if(test("XK_Alt_L", XK_Alt_L, 0xFFE9) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Alt_L"); + FAIL; +#endif + +#ifdef XK_Alt_R + if(test("XK_Alt_R", XK_Alt_R, 0xFFEA) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Alt_R"); + FAIL; +#endif + +#ifdef XK_Super_L + if(test("XK_Super_L", XK_Super_L, 0xFFEB) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Super_L"); + FAIL; +#endif + +#ifdef XK_Super_R + if(test("XK_Super_R", XK_Super_R, 0xFFEC) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Super_R"); + FAIL; +#endif + +#ifdef XK_Hyper_L + if(test("XK_Hyper_L", XK_Hyper_L, 0xFFED) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Hyper_L"); + FAIL; +#endif + +#ifdef XK_Hyper_R + if(test("XK_Hyper_R", XK_Hyper_R, 0xFFEE) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Hyper_R"); + FAIL; +#endif + +#ifdef XK_Delete + if(test("XK_Delete", XK_Delete, 0xFFFF) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Delete"); + FAIL; +#endif + + + CHECKPASS(148); +} diff --git a/xts5/Xopen/keysym/keysym.m b/xts5/Xopen/keysym/keysym.m new file mode 100644 index 00000000..1280c4ee --- /dev/null +++ b/xts5/Xopen/keysym/keysym.m @@ -0,0 +1,702 @@ +Copyright (c) 2005 X.Org Foundation L.L.C. + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies +of the Software, and to permit persons to whom the Software is furnished to do +so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. +$Header: /cvs/xtest/xtest/xts5/tset/Xopen/keysym/keysym.m,v 1.2 2005-11-03 08:44:00 jmichael Exp $ + +>># Project: VSW5 +>># +>># File: xts5/tset/Xopen/keysym/keysym.m +>># +>># Description: +>># Tests for keysym() +>># +>># Modifications: +>># $Log: kysym.m,v $ +>># Revision 1.2 2005-11-03 08:44:00 jmichael +>># clean up all vsw5 paths to use xts5 instead. +>># +>># Revision 1.1.1.2 2005/04/15 14:05:40 anderson +>># Reimport of the base with the legal name in the copyright fixed. +>># +>># Revision 8.0 1998/12/23 23:35:34 mar +>># Branch point for Release 5.0.2 +>># +>># Revision 7.0 1998/10/30 22:58:07 mar +>># Branch point for Release 5.0.2b1 +>># +>># Revision 6.0 1998/03/02 05:26:48 tbr +>># Branch point for Release 5.0.1 +>># +>># Revision 5.0 1998/01/26 03:23:22 tbr +>># Branch point for Release 5.0.1b1 +>># +>># Revision 4.0 1995/12/15 09:13:36 tbr +>># Branch point for Release 5.0.0 +>># +>># Revision 3.1 1995/12/15 01:16:53 andy +>># Prepare for GA Release +>># +/* + * SCCS: @(#) kysym.m Rel 1.11 (5/12/92) + * + * UniSoft Ltd., London, England + * + * (C) Copyright 1991 X/Open Company Limited + * + * All rights reserved. No part of this source code may be reproduced, + * stored in a retrieval system, or transmitted, in any form or by any + * means, electronic, mechanical, photocopying, recording or otherwise, + * except as stated in the end-user licence agreement, without the prior + * permission of the copyright owners. + * + * X/Open and the 'X' symbol are trademarks of X/Open Company Limited in + * the UK and other countries. + */ +>>TITLE keysym Xopen +>>CFILES Test0.c Test1.c Test2.c Test3.c Test4.c TestG.c TestM.c +>>ASSERTION Good A +When the header file <X11/keysym.h> is included, +then the symbols in the table which have code 1 +are defined to have the hexadecimal values given in the table. +.tL "Code" "Value" "Name" +.tL "1" "20" "XK_space" +.tL "1" "21" "XK_exclam" +.tL "1" "22" "XK_quotedbl" +.tL "1" "23" "XK_numbersign" +.tL "1" "24" "XK_dollar" +.tL "1" "25" "XK_percent" +.tL "1" "26" "XK_ampersand" +.tL "1" "27" "XK_apostrophe" +.tL "1" "27" "XK_quoteright" +.tL "1" "28" "XK_parenleft" +.tL "1" "29" "XK_parenright" +.tL "1" "2A" "XK_asterisk" +.tL "1" "2B" "XK_plus" +.tL "1" "2C" "XK_comma" +.tL "1" "2D" "XK_minus" +.tL "1" "2E" "XK_period" +.tL "1" "2F" "XK_slash" +.tL "1" "30" "XK_0" +.tL "1" "31" "XK_1" +.tL "1" "32" "XK_2" +.tL "1" "33" "XK_3" +.tL "1" "34" "XK_4" +.tL "1" "35" "XK_5" +.tL "1" "36" "XK_6" +.tL "1" "37" "XK_7" +.tL "1" "38" "XK_8" +.tL "1" "39" "XK_9" +.tL "1" "3A" "XK_colon" +.tL "1" "3B" "XK_semicolon" +.tL "1" "3C" "XK_less" +.tL "1" "3D" "XK_equal" +.tL "1" "3E" "XK_greater" +.tL "1" "3F" "XK_question" +.tL "1" "40" "XK_at" +.tL "1" "41" "XK_A" +.tL "1" "42" "XK_B" +.tL "1" "43" "XK_C" +.tL "1" "44" "XK_D" +.tL "1" "45" "XK_E" +.tL "1" "46" "XK_F" +.tL "1" "47" "XK_G" +.tL "1" "48" "XK_H" +.tL "1" "49" "XK_I" +.tL "1" "4A" "XK_J" +.tL "1" "4B" "XK_K" +.tL "1" "4C" "XK_L" +.tL "1" "4D" "XK_M" +.tL "1" "4E" "XK_N" +.tL "1" "4F" "XK_O" +.tL "1" "50" "XK_P" +.tL "1" "51" "XK_Q" +.tL "1" "52" "XK_R" +.tL "1" "53" "XK_S" +.tL "1" "54" "XK_T" +.tL "1" "55" "XK_U" +.tL "1" "56" "XK_V" +.tL "1" "57" "XK_W" +.tL "1" "58" "XK_X" +.tL "1" "59" "XK_Y" +.tL "1" "5A" "XK_Z" +.tL "1" "5B" "XK_bracketleft" +.tL "1" "5C" "XK_backslash" +.tL "1" "5D" "XK_bracketright" +.tL "1" "5E" "XK_asciicircum" +.tL "1" "5F" "XK_underscore" +.tL "1" "60" "XK_grave" +.tL "1" "60" "XK_quoteleft" +.tL "1" "61" "XK_a" +.tL "1" "62" "XK_b" +.tL "1" "63" "XK_c" +.tL "1" "64" "XK_d" +.tL "1" "65" "XK_e" +.tL "1" "66" "XK_f" +.tL "1" "67" "XK_g" +.tL "1" "68" "XK_h" +.tL "1" "69" "XK_i" +.tL "1" "6A" "XK_j" +.tL "1" "6B" "XK_k" +.tL "1" "6C" "XK_l" +.tL "1" "6D" "XK_m" +.tL "1" "6E" "XK_n" +.tL "1" "6F" "XK_o" +.tL "1" "70" "XK_p" +.tL "1" "71" "XK_q" +.tL "1" "72" "XK_r" +.tL "1" "73" "XK_s" +.tL "1" "74" "XK_t" +.tL "1" "75" "XK_u" +.tL "1" "76" "XK_v" +.tL "1" "77" "XK_w" +.tL "1" "78" "XK_x" +.tL "1" "79" "XK_y" +.tL "1" "7A" "XK_z" +.tL "1" "7B" "XK_braceleft" +.tL "1" "7C" "XK_bar" +.tL "1" "7D" "XK_braceright" +.tL "1" "7E" "XK_asciitilde" +.tL "1" "A0" "XK_nobreakspace" +.tL "1" "A1" "XK_exclamdown" +.tL "1" "A2" "XK_cent" +.tL "1" "A3" "XK_sterling" +.tL "1" "A4" "XK_currency" +.tL "1" "A5" "XK_yen" +.tL "1" "A6" "XK_brokenbar" +.tL "1" "A7" "XK_section" +.tL "1" "A8" "XK_diaeresis" +.tL "1" "A9" "XK_copyright" +.tL "1" "AA" "XK_ordfeminine" +.tL "1" "AB" "XK_guillemotleft" +.tL "1" "AC" "XK_notsign" +.tL "1" "AD" "XK_hyphen" +.tL "1" "AE" "XK_registered" +.tL "1" "AF" "XK_macron" +.tL "1" "B0" "XK_degree" +.tL "1" "B1" "XK_plusminus" +.tL "1" "B2" "XK_twosuperior" +.tL "1" "B3" "XK_threesuperior" +.tL "1" "B4" "XK_acute" +.tL "1" "B5" "XK_mu" +.tL "1" "B6" "XK_paragraph" +.tL "1" "B7" "XK_periodcentered" +.tL "1" "B8" "XK_cedilla" +.tL "1" "B9" "XK_onesuperior" +.tL "1" "BA" "XK_masculine" +.tL "1" "BB" "XK_guillemotright" +.tL "1" "BC" "XK_onequarter" +.tL "1" "BD" "XK_onehalf" +.tL "1" "BE" "XK_threequarters" +.tL "1" "BF" "XK_questiondown" +.tL "1" "C0" "XK_Agrave" +.tL "1" "C1" "XK_Aacute" +.tL "1" "C2" "XK_Acircumflex" +.tL "1" "C3" "XK_Atilde" +.tL "1" "C4" "XK_Adiaeresis" +.tL "1" "C5" "XK_Aring" +.tL "1" "C6" "XK_AE" +.tL "1" "C7" "XK_Ccedilla" +.tL "1" "C8" "XK_Egrave" +.tL "1" "C9" "XK_Eacute" +.tL "1" "CA" "XK_Ecircumflex" +.tL "1" "CB" "XK_Ediaeresis" +.tL "1" "CC" "XK_Igrave" +.tL "1" "CD" "XK_Iacute" +.tL "1" "CE" "XK_Icircumflex" +.tL "1" "CF" "XK_Idiaeresis" +.tL "1" "D0" "XK_ETH" +.tL "1" "D0" "XK_Eth" +.tL "1" "D1" "XK_Ntilde" +.tL "1" "D2" "XK_Ograve" +.tL "1" "D3" "XK_Oacute" +.tL "1" "D4" "XK_Ocircumflex" +.tL "1" "D5" "XK_Otilde" +.tL "1" "D6" "XK_Odiaeresis" +.tL "1" "D7" "XK_multiply" +.tL "1" "D8" "XK_Ooblique" +.tL "1" "D9" "XK_Ugrave" +.tL "1" "DA" "XK_Uacute" +.tL "1" "DB" "XK_Ucircumflex" +.tL "1" "DC" "XK_Udiaeresis" +.tL "1" "DD" "XK_Yacute" +.tL "1" "DE" "XK_THORN" +.tL "1" "DE" "XK_Thorn" +.tL "1" "DF" "XK_ssharp" +.tL "1" "E0" "XK_agrave" +.tL "1" "E1" "XK_aacute" +.tL "1" "E2" "XK_acircumflex" +.tL "1" "E3" "XK_atilde" +.tL "1" "E4" "XK_adiaeresis" +.tL "1" "E5" "XK_aring" +.tL "1" "E6" "XK_ae" +.tL "1" "E7" "XK_ccedilla" +.tL "1" "E8" "XK_egrave" +.tL "1" "E9" "XK_eacute" +.tL "1" "EA" "XK_ecircumflex" +.tL "1" "EB" "XK_ediaeresis" +.tL "1" "EC" "XK_igrave" +.tL "1" "ED" "XK_iacute" +.tL "1" "EE" "XK_icircumflex" +.tL "1" "EF" "XK_idiaeresis" +.tL "1" "F0" "XK_eth" +.tL "1" "F1" "XK_ntilde" +.tL "1" "F2" "XK_ograve" +.tL "1" "F3" "XK_oacute" +.tL "1" "F4" "XK_ocircumflex" +.tL "1" "F5" "XK_otilde" +.tL "1" "F6" "XK_odiaeresis" +.tL "1" "F7" "XK_division" +.tL "1" "F8" "XK_oslash" +.tL "1" "F9" "XK_ugrave" +.tL "1" "FA" "XK_uacute" +.tL "1" "FB" "XK_ucircumflex" +.tL "1" "FC" "XK_udiaeresis" +.tL "1" "FD" "XK_yacute" +.tL "1" "FE" "XK_thorn" +.tL "1" "FF" "XK_ydiaeresis" +>>STRATEGY +Include header file <X11/keysym.h> +For each KeySym in table with code 1: + Verify that the symbol is defined using #ifdef. + Verify that the symbol has the expected value using #if. +>>CODE + + kysym1(); + +>>ASSERTION Good A +When the header file <X11/keysym.h> is included, +then the symbols in the table which have code 2 +are defined to have the hexadecimal values given in the table. +.tL "Code" "Value" "Name" +.tL "2" "1A1" "XK_Aogonek" +.tL "2" "1A2" "XK_breve" +.tL "2" "1A3" "XK_Lstroke" +.tL "2" "1A5" "XK_Lcaron" +.tL "2" "1A6" "XK_Sacute" +.tL "2" "1A9" "XK_Scaron" +.tL "2" "1AA" "XK_Scedilla" +.tL "2" "1AB" "XK_Tcaron" +.tL "2" "1AC" "XK_Zacute" +.tL "2" "1AE" "XK_Zcaron" +.tL "2" "1AF" "XK_Zabovedot" +.tL "2" "1B1" "XK_aogonek" +.tL "2" "1B2" "XK_ogonek" +.tL "2" "1B3" "XK_lstroke" +.tL "2" "1B5" "XK_lcaron" +.tL "2" "1B6" "XK_sacute" +.tL "2" "1B7" "XK_caron" +.tL "2" "1B9" "XK_scaron" +.tL "2" "1BA" "XK_scedilla" +.tL "2" "1BB" "XK_tcaron" +.tL "2" "1BC" "XK_zacute" +.tL "2" "1BD" "XK_doubleacute" +.tL "2" "1BE" "XK_zcaron" +.tL "2" "1BF" "XK_zabovedot" +.tL "2" "1C0" "XK_Racute" +.tL "2" "1C3" "XK_Abreve" +.tL "2" "1C5" "XK_Lacute" +.tL "2" "1C6" "XK_Cacute" +.tL "2" "1C8" "XK_Ccaron" +.tL "2" "1CA" "XK_Eogonek" +.tL "2" "1CC" "XK_Ecaron" +.tL "2" "1CF" "XK_Dcaron" +.tL "2" "1D0" "XK_Dstroke" +.tL "2" "1D1" "XK_Nacute" +.tL "2" "1D2" "XK_Ncaron" +.tL "2" "1D5" "XK_Odoubleacute" +.tL "2" "1D8" "XK_Rcaron" +.tL "2" "1D9" "XK_Uring" +.tL "2" "1DB" "XK_Udoubleacute" +.tL "2" "1DE" "XK_Tcedilla" +.tL "2" "1E0" "XK_racute" +.tL "2" "1E3" "XK_abreve" +.tL "2" "1E5" "XK_lacute" +.tL "2" "1E6" "XK_cacute" +.tL "2" "1E8" "XK_ccaron" +.tL "2" "1EA" "XK_eogonek" +.tL "2" "1EC" "XK_ecaron" +.tL "2" "1EF" "XK_dcaron" +.tL "2" "1F0" "XK_dstroke" +.tL "2" "1F1" "XK_nacute" +.tL "2" "1F2" "XK_ncaron" +.tL "2" "1F5" "XK_odoubleacute" +.tL "2" "1F8" "XK_rcaron" +.tL "2" "1F9" "XK_uring" +.tL "2" "1FB" "XK_udoubleacute" +.tL "2" "1FE" "XK_tcedilla" +.tL "2" "1FF" "XK_abovedot" +>>STRATEGY +Include header file <X11/keysym.h> +For each KeySym in table with code 2: + Verify that the symbol is defined using #ifdef. + Verify that the symbol has the expected value using #if. +>>CODE + + kysym2(); + +>>ASSERTION Good A +When the header file <X11/keysym.h> is included, +then the symbols in the table which have code 3 +are defined to have the hexadecimal values given in the table. +.tL "Code" "Value" "Name" +.tL "3" "2A1" "XK_Hstroke" +.tL "3" "2A6" "XK_Hcircumflex" +.tL "3" "2A9" "XK_Iabovedot" +.tL "3" "2AB" "XK_Gbreve" +.tL "3" "2AC" "XK_Jcircumflex" +.tL "3" "2B1" "XK_hstroke" +.tL "3" "2B6" "XK_hcircumflex" +.tL "3" "2B9" "XK_idotless" +.tL "3" "2BB" "XK_gbreve" +.tL "3" "2BC" "XK_jcircumflex" +.tL "3" "2C5" "XK_Cabovedot" +.tL "3" "2C6" "XK_Ccircumflex" +.tL "3" "2D5" "XK_Gabovedot" +.tL "3" "2D8" "XK_Gcircumflex" +.tL "3" "2DD" "XK_Ubreve" +.tL "3" "2DE" "XK_Scircumflex" +.tL "3" "2E5" "XK_cabovedot" +.tL "3" "2E6" "XK_ccircumflex" +.tL "3" "2F5" "XK_gabovedot" +.tL "3" "2F8" "XK_gcircumflex" +.tL "3" "2FD" "XK_ubreve" +.tL "3" "2FE" "XK_scircumflex" +>>STRATEGY +Include header file <X11/keysym.h> +For each KeySym in table with code 3: + Verify that the symbol is defined using #ifdef. + Verify that the symbol has the expected value using #if. +>>CODE + + kysym3(); + +>>ASSERTION Good A +When the header file <X11/keysym.h> is included, +then the symbols in the table which have code 4 +are defined to have the hexadecimal values given in the table. +.tL "Code" "Value" "Name" +.tL "4" "3A2" "XK_kra" +.tL "4" "3A2" "XK_kappa" +.tL "4" "3A3" "XK_Rcedilla" +.tL "4" "3A5" "XK_Itilde" +.tL "4" "3A6" "XK_Lcedilla" +.tL "4" "3AA" "XK_Emacron" +.tL "4" "3AB" "XK_Gcedilla" +.tL "4" "3AC" "XK_Tslash" +.tL "4" "3B3" "XK_rcedilla" +.tL "4" "3B5" "XK_itilde" +.tL "4" "3B6" "XK_lcedilla" +.tL "4" "3BA" "XK_emacron" +.tL "4" "3BB" "XK_gcedilla" +.tL "4" "3BC" "XK_tslash" +.tL "4" "3BD" "XK_ENG" +.tL "4" "3BF" "XK_eng" +.tL "4" "3C0" "XK_Amacron" +.tL "4" "3C7" "XK_Iogonek" +.tL "4" "3CC" "XK_Eabovedot" +.tL "4" "3CF" "XK_Imacron" +.tL "4" "3D1" "XK_Ncedilla" +.tL "4" "3D2" "XK_Omacron" +.tL "4" "3D3" "XK_Kcedilla" +.tL "4" "3D9" "XK_Uogonek" +.tL "4" "3DD" "XK_Utilde" +.tL "4" "3DE" "XK_Umacron" +.tL "4" "3E0" "XK_amacron" +.tL "4" "3E7" "XK_iogonek" +.tL "4" "3EC" "XK_eabovedot" +.tL "4" "3EF" "XK_imacron" +.tL "4" "3F1" "XK_ncedilla" +.tL "4" "3F2" "XK_omacron" +.tL "4" "3F3" "XK_kcedilla" +.tL "4" "3F9" "XK_uogonek" +.tL "4" "3FD" "XK_utilde" +.tL "4" "3FE" "XK_umacron" +>>STRATEGY +Include header file <X11/keysym.h> +For each KeySym in table with code 4: + Verify that the symbol is defined using #ifdef. + Verify that the symbol has the expected value using #if. +>>CODE + + kysym4(); + +>>ASSERTION Good A +When the header file <X11/keysym.h> is included, +then the symbols in the table which have code G +are defined to have the hexadecimal values given in the table. +.tL "Code" "Value" "Name" +.tL "G" "7A1" "XK_Greek_ALPHAaccent" +.tL "G" "7A2" "XK_Greek_EPSILONaccent" +.tL "G" "7A3" "XK_Greek_ETAaccent" +.tL "G" "7A4" "XK_Greek_IOTAaccent" +.tL "G" "7A5" "XK_Greek_IOTAdiaeresis" +.tL "G" "7A7" "XK_Greek_OMICRONaccent" +.tL "G" "7A8" "XK_Greek_UPSILONaccent" +.tL "G" "7A9" "XK_Greek_UPSILONdieresis" +.tL "G" "7AB" "XK_Greek_OMEGAaccent" +.tL "G" "7AE" "XK_Greek_accentdieresis" +.tL "G" "7AF" "XK_Greek_horizbar" +.tL "G" "7B1" "XK_Greek_alphaaccent" +.tL "G" "7B2" "XK_Greek_epsilonaccent" +.tL "G" "7B3" "XK_Greek_etaaccent" +.tL "G" "7B4" "XK_Greek_iotaaccent" +.tL "G" "7B5" "XK_Greek_iotadieresis" +.tL "G" "7B6" "XK_Greek_iotaaccentdieresis" +.tL "G" "7B7" "XK_Greek_omicronaccent" +.tL "G" "7B8" "XK_Greek_upsilonaccent" +.tL "G" "7B9" "XK_Greek_upsilondieresis" +.tL "G" "7BA" "XK_Greek_upsilonaccentdieresis" +.tL "G" "7BB" "XK_Greek_omegaaccent" +.tL "G" "7C1" "XK_Greek_ALPHA" +.tL "G" "7C2" "XK_Greek_BETA" +.tL "G" "7C3" "XK_Greek_GAMMA" +.tL "G" "7C4" "XK_Greek_DELTA" +.tL "G" "7C5" "XK_Greek_EPSILON" +.tL "G" "7C6" "XK_Greek_ZETA" +.tL "G" "7C7" "XK_Greek_ETA" +.tL "G" "7C8" "XK_Greek_THETA" +.tL "G" "7C9" "XK_Greek_IOTA" +.tL "G" "7CA" "XK_Greek_KAPPA" +.tL "G" "7CB" "XK_Greek_LAMBDA" +.tL "G" "7CB" "XK_Greek_LAMDA" +.tL "G" "7CC" "XK_Greek_MU" +.tL "G" "7CD" "XK_Greek_NU" +.tL "G" "7CE" "XK_Greek_XI" +.tL "G" "7CF" "XK_Greek_OMICRON" +.tL "G" "7D0" "XK_Greek_PI" +.tL "G" "7D1" "XK_Greek_RHO" +.tL "G" "7D2" "XK_Greek_SIGMA" +.tL "G" "7D4" "XK_Greek_TAU" +.tL "G" "7D5" "XK_Greek_UPSILON" +.tL "G" "7D6" "XK_Greek_PHI" +.tL "G" "7D7" "XK_Greek_CHI" +.tL "G" "7D8" "XK_Greek_PSI" +.tL "G" "7D9" "XK_Greek_OMEGA" +.tL "G" "7E1" "XK_Greek_alpha" +.tL "G" "7E2" "XK_Greek_beta" +.tL "G" "7E3" "XK_Greek_gamma" +.tL "G" "7E4" "XK_Greek_delta" +.tL "G" "7E5" "XK_Greek_epsilon" +.tL "G" "7E6" "XK_Greek_zeta" +.tL "G" "7E7" "XK_Greek_eta" +.tL "G" "7E8" "XK_Greek_theta" +.tL "G" "7E9" "XK_Greek_iota" +.tL "G" "7EA" "XK_Greek_kappa" +.tL "G" "7EB" "XK_Greek_lambda" +.tL "G" "7EB" "XK_Greek_lamda" +.tL "G" "7EC" "XK_Greek_mu" +.tL "G" "7ED" "XK_Greek_nu" +.tL "G" "7EE" "XK_Greek_xi" +.tL "G" "7EF" "XK_Greek_omicron" +.tL "G" "7F0" "XK_Greek_pi" +.tL "G" "7F1" "XK_Greek_rho" +.tL "G" "7F2" "XK_Greek_sigma" +.tL "G" "7F3" "XK_Greek_finalsmallsigma" +.tL "G" "7F4" "XK_Greek_tau" +.tL "G" "7F5" "XK_Greek_upsilon" +.tL "G" "7F6" "XK_Greek_phi" +.tL "G" "7F7" "XK_Greek_chi" +.tL "G" "7F8" "XK_Greek_psi" +.tL "G" "7F9" "XK_Greek_omega" +.tL "G" "FF7E" "XK_Greek_switch" +>>STRATEGY +Include header file <X11/keysym.h> +For each KeySym in table with code G: + Verify that the symbol is defined using #ifdef. + Verify that the symbol has the expected value using #if. +>>CODE + + kysymG(); + +>>ASSERTION Good A +When the header file <X11/keysym.h> is included, +then the symbols in the table which have code M +are defined to have the hexadecimal values given in the table. +.tL "Code" "Value" "Name" +.tL "M" "FF08" "XK_BackSpace" +.tL "M" "FF09" "XK_Tab" +.tL "M" "FF0A" "XK_Linefeed" +.tL "M" "FF0B" "XK_Clear" +.tL "M" "FF0D" "XK_Return" +.tL "M" "FF13" "XK_Pause" +.tL "M" "FF14" "XK_Scroll_Lock" +.tL "M" "FF1B" "XK_Escape" +.tL "M" "FF20" "XK_Multi_key" +.tL "M" "FF21" "XK_Kanji" +.tL "M" "FF22" "XK_Muhenkan" +.tL "M" "FF23" "XK_Henkan" +.tL "M" "FF23" "XK_Henkan_Mode" +.tL "M" "FF24" "XK_Romaji" +.tL "M" "FF25" "XK_Hiragana" +.tL "M" "FF26" "XK_Katakana" +.tL "M" "FF27" "XK_Hiragana_Katakana" +.tL "M" "FF28" "XK_Zenkaku" +.tL "M" "FF29" "XK_Hankaku" +.tL "M" "FF2A" "XK_Zenkaku_Hankaku" +.tL "M" "FF2B" "XK_Touroku" +.tL "M" "FF2C" "XK_Massyo" +.tL "M" "FF2D" "XK_Kana_Lock" +.tL "M" "FF2E" "XK_Kana_Shift" +.tL "M" "FF2F" "XK_Eisu_Shift" +.tL "M" "FF30" "XK_Eisu_toggle" +.tL "M" "FF50" "XK_Home" +.tL "M" "FF51" "XK_Left" +.tL "M" "FF52" "XK_Up" +.tL "M" "FF53" "XK_Right" +.tL "M" "FF54" "XK_Down" +.tL "M" "FF55" "XK_Prior" +.tL "M" "FF56" "XK_Next" +.tL "M" "FF57" "XK_End" +.tL "M" "FF58" "XK_Begin" +.tL "M" "FF60" "XK_Select" +.tL "M" "FF61" "XK_Print" +.tL "M" "FF62" "XK_Execute" +.tL "M" "FF63" "XK_Insert" +.tL "M" "FF65" "XK_Undo" +.tL "M" "FF66" "XK_Redo" +.tL "M" "FF67" "XK_Menu" +.tL "M" "FF68" "XK_Find" +.tL "M" "FF69" "XK_Cancel" +.tL "M" "FF6A" "XK_Help" +.tL "M" "FF6B" "XK_Break" +.tL "M" "FF7E" "XK_Mode_switch" +.tL "M" "FF7E" "XK_script_switch" +.tL "M" "FF7F" "XK_Num_Lock" +.tL "M" "FF80" "XK_KP_Space" +.tL "M" "FF89" "XK_KP_Tab" +.tL "M" "FF8D" "XK_KP_Enter" +.tL "M" "FF91" "XK_KP_F1" +.tL "M" "FF92" "XK_KP_F2" +.tL "M" "FF93" "XK_KP_F3" +.tL "M" "FF94" "XK_KP_F4" +.tL "M" "FFAA" "XK_KP_Multiply" +.tL "M" "FFAB" "XK_KP_Add" +.tL "M" "FFAC" "XK_KP_Separator" +.tL "M" "FFAD" "XK_KP_Subtract" +.tL "M" "FFAE" "XK_KP_Decimal" +.tL "M" "FFAF" "XK_KP_Divide" +.tL "M" "FFB0" "XK_KP_0" +.tL "M" "FFB1" "XK_KP_1" +.tL "M" "FFB2" "XK_KP_2" +.tL "M" "FFB3" "XK_KP_3" +.tL "M" "FFB4" "XK_KP_4" +.tL "M" "FFB5" "XK_KP_5" +.tL "M" "FFB6" "XK_KP_6" +.tL "M" "FFB7" "XK_KP_7" +.tL "M" "FFB8" "XK_KP_8" +.tL "M" "FFB9" "XK_KP_9" +.tL "M" "FFBD" "XK_KP_Equal" +.tL "M" "FFBE" "XK_F1" +.tL "M" "FFBF" "XK_F2" +.tL "M" "FFC0" "XK_F3" +.tL "M" "FFC1" "XK_F4" +.tL "M" "FFC2" "XK_F5" +.tL "M" "FFC3" "XK_F6" +.tL "M" "FFC4" "XK_F7" +.tL "M" "FFC5" "XK_F8" +.tL "M" "FFC6" "XK_F9" +.tL "M" "FFC7" "XK_F10" +.tL "M" "FFC8" "XK_F11" +.tL "M" "FFC8" "XK_L1" +.tL "M" "FFC9" "XK_F12" +.tL "M" "FFC9" "XK_L2" +.tL "M" "FFCA" "XK_F13" +.tL "M" "FFCA" "XK_L3" +.tL "M" "FFCB" "XK_F14" +.tL "M" "FFCB" "XK_L4" +.tL "M" "FFCC" "XK_F15" +.tL "M" "FFCC" "XK_L5" +.tL "M" "FFCD" "XK_F16" +.tL "M" "FFCD" "XK_L6" +.tL "M" "FFCE" "XK_F17" +.tL "M" "FFCE" "XK_L7" +.tL "M" "FFCF" "XK_F18" +.tL "M" "FFCF" "XK_L8" +.tL "M" "FFD0" "XK_F19" +.tL "M" "FFD0" "XK_L9" +.tL "M" "FFD1" "XK_F20" +.tL "M" "FFD1" "XK_L10" +.tL "M" "FFD2" "XK_F21" +.tL "M" "FFD2" "XK_R1" +.tL "M" "FFD3" "XK_F22" +.tL "M" "FFD3" "XK_R2" +.tL "M" "FFD4" "XK_F23" +.tL "M" "FFD4" "XK_R3" +.tL "M" "FFD5" "XK_F24" +.tL "M" "FFD5" "XK_R4" +.tL "M" "FFD6" "XK_F25" +.tL "M" "FFD6" "XK_R5" +.tL "M" "FFD7" "XK_F26" +.tL "M" "FFD7" "XK_R6" +.tL "M" "FFD8" "XK_F27" +.tL "M" "FFD8" "XK_R7" +.tL "M" "FFD9" "XK_F28" +.tL "M" "FFD9" "XK_R8" +.tL "M" "FFDA" "XK_F29" +.tL "M" "FFDA" "XK_R9" +.tL "M" "FFDB" "XK_F30" +.tL "M" "FFDB" "XK_R10" +.tL "M" "FFDC" "XK_F31" +.tL "M" "FFDC" "XK_R11" +.tL "M" "FFDD" "XK_F32" +.tL "M" "FFDD" "XK_R12" +.tL "M" "FFDE" "XK_F33" +.tL "M" "FFDE" "XK_R13" +.tL "M" "FFDF" "XK_F34" +.tL "M" "FFDF" "XK_R14" +.tL "M" "FFE0" "XK_F35" +.tL "M" "FFE0" "XK_R15" +.tL "M" "FFE1" "XK_Shift_L" +.tL "M" "FFE2" "XK_Shift_R" +.tL "M" "FFE3" "XK_Control_L" +.tL "M" "FFE4" "XK_Control_R" +.tL "M" "FFE5" "XK_Caps_Lock" +.tL "M" "FFE6" "XK_Shift_Lock" +.tL "M" "FFE7" "XK_Meta_L" +.tL "M" "FFE8" "XK_Meta_R" +.tL "M" "FFE9" "XK_Alt_L" +.tL "M" "FFEA" "XK_Alt_R" +.tL "M" "FFEB" "XK_Super_L" +.tL "M" "FFEC" "XK_Super_R" +.tL "M" "FFED" "XK_Hyper_L" +.tL "M" "FFEE" "XK_Hyper_R" +.tL "M" "FFFF" "XK_Delete" +>>STRATEGY +Include header file <X11/keysym.h> +For each KeySym in table with code M: + Verify that the symbol is defined using #ifdef. + Verify that the symbol has the expected value using #if. +>>CODE + + kysymM(); + +>>ASSERTION Good A +When the header file <X11/keysym.h> is included, +then the symbols in the table +are defined to have the hexadecimal values given in the table. +.tL "Value" "Name" +.tL "FFFFFF" "XK_VoidSymbol" +>>STRATEGY +Include header file <X11/keysym.h> +For each KeySym in table: + Verify that the symbol is defined using #ifdef. + Verify that the symbol has the expected value using #if. +>>CODE + + kysym0(); diff --git a/xts5/Xopen/keysymdef/Test0.c b/xts5/Xopen/keysymdef/Test0.c new file mode 100644 index 00000000..53bd53e8 --- /dev/null +++ b/xts5/Xopen/keysymdef/Test0.c @@ -0,0 +1,136 @@ +/* +Copyright (c) 2005 X.Org Foundation L.L.C. + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies +of the Software, and to permit persons to whom the Software is furnished to do +so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. +*/ +/* +* $Header: /cvs/xtest/xtest/xts5/tset/Xopen/keysymdef/Test0.c,v 1.2 2005-11-03 08:44:00 jmichael Exp $ +* +* Project: VSW5 +* +* File: xts5/tset/Xopen/keysymdef/Test0.c +* +* Description: +* Tests for keysymdef() +* +* Modifications: +* $Log: Test0.c,v $ +* Revision 1.2 2005-11-03 08:44:00 jmichael +* clean up all vsw5 paths to use xts5 instead. +* +* Revision 1.1.1.2 2005/04/15 14:05:40 anderson +* Reimport of the base with the legal name in the copyright fixed. +* +* Revision 8.0 1998/12/23 23:35:35 mar +* Branch point for Release 5.0.2 +* +* Revision 7.0 1998/10/30 22:58:08 mar +* Branch point for Release 5.0.2b1 +* +* Revision 6.0 1998/03/02 05:26:49 tbr +* Branch point for Release 5.0.1 +* +* Revision 5.0 1998/01/26 03:23:22 tbr +* Branch point for Release 5.0.1b1 +* +* Revision 4.1 1996/05/09 21:16:18 andy +* Fixed X includes +* +* Revision 4.0 1995/12/15 09:13:38 tbr +* Branch point for Release 5.0.0 +* +* Revision 3.1 1995/12/15 01:16:55 andy +* Prepare for GA Release +* +*/ +/* + * SCCS: @(#) Test0.c Rel 1.2 (7/17/92) + * + * UniSoft Ltd., London, England + * + * (C) Copyright 1991 X/Open Company Limited + * + * All rights reserved. No part of this source code may be reproduced, + * stored in a retrieval system, or transmitted, in any form or by any + * means, electronic, mechanical, photocopying, recording or otherwise, + * except as stated in the end-user licence agreement, without the prior + * permission of the copyright owners. + * + * X/Open and the 'X' symbol are trademarks of X/Open Company Limited in + * the UK and other countries. + */ + +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif + +#include <stdlib.h> +#include "xtest.h" +#include "X11/Xlib.h" +#include "X11/Xutil.h" +#include "X11/Xresource.h" +#include "tet_api.h" +#include "xtestlib.h" +#include "pixval.h" + +extern char *TestName; + +static int +test(name, val, aval) +char *name; +int val; +int aval; +{ + + if(val != aval) { + report("KeySym \"%s\" is defined to have value 0x%x instead of 0x%x.", name, val, aval); + return(0); + } + return(1); +} + + + +static void +reporterr(s) +char *s; +{ + report("Keysym \"%s\" is not defined.", s); +} + +#define XK_LATIN2 +#include <X11/keysymdef.h> +#undef XK_LATIN2 + + +kysymdf0() +{ +int pass = 0, fail = 0; +#ifdef XK_VoidSymbol + if(test("XK_VoidSymbol", XK_VoidSymbol, 0xFFFFFF) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_VoidSymbol"); + FAIL; +#endif + + CHECKPASS(1); +} diff --git a/xts5/Xopen/keysymdef/Test1.c b/xts5/Xopen/keysymdef/Test1.c new file mode 100644 index 00000000..e6a8dd6e --- /dev/null +++ b/xts5/Xopen/keysymdef/Test1.c @@ -0,0 +1,2076 @@ +/* +Copyright (c) 2005 X.Org Foundation L.L.C. + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies +of the Software, and to permit persons to whom the Software is furnished to do +so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. +*/ +/* +* $Header: /cvs/xtest/xtest/xts5/tset/Xopen/keysymdef/Test1.c,v 1.2 2005-11-03 08:44:00 jmichael Exp $ +* +* Project: VSW5 +* +* File: xts5/tset/Xopen/keysymdef/Test1.c +* +* Description: +* Tests for keysymdef() +* +* Modifications: +* $Log: Test1.c,v $ +* Revision 1.2 2005-11-03 08:44:00 jmichael +* clean up all vsw5 paths to use xts5 instead. +* +* Revision 1.1.1.2 2005/04/15 14:05:40 anderson +* Reimport of the base with the legal name in the copyright fixed. +* +* Revision 8.0 1998/12/23 23:35:35 mar +* Branch point for Release 5.0.2 +* +* Revision 7.0 1998/10/30 22:58:09 mar +* Branch point for Release 5.0.2b1 +* +* Revision 6.0 1998/03/02 05:26:49 tbr +* Branch point for Release 5.0.1 +* +* Revision 5.0 1998/01/26 03:23:23 tbr +* Branch point for Release 5.0.1b1 +* +* Revision 4.1 1996/05/09 21:16:18 andy +* Fixed X includes +* +* Revision 4.0 1995/12/15 09:13:40 tbr +* Branch point for Release 5.0.0 +* +* Revision 3.1 1995/12/15 01:16:57 andy +* Prepare for GA Release +* +*/ +/* + * SCCS: @(#) Test1.c Rel 1.1 (11/28/91) + * + * UniSoft Ltd., London, England + * + * (C) Copyright 1991 X/Open Company Limited + * + * All rights reserved. No part of this source code may be reproduced, + * stored in a retrieval system, or transmitted, in any form or by any + * means, electronic, mechanical, photocopying, recording or otherwise, + * except as stated in the end-user licence agreement, without the prior + * permission of the copyright owners. + * + * X/Open and the 'X' symbol are trademarks of X/Open Company Limited in + * the UK and other countries. + */ + +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif + +#include <stdlib.h> +#include "xtest.h" +#include "X11/Xlib.h" +#include "X11/Xutil.h" +#include "X11/Xresource.h" +#include "tet_api.h" +#include "xtestlib.h" +#include "pixval.h" + +extern char *TestName; + +static int +test(name, val, aval) +char *name; +int val; +int aval; +{ + + if(val != aval) { + report("KeySym \"%s\" is defined to have value 0x%x instead of 0x%x.", name, val, aval); + return(0); + } + return(1); +} + + + +static void +reporterr(s) +char *s; +{ + report("Keysym \"%s\" is not defined.", s); +} + +#define XK_LATIN1 +#include <X11/keysymdef.h> +#undef XK_LATIN1 + +kysymdf1() +{ +int pass = 0, fail = 0; +#ifdef XK_space + if(test("XK_space", XK_space, 0x20) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_space"); + FAIL; +#endif + +#ifdef XK_exclam + if(test("XK_exclam", XK_exclam, 0x21) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_exclam"); + FAIL; +#endif + +#ifdef XK_quotedbl + if(test("XK_quotedbl", XK_quotedbl, 0x22) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_quotedbl"); + FAIL; +#endif + +#ifdef XK_numbersign + if(test("XK_numbersign", XK_numbersign, 0x23) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_numbersign"); + FAIL; +#endif + +#ifdef XK_dollar + if(test("XK_dollar", XK_dollar, 0x24) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_dollar"); + FAIL; +#endif + +#ifdef XK_percent + if(test("XK_percent", XK_percent, 0x25) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_percent"); + FAIL; +#endif + +#ifdef XK_ampersand + if(test("XK_ampersand", XK_ampersand, 0x26) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_ampersand"); + FAIL; +#endif + +#ifdef XK_apostrophe + if(test("XK_apostrophe", XK_apostrophe, 0x27) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_apostrophe"); + FAIL; +#endif + +#ifdef XK_quoteright + if(test("XK_quoteright", XK_quoteright, 0x27) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_quoteright"); + FAIL; +#endif + +#ifdef XK_parenleft + if(test("XK_parenleft", XK_parenleft, 0x28) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_parenleft"); + FAIL; +#endif + +#ifdef XK_parenright + if(test("XK_parenright", XK_parenright, 0x29) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_parenright"); + FAIL; +#endif + +#ifdef XK_asterisk + if(test("XK_asterisk", XK_asterisk, 0x2A) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_asterisk"); + FAIL; +#endif + +#ifdef XK_plus + if(test("XK_plus", XK_plus, 0x2B) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_plus"); + FAIL; +#endif + +#ifdef XK_comma + if(test("XK_comma", XK_comma, 0x2C) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_comma"); + FAIL; +#endif + +#ifdef XK_minus + if(test("XK_minus", XK_minus, 0x2D) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_minus"); + FAIL; +#endif + +#ifdef XK_period + if(test("XK_period", XK_period, 0x2E) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_period"); + FAIL; +#endif + +#ifdef XK_slash + if(test("XK_slash", XK_slash, 0x2F) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_slash"); + FAIL; +#endif + +#ifdef XK_0 + if(test("XK_0", XK_0, 0x30) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_0"); + FAIL; +#endif + +#ifdef XK_1 + if(test("XK_1", XK_1, 0x31) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_1"); + FAIL; +#endif + +#ifdef XK_2 + if(test("XK_2", XK_2, 0x32) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_2"); + FAIL; +#endif + +#ifdef XK_3 + if(test("XK_3", XK_3, 0x33) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_3"); + FAIL; +#endif + +#ifdef XK_4 + if(test("XK_4", XK_4, 0x34) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_4"); + FAIL; +#endif + +#ifdef XK_5 + if(test("XK_5", XK_5, 0x35) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_5"); + FAIL; +#endif + +#ifdef XK_6 + if(test("XK_6", XK_6, 0x36) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_6"); + FAIL; +#endif + +#ifdef XK_7 + if(test("XK_7", XK_7, 0x37) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_7"); + FAIL; +#endif + +#ifdef XK_8 + if(test("XK_8", XK_8, 0x38) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_8"); + FAIL; +#endif + +#ifdef XK_9 + if(test("XK_9", XK_9, 0x39) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_9"); + FAIL; +#endif + +#ifdef XK_colon + if(test("XK_colon", XK_colon, 0x3A) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_colon"); + FAIL; +#endif + +#ifdef XK_semicolon + if(test("XK_semicolon", XK_semicolon, 0x3B) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_semicolon"); + FAIL; +#endif + +#ifdef XK_less + if(test("XK_less", XK_less, 0x3C) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_less"); + FAIL; +#endif + +#ifdef XK_equal + if(test("XK_equal", XK_equal, 0x3D) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_equal"); + FAIL; +#endif + +#ifdef XK_greater + if(test("XK_greater", XK_greater, 0x3E) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_greater"); + FAIL; +#endif + +#ifdef XK_question + if(test("XK_question", XK_question, 0x3F) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_question"); + FAIL; +#endif + +#ifdef XK_at + if(test("XK_at", XK_at, 0x40) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_at"); + FAIL; +#endif + +#ifdef XK_A + if(test("XK_A", XK_A, 0x41) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_A"); + FAIL; +#endif + +#ifdef XK_B + if(test("XK_B", XK_B, 0x42) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_B"); + FAIL; +#endif + +#ifdef XK_C + if(test("XK_C", XK_C, 0x43) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_C"); + FAIL; +#endif + +#ifdef XK_D + if(test("XK_D", XK_D, 0x44) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_D"); + FAIL; +#endif + +#ifdef XK_E + if(test("XK_E", XK_E, 0x45) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_E"); + FAIL; +#endif + +#ifdef XK_F + if(test("XK_F", XK_F, 0x46) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_F"); + FAIL; +#endif + +#ifdef XK_G + if(test("XK_G", XK_G, 0x47) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_G"); + FAIL; +#endif + +#ifdef XK_H + if(test("XK_H", XK_H, 0x48) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_H"); + FAIL; +#endif + +#ifdef XK_I + if(test("XK_I", XK_I, 0x49) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_I"); + FAIL; +#endif + +#ifdef XK_J + if(test("XK_J", XK_J, 0x4A) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_J"); + FAIL; +#endif + +#ifdef XK_K + if(test("XK_K", XK_K, 0x4B) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_K"); + FAIL; +#endif + +#ifdef XK_L + if(test("XK_L", XK_L, 0x4C) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_L"); + FAIL; +#endif + +#ifdef XK_M + if(test("XK_M", XK_M, 0x4D) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_M"); + FAIL; +#endif + +#ifdef XK_N + if(test("XK_N", XK_N, 0x4E) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_N"); + FAIL; +#endif + +#ifdef XK_O + if(test("XK_O", XK_O, 0x4F) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_O"); + FAIL; +#endif + +#ifdef XK_P + if(test("XK_P", XK_P, 0x50) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_P"); + FAIL; +#endif + +#ifdef XK_Q + if(test("XK_Q", XK_Q, 0x51) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Q"); + FAIL; +#endif + +#ifdef XK_R + if(test("XK_R", XK_R, 0x52) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_R"); + FAIL; +#endif + +#ifdef XK_S + if(test("XK_S", XK_S, 0x53) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_S"); + FAIL; +#endif + +#ifdef XK_T + if(test("XK_T", XK_T, 0x54) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_T"); + FAIL; +#endif + +#ifdef XK_U + if(test("XK_U", XK_U, 0x55) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_U"); + FAIL; +#endif + +#ifdef XK_V + if(test("XK_V", XK_V, 0x56) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_V"); + FAIL; +#endif + +#ifdef XK_W + if(test("XK_W", XK_W, 0x57) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_W"); + FAIL; +#endif + +#ifdef XK_X + if(test("XK_X", XK_X, 0x58) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_X"); + FAIL; +#endif + +#ifdef XK_Y + if(test("XK_Y", XK_Y, 0x59) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Y"); + FAIL; +#endif + +#ifdef XK_Z + if(test("XK_Z", XK_Z, 0x5A) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Z"); + FAIL; +#endif + +#ifdef XK_bracketleft + if(test("XK_bracketleft", XK_bracketleft, 0x5B) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_bracketleft"); + FAIL; +#endif + +#ifdef XK_backslash + if(test("XK_backslash", XK_backslash, 0x5C) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_backslash"); + FAIL; +#endif + +#ifdef XK_bracketright + if(test("XK_bracketright", XK_bracketright, 0x5D) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_bracketright"); + FAIL; +#endif + +#ifdef XK_asciicircum + if(test("XK_asciicircum", XK_asciicircum, 0x5E) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_asciicircum"); + FAIL; +#endif + +#ifdef XK_underscore + if(test("XK_underscore", XK_underscore, 0x5F) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_underscore"); + FAIL; +#endif + +#ifdef XK_grave + if(test("XK_grave", XK_grave, 0x60) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_grave"); + FAIL; +#endif + +#ifdef XK_quoteleft + if(test("XK_quoteleft", XK_quoteleft, 0x60) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_quoteleft"); + FAIL; +#endif + +#ifdef XK_a + if(test("XK_a", XK_a, 0x61) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_a"); + FAIL; +#endif + +#ifdef XK_b + if(test("XK_b", XK_b, 0x62) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_b"); + FAIL; +#endif + +#ifdef XK_c + if(test("XK_c", XK_c, 0x63) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_c"); + FAIL; +#endif + +#ifdef XK_d + if(test("XK_d", XK_d, 0x64) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_d"); + FAIL; +#endif + +#ifdef XK_e + if(test("XK_e", XK_e, 0x65) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_e"); + FAIL; +#endif + +#ifdef XK_f + if(test("XK_f", XK_f, 0x66) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_f"); + FAIL; +#endif + +#ifdef XK_g + if(test("XK_g", XK_g, 0x67) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_g"); + FAIL; +#endif + +#ifdef XK_h + if(test("XK_h", XK_h, 0x68) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_h"); + FAIL; +#endif + +#ifdef XK_i + if(test("XK_i", XK_i, 0x69) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_i"); + FAIL; +#endif + +#ifdef XK_j + if(test("XK_j", XK_j, 0x6A) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_j"); + FAIL; +#endif + +#ifdef XK_k + if(test("XK_k", XK_k, 0x6B) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_k"); + FAIL; +#endif + +#ifdef XK_l + if(test("XK_l", XK_l, 0x6C) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_l"); + FAIL; +#endif + +#ifdef XK_m + if(test("XK_m", XK_m, 0x6D) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_m"); + FAIL; +#endif + +#ifdef XK_n + if(test("XK_n", XK_n, 0x6E) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_n"); + FAIL; +#endif + +#ifdef XK_o + if(test("XK_o", XK_o, 0x6F) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_o"); + FAIL; +#endif + +#ifdef XK_p + if(test("XK_p", XK_p, 0x70) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_p"); + FAIL; +#endif + +#ifdef XK_q + if(test("XK_q", XK_q, 0x71) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_q"); + FAIL; +#endif + +#ifdef XK_r + if(test("XK_r", XK_r, 0x72) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_r"); + FAIL; +#endif + +#ifdef XK_s + if(test("XK_s", XK_s, 0x73) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_s"); + FAIL; +#endif + +#ifdef XK_t + if(test("XK_t", XK_t, 0x74) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_t"); + FAIL; +#endif + +#ifdef XK_u + if(test("XK_u", XK_u, 0x75) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_u"); + FAIL; +#endif + +#ifdef XK_v + if(test("XK_v", XK_v, 0x76) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_v"); + FAIL; +#endif + +#ifdef XK_w + if(test("XK_w", XK_w, 0x77) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_w"); + FAIL; +#endif + +#ifdef XK_x + if(test("XK_x", XK_x, 0x78) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_x"); + FAIL; +#endif + +#ifdef XK_y + if(test("XK_y", XK_y, 0x79) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_y"); + FAIL; +#endif + +#ifdef XK_z + if(test("XK_z", XK_z, 0x7A) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_z"); + FAIL; +#endif + +#ifdef XK_braceleft + if(test("XK_braceleft", XK_braceleft, 0x7B) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_braceleft"); + FAIL; +#endif + +#ifdef XK_bar + if(test("XK_bar", XK_bar, 0x7C) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_bar"); + FAIL; +#endif + +#ifdef XK_braceright + if(test("XK_braceright", XK_braceright, 0x7D) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_braceright"); + FAIL; +#endif + +#ifdef XK_asciitilde + if(test("XK_asciitilde", XK_asciitilde, 0x7E) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_asciitilde"); + FAIL; +#endif + +#ifdef XK_nobreakspace + if(test("XK_nobreakspace", XK_nobreakspace, 0xA0) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_nobreakspace"); + FAIL; +#endif + +#ifdef XK_exclamdown + if(test("XK_exclamdown", XK_exclamdown, 0xA1) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_exclamdown"); + FAIL; +#endif + +#ifdef XK_cent + if(test("XK_cent", XK_cent, 0xA2) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_cent"); + FAIL; +#endif + +#ifdef XK_sterling + if(test("XK_sterling", XK_sterling, 0xA3) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_sterling"); + FAIL; +#endif + +#ifdef XK_currency + if(test("XK_currency", XK_currency, 0xA4) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_currency"); + FAIL; +#endif + +#ifdef XK_yen + if(test("XK_yen", XK_yen, 0xA5) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_yen"); + FAIL; +#endif + +#ifdef XK_brokenbar + if(test("XK_brokenbar", XK_brokenbar, 0xA6) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_brokenbar"); + FAIL; +#endif + +#ifdef XK_section + if(test("XK_section", XK_section, 0xA7) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_section"); + FAIL; +#endif + +#ifdef XK_diaeresis + if(test("XK_diaeresis", XK_diaeresis, 0xA8) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_diaeresis"); + FAIL; +#endif + +#ifdef XK_copyright + if(test("XK_copyright", XK_copyright, 0xA9) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_copyright"); + FAIL; +#endif + +#ifdef XK_ordfeminine + if(test("XK_ordfeminine", XK_ordfeminine, 0xAA) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_ordfeminine"); + FAIL; +#endif + +#ifdef XK_guillemotleft + if(test("XK_guillemotleft", XK_guillemotleft, 0xAB) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_guillemotleft"); + FAIL; +#endif + +#ifdef XK_notsign + if(test("XK_notsign", XK_notsign, 0xAC) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_notsign"); + FAIL; +#endif + +#ifdef XK_hyphen + if(test("XK_hyphen", XK_hyphen, 0xAD) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_hyphen"); + FAIL; +#endif + +#ifdef XK_registered + if(test("XK_registered", XK_registered, 0xAE) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_registered"); + FAIL; +#endif + +#ifdef XK_macron + if(test("XK_macron", XK_macron, 0xAF) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_macron"); + FAIL; +#endif + +#ifdef XK_degree + if(test("XK_degree", XK_degree, 0xB0) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_degree"); + FAIL; +#endif + +#ifdef XK_plusminus + if(test("XK_plusminus", XK_plusminus, 0xB1) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_plusminus"); + FAIL; +#endif + +#ifdef XK_twosuperior + if(test("XK_twosuperior", XK_twosuperior, 0xB2) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_twosuperior"); + FAIL; +#endif + +#ifdef XK_threesuperior + if(test("XK_threesuperior", XK_threesuperior, 0xB3) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_threesuperior"); + FAIL; +#endif + +#ifdef XK_acute + if(test("XK_acute", XK_acute, 0xB4) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_acute"); + FAIL; +#endif + +#ifdef XK_mu + if(test("XK_mu", XK_mu, 0xB5) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_mu"); + FAIL; +#endif + +#ifdef XK_paragraph + if(test("XK_paragraph", XK_paragraph, 0xB6) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_paragraph"); + FAIL; +#endif + +#ifdef XK_periodcentered + if(test("XK_periodcentered", XK_periodcentered, 0xB7) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_periodcentered"); + FAIL; +#endif + +#ifdef XK_cedilla + if(test("XK_cedilla", XK_cedilla, 0xB8) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_cedilla"); + FAIL; +#endif + +#ifdef XK_onesuperior + if(test("XK_onesuperior", XK_onesuperior, 0xB9) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_onesuperior"); + FAIL; +#endif + +#ifdef XK_masculine + if(test("XK_masculine", XK_masculine, 0xBA) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_masculine"); + FAIL; +#endif + +#ifdef XK_guillemotright + if(test("XK_guillemotright", XK_guillemotright, 0xBB) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_guillemotright"); + FAIL; +#endif + +#ifdef XK_onequarter + if(test("XK_onequarter", XK_onequarter, 0xBC) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_onequarter"); + FAIL; +#endif + +#ifdef XK_onehalf + if(test("XK_onehalf", XK_onehalf, 0xBD) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_onehalf"); + FAIL; +#endif + +#ifdef XK_threequarters + if(test("XK_threequarters", XK_threequarters, 0xBE) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_threequarters"); + FAIL; +#endif + +#ifdef XK_questiondown + if(test("XK_questiondown", XK_questiondown, 0xBF) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_questiondown"); + FAIL; +#endif + +#ifdef XK_Agrave + if(test("XK_Agrave", XK_Agrave, 0xC0) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Agrave"); + FAIL; +#endif + +#ifdef XK_Aacute + if(test("XK_Aacute", XK_Aacute, 0xC1) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Aacute"); + FAIL; +#endif + +#ifdef XK_Acircumflex + if(test("XK_Acircumflex", XK_Acircumflex, 0xC2) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Acircumflex"); + FAIL; +#endif + +#ifdef XK_Atilde + if(test("XK_Atilde", XK_Atilde, 0xC3) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Atilde"); + FAIL; +#endif + +#ifdef XK_Adiaeresis + if(test("XK_Adiaeresis", XK_Adiaeresis, 0xC4) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Adiaeresis"); + FAIL; +#endif + +#ifdef XK_Aring + if(test("XK_Aring", XK_Aring, 0xC5) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Aring"); + FAIL; +#endif + +#ifdef XK_AE + if(test("XK_AE", XK_AE, 0xC6) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_AE"); + FAIL; +#endif + +#ifdef XK_Ccedilla + if(test("XK_Ccedilla", XK_Ccedilla, 0xC7) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Ccedilla"); + FAIL; +#endif + +#ifdef XK_Egrave + if(test("XK_Egrave", XK_Egrave, 0xC8) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Egrave"); + FAIL; +#endif + +#ifdef XK_Eacute + if(test("XK_Eacute", XK_Eacute, 0xC9) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Eacute"); + FAIL; +#endif + +#ifdef XK_Ecircumflex + if(test("XK_Ecircumflex", XK_Ecircumflex, 0xCA) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Ecircumflex"); + FAIL; +#endif + +#ifdef XK_Ediaeresis + if(test("XK_Ediaeresis", XK_Ediaeresis, 0xCB) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Ediaeresis"); + FAIL; +#endif + +#ifdef XK_Igrave + if(test("XK_Igrave", XK_Igrave, 0xCC) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Igrave"); + FAIL; +#endif + +#ifdef XK_Iacute + if(test("XK_Iacute", XK_Iacute, 0xCD) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Iacute"); + FAIL; +#endif + +#ifdef XK_Icircumflex + if(test("XK_Icircumflex", XK_Icircumflex, 0xCE) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Icircumflex"); + FAIL; +#endif + +#ifdef XK_Idiaeresis + if(test("XK_Idiaeresis", XK_Idiaeresis, 0xCF) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Idiaeresis"); + FAIL; +#endif + +#ifdef XK_ETH + if(test("XK_ETH", XK_ETH, 0xD0) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_ETH"); + FAIL; +#endif + +#ifdef XK_Eth + if(test("XK_Eth", XK_Eth, 0xD0) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Eth"); + FAIL; +#endif + +#ifdef XK_Ntilde + if(test("XK_Ntilde", XK_Ntilde, 0xD1) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Ntilde"); + FAIL; +#endif + +#ifdef XK_Ograve + if(test("XK_Ograve", XK_Ograve, 0xD2) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Ograve"); + FAIL; +#endif + +#ifdef XK_Oacute + if(test("XK_Oacute", XK_Oacute, 0xD3) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Oacute"); + FAIL; +#endif + +#ifdef XK_Ocircumflex + if(test("XK_Ocircumflex", XK_Ocircumflex, 0xD4) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Ocircumflex"); + FAIL; +#endif + +#ifdef XK_Otilde + if(test("XK_Otilde", XK_Otilde, 0xD5) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Otilde"); + FAIL; +#endif + +#ifdef XK_Odiaeresis + if(test("XK_Odiaeresis", XK_Odiaeresis, 0xD6) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Odiaeresis"); + FAIL; +#endif + +#ifdef XK_multiply + if(test("XK_multiply", XK_multiply, 0xD7) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_multiply"); + FAIL; +#endif + +#ifdef XK_Ooblique + if(test("XK_Ooblique", XK_Ooblique, 0xD8) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Ooblique"); + FAIL; +#endif + +#ifdef XK_Ugrave + if(test("XK_Ugrave", XK_Ugrave, 0xD9) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Ugrave"); + FAIL; +#endif + +#ifdef XK_Uacute + if(test("XK_Uacute", XK_Uacute, 0xDA) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Uacute"); + FAIL; +#endif + +#ifdef XK_Ucircumflex + if(test("XK_Ucircumflex", XK_Ucircumflex, 0xDB) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Ucircumflex"); + FAIL; +#endif + +#ifdef XK_Udiaeresis + if(test("XK_Udiaeresis", XK_Udiaeresis, 0xDC) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Udiaeresis"); + FAIL; +#endif + +#ifdef XK_Yacute + if(test("XK_Yacute", XK_Yacute, 0xDD) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Yacute"); + FAIL; +#endif + +#ifdef XK_THORN + if(test("XK_THORN", XK_THORN, 0xDE) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_THORN"); + FAIL; +#endif + +#ifdef XK_Thorn + if(test("XK_Thorn", XK_Thorn, 0xDE) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Thorn"); + FAIL; +#endif + +#ifdef XK_ssharp + if(test("XK_ssharp", XK_ssharp, 0xDF) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_ssharp"); + FAIL; +#endif + +#ifdef XK_agrave + if(test("XK_agrave", XK_agrave, 0xE0) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_agrave"); + FAIL; +#endif + +#ifdef XK_aacute + if(test("XK_aacute", XK_aacute, 0xE1) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_aacute"); + FAIL; +#endif + +#ifdef XK_acircumflex + if(test("XK_acircumflex", XK_acircumflex, 0xE2) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_acircumflex"); + FAIL; +#endif + +#ifdef XK_atilde + if(test("XK_atilde", XK_atilde, 0xE3) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_atilde"); + FAIL; +#endif + +#ifdef XK_adiaeresis + if(test("XK_adiaeresis", XK_adiaeresis, 0xE4) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_adiaeresis"); + FAIL; +#endif + +#ifdef XK_aring + if(test("XK_aring", XK_aring, 0xE5) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_aring"); + FAIL; +#endif + +#ifdef XK_ae + if(test("XK_ae", XK_ae, 0xE6) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_ae"); + FAIL; +#endif + +#ifdef XK_ccedilla + if(test("XK_ccedilla", XK_ccedilla, 0xE7) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_ccedilla"); + FAIL; +#endif + +#ifdef XK_egrave + if(test("XK_egrave", XK_egrave, 0xE8) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_egrave"); + FAIL; +#endif + +#ifdef XK_eacute + if(test("XK_eacute", XK_eacute, 0xE9) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_eacute"); + FAIL; +#endif + +#ifdef XK_ecircumflex + if(test("XK_ecircumflex", XK_ecircumflex, 0xEA) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_ecircumflex"); + FAIL; +#endif + +#ifdef XK_ediaeresis + if(test("XK_ediaeresis", XK_ediaeresis, 0xEB) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_ediaeresis"); + FAIL; +#endif + +#ifdef XK_igrave + if(test("XK_igrave", XK_igrave, 0xEC) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_igrave"); + FAIL; +#endif + +#ifdef XK_iacute + if(test("XK_iacute", XK_iacute, 0xED) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_iacute"); + FAIL; +#endif + +#ifdef XK_icircumflex + if(test("XK_icircumflex", XK_icircumflex, 0xEE) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_icircumflex"); + FAIL; +#endif + +#ifdef XK_idiaeresis + if(test("XK_idiaeresis", XK_idiaeresis, 0xEF) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_idiaeresis"); + FAIL; +#endif + +#ifdef XK_eth + if(test("XK_eth", XK_eth, 0xF0) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_eth"); + FAIL; +#endif + +#ifdef XK_ntilde + if(test("XK_ntilde", XK_ntilde, 0xF1) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_ntilde"); + FAIL; +#endif + +#ifdef XK_ograve + if(test("XK_ograve", XK_ograve, 0xF2) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_ograve"); + FAIL; +#endif + +#ifdef XK_oacute + if(test("XK_oacute", XK_oacute, 0xF3) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_oacute"); + FAIL; +#endif + +#ifdef XK_ocircumflex + if(test("XK_ocircumflex", XK_ocircumflex, 0xF4) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_ocircumflex"); + FAIL; +#endif + +#ifdef XK_otilde + if(test("XK_otilde", XK_otilde, 0xF5) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_otilde"); + FAIL; +#endif + +#ifdef XK_odiaeresis + if(test("XK_odiaeresis", XK_odiaeresis, 0xF6) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_odiaeresis"); + FAIL; +#endif + +#ifdef XK_division + if(test("XK_division", XK_division, 0xF7) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_division"); + FAIL; +#endif + +#ifdef XK_oslash + if(test("XK_oslash", XK_oslash, 0xF8) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_oslash"); + FAIL; +#endif + +#ifdef XK_ugrave + if(test("XK_ugrave", XK_ugrave, 0xF9) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_ugrave"); + FAIL; +#endif + +#ifdef XK_uacute + if(test("XK_uacute", XK_uacute, 0xFA) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_uacute"); + FAIL; +#endif + +#ifdef XK_ucircumflex + if(test("XK_ucircumflex", XK_ucircumflex, 0xFB) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_ucircumflex"); + FAIL; +#endif + +#ifdef XK_udiaeresis + if(test("XK_udiaeresis", XK_udiaeresis, 0xFC) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_udiaeresis"); + FAIL; +#endif + +#ifdef XK_yacute + if(test("XK_yacute", XK_yacute, 0xFD) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_yacute"); + FAIL; +#endif + +#ifdef XK_thorn + if(test("XK_thorn", XK_thorn, 0xFE) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_thorn"); + FAIL; +#endif + +#ifdef XK_ydiaeresis + if(test("XK_ydiaeresis", XK_ydiaeresis, 0xFF) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_ydiaeresis"); + FAIL; +#endif + + + CHECKPASS(195); +} diff --git a/xts5/Xopen/keysymdef/Test2.c b/xts5/Xopen/keysymdef/Test2.c new file mode 100644 index 00000000..d512c380 --- /dev/null +++ b/xts5/Xopen/keysymdef/Test2.c @@ -0,0 +1,696 @@ +/* +Copyright (c) 2005 X.Org Foundation L.L.C. + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies +of the Software, and to permit persons to whom the Software is furnished to do +so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. +*/ +/* +* $Header: /cvs/xtest/xtest/xts5/tset/Xopen/keysymdef/Test2.c,v 1.2 2005-11-03 08:44:00 jmichael Exp $ +* +* Project: VSW5 +* +* File: xts5/tset/Xopen/keysymdef/Test2.c +* +* Description: +* Tests for keysymdef() +* +* Modifications: +* $Log: Test2.c,v $ +* Revision 1.2 2005-11-03 08:44:00 jmichael +* clean up all vsw5 paths to use xts5 instead. +* +* Revision 1.1.1.2 2005/04/15 14:05:40 anderson +* Reimport of the base with the legal name in the copyright fixed. +* +* Revision 8.0 1998/12/23 23:35:36 mar +* Branch point for Release 5.0.2 +* +* Revision 7.0 1998/10/30 22:58:10 mar +* Branch point for Release 5.0.2b1 +* +* Revision 6.0 1998/03/02 05:26:50 tbr +* Branch point for Release 5.0.1 +* +* Revision 5.0 1998/01/26 03:23:23 tbr +* Branch point for Release 5.0.1b1 +* +* Revision 4.1 1996/05/09 21:16:18 andy +* Fixed X includes +* +* Revision 4.0 1995/12/15 09:13:41 tbr +* Branch point for Release 5.0.0 +* +* Revision 3.1 1995/12/15 01:16:58 andy +* Prepare for GA Release +* +*/ +/* + * SCCS: @(#) Test2.c Rel 1.1 (11/28/91) + * + * UniSoft Ltd., London, England + * + * (C) Copyright 1991 X/Open Company Limited + * + * All rights reserved. No part of this source code may be reproduced, + * stored in a retrieval system, or transmitted, in any form or by any + * means, electronic, mechanical, photocopying, recording or otherwise, + * except as stated in the end-user licence agreement, without the prior + * permission of the copyright owners. + * + * X/Open and the 'X' symbol are trademarks of X/Open Company Limited in + * the UK and other countries. + */ + +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif + +#include <stdlib.h> +#include "xtest.h" +#include "X11/Xlib.h" +#include "X11/Xutil.h" +#include "X11/Xresource.h" +#include "tet_api.h" +#include "xtestlib.h" +#include "pixval.h" + +extern char *TestName; + +static int +test(name, val, aval) +char *name; +int val; +int aval; +{ + + if(val != aval) { + report("KeySym \"%s\" is defined to have value 0x%x instead of 0x%x.", name, val, aval); + return(0); + } + return(1); +} + + + +static void +reporterr(s) +char *s; +{ + report("Keysym \"%s\" is not defined.", s); +} + +#define XK_LATIN2 +#include <X11/keysymdef.h> +#undef XK_LATIN2 + +kysymdf2() +{ +int pass = 0, fail = 0; +#ifdef XK_Aogonek + if(test("XK_Aogonek", XK_Aogonek, 0x1A1) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Aogonek"); + FAIL; +#endif + +#ifdef XK_breve + if(test("XK_breve", XK_breve, 0x1A2) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_breve"); + FAIL; +#endif + +#ifdef XK_Lstroke + if(test("XK_Lstroke", XK_Lstroke, 0x1A3) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Lstroke"); + FAIL; +#endif + +#ifdef XK_Lcaron + if(test("XK_Lcaron", XK_Lcaron, 0x1A5) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Lcaron"); + FAIL; +#endif + +#ifdef XK_Sacute + if(test("XK_Sacute", XK_Sacute, 0x1A6) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Sacute"); + FAIL; +#endif + +#ifdef XK_Scaron + if(test("XK_Scaron", XK_Scaron, 0x1A9) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Scaron"); + FAIL; +#endif + +#ifdef XK_Scedilla + if(test("XK_Scedilla", XK_Scedilla, 0x1AA) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Scedilla"); + FAIL; +#endif + +#ifdef XK_Tcaron + if(test("XK_Tcaron", XK_Tcaron, 0x1AB) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Tcaron"); + FAIL; +#endif + +#ifdef XK_Zacute + if(test("XK_Zacute", XK_Zacute, 0x1AC) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Zacute"); + FAIL; +#endif + +#ifdef XK_Zcaron + if(test("XK_Zcaron", XK_Zcaron, 0x1AE) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Zcaron"); + FAIL; +#endif + +#ifdef XK_Zabovedot + if(test("XK_Zabovedot", XK_Zabovedot, 0x1AF) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Zabovedot"); + FAIL; +#endif + +#ifdef XK_aogonek + if(test("XK_aogonek", XK_aogonek, 0x1B1) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_aogonek"); + FAIL; +#endif + +#ifdef XK_ogonek + if(test("XK_ogonek", XK_ogonek, 0x1B2) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_ogonek"); + FAIL; +#endif + +#ifdef XK_lstroke + if(test("XK_lstroke", XK_lstroke, 0x1B3) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_lstroke"); + FAIL; +#endif + +#ifdef XK_lcaron + if(test("XK_lcaron", XK_lcaron, 0x1B5) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_lcaron"); + FAIL; +#endif + +#ifdef XK_sacute + if(test("XK_sacute", XK_sacute, 0x1B6) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_sacute"); + FAIL; +#endif + +#ifdef XK_caron + if(test("XK_caron", XK_caron, 0x1B7) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_caron"); + FAIL; +#endif + +#ifdef XK_scaron + if(test("XK_scaron", XK_scaron, 0x1B9) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_scaron"); + FAIL; +#endif + +#ifdef XK_scedilla + if(test("XK_scedilla", XK_scedilla, 0x1BA) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_scedilla"); + FAIL; +#endif + +#ifdef XK_tcaron + if(test("XK_tcaron", XK_tcaron, 0x1BB) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_tcaron"); + FAIL; +#endif + +#ifdef XK_zacute + if(test("XK_zacute", XK_zacute, 0x1BC) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_zacute"); + FAIL; +#endif + +#ifdef XK_doubleacute + if(test("XK_doubleacute", XK_doubleacute, 0x1BD) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_doubleacute"); + FAIL; +#endif + +#ifdef XK_zcaron + if(test("XK_zcaron", XK_zcaron, 0x1BE) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_zcaron"); + FAIL; +#endif + +#ifdef XK_zabovedot + if(test("XK_zabovedot", XK_zabovedot, 0x1BF) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_zabovedot"); + FAIL; +#endif + +#ifdef XK_Racute + if(test("XK_Racute", XK_Racute, 0x1C0) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Racute"); + FAIL; +#endif + +#ifdef XK_Abreve + if(test("XK_Abreve", XK_Abreve, 0x1C3) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Abreve"); + FAIL; +#endif + +#ifdef XK_Lacute + if(test("XK_Lacute", XK_Lacute, 0x1C5) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Lacute"); + FAIL; +#endif + +#ifdef XK_Cacute + if(test("XK_Cacute", XK_Cacute, 0x1C6) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Cacute"); + FAIL; +#endif + +#ifdef XK_Ccaron + if(test("XK_Ccaron", XK_Ccaron, 0x1C8) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Ccaron"); + FAIL; +#endif + +#ifdef XK_Eogonek + if(test("XK_Eogonek", XK_Eogonek, 0x1CA) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Eogonek"); + FAIL; +#endif + +#ifdef XK_Ecaron + if(test("XK_Ecaron", XK_Ecaron, 0x1CC) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Ecaron"); + FAIL; +#endif + +#ifdef XK_Dcaron + if(test("XK_Dcaron", XK_Dcaron, 0x1CF) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Dcaron"); + FAIL; +#endif + +#ifdef XK_Dstroke + if(test("XK_Dstroke", XK_Dstroke, 0x1D0) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Dstroke"); + FAIL; +#endif + +#ifdef XK_Nacute + if(test("XK_Nacute", XK_Nacute, 0x1D1) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Nacute"); + FAIL; +#endif + +#ifdef XK_Ncaron + if(test("XK_Ncaron", XK_Ncaron, 0x1D2) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Ncaron"); + FAIL; +#endif + +#ifdef XK_Odoubleacute + if(test("XK_Odoubleacute", XK_Odoubleacute, 0x1D5) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Odoubleacute"); + FAIL; +#endif + +#ifdef XK_Rcaron + if(test("XK_Rcaron", XK_Rcaron, 0x1D8) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Rcaron"); + FAIL; +#endif + +#ifdef XK_Uring + if(test("XK_Uring", XK_Uring, 0x1D9) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Uring"); + FAIL; +#endif + +#ifdef XK_Udoubleacute + if(test("XK_Udoubleacute", XK_Udoubleacute, 0x1DB) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Udoubleacute"); + FAIL; +#endif + +#ifdef XK_Tcedilla + if(test("XK_Tcedilla", XK_Tcedilla, 0x1DE) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Tcedilla"); + FAIL; +#endif + +#ifdef XK_racute + if(test("XK_racute", XK_racute, 0x1E0) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_racute"); + FAIL; +#endif + +#ifdef XK_abreve + if(test("XK_abreve", XK_abreve, 0x1E3) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_abreve"); + FAIL; +#endif + +#ifdef XK_lacute + if(test("XK_lacute", XK_lacute, 0x1E5) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_lacute"); + FAIL; +#endif + +#ifdef XK_cacute + if(test("XK_cacute", XK_cacute, 0x1E6) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_cacute"); + FAIL; +#endif + +#ifdef XK_ccaron + if(test("XK_ccaron", XK_ccaron, 0x1E8) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_ccaron"); + FAIL; +#endif + +#ifdef XK_eogonek + if(test("XK_eogonek", XK_eogonek, 0x1EA) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_eogonek"); + FAIL; +#endif + +#ifdef XK_ecaron + if(test("XK_ecaron", XK_ecaron, 0x1EC) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_ecaron"); + FAIL; +#endif + +#ifdef XK_dcaron + if(test("XK_dcaron", XK_dcaron, 0x1EF) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_dcaron"); + FAIL; +#endif + +#ifdef XK_dstroke + if(test("XK_dstroke", XK_dstroke, 0x1F0) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_dstroke"); + FAIL; +#endif + +#ifdef XK_nacute + if(test("XK_nacute", XK_nacute, 0x1F1) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_nacute"); + FAIL; +#endif + +#ifdef XK_ncaron + if(test("XK_ncaron", XK_ncaron, 0x1F2) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_ncaron"); + FAIL; +#endif + +#ifdef XK_odoubleacute + if(test("XK_odoubleacute", XK_odoubleacute, 0x1F5) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_odoubleacute"); + FAIL; +#endif + +#ifdef XK_rcaron + if(test("XK_rcaron", XK_rcaron, 0x1F8) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_rcaron"); + FAIL; +#endif + +#ifdef XK_uring + if(test("XK_uring", XK_uring, 0x1F9) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_uring"); + FAIL; +#endif + +#ifdef XK_udoubleacute + if(test("XK_udoubleacute", XK_udoubleacute, 0x1FB) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_udoubleacute"); + FAIL; +#endif + +#ifdef XK_tcedilla + if(test("XK_tcedilla", XK_tcedilla, 0x1FE) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_tcedilla"); + FAIL; +#endif + +#ifdef XK_abovedot + if(test("XK_abovedot", XK_abovedot, 0x1FF) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_abovedot"); + FAIL; +#endif + + + CHECKPASS(57); +} diff --git a/xts5/Xopen/keysymdef/Test3.c b/xts5/Xopen/keysymdef/Test3.c new file mode 100644 index 00000000..9bf79d5f --- /dev/null +++ b/xts5/Xopen/keysymdef/Test3.c @@ -0,0 +1,346 @@ +/* +Copyright (c) 2005 X.Org Foundation L.L.C. + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies +of the Software, and to permit persons to whom the Software is furnished to do +so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. +*/ +/* +* $Header: /cvs/xtest/xtest/xts5/tset/Xopen/keysymdef/Test3.c,v 1.2 2005-11-03 08:44:00 jmichael Exp $ +* +* Project: VSW5 +* +* File: xts5/tset/Xopen/keysymdef/Test3.c +* +* Description: +* Tests for keysymdef() +* +* Modifications: +* $Log: Test3.c,v $ +* Revision 1.2 2005-11-03 08:44:00 jmichael +* clean up all vsw5 paths to use xts5 instead. +* +* Revision 1.1.1.2 2005/04/15 14:05:40 anderson +* Reimport of the base with the legal name in the copyright fixed. +* +* Revision 8.0 1998/12/23 23:35:36 mar +* Branch point for Release 5.0.2 +* +* Revision 7.0 1998/10/30 22:58:10 mar +* Branch point for Release 5.0.2b1 +* +* Revision 6.0 1998/03/02 05:26:50 tbr +* Branch point for Release 5.0.1 +* +* Revision 5.0 1998/01/26 03:23:23 tbr +* Branch point for Release 5.0.1b1 +* +* Revision 4.1 1996/05/09 21:16:18 andy +* Fixed X includes +* +* Revision 4.0 1995/12/15 09:13:42 tbr +* Branch point for Release 5.0.0 +* +* Revision 3.1 1995/12/15 01:17:00 andy +* Prepare for GA Release +* +*/ +/* + * SCCS: @(#) Test3.c Rel 1.1 (11/28/91) + * + * UniSoft Ltd., London, England + * + * (C) Copyright 1991 X/Open Company Limited + * + * All rights reserved. No part of this source code may be reproduced, + * stored in a retrieval system, or transmitted, in any form or by any + * means, electronic, mechanical, photocopying, recording or otherwise, + * except as stated in the end-user licence agreement, without the prior + * permission of the copyright owners. + * + * X/Open and the 'X' symbol are trademarks of X/Open Company Limited in + * the UK and other countries. + */ + +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif + +#include <stdlib.h> +#include "xtest.h" +#include "X11/Xlib.h" +#include "X11/Xutil.h" +#include "X11/Xresource.h" +#include "tet_api.h" +#include "xtestlib.h" +#include "pixval.h" + +extern char *TestName; + +static int +test(name, val, aval) +char *name; +int val; +int aval; +{ + + if(val != aval) { + report("KeySym \"%s\" is defined to have value 0x%x instead of 0x%x.", name, val, aval); + return(0); + } + return(1); +} + + + +static void +reporterr(s) +char *s; +{ + report("Keysym \"%s\" is not defined.", s); +} + +#define XK_LATIN3 +#include <X11/keysymdef.h> +#undef XK_LATIN3 + +kysymdf3() +{ +int pass = 0, fail = 0; +#ifdef XK_Hstroke + if(test("XK_Hstroke", XK_Hstroke, 0x2A1) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Hstroke"); + FAIL; +#endif + +#ifdef XK_Hcircumflex + if(test("XK_Hcircumflex", XK_Hcircumflex, 0x2A6) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Hcircumflex"); + FAIL; +#endif + +#ifdef XK_Iabovedot + if(test("XK_Iabovedot", XK_Iabovedot, 0x2A9) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Iabovedot"); + FAIL; +#endif + +#ifdef XK_Gbreve + if(test("XK_Gbreve", XK_Gbreve, 0x2AB) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Gbreve"); + FAIL; +#endif + +#ifdef XK_Jcircumflex + if(test("XK_Jcircumflex", XK_Jcircumflex, 0x2AC) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Jcircumflex"); + FAIL; +#endif + +#ifdef XK_hstroke + if(test("XK_hstroke", XK_hstroke, 0x2B1) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_hstroke"); + FAIL; +#endif + +#ifdef XK_hcircumflex + if(test("XK_hcircumflex", XK_hcircumflex, 0x2B6) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_hcircumflex"); + FAIL; +#endif + +#ifdef XK_idotless + if(test("XK_idotless", XK_idotless, 0x2B9) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_idotless"); + FAIL; +#endif + +#ifdef XK_gbreve + if(test("XK_gbreve", XK_gbreve, 0x2BB) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_gbreve"); + FAIL; +#endif + +#ifdef XK_jcircumflex + if(test("XK_jcircumflex", XK_jcircumflex, 0x2BC) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_jcircumflex"); + FAIL; +#endif + +#ifdef XK_Cabovedot + if(test("XK_Cabovedot", XK_Cabovedot, 0x2C5) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Cabovedot"); + FAIL; +#endif + +#ifdef XK_Ccircumflex + if(test("XK_Ccircumflex", XK_Ccircumflex, 0x2C6) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Ccircumflex"); + FAIL; +#endif + +#ifdef XK_Gabovedot + if(test("XK_Gabovedot", XK_Gabovedot, 0x2D5) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Gabovedot"); + FAIL; +#endif + +#ifdef XK_Gcircumflex + if(test("XK_Gcircumflex", XK_Gcircumflex, 0x2D8) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Gcircumflex"); + FAIL; +#endif + +#ifdef XK_Ubreve + if(test("XK_Ubreve", XK_Ubreve, 0x2DD) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Ubreve"); + FAIL; +#endif + +#ifdef XK_Scircumflex + if(test("XK_Scircumflex", XK_Scircumflex, 0x2DE) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Scircumflex"); + FAIL; +#endif + +#ifdef XK_cabovedot + if(test("XK_cabovedot", XK_cabovedot, 0x2E5) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_cabovedot"); + FAIL; +#endif + +#ifdef XK_ccircumflex + if(test("XK_ccircumflex", XK_ccircumflex, 0x2E6) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_ccircumflex"); + FAIL; +#endif + +#ifdef XK_gabovedot + if(test("XK_gabovedot", XK_gabovedot, 0x2F5) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_gabovedot"); + FAIL; +#endif + +#ifdef XK_gcircumflex + if(test("XK_gcircumflex", XK_gcircumflex, 0x2F8) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_gcircumflex"); + FAIL; +#endif + +#ifdef XK_ubreve + if(test("XK_ubreve", XK_ubreve, 0x2FD) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_ubreve"); + FAIL; +#endif + +#ifdef XK_scircumflex + if(test("XK_scircumflex", XK_scircumflex, 0x2FE) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_scircumflex"); + FAIL; +#endif + + + CHECKPASS(22); +} diff --git a/xts5/Xopen/keysymdef/Test4.c b/xts5/Xopen/keysymdef/Test4.c new file mode 100644 index 00000000..92e17fde --- /dev/null +++ b/xts5/Xopen/keysymdef/Test4.c @@ -0,0 +1,486 @@ +/* +Copyright (c) 2005 X.Org Foundation L.L.C. + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies +of the Software, and to permit persons to whom the Software is furnished to do +so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. +*/ +/* +* $Header: /cvs/xtest/xtest/xts5/tset/Xopen/keysymdef/Test4.c,v 1.2 2005-11-03 08:44:00 jmichael Exp $ +* +* Project: VSW5 +* +* File: xts5/tset/Xopen/keysymdef/Test4.c +* +* Description: +* Tests for keysymdef() +* +* Modifications: +* $Log: Test4.c,v $ +* Revision 1.2 2005-11-03 08:44:00 jmichael +* clean up all vsw5 paths to use xts5 instead. +* +* Revision 1.1.1.2 2005/04/15 14:05:40 anderson +* Reimport of the base with the legal name in the copyright fixed. +* +* Revision 8.0 1998/12/23 23:35:37 mar +* Branch point for Release 5.0.2 +* +* Revision 7.0 1998/10/30 22:58:11 mar +* Branch point for Release 5.0.2b1 +* +* Revision 6.0 1998/03/02 05:26:51 tbr +* Branch point for Release 5.0.1 +* +* Revision 5.0 1998/01/26 03:23:24 tbr +* Branch point for Release 5.0.1b1 +* +* Revision 4.1 1996/05/09 21:16:18 andy +* Fixed X includes +* +* Revision 4.0 1995/12/15 09:13:44 tbr +* Branch point for Release 5.0.0 +* +* Revision 3.1 1995/12/15 01:17:01 andy +* Prepare for GA Release +* +*/ +/* + * SCCS: @(#) Test4.c Rel 1.1 (11/28/91) + * + * UniSoft Ltd., London, England + * + * (C) Copyright 1991 X/Open Company Limited + * + * All rights reserved. No part of this source code may be reproduced, + * stored in a retrieval system, or transmitted, in any form or by any + * means, electronic, mechanical, photocopying, recording or otherwise, + * except as stated in the end-user licence agreement, without the prior + * permission of the copyright owners. + * + * X/Open and the 'X' symbol are trademarks of X/Open Company Limited in + * the UK and other countries. + */ + +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif + +#include <stdlib.h> +#include "xtest.h" +#include "X11/Xlib.h" +#include "X11/Xutil.h" +#include "X11/Xresource.h" +#include "tet_api.h" +#include "xtestlib.h" +#include "pixval.h" + +extern char *TestName; + +static int +test(name, val, aval) +char *name; +int val; +int aval; +{ + + if(val != aval) { + report("KeySym \"%s\" is defined to have value 0x%x instead of 0x%x.", name, val, aval); + return(0); + } + return(1); +} + + + +static void +reporterr(s) +char *s; +{ + report("Keysym \"%s\" is not defined.", s); +} + +#define XK_LATIN4 +#include <X11/keysymdef.h> +#undef XK_LATIN4 + +kysymdf4() +{ +int pass = 0, fail = 0; +#ifdef XK_kra + if(test("XK_kra", XK_kra, 0x3A2) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_kra"); + FAIL; +#endif + +#ifdef XK_kappa + if(test("XK_kappa", XK_kappa, 0x3A2) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_kappa"); + FAIL; +#endif + +#ifdef XK_Rcedilla + if(test("XK_Rcedilla", XK_Rcedilla, 0x3A3) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Rcedilla"); + FAIL; +#endif + +#ifdef XK_Itilde + if(test("XK_Itilde", XK_Itilde, 0x3A5) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Itilde"); + FAIL; +#endif + +#ifdef XK_Lcedilla + if(test("XK_Lcedilla", XK_Lcedilla, 0x3A6) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Lcedilla"); + FAIL; +#endif + +#ifdef XK_Emacron + if(test("XK_Emacron", XK_Emacron, 0x3AA) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Emacron"); + FAIL; +#endif + +#ifdef XK_Gcedilla + if(test("XK_Gcedilla", XK_Gcedilla, 0x3AB) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Gcedilla"); + FAIL; +#endif + +#ifdef XK_Tslash + if(test("XK_Tslash", XK_Tslash, 0x3AC) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Tslash"); + FAIL; +#endif + +#ifdef XK_rcedilla + if(test("XK_rcedilla", XK_rcedilla, 0x3B3) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_rcedilla"); + FAIL; +#endif + +#ifdef XK_itilde + if(test("XK_itilde", XK_itilde, 0x3B5) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_itilde"); + FAIL; +#endif + +#ifdef XK_lcedilla + if(test("XK_lcedilla", XK_lcedilla, 0x3B6) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_lcedilla"); + FAIL; +#endif + +#ifdef XK_emacron + if(test("XK_emacron", XK_emacron, 0x3BA) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_emacron"); + FAIL; +#endif + +#ifdef XK_gcedilla + if(test("XK_gcedilla", XK_gcedilla, 0x3BB) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_gcedilla"); + FAIL; +#endif + +#ifdef XK_tslash + if(test("XK_tslash", XK_tslash, 0x3BC) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_tslash"); + FAIL; +#endif + +#ifdef XK_ENG + if(test("XK_ENG", XK_ENG, 0x3BD) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_ENG"); + FAIL; +#endif + +#ifdef XK_eng + if(test("XK_eng", XK_eng, 0x3BF) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_eng"); + FAIL; +#endif + +#ifdef XK_Amacron + if(test("XK_Amacron", XK_Amacron, 0x3C0) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Amacron"); + FAIL; +#endif + +#ifdef XK_Iogonek + if(test("XK_Iogonek", XK_Iogonek, 0x3C7) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Iogonek"); + FAIL; +#endif + +#ifdef XK_Eabovedot + if(test("XK_Eabovedot", XK_Eabovedot, 0x3CC) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Eabovedot"); + FAIL; +#endif + +#ifdef XK_Imacron + if(test("XK_Imacron", XK_Imacron, 0x3CF) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Imacron"); + FAIL; +#endif + +#ifdef XK_Ncedilla + if(test("XK_Ncedilla", XK_Ncedilla, 0x3D1) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Ncedilla"); + FAIL; +#endif + +#ifdef XK_Omacron + if(test("XK_Omacron", XK_Omacron, 0x3D2) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Omacron"); + FAIL; +#endif + +#ifdef XK_Kcedilla + if(test("XK_Kcedilla", XK_Kcedilla, 0x3D3) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Kcedilla"); + FAIL; +#endif + +#ifdef XK_Uogonek + if(test("XK_Uogonek", XK_Uogonek, 0x3D9) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Uogonek"); + FAIL; +#endif + +#ifdef XK_Utilde + if(test("XK_Utilde", XK_Utilde, 0x3DD) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Utilde"); + FAIL; +#endif + +#ifdef XK_Umacron + if(test("XK_Umacron", XK_Umacron, 0x3DE) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Umacron"); + FAIL; +#endif + +#ifdef XK_amacron + if(test("XK_amacron", XK_amacron, 0x3E0) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_amacron"); + FAIL; +#endif + +#ifdef XK_iogonek + if(test("XK_iogonek", XK_iogonek, 0x3E7) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_iogonek"); + FAIL; +#endif + +#ifdef XK_eabovedot + if(test("XK_eabovedot", XK_eabovedot, 0x3EC) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_eabovedot"); + FAIL; +#endif + +#ifdef XK_imacron + if(test("XK_imacron", XK_imacron, 0x3EF) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_imacron"); + FAIL; +#endif + +#ifdef XK_ncedilla + if(test("XK_ncedilla", XK_ncedilla, 0x3F1) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_ncedilla"); + FAIL; +#endif + +#ifdef XK_omacron + if(test("XK_omacron", XK_omacron, 0x3F2) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_omacron"); + FAIL; +#endif + +#ifdef XK_kcedilla + if(test("XK_kcedilla", XK_kcedilla, 0x3F3) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_kcedilla"); + FAIL; +#endif + +#ifdef XK_uogonek + if(test("XK_uogonek", XK_uogonek, 0x3F9) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_uogonek"); + FAIL; +#endif + +#ifdef XK_utilde + if(test("XK_utilde", XK_utilde, 0x3FD) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_utilde"); + FAIL; +#endif + +#ifdef XK_umacron + if(test("XK_umacron", XK_umacron, 0x3FE) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_umacron"); + FAIL; +#endif + + + CHECKPASS(36); +} diff --git a/xts5/Xopen/keysymdef/TestA.c b/xts5/Xopen/keysymdef/TestA.c new file mode 100644 index 00000000..f447f147 --- /dev/null +++ b/xts5/Xopen/keysymdef/TestA.c @@ -0,0 +1,626 @@ +/* +Copyright (c) 2005 X.Org Foundation L.L.C. + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies +of the Software, and to permit persons to whom the Software is furnished to do +so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. +*/ +/* +* $Header: /cvs/xtest/xtest/xts5/tset/Xopen/keysymdef/TestA.c,v 1.2 2005-11-03 08:44:00 jmichael Exp $ +* +* Project: VSW5 +* +* File: xts5/tset/Xopen/keysymdef/TestA.c +* +* Description: +* Tests for keysymdef() +* +* Modifications: +* $Log: TestA.c,v $ +* Revision 1.2 2005-11-03 08:44:00 jmichael +* clean up all vsw5 paths to use xts5 instead. +* +* Revision 1.1.1.2 2005/04/15 14:05:40 anderson +* Reimport of the base with the legal name in the copyright fixed. +* +* Revision 8.0 1998/12/23 23:35:37 mar +* Branch point for Release 5.0.2 +* +* Revision 7.0 1998/10/30 22:58:12 mar +* Branch point for Release 5.0.2b1 +* +* Revision 6.0 1998/03/02 05:26:51 tbr +* Branch point for Release 5.0.1 +* +* Revision 5.0 1998/01/26 03:23:25 tbr +* Branch point for Release 5.0.1b1 +* +* Revision 4.1 1996/05/09 21:16:18 andy +* Fixed X includes +* +* Revision 4.0 1995/12/15 09:13:45 tbr +* Branch point for Release 5.0.0 +* +* Revision 3.1 1995/12/15 01:17:02 andy +* Prepare for GA Release +* +*/ +/* + * SCCS: @(#) TestA.c Rel 1.1 (11/28/91) + * + * UniSoft Ltd., London, England + * + * (C) Copyright 1991 X/Open Company Limited + * + * All rights reserved. No part of this source code may be reproduced, + * stored in a retrieval system, or transmitted, in any form or by any + * means, electronic, mechanical, photocopying, recording or otherwise, + * except as stated in the end-user licence agreement, without the prior + * permission of the copyright owners. + * + * X/Open and the 'X' symbol are trademarks of X/Open Company Limited in + * the UK and other countries. + */ + +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif + +#include <stdlib.h> +#include "xtest.h" +#include "X11/Xlib.h" +#include "X11/Xutil.h" +#include "X11/Xresource.h" +#include "tet_api.h" +#include "xtestlib.h" +#include "pixval.h" + +extern char *TestName; + +static int +test(name, val, aval) +char *name; +int val; +int aval; +{ + + if(val != aval) { + report("KeySym \"%s\" is defined to have value 0x%x instead of 0x%x.", name, val, aval); + return(0); + } + return(1); +} + + + +static void +reporterr(s) +char *s; +{ + report("Keysym \"%s\" is not defined.", s); +} + +#define XK_ARABIC +#include <X11/keysymdef.h> +#undef XK_ARABIC + +kysymdf5() +{ +int pass = 0, fail = 0; +#ifdef XK_Arabic_comma + if(test("XK_Arabic_comma", XK_Arabic_comma, 0x5AC) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Arabic_comma"); + FAIL; +#endif + +#ifdef XK_Arabic_semicolon + if(test("XK_Arabic_semicolon", XK_Arabic_semicolon, 0x5BB) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Arabic_semicolon"); + FAIL; +#endif + +#ifdef XK_Arabic_question_mark + if(test("XK_Arabic_question_mark", XK_Arabic_question_mark, 0x5BF) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Arabic_question_mark"); + FAIL; +#endif + +#ifdef XK_Arabic_hamza + if(test("XK_Arabic_hamza", XK_Arabic_hamza, 0x5C1) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Arabic_hamza"); + FAIL; +#endif + +#ifdef XK_Arabic_maddaonalef + if(test("XK_Arabic_maddaonalef", XK_Arabic_maddaonalef, 0x5C2) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Arabic_maddaonalef"); + FAIL; +#endif + +#ifdef XK_Arabic_hamzaonalef + if(test("XK_Arabic_hamzaonalef", XK_Arabic_hamzaonalef, 0x5C3) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Arabic_hamzaonalef"); + FAIL; +#endif + +#ifdef XK_Arabic_hamzaonwaw + if(test("XK_Arabic_hamzaonwaw", XK_Arabic_hamzaonwaw, 0x5C4) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Arabic_hamzaonwaw"); + FAIL; +#endif + +#ifdef XK_Arabic_hamzaunderalef + if(test("XK_Arabic_hamzaunderalef", XK_Arabic_hamzaunderalef, 0x5C5) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Arabic_hamzaunderalef"); + FAIL; +#endif + +#ifdef XK_Arabic_hamzaonyeh + if(test("XK_Arabic_hamzaonyeh", XK_Arabic_hamzaonyeh, 0x5C6) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Arabic_hamzaonyeh"); + FAIL; +#endif + +#ifdef XK_Arabic_alef + if(test("XK_Arabic_alef", XK_Arabic_alef, 0x5C7) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Arabic_alef"); + FAIL; +#endif + +#ifdef XK_Arabic_beh + if(test("XK_Arabic_beh", XK_Arabic_beh, 0x5C8) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Arabic_beh"); + FAIL; +#endif + +#ifdef XK_Arabic_tehmarbuta + if(test("XK_Arabic_tehmarbuta", XK_Arabic_tehmarbuta, 0x5C9) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Arabic_tehmarbuta"); + FAIL; +#endif + +#ifdef XK_Arabic_teh + if(test("XK_Arabic_teh", XK_Arabic_teh, 0x5CA) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Arabic_teh"); + FAIL; +#endif + +#ifdef XK_Arabic_theh + if(test("XK_Arabic_theh", XK_Arabic_theh, 0x5CB) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Arabic_theh"); + FAIL; +#endif + +#ifdef XK_Arabic_jeem + if(test("XK_Arabic_jeem", XK_Arabic_jeem, 0x5CC) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Arabic_jeem"); + FAIL; +#endif + +#ifdef XK_Arabic_hah + if(test("XK_Arabic_hah", XK_Arabic_hah, 0x5CD) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Arabic_hah"); + FAIL; +#endif + +#ifdef XK_Arabic_khah + if(test("XK_Arabic_khah", XK_Arabic_khah, 0x5CE) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Arabic_khah"); + FAIL; +#endif + +#ifdef XK_Arabic_dal + if(test("XK_Arabic_dal", XK_Arabic_dal, 0x5CF) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Arabic_dal"); + FAIL; +#endif + +#ifdef XK_Arabic_thal + if(test("XK_Arabic_thal", XK_Arabic_thal, 0x5D0) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Arabic_thal"); + FAIL; +#endif + +#ifdef XK_Arabic_ra + if(test("XK_Arabic_ra", XK_Arabic_ra, 0x5D1) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Arabic_ra"); + FAIL; +#endif + +#ifdef XK_Arabic_zain + if(test("XK_Arabic_zain", XK_Arabic_zain, 0x5D2) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Arabic_zain"); + FAIL; +#endif + +#ifdef XK_Arabic_seen + if(test("XK_Arabic_seen", XK_Arabic_seen, 0x5D3) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Arabic_seen"); + FAIL; +#endif + +#ifdef XK_Arabic_sheen + if(test("XK_Arabic_sheen", XK_Arabic_sheen, 0x5D4) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Arabic_sheen"); + FAIL; +#endif + +#ifdef XK_Arabic_sad + if(test("XK_Arabic_sad", XK_Arabic_sad, 0x5D5) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Arabic_sad"); + FAIL; +#endif + +#ifdef XK_Arabic_dad + if(test("XK_Arabic_dad", XK_Arabic_dad, 0x5D6) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Arabic_dad"); + FAIL; +#endif + +#ifdef XK_Arabic_tah + if(test("XK_Arabic_tah", XK_Arabic_tah, 0x5D7) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Arabic_tah"); + FAIL; +#endif + +#ifdef XK_Arabic_zah + if(test("XK_Arabic_zah", XK_Arabic_zah, 0x5D8) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Arabic_zah"); + FAIL; +#endif + +#ifdef XK_Arabic_ain + if(test("XK_Arabic_ain", XK_Arabic_ain, 0x5D9) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Arabic_ain"); + FAIL; +#endif + +#ifdef XK_Arabic_ghain + if(test("XK_Arabic_ghain", XK_Arabic_ghain, 0x5DA) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Arabic_ghain"); + FAIL; +#endif + +#ifdef XK_Arabic_tatweel + if(test("XK_Arabic_tatweel", XK_Arabic_tatweel, 0x5E0) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Arabic_tatweel"); + FAIL; +#endif + +#ifdef XK_Arabic_feh + if(test("XK_Arabic_feh", XK_Arabic_feh, 0x5E1) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Arabic_feh"); + FAIL; +#endif + +#ifdef XK_Arabic_qaf + if(test("XK_Arabic_qaf", XK_Arabic_qaf, 0x5E2) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Arabic_qaf"); + FAIL; +#endif + +#ifdef XK_Arabic_kaf + if(test("XK_Arabic_kaf", XK_Arabic_kaf, 0x5E3) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Arabic_kaf"); + FAIL; +#endif + +#ifdef XK_Arabic_lam + if(test("XK_Arabic_lam", XK_Arabic_lam, 0x5E4) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Arabic_lam"); + FAIL; +#endif + +#ifdef XK_Arabic_meem + if(test("XK_Arabic_meem", XK_Arabic_meem, 0x5E5) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Arabic_meem"); + FAIL; +#endif + +#ifdef XK_Arabic_noon + if(test("XK_Arabic_noon", XK_Arabic_noon, 0x5E6) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Arabic_noon"); + FAIL; +#endif + +#ifdef XK_Arabic_ha + if(test("XK_Arabic_ha", XK_Arabic_ha, 0x5E7) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Arabic_ha"); + FAIL; +#endif + +#ifdef XK_Arabic_heh + if(test("XK_Arabic_heh", XK_Arabic_heh, 0x5E7) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Arabic_heh"); + FAIL; +#endif + +#ifdef XK_Arabic_waw + if(test("XK_Arabic_waw", XK_Arabic_waw, 0x5E8) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Arabic_waw"); + FAIL; +#endif + +#ifdef XK_Arabic_alefmaksura + if(test("XK_Arabic_alefmaksura", XK_Arabic_alefmaksura, 0x5E9) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Arabic_alefmaksura"); + FAIL; +#endif + +#ifdef XK_Arabic_yeh + if(test("XK_Arabic_yeh", XK_Arabic_yeh, 0x5EA) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Arabic_yeh"); + FAIL; +#endif + +#ifdef XK_Arabic_fathatan + if(test("XK_Arabic_fathatan", XK_Arabic_fathatan, 0x5EB) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Arabic_fathatan"); + FAIL; +#endif + +#ifdef XK_Arabic_dammatan + if(test("XK_Arabic_dammatan", XK_Arabic_dammatan, 0x5EC) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Arabic_dammatan"); + FAIL; +#endif + +#ifdef XK_Arabic_kasratan + if(test("XK_Arabic_kasratan", XK_Arabic_kasratan, 0x5ED) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Arabic_kasratan"); + FAIL; +#endif + +#ifdef XK_Arabic_fatha + if(test("XK_Arabic_fatha", XK_Arabic_fatha, 0x5EE) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Arabic_fatha"); + FAIL; +#endif + +#ifdef XK_Arabic_damma + if(test("XK_Arabic_damma", XK_Arabic_damma, 0x5EF) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Arabic_damma"); + FAIL; +#endif + +#ifdef XK_Arabic_kasra + if(test("XK_Arabic_kasra", XK_Arabic_kasra, 0x5F0) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Arabic_kasra"); + FAIL; +#endif + +#ifdef XK_Arabic_shadda + if(test("XK_Arabic_shadda", XK_Arabic_shadda, 0x5F1) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Arabic_shadda"); + FAIL; +#endif + +#ifdef XK_Arabic_sukun + if(test("XK_Arabic_sukun", XK_Arabic_sukun, 0x5F2) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Arabic_sukun"); + FAIL; +#endif + +#ifdef XK_Arabic_switch + if(test("XK_Arabic_switch", XK_Arabic_switch, 0xFF7E) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Arabic_switch"); + FAIL; +#endif + + + CHECKPASS(50); +} diff --git a/xts5/Xopen/keysymdef/TestC.c b/xts5/Xopen/keysymdef/TestC.c new file mode 100644 index 00000000..b9ddc357 --- /dev/null +++ b/xts5/Xopen/keysymdef/TestC.c @@ -0,0 +1,1196 @@ +/* +Copyright (c) 2005 X.Org Foundation L.L.C. + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies +of the Software, and to permit persons to whom the Software is furnished to do +so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. +*/ +/* +* $Header: /cvs/xtest/xtest/xts5/tset/Xopen/keysymdef/TestC.c,v 1.2 2005-11-03 08:44:00 jmichael Exp $ +* +* Project: VSW5 +* +* File: xts5/tset/Xopen/keysymdef/TestC.c +* +* Description: +* Tests for keysymdef() +* +* Modifications: +* $Log: TestC.c,v $ +* Revision 1.2 2005-11-03 08:44:00 jmichael +* clean up all vsw5 paths to use xts5 instead. +* +* Revision 1.1.1.2 2005/04/15 14:05:40 anderson +* Reimport of the base with the legal name in the copyright fixed. +* +* Revision 8.0 1998/12/23 23:35:38 mar +* Branch point for Release 5.0.2 +* +* Revision 7.0 1998/10/30 22:58:13 mar +* Branch point for Release 5.0.2b1 +* +* Revision 6.0 1998/03/02 05:26:52 tbr +* Branch point for Release 5.0.1 +* +* Revision 5.0 1998/01/26 03:23:25 tbr +* Branch point for Release 5.0.1b1 +* +* Revision 4.1 1996/05/09 21:16:18 andy +* Fixed X includes +* +* Revision 4.0 1995/12/15 09:13:46 tbr +* Branch point for Release 5.0.0 +* +* Revision 3.1 1995/12/15 01:17:04 andy +* Prepare for GA Release +* +*/ +/* + * SCCS: @(#) TestC.c Rel 1.1 (11/28/91) + * + * UniSoft Ltd., London, England + * + * (C) Copyright 1991 X/Open Company Limited + * + * All rights reserved. No part of this source code may be reproduced, + * stored in a retrieval system, or transmitted, in any form or by any + * means, electronic, mechanical, photocopying, recording or otherwise, + * except as stated in the end-user licence agreement, without the prior + * permission of the copyright owners. + * + * X/Open and the 'X' symbol are trademarks of X/Open Company Limited in + * the UK and other countries. + */ + +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif + +#include <stdlib.h> +#include "xtest.h" +#include "X11/Xlib.h" +#include "X11/Xutil.h" +#include "X11/Xresource.h" +#include "tet_api.h" +#include "xtestlib.h" +#include "pixval.h" + +extern char *TestName; + +static int +test(name, val, aval) +char *name; +int val; +int aval; +{ + + if(val != aval) { + report("KeySym \"%s\" is defined to have value 0x%x instead of 0x%x.", name, val, aval); + return(0); + } + return(1); +} + + + +static void +reporterr(s) +char *s; +{ + report("Keysym \"%s\" is not defined.", s); +} + +#define XK_CYRILLIC +#include <X11/keysymdef.h> +#undef XK_CYRILLIC + +kysymdf6() +{ +int pass = 0, fail = 0; +#ifdef XK_Serbian_dje + if(test("XK_Serbian_dje", XK_Serbian_dje, 0x6A1) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Serbian_dje"); + FAIL; +#endif + +#ifdef XK_Macedonia_gje + if(test("XK_Macedonia_gje", XK_Macedonia_gje, 0x6A2) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Macedonia_gje"); + FAIL; +#endif + +#ifdef XK_Cyrillic_io + if(test("XK_Cyrillic_io", XK_Cyrillic_io, 0x6A3) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Cyrillic_io"); + FAIL; +#endif + +#ifdef XK_Ukrainian_ie + if(test("XK_Ukrainian_ie", XK_Ukrainian_ie, 0x6A4) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Ukrainian_ie"); + FAIL; +#endif + +#ifdef XK_Ukranian_je + if(test("XK_Ukranian_je", XK_Ukranian_je, 0x6A4) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Ukranian_je"); + FAIL; +#endif + +#ifdef XK_Macedonia_dse + if(test("XK_Macedonia_dse", XK_Macedonia_dse, 0x6A5) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Macedonia_dse"); + FAIL; +#endif + +#ifdef XK_Ukrainian_i + if(test("XK_Ukrainian_i", XK_Ukrainian_i, 0x6A6) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Ukrainian_i"); + FAIL; +#endif + +#ifdef XK_Ukranian_i + if(test("XK_Ukranian_i", XK_Ukranian_i, 0x6A6) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Ukranian_i"); + FAIL; +#endif + +#ifdef XK_Ukrainian_yi + if(test("XK_Ukrainian_yi", XK_Ukrainian_yi, 0x6A7) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Ukrainian_yi"); + FAIL; +#endif + +#ifdef XK_Ukranian_yi + if(test("XK_Ukranian_yi", XK_Ukranian_yi, 0x6A7) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Ukranian_yi"); + FAIL; +#endif + +#ifdef XK_Cyrillic_je + if(test("XK_Cyrillic_je", XK_Cyrillic_je, 0x6A8) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Cyrillic_je"); + FAIL; +#endif + +#ifdef XK_Serbian_je + if(test("XK_Serbian_je", XK_Serbian_je, 0x6A8) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Serbian_je"); + FAIL; +#endif + +#ifdef XK_Cyrillic_lje + if(test("XK_Cyrillic_lje", XK_Cyrillic_lje, 0x6A9) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Cyrillic_lje"); + FAIL; +#endif + +#ifdef XK_Serbian_lje + if(test("XK_Serbian_lje", XK_Serbian_lje, 0x6A9) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Serbian_lje"); + FAIL; +#endif + +#ifdef XK_Cyrillic_nje + if(test("XK_Cyrillic_nje", XK_Cyrillic_nje, 0x6AA) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Cyrillic_nje"); + FAIL; +#endif + +#ifdef XK_Serbian_nje + if(test("XK_Serbian_nje", XK_Serbian_nje, 0x6AA) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Serbian_nje"); + FAIL; +#endif + +#ifdef XK_Serbian_tshe + if(test("XK_Serbian_tshe", XK_Serbian_tshe, 0x6AB) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Serbian_tshe"); + FAIL; +#endif + +#ifdef XK_Macedonia_kje + if(test("XK_Macedonia_kje", XK_Macedonia_kje, 0x6AC) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Macedonia_kje"); + FAIL; +#endif + +#ifdef XK_Byelorussian_shortu + if(test("XK_Byelorussian_shortu", XK_Byelorussian_shortu, 0x6AE) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Byelorussian_shortu"); + FAIL; +#endif + +#ifdef XK_Cyrillic_dzhe + if(test("XK_Cyrillic_dzhe", XK_Cyrillic_dzhe, 0x6AF) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Cyrillic_dzhe"); + FAIL; +#endif + +#ifdef XK_Serbian_dze + if(test("XK_Serbian_dze", XK_Serbian_dze, 0x6AF) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Serbian_dze"); + FAIL; +#endif + +#ifdef XK_numerosign + if(test("XK_numerosign", XK_numerosign, 0x6B0) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_numerosign"); + FAIL; +#endif + +#ifdef XK_Serbian_DJE + if(test("XK_Serbian_DJE", XK_Serbian_DJE, 0x6B1) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Serbian_DJE"); + FAIL; +#endif + +#ifdef XK_Macedonia_GJE + if(test("XK_Macedonia_GJE", XK_Macedonia_GJE, 0x6B2) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Macedonia_GJE"); + FAIL; +#endif + +#ifdef XK_Cyrillic_IO + if(test("XK_Cyrillic_IO", XK_Cyrillic_IO, 0x6B3) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Cyrillic_IO"); + FAIL; +#endif + +#ifdef XK_Ukrainian_IE + if(test("XK_Ukrainian_IE", XK_Ukrainian_IE, 0x6B4) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Ukrainian_IE"); + FAIL; +#endif + +#ifdef XK_Ukranian_JE + if(test("XK_Ukranian_JE", XK_Ukranian_JE, 0x6B4) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Ukranian_JE"); + FAIL; +#endif + +#ifdef XK_Macedonia_DSE + if(test("XK_Macedonia_DSE", XK_Macedonia_DSE, 0x6B5) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Macedonia_DSE"); + FAIL; +#endif + +#ifdef XK_Ukrainian_I + if(test("XK_Ukrainian_I", XK_Ukrainian_I, 0x6B6) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Ukrainian_I"); + FAIL; +#endif + +#ifdef XK_Ukranian_I + if(test("XK_Ukranian_I", XK_Ukranian_I, 0x6B6) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Ukranian_I"); + FAIL; +#endif + +#ifdef XK_Ukrainian_YI + if(test("XK_Ukrainian_YI", XK_Ukrainian_YI, 0x6B7) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Ukrainian_YI"); + FAIL; +#endif + +#ifdef XK_Ukranian_YI + if(test("XK_Ukranian_YI", XK_Ukranian_YI, 0x6B7) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Ukranian_YI"); + FAIL; +#endif + +#ifdef XK_Cyrillic_JE + if(test("XK_Cyrillic_JE", XK_Cyrillic_JE, 0x6B8) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Cyrillic_JE"); + FAIL; +#endif + +#ifdef XK_Serbian_JE + if(test("XK_Serbian_JE", XK_Serbian_JE, 0x6B8) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Serbian_JE"); + FAIL; +#endif + +#ifdef XK_Cyrillic_LJE + if(test("XK_Cyrillic_LJE", XK_Cyrillic_LJE, 0x6B9) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Cyrillic_LJE"); + FAIL; +#endif + +#ifdef XK_Serbian_LJE + if(test("XK_Serbian_LJE", XK_Serbian_LJE, 0x6B9) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Serbian_LJE"); + FAIL; +#endif + +#ifdef XK_Cyrillic_NJE + if(test("XK_Cyrillic_NJE", XK_Cyrillic_NJE, 0x6BA) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Cyrillic_NJE"); + FAIL; +#endif + +#ifdef XK_Serbian_NJE + if(test("XK_Serbian_NJE", XK_Serbian_NJE, 0x6BA) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Serbian_NJE"); + FAIL; +#endif + +#ifdef XK_Serbian_TSHE + if(test("XK_Serbian_TSHE", XK_Serbian_TSHE, 0x6BB) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Serbian_TSHE"); + FAIL; +#endif + +#ifdef XK_Macedonia_KJE + if(test("XK_Macedonia_KJE", XK_Macedonia_KJE, 0x6BC) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Macedonia_KJE"); + FAIL; +#endif + +#ifdef XK_Byelorussian_SHORTU + if(test("XK_Byelorussian_SHORTU", XK_Byelorussian_SHORTU, 0x6BE) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Byelorussian_SHORTU"); + FAIL; +#endif + +#ifdef XK_Cyrillic_DZHE + if(test("XK_Cyrillic_DZHE", XK_Cyrillic_DZHE, 0x6BF) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Cyrillic_DZHE"); + FAIL; +#endif + +#ifdef XK_Serbian_DZE + if(test("XK_Serbian_DZE", XK_Serbian_DZE, 0x6BF) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Serbian_DZE"); + FAIL; +#endif + +#ifdef XK_Cyrillic_yu + if(test("XK_Cyrillic_yu", XK_Cyrillic_yu, 0x6C0) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Cyrillic_yu"); + FAIL; +#endif + +#ifdef XK_Cyrillic_a + if(test("XK_Cyrillic_a", XK_Cyrillic_a, 0x6C1) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Cyrillic_a"); + FAIL; +#endif + +#ifdef XK_Cyrillic_be + if(test("XK_Cyrillic_be", XK_Cyrillic_be, 0x6C2) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Cyrillic_be"); + FAIL; +#endif + +#ifdef XK_Cyrillic_tse + if(test("XK_Cyrillic_tse", XK_Cyrillic_tse, 0x6C3) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Cyrillic_tse"); + FAIL; +#endif + +#ifdef XK_Cyrillic_de + if(test("XK_Cyrillic_de", XK_Cyrillic_de, 0x6C4) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Cyrillic_de"); + FAIL; +#endif + +#ifdef XK_Cyrillic_ie + if(test("XK_Cyrillic_ie", XK_Cyrillic_ie, 0x6C5) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Cyrillic_ie"); + FAIL; +#endif + +#ifdef XK_Cyrillic_ef + if(test("XK_Cyrillic_ef", XK_Cyrillic_ef, 0x6C6) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Cyrillic_ef"); + FAIL; +#endif + +#ifdef XK_Cyrillic_ghe + if(test("XK_Cyrillic_ghe", XK_Cyrillic_ghe, 0x6C7) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Cyrillic_ghe"); + FAIL; +#endif + +#ifdef XK_Cyrillic_ha + if(test("XK_Cyrillic_ha", XK_Cyrillic_ha, 0x6C8) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Cyrillic_ha"); + FAIL; +#endif + +#ifdef XK_Cyrillic_i + if(test("XK_Cyrillic_i", XK_Cyrillic_i, 0x6C9) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Cyrillic_i"); + FAIL; +#endif + +#ifdef XK_Cyrillic_shorti + if(test("XK_Cyrillic_shorti", XK_Cyrillic_shorti, 0x6CA) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Cyrillic_shorti"); + FAIL; +#endif + +#ifdef XK_Cyrillic_ka + if(test("XK_Cyrillic_ka", XK_Cyrillic_ka, 0x6CB) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Cyrillic_ka"); + FAIL; +#endif + +#ifdef XK_Cyrillic_el + if(test("XK_Cyrillic_el", XK_Cyrillic_el, 0x6CC) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Cyrillic_el"); + FAIL; +#endif + +#ifdef XK_Cyrillic_em + if(test("XK_Cyrillic_em", XK_Cyrillic_em, 0x6CD) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Cyrillic_em"); + FAIL; +#endif + +#ifdef XK_Cyrillic_en + if(test("XK_Cyrillic_en", XK_Cyrillic_en, 0x6CE) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Cyrillic_en"); + FAIL; +#endif + +#ifdef XK_Cyrillic_o + if(test("XK_Cyrillic_o", XK_Cyrillic_o, 0x6CF) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Cyrillic_o"); + FAIL; +#endif + +#ifdef XK_Cyrillic_pe + if(test("XK_Cyrillic_pe", XK_Cyrillic_pe, 0x6D0) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Cyrillic_pe"); + FAIL; +#endif + +#ifdef XK_Cyrillic_ya + if(test("XK_Cyrillic_ya", XK_Cyrillic_ya, 0x6D1) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Cyrillic_ya"); + FAIL; +#endif + +#ifdef XK_Cyrillic_er + if(test("XK_Cyrillic_er", XK_Cyrillic_er, 0x6D2) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Cyrillic_er"); + FAIL; +#endif + +#ifdef XK_Cyrillic_es + if(test("XK_Cyrillic_es", XK_Cyrillic_es, 0x6D3) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Cyrillic_es"); + FAIL; +#endif + +#ifdef XK_Cyrillic_te + if(test("XK_Cyrillic_te", XK_Cyrillic_te, 0x6D4) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Cyrillic_te"); + FAIL; +#endif + +#ifdef XK_Cyrillic_u + if(test("XK_Cyrillic_u", XK_Cyrillic_u, 0x6D5) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Cyrillic_u"); + FAIL; +#endif + +#ifdef XK_Cyrillic_zhe + if(test("XK_Cyrillic_zhe", XK_Cyrillic_zhe, 0x6D6) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Cyrillic_zhe"); + FAIL; +#endif + +#ifdef XK_Cyrillic_ve + if(test("XK_Cyrillic_ve", XK_Cyrillic_ve, 0x6D7) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Cyrillic_ve"); + FAIL; +#endif + +#ifdef XK_Cyrillic_softsign + if(test("XK_Cyrillic_softsign", XK_Cyrillic_softsign, 0x6D8) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Cyrillic_softsign"); + FAIL; +#endif + +#ifdef XK_Cyrillic_yeru + if(test("XK_Cyrillic_yeru", XK_Cyrillic_yeru, 0x6D9) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Cyrillic_yeru"); + FAIL; +#endif + +#ifdef XK_Cyrillic_ze + if(test("XK_Cyrillic_ze", XK_Cyrillic_ze, 0x6DA) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Cyrillic_ze"); + FAIL; +#endif + +#ifdef XK_Cyrillic_sha + if(test("XK_Cyrillic_sha", XK_Cyrillic_sha, 0x6DB) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Cyrillic_sha"); + FAIL; +#endif + +#ifdef XK_Cyrillic_e + if(test("XK_Cyrillic_e", XK_Cyrillic_e, 0x6DC) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Cyrillic_e"); + FAIL; +#endif + +#ifdef XK_Cyrillic_shcha + if(test("XK_Cyrillic_shcha", XK_Cyrillic_shcha, 0x6DD) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Cyrillic_shcha"); + FAIL; +#endif + +#ifdef XK_Cyrillic_che + if(test("XK_Cyrillic_che", XK_Cyrillic_che, 0x6DE) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Cyrillic_che"); + FAIL; +#endif + +#ifdef XK_Cyrillic_hardsign + if(test("XK_Cyrillic_hardsign", XK_Cyrillic_hardsign, 0x6DF) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Cyrillic_hardsign"); + FAIL; +#endif + +#ifdef XK_Cyrillic_YU + if(test("XK_Cyrillic_YU", XK_Cyrillic_YU, 0x6E0) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Cyrillic_YU"); + FAIL; +#endif + +#ifdef XK_Cyrillic_A + if(test("XK_Cyrillic_A", XK_Cyrillic_A, 0x6E1) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Cyrillic_A"); + FAIL; +#endif + +#ifdef XK_Cyrillic_BE + if(test("XK_Cyrillic_BE", XK_Cyrillic_BE, 0x6E2) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Cyrillic_BE"); + FAIL; +#endif + +#ifdef XK_Cyrillic_TSE + if(test("XK_Cyrillic_TSE", XK_Cyrillic_TSE, 0x6E3) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Cyrillic_TSE"); + FAIL; +#endif + +#ifdef XK_Cyrillic_DE + if(test("XK_Cyrillic_DE", XK_Cyrillic_DE, 0x6E4) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Cyrillic_DE"); + FAIL; +#endif + +#ifdef XK_Cyrillic_IE + if(test("XK_Cyrillic_IE", XK_Cyrillic_IE, 0x6E5) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Cyrillic_IE"); + FAIL; +#endif + +#ifdef XK_Cyrillic_EF + if(test("XK_Cyrillic_EF", XK_Cyrillic_EF, 0x6E6) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Cyrillic_EF"); + FAIL; +#endif + +#ifdef XK_Cyrillic_GHE + if(test("XK_Cyrillic_GHE", XK_Cyrillic_GHE, 0x6E7) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Cyrillic_GHE"); + FAIL; +#endif + +#ifdef XK_Cyrillic_HA + if(test("XK_Cyrillic_HA", XK_Cyrillic_HA, 0x6E8) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Cyrillic_HA"); + FAIL; +#endif + +#ifdef XK_Cyrillic_I + if(test("XK_Cyrillic_I", XK_Cyrillic_I, 0x6E9) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Cyrillic_I"); + FAIL; +#endif + +#ifdef XK_Cyrillic_SHORTI + if(test("XK_Cyrillic_SHORTI", XK_Cyrillic_SHORTI, 0x6EA) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Cyrillic_SHORTI"); + FAIL; +#endif + +#ifdef XK_Cyrillic_KA + if(test("XK_Cyrillic_KA", XK_Cyrillic_KA, 0x6EB) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Cyrillic_KA"); + FAIL; +#endif + +#ifdef XK_Cyrillic_EL + if(test("XK_Cyrillic_EL", XK_Cyrillic_EL, 0x6EC) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Cyrillic_EL"); + FAIL; +#endif + +#ifdef XK_Cyrillic_EM + if(test("XK_Cyrillic_EM", XK_Cyrillic_EM, 0x6ED) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Cyrillic_EM"); + FAIL; +#endif + +#ifdef XK_Cyrillic_EN + if(test("XK_Cyrillic_EN", XK_Cyrillic_EN, 0x6EE) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Cyrillic_EN"); + FAIL; +#endif + +#ifdef XK_Cyrillic_O + if(test("XK_Cyrillic_O", XK_Cyrillic_O, 0x6EF) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Cyrillic_O"); + FAIL; +#endif + +#ifdef XK_Cyrillic_PE + if(test("XK_Cyrillic_PE", XK_Cyrillic_PE, 0x6F0) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Cyrillic_PE"); + FAIL; +#endif + +#ifdef XK_Cyrillic_YA + if(test("XK_Cyrillic_YA", XK_Cyrillic_YA, 0x6F1) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Cyrillic_YA"); + FAIL; +#endif + +#ifdef XK_Cyrillic_ER + if(test("XK_Cyrillic_ER", XK_Cyrillic_ER, 0x6F2) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Cyrillic_ER"); + FAIL; +#endif + +#ifdef XK_Cyrillic_ES + if(test("XK_Cyrillic_ES", XK_Cyrillic_ES, 0x6F3) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Cyrillic_ES"); + FAIL; +#endif + +#ifdef XK_Cyrillic_TE + if(test("XK_Cyrillic_TE", XK_Cyrillic_TE, 0x6F4) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Cyrillic_TE"); + FAIL; +#endif + +#ifdef XK_Cyrillic_U + if(test("XK_Cyrillic_U", XK_Cyrillic_U, 0x6F5) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Cyrillic_U"); + FAIL; +#endif + +#ifdef XK_Cyrillic_ZHE + if(test("XK_Cyrillic_ZHE", XK_Cyrillic_ZHE, 0x6F6) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Cyrillic_ZHE"); + FAIL; +#endif + +#ifdef XK_Cyrillic_VE + if(test("XK_Cyrillic_VE", XK_Cyrillic_VE, 0x6F7) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Cyrillic_VE"); + FAIL; +#endif + +#ifdef XK_Cyrillic_SOFTSIGN + if(test("XK_Cyrillic_SOFTSIGN", XK_Cyrillic_SOFTSIGN, 0x6F8) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Cyrillic_SOFTSIGN"); + FAIL; +#endif + +#ifdef XK_Cyrillic_YERU + if(test("XK_Cyrillic_YERU", XK_Cyrillic_YERU, 0x6F9) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Cyrillic_YERU"); + FAIL; +#endif + +#ifdef XK_Cyrillic_ZE + if(test("XK_Cyrillic_ZE", XK_Cyrillic_ZE, 0x6FA) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Cyrillic_ZE"); + FAIL; +#endif + +#ifdef XK_Cyrillic_SHA + if(test("XK_Cyrillic_SHA", XK_Cyrillic_SHA, 0x6FB) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Cyrillic_SHA"); + FAIL; +#endif + +#ifdef XK_Cyrillic_E + if(test("XK_Cyrillic_E", XK_Cyrillic_E, 0x6FC) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Cyrillic_E"); + FAIL; +#endif + +#ifdef XK_Cyrillic_SHCHA + if(test("XK_Cyrillic_SHCHA", XK_Cyrillic_SHCHA, 0x6FD) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Cyrillic_SHCHA"); + FAIL; +#endif + +#ifdef XK_Cyrillic_CHE + if(test("XK_Cyrillic_CHE", XK_Cyrillic_CHE, 0x6FE) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Cyrillic_CHE"); + FAIL; +#endif + +#ifdef XK_Cyrillic_HARDSIGN + if(test("XK_Cyrillic_HARDSIGN", XK_Cyrillic_HARDSIGN, 0x6FF) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Cyrillic_HARDSIGN"); + FAIL; +#endif + + + CHECKPASS(107); +} diff --git a/xts5/Xopen/keysymdef/TestG.c b/xts5/Xopen/keysymdef/TestG.c new file mode 100644 index 00000000..751bbcb9 --- /dev/null +++ b/xts5/Xopen/keysymdef/TestG.c @@ -0,0 +1,866 @@ +/* +Copyright (c) 2005 X.Org Foundation L.L.C. + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies +of the Software, and to permit persons to whom the Software is furnished to do +so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. +*/ +/* +* $Header: /cvs/xtest/xtest/xts5/tset/Xopen/keysymdef/TestG.c,v 1.2 2005-11-03 08:44:00 jmichael Exp $ +* +* Project: VSW5 +* +* File: xts5/tset/Xopen/keysymdef/TestG.c +* +* Description: +* Tests for keysymdef() +* +* Modifications: +* $Log: TestG.c,v $ +* Revision 1.2 2005-11-03 08:44:00 jmichael +* clean up all vsw5 paths to use xts5 instead. +* +* Revision 1.1.1.2 2005/04/15 14:05:40 anderson +* Reimport of the base with the legal name in the copyright fixed. +* +* Revision 8.0 1998/12/23 23:35:38 mar +* Branch point for Release 5.0.2 +* +* Revision 7.0 1998/10/30 22:58:13 mar +* Branch point for Release 5.0.2b1 +* +* Revision 6.0 1998/03/02 05:26:52 tbr +* Branch point for Release 5.0.1 +* +* Revision 5.0 1998/01/26 03:23:26 tbr +* Branch point for Release 5.0.1b1 +* +* Revision 4.1 1996/05/09 21:16:18 andy +* Fixed X includes +* +* Revision 4.0 1995/12/15 09:13:48 tbr +* Branch point for Release 5.0.0 +* +* Revision 3.1 1995/12/15 01:17:06 andy +* Prepare for GA Release +* +*/ +/* + * SCCS: @(#) TestG.c Rel 1.1 (11/28/91) + * + * UniSoft Ltd., London, England + * + * (C) Copyright 1991 X/Open Company Limited + * + * All rights reserved. No part of this source code may be reproduced, + * stored in a retrieval system, or transmitted, in any form or by any + * means, electronic, mechanical, photocopying, recording or otherwise, + * except as stated in the end-user licence agreement, without the prior + * permission of the copyright owners. + * + * X/Open and the 'X' symbol are trademarks of X/Open Company Limited in + * the UK and other countries. + */ + +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif + +#include <stdlib.h> +#include "xtest.h" +#include "X11/Xlib.h" +#include "X11/Xutil.h" +#include "X11/Xresource.h" +#include "tet_api.h" +#include "xtestlib.h" +#include "pixval.h" + +extern char *TestName; + +static int +test(name, val, aval) +char *name; +int val; +int aval; +{ + + if(val != aval) { + report("KeySym \"%s\" is defined to have value 0x%x instead of 0x%x.", name, val, aval); + return(0); + } + return(1); +} + + + +static void +reporterr(s) +char *s; +{ + report("Keysym \"%s\" is not defined.", s); +} + +#define XK_GREEK +#include <X11/keysymdef.h> +#undef XK_GREEK + +kysymdf7() +{ +int pass = 0, fail = 0; +#ifdef XK_Greek_ALPHAaccent + if(test("XK_Greek_ALPHAaccent", XK_Greek_ALPHAaccent, 0x7A1) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_ALPHAaccent"); + FAIL; +#endif + +#ifdef XK_Greek_EPSILONaccent + if(test("XK_Greek_EPSILONaccent", XK_Greek_EPSILONaccent, 0x7A2) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_EPSILONaccent"); + FAIL; +#endif + +#ifdef XK_Greek_ETAaccent + if(test("XK_Greek_ETAaccent", XK_Greek_ETAaccent, 0x7A3) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_ETAaccent"); + FAIL; +#endif + +#ifdef XK_Greek_IOTAaccent + if(test("XK_Greek_IOTAaccent", XK_Greek_IOTAaccent, 0x7A4) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_IOTAaccent"); + FAIL; +#endif + +#ifdef XK_Greek_IOTAdiaeresis + if(test("XK_Greek_IOTAdiaeresis", XK_Greek_IOTAdiaeresis, 0x7A5) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_IOTAdiaeresis"); + FAIL; +#endif + +#ifdef XK_Greek_OMICRONaccent + if(test("XK_Greek_OMICRONaccent", XK_Greek_OMICRONaccent, 0x7A7) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_OMICRONaccent"); + FAIL; +#endif + +#ifdef XK_Greek_UPSILONaccent + if(test("XK_Greek_UPSILONaccent", XK_Greek_UPSILONaccent, 0x7A8) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_UPSILONaccent"); + FAIL; +#endif + +#ifdef XK_Greek_UPSILONdieresis + if(test("XK_Greek_UPSILONdieresis", XK_Greek_UPSILONdieresis, 0x7A9) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_UPSILONdieresis"); + FAIL; +#endif + +#ifdef XK_Greek_OMEGAaccent + if(test("XK_Greek_OMEGAaccent", XK_Greek_OMEGAaccent, 0x7AB) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_OMEGAaccent"); + FAIL; +#endif + +#ifdef XK_Greek_accentdieresis + if(test("XK_Greek_accentdieresis", XK_Greek_accentdieresis, 0x7AE) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_accentdieresis"); + FAIL; +#endif + +#ifdef XK_Greek_horizbar + if(test("XK_Greek_horizbar", XK_Greek_horizbar, 0x7AF) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_horizbar"); + FAIL; +#endif + +#ifdef XK_Greek_alphaaccent + if(test("XK_Greek_alphaaccent", XK_Greek_alphaaccent, 0x7B1) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_alphaaccent"); + FAIL; +#endif + +#ifdef XK_Greek_epsilonaccent + if(test("XK_Greek_epsilonaccent", XK_Greek_epsilonaccent, 0x7B2) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_epsilonaccent"); + FAIL; +#endif + +#ifdef XK_Greek_etaaccent + if(test("XK_Greek_etaaccent", XK_Greek_etaaccent, 0x7B3) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_etaaccent"); + FAIL; +#endif + +#ifdef XK_Greek_iotaaccent + if(test("XK_Greek_iotaaccent", XK_Greek_iotaaccent, 0x7B4) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_iotaaccent"); + FAIL; +#endif + +#ifdef XK_Greek_iotadieresis + if(test("XK_Greek_iotadieresis", XK_Greek_iotadieresis, 0x7B5) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_iotadieresis"); + FAIL; +#endif + +#ifdef XK_Greek_iotaaccentdieresis + if(test("XK_Greek_iotaaccentdieresis", XK_Greek_iotaaccentdieresis, 0x7B6) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_iotaaccentdieresis"); + FAIL; +#endif + +#ifdef XK_Greek_omicronaccent + if(test("XK_Greek_omicronaccent", XK_Greek_omicronaccent, 0x7B7) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_omicronaccent"); + FAIL; +#endif + +#ifdef XK_Greek_upsilonaccent + if(test("XK_Greek_upsilonaccent", XK_Greek_upsilonaccent, 0x7B8) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_upsilonaccent"); + FAIL; +#endif + +#ifdef XK_Greek_upsilondieresis + if(test("XK_Greek_upsilondieresis", XK_Greek_upsilondieresis, 0x7B9) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_upsilondieresis"); + FAIL; +#endif + +#ifdef XK_Greek_upsilonaccentdieresis + if(test("XK_Greek_upsilonaccentdieresis", XK_Greek_upsilonaccentdieresis, 0x7BA) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_upsilonaccentdieresis"); + FAIL; +#endif + +#ifdef XK_Greek_omegaaccent + if(test("XK_Greek_omegaaccent", XK_Greek_omegaaccent, 0x7BB) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_omegaaccent"); + FAIL; +#endif + +#ifdef XK_Greek_ALPHA + if(test("XK_Greek_ALPHA", XK_Greek_ALPHA, 0x7C1) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_ALPHA"); + FAIL; +#endif + +#ifdef XK_Greek_BETA + if(test("XK_Greek_BETA", XK_Greek_BETA, 0x7C2) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_BETA"); + FAIL; +#endif + +#ifdef XK_Greek_GAMMA + if(test("XK_Greek_GAMMA", XK_Greek_GAMMA, 0x7C3) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_GAMMA"); + FAIL; +#endif + +#ifdef XK_Greek_DELTA + if(test("XK_Greek_DELTA", XK_Greek_DELTA, 0x7C4) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_DELTA"); + FAIL; +#endif + +#ifdef XK_Greek_EPSILON + if(test("XK_Greek_EPSILON", XK_Greek_EPSILON, 0x7C5) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_EPSILON"); + FAIL; +#endif + +#ifdef XK_Greek_ZETA + if(test("XK_Greek_ZETA", XK_Greek_ZETA, 0x7C6) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_ZETA"); + FAIL; +#endif + +#ifdef XK_Greek_ETA + if(test("XK_Greek_ETA", XK_Greek_ETA, 0x7C7) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_ETA"); + FAIL; +#endif + +#ifdef XK_Greek_THETA + if(test("XK_Greek_THETA", XK_Greek_THETA, 0x7C8) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_THETA"); + FAIL; +#endif + +#ifdef XK_Greek_IOTA + if(test("XK_Greek_IOTA", XK_Greek_IOTA, 0x7C9) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_IOTA"); + FAIL; +#endif + +#ifdef XK_Greek_KAPPA + if(test("XK_Greek_KAPPA", XK_Greek_KAPPA, 0x7CA) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_KAPPA"); + FAIL; +#endif + +#ifdef XK_Greek_LAMBDA + if(test("XK_Greek_LAMBDA", XK_Greek_LAMBDA, 0x7CB) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_LAMBDA"); + FAIL; +#endif + +#ifdef XK_Greek_LAMDA + if(test("XK_Greek_LAMDA", XK_Greek_LAMDA, 0x7CB) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_LAMDA"); + FAIL; +#endif + +#ifdef XK_Greek_MU + if(test("XK_Greek_MU", XK_Greek_MU, 0x7CC) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_MU"); + FAIL; +#endif + +#ifdef XK_Greek_NU + if(test("XK_Greek_NU", XK_Greek_NU, 0x7CD) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_NU"); + FAIL; +#endif + +#ifdef XK_Greek_XI + if(test("XK_Greek_XI", XK_Greek_XI, 0x7CE) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_XI"); + FAIL; +#endif + +#ifdef XK_Greek_OMICRON + if(test("XK_Greek_OMICRON", XK_Greek_OMICRON, 0x7CF) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_OMICRON"); + FAIL; +#endif + +#ifdef XK_Greek_PI + if(test("XK_Greek_PI", XK_Greek_PI, 0x7D0) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_PI"); + FAIL; +#endif + +#ifdef XK_Greek_RHO + if(test("XK_Greek_RHO", XK_Greek_RHO, 0x7D1) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_RHO"); + FAIL; +#endif + +#ifdef XK_Greek_SIGMA + if(test("XK_Greek_SIGMA", XK_Greek_SIGMA, 0x7D2) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_SIGMA"); + FAIL; +#endif + +#ifdef XK_Greek_TAU + if(test("XK_Greek_TAU", XK_Greek_TAU, 0x7D4) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_TAU"); + FAIL; +#endif + +#ifdef XK_Greek_UPSILON + if(test("XK_Greek_UPSILON", XK_Greek_UPSILON, 0x7D5) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_UPSILON"); + FAIL; +#endif + +#ifdef XK_Greek_PHI + if(test("XK_Greek_PHI", XK_Greek_PHI, 0x7D6) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_PHI"); + FAIL; +#endif + +#ifdef XK_Greek_CHI + if(test("XK_Greek_CHI", XK_Greek_CHI, 0x7D7) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_CHI"); + FAIL; +#endif + +#ifdef XK_Greek_PSI + if(test("XK_Greek_PSI", XK_Greek_PSI, 0x7D8) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_PSI"); + FAIL; +#endif + +#ifdef XK_Greek_OMEGA + if(test("XK_Greek_OMEGA", XK_Greek_OMEGA, 0x7D9) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_OMEGA"); + FAIL; +#endif + +#ifdef XK_Greek_alpha + if(test("XK_Greek_alpha", XK_Greek_alpha, 0x7E1) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_alpha"); + FAIL; +#endif + +#ifdef XK_Greek_beta + if(test("XK_Greek_beta", XK_Greek_beta, 0x7E2) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_beta"); + FAIL; +#endif + +#ifdef XK_Greek_gamma + if(test("XK_Greek_gamma", XK_Greek_gamma, 0x7E3) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_gamma"); + FAIL; +#endif + +#ifdef XK_Greek_delta + if(test("XK_Greek_delta", XK_Greek_delta, 0x7E4) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_delta"); + FAIL; +#endif + +#ifdef XK_Greek_epsilon + if(test("XK_Greek_epsilon", XK_Greek_epsilon, 0x7E5) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_epsilon"); + FAIL; +#endif + +#ifdef XK_Greek_zeta + if(test("XK_Greek_zeta", XK_Greek_zeta, 0x7E6) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_zeta"); + FAIL; +#endif + +#ifdef XK_Greek_eta + if(test("XK_Greek_eta", XK_Greek_eta, 0x7E7) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_eta"); + FAIL; +#endif + +#ifdef XK_Greek_theta + if(test("XK_Greek_theta", XK_Greek_theta, 0x7E8) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_theta"); + FAIL; +#endif + +#ifdef XK_Greek_iota + if(test("XK_Greek_iota", XK_Greek_iota, 0x7E9) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_iota"); + FAIL; +#endif + +#ifdef XK_Greek_kappa + if(test("XK_Greek_kappa", XK_Greek_kappa, 0x7EA) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_kappa"); + FAIL; +#endif + +#ifdef XK_Greek_lambda + if(test("XK_Greek_lambda", XK_Greek_lambda, 0x7EB) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_lambda"); + FAIL; +#endif + +#ifdef XK_Greek_lamda + if(test("XK_Greek_lamda", XK_Greek_lamda, 0x7EB) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_lamda"); + FAIL; +#endif + +#ifdef XK_Greek_mu + if(test("XK_Greek_mu", XK_Greek_mu, 0x7EC) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_mu"); + FAIL; +#endif + +#ifdef XK_Greek_nu + if(test("XK_Greek_nu", XK_Greek_nu, 0x7ED) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_nu"); + FAIL; +#endif + +#ifdef XK_Greek_xi + if(test("XK_Greek_xi", XK_Greek_xi, 0x7EE) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_xi"); + FAIL; +#endif + +#ifdef XK_Greek_omicron + if(test("XK_Greek_omicron", XK_Greek_omicron, 0x7EF) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_omicron"); + FAIL; +#endif + +#ifdef XK_Greek_pi + if(test("XK_Greek_pi", XK_Greek_pi, 0x7F0) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_pi"); + FAIL; +#endif + +#ifdef XK_Greek_rho + if(test("XK_Greek_rho", XK_Greek_rho, 0x7F1) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_rho"); + FAIL; +#endif + +#ifdef XK_Greek_sigma + if(test("XK_Greek_sigma", XK_Greek_sigma, 0x7F2) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_sigma"); + FAIL; +#endif + +#ifdef XK_Greek_finalsmallsigma + if(test("XK_Greek_finalsmallsigma", XK_Greek_finalsmallsigma, 0x7F3) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_finalsmallsigma"); + FAIL; +#endif + +#ifdef XK_Greek_tau + if(test("XK_Greek_tau", XK_Greek_tau, 0x7F4) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_tau"); + FAIL; +#endif + +#ifdef XK_Greek_upsilon + if(test("XK_Greek_upsilon", XK_Greek_upsilon, 0x7F5) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_upsilon"); + FAIL; +#endif + +#ifdef XK_Greek_phi + if(test("XK_Greek_phi", XK_Greek_phi, 0x7F6) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_phi"); + FAIL; +#endif + +#ifdef XK_Greek_chi + if(test("XK_Greek_chi", XK_Greek_chi, 0x7F7) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_chi"); + FAIL; +#endif + +#ifdef XK_Greek_psi + if(test("XK_Greek_psi", XK_Greek_psi, 0x7F8) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_psi"); + FAIL; +#endif + +#ifdef XK_Greek_omega + if(test("XK_Greek_omega", XK_Greek_omega, 0x7F9) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_omega"); + FAIL; +#endif + +#ifdef XK_Greek_switch + if(test("XK_Greek_switch", XK_Greek_switch, 0xFF7E) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Greek_switch"); + FAIL; +#endif + + + CHECKPASS(74); +} diff --git a/xts5/Xopen/keysymdef/TestH.c b/xts5/Xopen/keysymdef/TestH.c new file mode 100644 index 00000000..ccc2b0f4 --- /dev/null +++ b/xts5/Xopen/keysymdef/TestH.c @@ -0,0 +1,526 @@ +/* +Copyright (c) 2005 X.Org Foundation L.L.C. + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies +of the Software, and to permit persons to whom the Software is furnished to do +so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. +*/ +/* +* $Header: /cvs/xtest/xtest/xts5/tset/Xopen/keysymdef/TestH.c,v 1.2 2005-11-03 08:44:00 jmichael Exp $ +* +* Project: VSW5 +* +* File: xts5/tset/Xopen/keysymdef/TestH.c +* +* Description: +* Tests for keysymdef() +* +* Modifications: +* $Log: TestH.c,v $ +* Revision 1.2 2005-11-03 08:44:00 jmichael +* clean up all vsw5 paths to use xts5 instead. +* +* Revision 1.1.1.2 2005/04/15 14:05:40 anderson +* Reimport of the base with the legal name in the copyright fixed. +* +* Revision 8.0 1998/12/23 23:35:39 mar +* Branch point for Release 5.0.2 +* +* Revision 7.0 1998/10/30 22:58:14 mar +* Branch point for Release 5.0.2b1 +* +* Revision 6.0 1998/03/02 05:26:53 tbr +* Branch point for Release 5.0.1 +* +* Revision 5.0 1998/01/26 03:23:26 tbr +* Branch point for Release 5.0.1b1 +* +* Revision 4.1 1996/05/09 21:16:18 andy +* Fixed X includes +* +* Revision 4.0 1995/12/15 09:13:49 tbr +* Branch point for Release 5.0.0 +* +* Revision 3.1 1995/12/15 01:17:07 andy +* Prepare for GA Release +* +*/ +/* + * SCCS: @(#) TestH.c Rel 1.1 (11/28/91) + * + * UniSoft Ltd., London, England + * + * (C) Copyright 1991 X/Open Company Limited + * + * All rights reserved. No part of this source code may be reproduced, + * stored in a retrieval system, or transmitted, in any form or by any + * means, electronic, mechanical, photocopying, recording or otherwise, + * except as stated in the end-user licence agreement, without the prior + * permission of the copyright owners. + * + * X/Open and the 'X' symbol are trademarks of X/Open Company Limited in + * the UK and other countries. + */ + +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif + +#include <stdlib.h> +#include "xtest.h" +#include "X11/Xlib.h" +#include "X11/Xutil.h" +#include "X11/Xresource.h" +#include "tet_api.h" +#include "xtestlib.h" +#include "pixval.h" + +extern char *TestName; + +static int +test(name, val, aval) +char *name; +int val; +int aval; +{ + + if(val != aval) { + report("KeySym \"%s\" is defined to have value 0x%x instead of 0x%x.", name, val, aval); + return(0); + } + return(1); +} + + + +static void +reporterr(s) +char *s; +{ + report("Keysym \"%s\" is not defined.", s); +} + +#define XK_HEBREW +#include <X11/keysymdef.h> +#undef XK_HEBREW + +kysymdf8() +{ +int pass = 0, fail = 0; +#ifdef XK_hebrew_doublelowline + if(test("XK_hebrew_doublelowline", XK_hebrew_doublelowline, 0xCDF) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_hebrew_doublelowline"); + FAIL; +#endif + +#ifdef XK_hebrew_aleph + if(test("XK_hebrew_aleph", XK_hebrew_aleph, 0xCE0) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_hebrew_aleph"); + FAIL; +#endif + +#ifdef XK_hebrew_bet + if(test("XK_hebrew_bet", XK_hebrew_bet, 0xCE1) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_hebrew_bet"); + FAIL; +#endif + +#ifdef XK_hebrew_beth + if(test("XK_hebrew_beth", XK_hebrew_beth, 0xCE1) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_hebrew_beth"); + FAIL; +#endif + +#ifdef XK_hebrew_gimel + if(test("XK_hebrew_gimel", XK_hebrew_gimel, 0xCE2) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_hebrew_gimel"); + FAIL; +#endif + +#ifdef XK_hebrew_gimmel + if(test("XK_hebrew_gimmel", XK_hebrew_gimmel, 0xCE2) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_hebrew_gimmel"); + FAIL; +#endif + +#ifdef XK_hebrew_dalet + if(test("XK_hebrew_dalet", XK_hebrew_dalet, 0xCE3) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_hebrew_dalet"); + FAIL; +#endif + +#ifdef XK_hebrew_daleth + if(test("XK_hebrew_daleth", XK_hebrew_daleth, 0xCE3) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_hebrew_daleth"); + FAIL; +#endif + +#ifdef XK_hebrew_he + if(test("XK_hebrew_he", XK_hebrew_he, 0xCE4) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_hebrew_he"); + FAIL; +#endif + +#ifdef XK_hebrew_waw + if(test("XK_hebrew_waw", XK_hebrew_waw, 0xCE5) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_hebrew_waw"); + FAIL; +#endif + +#ifdef XK_hebrew_zain + if(test("XK_hebrew_zain", XK_hebrew_zain, 0xCE6) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_hebrew_zain"); + FAIL; +#endif + +#ifdef XK_hebrew_zayin + if(test("XK_hebrew_zayin", XK_hebrew_zayin, 0xCE6) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_hebrew_zayin"); + FAIL; +#endif + +#ifdef XK_hebrew_chet + if(test("XK_hebrew_chet", XK_hebrew_chet, 0xCE7) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_hebrew_chet"); + FAIL; +#endif + +#ifdef XK_hebrew_het + if(test("XK_hebrew_het", XK_hebrew_het, 0xCE7) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_hebrew_het"); + FAIL; +#endif + +#ifdef XK_hebrew_tet + if(test("XK_hebrew_tet", XK_hebrew_tet, 0xCE8) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_hebrew_tet"); + FAIL; +#endif + +#ifdef XK_hebrew_teth + if(test("XK_hebrew_teth", XK_hebrew_teth, 0xCE8) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_hebrew_teth"); + FAIL; +#endif + +#ifdef XK_hebrew_yod + if(test("XK_hebrew_yod", XK_hebrew_yod, 0xCE9) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_hebrew_yod"); + FAIL; +#endif + +#ifdef XK_hebrew_finalkaph + if(test("XK_hebrew_finalkaph", XK_hebrew_finalkaph, 0xCEA) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_hebrew_finalkaph"); + FAIL; +#endif + +#ifdef XK_hebrew_kaph + if(test("XK_hebrew_kaph", XK_hebrew_kaph, 0xCEB) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_hebrew_kaph"); + FAIL; +#endif + +#ifdef XK_hebrew_lamed + if(test("XK_hebrew_lamed", XK_hebrew_lamed, 0xCEC) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_hebrew_lamed"); + FAIL; +#endif + +#ifdef XK_hebrew_finalmem + if(test("XK_hebrew_finalmem", XK_hebrew_finalmem, 0xCED) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_hebrew_finalmem"); + FAIL; +#endif + +#ifdef XK_hebrew_mem + if(test("XK_hebrew_mem", XK_hebrew_mem, 0xCEE) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_hebrew_mem"); + FAIL; +#endif + +#ifdef XK_hebrew_finalnun + if(test("XK_hebrew_finalnun", XK_hebrew_finalnun, 0xCEF) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_hebrew_finalnun"); + FAIL; +#endif + +#ifdef XK_hebrew_nun + if(test("XK_hebrew_nun", XK_hebrew_nun, 0xCF0) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_hebrew_nun"); + FAIL; +#endif + +#ifdef XK_hebrew_samech + if(test("XK_hebrew_samech", XK_hebrew_samech, 0xCF1) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_hebrew_samech"); + FAIL; +#endif + +#ifdef XK_hebrew_samekh + if(test("XK_hebrew_samekh", XK_hebrew_samekh, 0xCF1) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_hebrew_samekh"); + FAIL; +#endif + +#ifdef XK_hebrew_ayin + if(test("XK_hebrew_ayin", XK_hebrew_ayin, 0xCF2) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_hebrew_ayin"); + FAIL; +#endif + +#ifdef XK_hebrew_finalpe + if(test("XK_hebrew_finalpe", XK_hebrew_finalpe, 0xCF3) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_hebrew_finalpe"); + FAIL; +#endif + +#ifdef XK_hebrew_pe + if(test("XK_hebrew_pe", XK_hebrew_pe, 0xCF4) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_hebrew_pe"); + FAIL; +#endif + +#ifdef XK_hebrew_finalzade + if(test("XK_hebrew_finalzade", XK_hebrew_finalzade, 0xCF5) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_hebrew_finalzade"); + FAIL; +#endif + +#ifdef XK_hebrew_finalzadi + if(test("XK_hebrew_finalzadi", XK_hebrew_finalzadi, 0xCF5) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_hebrew_finalzadi"); + FAIL; +#endif + +#ifdef XK_hebrew_zade + if(test("XK_hebrew_zade", XK_hebrew_zade, 0xCF6) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_hebrew_zade"); + FAIL; +#endif + +#ifdef XK_hebrew_zadi + if(test("XK_hebrew_zadi", XK_hebrew_zadi, 0xCF6) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_hebrew_zadi"); + FAIL; +#endif + +#ifdef XK_hebrew_qoph + if(test("XK_hebrew_qoph", XK_hebrew_qoph, 0xCF7) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_hebrew_qoph"); + FAIL; +#endif + +#ifdef XK_hebrew_kuf + if(test("XK_hebrew_kuf", XK_hebrew_kuf, 0xCF7) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_hebrew_kuf"); + FAIL; +#endif + +#ifdef XK_hebrew_resh + if(test("XK_hebrew_resh", XK_hebrew_resh, 0xCF8) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_hebrew_resh"); + FAIL; +#endif + +#ifdef XK_hebrew_shin + if(test("XK_hebrew_shin", XK_hebrew_shin, 0xCF9) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_hebrew_shin"); + FAIL; +#endif + +#ifdef XK_hebrew_taw + if(test("XK_hebrew_taw", XK_hebrew_taw, 0xCFA) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_hebrew_taw"); + FAIL; +#endif + +#ifdef XK_hebrew_taf + if(test("XK_hebrew_taf", XK_hebrew_taf, 0xCFA) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_hebrew_taf"); + FAIL; +#endif + +#ifdef XK_Hebrew_switch + if(test("XK_Hebrew_switch", XK_Hebrew_switch, 0xFF7E) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Hebrew_switch"); + FAIL; +#endif + + + CHECKPASS(40); +} diff --git a/xts5/Xopen/keysymdef/TestK.c b/xts5/Xopen/keysymdef/TestK.c new file mode 100644 index 00000000..8639256e --- /dev/null +++ b/xts5/Xopen/keysymdef/TestK.c @@ -0,0 +1,826 @@ +/* +Copyright (c) 2005 X.Org Foundation L.L.C. + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies +of the Software, and to permit persons to whom the Software is furnished to do +so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. +*/ +/* +* $Header: /cvs/xtest/xtest/xts5/tset/Xopen/keysymdef/TestK.c,v 1.2 2005-11-03 08:44:00 jmichael Exp $ +* +* Project: VSW5 +* +* File: xts5/tset/Xopen/keysymdef/TestK.c +* +* Description: +* Tests for keysymdef() +* +* Modifications: +* $Log: TestK.c,v $ +* Revision 1.2 2005-11-03 08:44:00 jmichael +* clean up all vsw5 paths to use xts5 instead. +* +* Revision 1.1.1.2 2005/04/15 14:05:40 anderson +* Reimport of the base with the legal name in the copyright fixed. +* +* Revision 8.0 1998/12/23 23:35:39 mar +* Branch point for Release 5.0.2 +* +* Revision 7.0 1998/10/30 22:58:15 mar +* Branch point for Release 5.0.2b1 +* +* Revision 6.0 1998/03/02 05:26:53 tbr +* Branch point for Release 5.0.1 +* +* Revision 5.0 1998/01/26 03:23:27 tbr +* Branch point for Release 5.0.1b1 +* +* Revision 4.1 1996/05/09 21:16:18 andy +* Fixed X includes +* +* Revision 4.0 1995/12/15 09:13:50 tbr +* Branch point for Release 5.0.0 +* +* Revision 3.1 1995/12/15 01:17:09 andy +* Prepare for GA Release +* +*/ +/* + * SCCS: @(#) TestK.c Rel 1.1 (11/28/91) + * + * UniSoft Ltd., London, England + * + * (C) Copyright 1991 X/Open Company Limited + * + * All rights reserved. No part of this source code may be reproduced, + * stored in a retrieval system, or transmitted, in any form or by any + * means, electronic, mechanical, photocopying, recording or otherwise, + * except as stated in the end-user licence agreement, without the prior + * permission of the copyright owners. + * + * X/Open and the 'X' symbol are trademarks of X/Open Company Limited in + * the UK and other countries. + */ + +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif + +#include <stdlib.h> +#include "xtest.h" +#include "X11/Xlib.h" +#include "X11/Xutil.h" +#include "X11/Xresource.h" +#include "tet_api.h" +#include "xtestlib.h" +#include "pixval.h" + +extern char *TestName; + +static int +test(name, val, aval) +char *name; +int val; +int aval; +{ + + if(val != aval) { + report("KeySym \"%s\" is defined to have value 0x%x instead of 0x%x.", name, val, aval); + return(0); + } + return(1); +} + + + +static void +reporterr(s) +char *s; +{ + report("Keysym \"%s\" is not defined.", s); +} + +#define XK_KATAKANA +#include <X11/keysymdef.h> +#undef XK_KATAKANA + +kysymdf9() +{ +int pass = 0, fail = 0; +#ifdef XK_overline + if(test("XK_overline", XK_overline, 0x47E) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_overline"); + FAIL; +#endif + +#ifdef XK_kana_fullstop + if(test("XK_kana_fullstop", XK_kana_fullstop, 0x4A1) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_kana_fullstop"); + FAIL; +#endif + +#ifdef XK_kana_openingbracket + if(test("XK_kana_openingbracket", XK_kana_openingbracket, 0x4A2) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_kana_openingbracket"); + FAIL; +#endif + +#ifdef XK_kana_closingbracket + if(test("XK_kana_closingbracket", XK_kana_closingbracket, 0x4A3) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_kana_closingbracket"); + FAIL; +#endif + +#ifdef XK_kana_comma + if(test("XK_kana_comma", XK_kana_comma, 0x4A4) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_kana_comma"); + FAIL; +#endif + +#ifdef XK_kana_conjunctive + if(test("XK_kana_conjunctive", XK_kana_conjunctive, 0x4A5) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_kana_conjunctive"); + FAIL; +#endif + +#ifdef XK_kana_middledot + if(test("XK_kana_middledot", XK_kana_middledot, 0x4A5) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_kana_middledot"); + FAIL; +#endif + +#ifdef XK_kana_WO + if(test("XK_kana_WO", XK_kana_WO, 0x4A6) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_kana_WO"); + FAIL; +#endif + +#ifdef XK_kana_a + if(test("XK_kana_a", XK_kana_a, 0x4A7) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_kana_a"); + FAIL; +#endif + +#ifdef XK_kana_i + if(test("XK_kana_i", XK_kana_i, 0x4A8) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_kana_i"); + FAIL; +#endif + +#ifdef XK_kana_u + if(test("XK_kana_u", XK_kana_u, 0x4A9) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_kana_u"); + FAIL; +#endif + +#ifdef XK_kana_e + if(test("XK_kana_e", XK_kana_e, 0x4AA) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_kana_e"); + FAIL; +#endif + +#ifdef XK_kana_o + if(test("XK_kana_o", XK_kana_o, 0x4AB) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_kana_o"); + FAIL; +#endif + +#ifdef XK_kana_ya + if(test("XK_kana_ya", XK_kana_ya, 0x4AC) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_kana_ya"); + FAIL; +#endif + +#ifdef XK_kana_yu + if(test("XK_kana_yu", XK_kana_yu, 0x4AD) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_kana_yu"); + FAIL; +#endif + +#ifdef XK_kana_yo + if(test("XK_kana_yo", XK_kana_yo, 0x4AE) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_kana_yo"); + FAIL; +#endif + +#ifdef XK_kana_tsu + if(test("XK_kana_tsu", XK_kana_tsu, 0x4AF) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_kana_tsu"); + FAIL; +#endif + +#ifdef XK_kana_tu + if(test("XK_kana_tu", XK_kana_tu, 0x4AF) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_kana_tu"); + FAIL; +#endif + +#ifdef XK_prolongedsound + if(test("XK_prolongedsound", XK_prolongedsound, 0x4B0) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_prolongedsound"); + FAIL; +#endif + +#ifdef XK_kana_A + if(test("XK_kana_A", XK_kana_A, 0x4B1) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_kana_A"); + FAIL; +#endif + +#ifdef XK_kana_I + if(test("XK_kana_I", XK_kana_I, 0x4B2) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_kana_I"); + FAIL; +#endif + +#ifdef XK_kana_U + if(test("XK_kana_U", XK_kana_U, 0x4B3) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_kana_U"); + FAIL; +#endif + +#ifdef XK_kana_E + if(test("XK_kana_E", XK_kana_E, 0x4B4) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_kana_E"); + FAIL; +#endif + +#ifdef XK_kana_O + if(test("XK_kana_O", XK_kana_O, 0x4B5) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_kana_O"); + FAIL; +#endif + +#ifdef XK_kana_KA + if(test("XK_kana_KA", XK_kana_KA, 0x4B6) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_kana_KA"); + FAIL; +#endif + +#ifdef XK_kana_KI + if(test("XK_kana_KI", XK_kana_KI, 0x4B7) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_kana_KI"); + FAIL; +#endif + +#ifdef XK_kana_KU + if(test("XK_kana_KU", XK_kana_KU, 0x4B8) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_kana_KU"); + FAIL; +#endif + +#ifdef XK_kana_KE + if(test("XK_kana_KE", XK_kana_KE, 0x4B9) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_kana_KE"); + FAIL; +#endif + +#ifdef XK_kana_KO + if(test("XK_kana_KO", XK_kana_KO, 0x4BA) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_kana_KO"); + FAIL; +#endif + +#ifdef XK_kana_SA + if(test("XK_kana_SA", XK_kana_SA, 0x4BB) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_kana_SA"); + FAIL; +#endif + +#ifdef XK_kana_SHI + if(test("XK_kana_SHI", XK_kana_SHI, 0x4BC) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_kana_SHI"); + FAIL; +#endif + +#ifdef XK_kana_SU + if(test("XK_kana_SU", XK_kana_SU, 0x4BD) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_kana_SU"); + FAIL; +#endif + +#ifdef XK_kana_SE + if(test("XK_kana_SE", XK_kana_SE, 0x4BE) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_kana_SE"); + FAIL; +#endif + +#ifdef XK_kana_SO + if(test("XK_kana_SO", XK_kana_SO, 0x4BF) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_kana_SO"); + FAIL; +#endif + +#ifdef XK_kana_TA + if(test("XK_kana_TA", XK_kana_TA, 0x4C0) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_kana_TA"); + FAIL; +#endif + +#ifdef XK_kana_CHI + if(test("XK_kana_CHI", XK_kana_CHI, 0x4C1) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_kana_CHI"); + FAIL; +#endif + +#ifdef XK_kana_TI + if(test("XK_kana_TI", XK_kana_TI, 0x4C1) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_kana_TI"); + FAIL; +#endif + +#ifdef XK_kana_TSU + if(test("XK_kana_TSU", XK_kana_TSU, 0x4C2) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_kana_TSU"); + FAIL; +#endif + +#ifdef XK_kana_TU + if(test("XK_kana_TU", XK_kana_TU, 0x4C2) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_kana_TU"); + FAIL; +#endif + +#ifdef XK_kana_TE + if(test("XK_kana_TE", XK_kana_TE, 0x4C3) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_kana_TE"); + FAIL; +#endif + +#ifdef XK_kana_TO + if(test("XK_kana_TO", XK_kana_TO, 0x4C4) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_kana_TO"); + FAIL; +#endif + +#ifdef XK_kana_NA + if(test("XK_kana_NA", XK_kana_NA, 0x4C5) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_kana_NA"); + FAIL; +#endif + +#ifdef XK_kana_NI + if(test("XK_kana_NI", XK_kana_NI, 0x4C6) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_kana_NI"); + FAIL; +#endif + +#ifdef XK_kana_NU + if(test("XK_kana_NU", XK_kana_NU, 0x4C7) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_kana_NU"); + FAIL; +#endif + +#ifdef XK_kana_NE + if(test("XK_kana_NE", XK_kana_NE, 0x4C8) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_kana_NE"); + FAIL; +#endif + +#ifdef XK_kana_NO + if(test("XK_kana_NO", XK_kana_NO, 0x4C9) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_kana_NO"); + FAIL; +#endif + +#ifdef XK_kana_HA + if(test("XK_kana_HA", XK_kana_HA, 0x4CA) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_kana_HA"); + FAIL; +#endif + +#ifdef XK_kana_HI + if(test("XK_kana_HI", XK_kana_HI, 0x4CB) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_kana_HI"); + FAIL; +#endif + +#ifdef XK_kana_FU + if(test("XK_kana_FU", XK_kana_FU, 0x4CC) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_kana_FU"); + FAIL; +#endif + +#ifdef XK_kana_HU + if(test("XK_kana_HU", XK_kana_HU, 0x4CC) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_kana_HU"); + FAIL; +#endif + +#ifdef XK_kana_HE + if(test("XK_kana_HE", XK_kana_HE, 0x4CD) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_kana_HE"); + FAIL; +#endif + +#ifdef XK_kana_HO + if(test("XK_kana_HO", XK_kana_HO, 0x4CE) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_kana_HO"); + FAIL; +#endif + +#ifdef XK_kana_MA + if(test("XK_kana_MA", XK_kana_MA, 0x4CF) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_kana_MA"); + FAIL; +#endif + +#ifdef XK_kana_MI + if(test("XK_kana_MI", XK_kana_MI, 0x4D0) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_kana_MI"); + FAIL; +#endif + +#ifdef XK_kana_MU + if(test("XK_kana_MU", XK_kana_MU, 0x4D1) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_kana_MU"); + FAIL; +#endif + +#ifdef XK_kana_ME + if(test("XK_kana_ME", XK_kana_ME, 0x4D2) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_kana_ME"); + FAIL; +#endif + +#ifdef XK_kana_MO + if(test("XK_kana_MO", XK_kana_MO, 0x4D3) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_kana_MO"); + FAIL; +#endif + +#ifdef XK_kana_YA + if(test("XK_kana_YA", XK_kana_YA, 0x4D4) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_kana_YA"); + FAIL; +#endif + +#ifdef XK_kana_YU + if(test("XK_kana_YU", XK_kana_YU, 0x4D5) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_kana_YU"); + FAIL; +#endif + +#ifdef XK_kana_YO + if(test("XK_kana_YO", XK_kana_YO, 0x4D6) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_kana_YO"); + FAIL; +#endif + +#ifdef XK_kana_RA + if(test("XK_kana_RA", XK_kana_RA, 0x4D7) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_kana_RA"); + FAIL; +#endif + +#ifdef XK_kana_RI + if(test("XK_kana_RI", XK_kana_RI, 0x4D8) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_kana_RI"); + FAIL; +#endif + +#ifdef XK_kana_RU + if(test("XK_kana_RU", XK_kana_RU, 0x4D9) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_kana_RU"); + FAIL; +#endif + +#ifdef XK_kana_RE + if(test("XK_kana_RE", XK_kana_RE, 0x4DA) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_kana_RE"); + FAIL; +#endif + +#ifdef XK_kana_RO + if(test("XK_kana_RO", XK_kana_RO, 0x4DB) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_kana_RO"); + FAIL; +#endif + +#ifdef XK_kana_WA + if(test("XK_kana_WA", XK_kana_WA, 0x4DC) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_kana_WA"); + FAIL; +#endif + +#ifdef XK_kana_N + if(test("XK_kana_N", XK_kana_N, 0x4DD) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_kana_N"); + FAIL; +#endif + +#ifdef XK_voicedsound + if(test("XK_voicedsound", XK_voicedsound, 0x4DE) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_voicedsound"); + FAIL; +#endif + +#ifdef XK_semivoicedsound + if(test("XK_semivoicedsound", XK_semivoicedsound, 0x4DF) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_semivoicedsound"); + FAIL; +#endif + +#ifdef XK_kana_switch + if(test("XK_kana_switch", XK_kana_switch, 0xFF7E) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_kana_switch"); + FAIL; +#endif + + + CHECKPASS(70); +} diff --git a/xts5/Xopen/keysymdef/TestL.c b/xts5/Xopen/keysymdef/TestL.c new file mode 100644 index 00000000..4d116146 --- /dev/null +++ b/xts5/Xopen/keysymdef/TestL.c @@ -0,0 +1,316 @@ +/* +Copyright (c) 2005 X.Org Foundation L.L.C. + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies +of the Software, and to permit persons to whom the Software is furnished to do +so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. +*/ +/* +* $Header: /cvs/xtest/xtest/xts5/tset/Xopen/keysymdef/TestL.c,v 1.2 2005-11-03 08:44:00 jmichael Exp $ +* +* Project: VSW5 +* +* File: xts5/tset/Xopen/keysymdef/TestL.c +* +* Description: +* Tests for keysymdef() +* +* Modifications: +* $Log: TestL.c,v $ +* Revision 1.2 2005-11-03 08:44:00 jmichael +* clean up all vsw5 paths to use xts5 instead. +* +* Revision 1.1.1.2 2005/04/15 14:05:40 anderson +* Reimport of the base with the legal name in the copyright fixed. +* +* Revision 8.0 1998/12/23 23:35:40 mar +* Branch point for Release 5.0.2 +* +* Revision 7.0 1998/10/30 22:58:15 mar +* Branch point for Release 5.0.2b1 +* +* Revision 6.0 1998/03/02 05:26:54 tbr +* Branch point for Release 5.0.1 +* +* Revision 5.0 1998/01/26 03:23:27 tbr +* Branch point for Release 5.0.1b1 +* +* Revision 4.1 1996/05/09 21:16:18 andy +* Fixed X includes +* +* Revision 4.0 1995/12/15 09:13:52 tbr +* Branch point for Release 5.0.0 +* +* Revision 3.1 1995/12/15 01:17:10 andy +* Prepare for GA Release +* +*/ +/* + * SCCS: @(#) TestL.c Rel 1.1 (11/28/91) + * + * UniSoft Ltd., London, England + * + * (C) Copyright 1991 X/Open Company Limited + * + * All rights reserved. No part of this source code may be reproduced, + * stored in a retrieval system, or transmitted, in any form or by any + * means, electronic, mechanical, photocopying, recording or otherwise, + * except as stated in the end-user licence agreement, without the prior + * permission of the copyright owners. + * + * X/Open and the 'X' symbol are trademarks of X/Open Company Limited in + * the UK and other countries. + */ + +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif + +#include <stdlib.h> +#include "xtest.h" +#include "X11/Xlib.h" +#include "X11/Xutil.h" +#include "X11/Xresource.h" +#include "tet_api.h" +#include "xtestlib.h" +#include "pixval.h" + +extern char *TestName; + +static int +test(name, val, aval) +char *name; +int val; +int aval; +{ + + if(val != aval) { + report("KeySym \"%s\" is defined to have value 0x%x instead of 0x%x.", name, val, aval); + return(0); + } + return(1); +} + + + +static void +reporterr(s) +char *s; +{ + report("Keysym \"%s\" is not defined.", s); +} + +#define XK_APL +#include <X11/keysymdef.h> +#undef XK_APL + +kysymdf10() +{ +int pass = 0, fail = 0; +#ifdef XK_leftcaret + if(test("XK_leftcaret", XK_leftcaret, 0xBA3) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_leftcaret"); + FAIL; +#endif + +#ifdef XK_rightcaret + if(test("XK_rightcaret", XK_rightcaret, 0xBA6) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_rightcaret"); + FAIL; +#endif + +#ifdef XK_downcaret + if(test("XK_downcaret", XK_downcaret, 0xBA8) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_downcaret"); + FAIL; +#endif + +#ifdef XK_upcaret + if(test("XK_upcaret", XK_upcaret, 0xBA9) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_upcaret"); + FAIL; +#endif + +#ifdef XK_overbar + if(test("XK_overbar", XK_overbar, 0xBC0) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_overbar"); + FAIL; +#endif + +#ifdef XK_downtack + if(test("XK_downtack", XK_downtack, 0xBC2) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_downtack"); + FAIL; +#endif + +#ifdef XK_upshoe + if(test("XK_upshoe", XK_upshoe, 0xBC3) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_upshoe"); + FAIL; +#endif + +#ifdef XK_downstile + if(test("XK_downstile", XK_downstile, 0xBC4) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_downstile"); + FAIL; +#endif + +#ifdef XK_underbar + if(test("XK_underbar", XK_underbar, 0xBC6) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_underbar"); + FAIL; +#endif + +#ifdef XK_jot + if(test("XK_jot", XK_jot, 0xBCA) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_jot"); + FAIL; +#endif + +#ifdef XK_quad + if(test("XK_quad", XK_quad, 0xBCC) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_quad"); + FAIL; +#endif + +#ifdef XK_uptack + if(test("XK_uptack", XK_uptack, 0xBCE) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_uptack"); + FAIL; +#endif + +#ifdef XK_circle + if(test("XK_circle", XK_circle, 0xBCF) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_circle"); + FAIL; +#endif + +#ifdef XK_upstile + if(test("XK_upstile", XK_upstile, 0xBD3) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_upstile"); + FAIL; +#endif + +#ifdef XK_downshoe + if(test("XK_downshoe", XK_downshoe, 0xBD6) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_downshoe"); + FAIL; +#endif + +#ifdef XK_rightshoe + if(test("XK_rightshoe", XK_rightshoe, 0xBD8) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_rightshoe"); + FAIL; +#endif + +#ifdef XK_leftshoe + if(test("XK_leftshoe", XK_leftshoe, 0xBDA) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_leftshoe"); + FAIL; +#endif + +#ifdef XK_lefttack + if(test("XK_lefttack", XK_lefttack, 0xBDC) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_lefttack"); + FAIL; +#endif + +#ifdef XK_righttack + if(test("XK_righttack", XK_righttack, 0xBFC) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_righttack"); + FAIL; +#endif + + + CHECKPASS(19); +} diff --git a/xts5/Xopen/keysymdef/TestM.c b/xts5/Xopen/keysymdef/TestM.c new file mode 100644 index 00000000..7f8c65af --- /dev/null +++ b/xts5/Xopen/keysymdef/TestM.c @@ -0,0 +1,1606 @@ +/* +Copyright (c) 2005 X.Org Foundation L.L.C. + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies +of the Software, and to permit persons to whom the Software is furnished to do +so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. +*/ +/* +* $Header: /cvs/xtest/xtest/xts5/tset/Xopen/keysymdef/TestM.c,v 1.2 2005-11-03 08:44:00 jmichael Exp $ +* +* Project: VSW5 +* +* File: xts5/tset/Xopen/keysymdef/TestM.c +* +* Description: +* Tests for keysymdef() +* +* Modifications: +* $Log: TestM.c,v $ +* Revision 1.2 2005-11-03 08:44:00 jmichael +* clean up all vsw5 paths to use xts5 instead. +* +* Revision 1.1.1.2 2005/04/15 14:05:40 anderson +* Reimport of the base with the legal name in the copyright fixed. +* +* Revision 8.0 1998/12/23 23:35:40 mar +* Branch point for Release 5.0.2 +* +* Revision 7.0 1998/10/30 22:58:16 mar +* Branch point for Release 5.0.2b1 +* +* Revision 6.0 1998/03/02 05:26:54 tbr +* Branch point for Release 5.0.1 +* +* Revision 5.0 1998/01/26 03:23:28 tbr +* Branch point for Release 5.0.1b1 +* +* Revision 4.1 1996/05/09 21:16:18 andy +* Fixed X includes +* +* Revision 4.0 1995/12/15 09:13:53 tbr +* Branch point for Release 5.0.0 +* +* Revision 3.1 1995/12/15 01:17:12 andy +* Prepare for GA Release +* +*/ +/* + * SCCS: @(#) TestM.c Rel 1.1 (11/28/91) + * + * UniSoft Ltd., London, England + * + * (C) Copyright 1991 X/Open Company Limited + * + * All rights reserved. No part of this source code may be reproduced, + * stored in a retrieval system, or transmitted, in any form or by any + * means, electronic, mechanical, photocopying, recording or otherwise, + * except as stated in the end-user licence agreement, without the prior + * permission of the copyright owners. + * + * X/Open and the 'X' symbol are trademarks of X/Open Company Limited in + * the UK and other countries. + */ + +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif + +#include <stdlib.h> +#include "xtest.h" +#include "X11/Xlib.h" +#include "X11/Xutil.h" +#include "X11/Xresource.h" +#include "tet_api.h" +#include "xtestlib.h" +#include "pixval.h" + +extern char *TestName; + +static int +test(name, val, aval) +char *name; +int val; +int aval; +{ + + if(val != aval) { + report("KeySym \"%s\" is defined to have value 0x%x instead of 0x%x.", name, val, aval); + return(0); + } + return(1); +} + + + +static void +reporterr(s) +char *s; +{ + report("Keysym \"%s\" is not defined.", s); +} + +#define XK_MISCELLANY +#include <X11/keysymdef.h> +#undef XK_MISCELLANY + +kysymdf11() +{ +int pass = 0, fail = 0; +#ifdef XK_BackSpace + if(test("XK_BackSpace", XK_BackSpace, 0xFF08) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_BackSpace"); + FAIL; +#endif + +#ifdef XK_Tab + if(test("XK_Tab", XK_Tab, 0xFF09) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Tab"); + FAIL; +#endif + +#ifdef XK_Linefeed + if(test("XK_Linefeed", XK_Linefeed, 0xFF0A) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Linefeed"); + FAIL; +#endif + +#ifdef XK_Clear + if(test("XK_Clear", XK_Clear, 0xFF0B) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Clear"); + FAIL; +#endif + +#ifdef XK_Return + if(test("XK_Return", XK_Return, 0xFF0D) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Return"); + FAIL; +#endif + +#ifdef XK_Pause + if(test("XK_Pause", XK_Pause, 0xFF13) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Pause"); + FAIL; +#endif + +#ifdef XK_Scroll_Lock + if(test("XK_Scroll_Lock", XK_Scroll_Lock, 0xFF14) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Scroll_Lock"); + FAIL; +#endif + +#ifdef XK_Escape + if(test("XK_Escape", XK_Escape, 0xFF1B) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Escape"); + FAIL; +#endif + +#ifdef XK_Multi_key + if(test("XK_Multi_key", XK_Multi_key, 0xFF20) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Multi_key"); + FAIL; +#endif + +#ifdef XK_Kanji + if(test("XK_Kanji", XK_Kanji, 0xFF21) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Kanji"); + FAIL; +#endif + +#ifdef XK_Muhenkan + if(test("XK_Muhenkan", XK_Muhenkan, 0xFF22) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Muhenkan"); + FAIL; +#endif + +#ifdef XK_Henkan + if(test("XK_Henkan", XK_Henkan, 0xFF23) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Henkan"); + FAIL; +#endif + +#ifdef XK_Henkan_Mode + if(test("XK_Henkan_Mode", XK_Henkan_Mode, 0xFF23) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Henkan_Mode"); + FAIL; +#endif + +#ifdef XK_Romaji + if(test("XK_Romaji", XK_Romaji, 0xFF24) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Romaji"); + FAIL; +#endif + +#ifdef XK_Hiragana + if(test("XK_Hiragana", XK_Hiragana, 0xFF25) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Hiragana"); + FAIL; +#endif + +#ifdef XK_Katakana + if(test("XK_Katakana", XK_Katakana, 0xFF26) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Katakana"); + FAIL; +#endif + +#ifdef XK_Hiragana_Katakana + if(test("XK_Hiragana_Katakana", XK_Hiragana_Katakana, 0xFF27) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Hiragana_Katakana"); + FAIL; +#endif + +#ifdef XK_Zenkaku + if(test("XK_Zenkaku", XK_Zenkaku, 0xFF28) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Zenkaku"); + FAIL; +#endif + +#ifdef XK_Hankaku + if(test("XK_Hankaku", XK_Hankaku, 0xFF29) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Hankaku"); + FAIL; +#endif + +#ifdef XK_Zenkaku_Hankaku + if(test("XK_Zenkaku_Hankaku", XK_Zenkaku_Hankaku, 0xFF2A) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Zenkaku_Hankaku"); + FAIL; +#endif + +#ifdef XK_Touroku + if(test("XK_Touroku", XK_Touroku, 0xFF2B) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Touroku"); + FAIL; +#endif + +#ifdef XK_Massyo + if(test("XK_Massyo", XK_Massyo, 0xFF2C) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Massyo"); + FAIL; +#endif + +#ifdef XK_Kana_Lock + if(test("XK_Kana_Lock", XK_Kana_Lock, 0xFF2D) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Kana_Lock"); + FAIL; +#endif + +#ifdef XK_Kana_Shift + if(test("XK_Kana_Shift", XK_Kana_Shift, 0xFF2E) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Kana_Shift"); + FAIL; +#endif + +#ifdef XK_Eisu_Shift + if(test("XK_Eisu_Shift", XK_Eisu_Shift, 0xFF2F) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Eisu_Shift"); + FAIL; +#endif + +#ifdef XK_Eisu_toggle + if(test("XK_Eisu_toggle", XK_Eisu_toggle, 0xFF30) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Eisu_toggle"); + FAIL; +#endif + +#ifdef XK_Home + if(test("XK_Home", XK_Home, 0xFF50) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Home"); + FAIL; +#endif + +#ifdef XK_Left + if(test("XK_Left", XK_Left, 0xFF51) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Left"); + FAIL; +#endif + +#ifdef XK_Up + if(test("XK_Up", XK_Up, 0xFF52) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Up"); + FAIL; +#endif + +#ifdef XK_Right + if(test("XK_Right", XK_Right, 0xFF53) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Right"); + FAIL; +#endif + +#ifdef XK_Down + if(test("XK_Down", XK_Down, 0xFF54) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Down"); + FAIL; +#endif + +#ifdef XK_Prior + if(test("XK_Prior", XK_Prior, 0xFF55) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Prior"); + FAIL; +#endif + +#ifdef XK_Next + if(test("XK_Next", XK_Next, 0xFF56) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Next"); + FAIL; +#endif + +#ifdef XK_End + if(test("XK_End", XK_End, 0xFF57) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_End"); + FAIL; +#endif + +#ifdef XK_Begin + if(test("XK_Begin", XK_Begin, 0xFF58) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Begin"); + FAIL; +#endif + +#ifdef XK_Select + if(test("XK_Select", XK_Select, 0xFF60) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Select"); + FAIL; +#endif + +#ifdef XK_Print + if(test("XK_Print", XK_Print, 0xFF61) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Print"); + FAIL; +#endif + +#ifdef XK_Execute + if(test("XK_Execute", XK_Execute, 0xFF62) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Execute"); + FAIL; +#endif + +#ifdef XK_Insert + if(test("XK_Insert", XK_Insert, 0xFF63) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Insert"); + FAIL; +#endif + +#ifdef XK_Undo + if(test("XK_Undo", XK_Undo, 0xFF65) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Undo"); + FAIL; +#endif + +#ifdef XK_Redo + if(test("XK_Redo", XK_Redo, 0xFF66) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Redo"); + FAIL; +#endif + +#ifdef XK_Menu + if(test("XK_Menu", XK_Menu, 0xFF67) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Menu"); + FAIL; +#endif + +#ifdef XK_Find + if(test("XK_Find", XK_Find, 0xFF68) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Find"); + FAIL; +#endif + +#ifdef XK_Cancel + if(test("XK_Cancel", XK_Cancel, 0xFF69) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Cancel"); + FAIL; +#endif + +#ifdef XK_Help + if(test("XK_Help", XK_Help, 0xFF6A) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Help"); + FAIL; +#endif + +#ifdef XK_Break + if(test("XK_Break", XK_Break, 0xFF6B) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Break"); + FAIL; +#endif + +#ifdef XK_Mode_switch + if(test("XK_Mode_switch", XK_Mode_switch, 0xFF7E) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Mode_switch"); + FAIL; +#endif + +#ifdef XK_script_switch + if(test("XK_script_switch", XK_script_switch, 0xFF7E) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_script_switch"); + FAIL; +#endif + +#ifdef XK_Num_Lock + if(test("XK_Num_Lock", XK_Num_Lock, 0xFF7F) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Num_Lock"); + FAIL; +#endif + +#ifdef XK_KP_Space + if(test("XK_KP_Space", XK_KP_Space, 0xFF80) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_KP_Space"); + FAIL; +#endif + +#ifdef XK_KP_Tab + if(test("XK_KP_Tab", XK_KP_Tab, 0xFF89) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_KP_Tab"); + FAIL; +#endif + +#ifdef XK_KP_Enter + if(test("XK_KP_Enter", XK_KP_Enter, 0xFF8D) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_KP_Enter"); + FAIL; +#endif + +#ifdef XK_KP_F1 + if(test("XK_KP_F1", XK_KP_F1, 0xFF91) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_KP_F1"); + FAIL; +#endif + +#ifdef XK_KP_F2 + if(test("XK_KP_F2", XK_KP_F2, 0xFF92) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_KP_F2"); + FAIL; +#endif + +#ifdef XK_KP_F3 + if(test("XK_KP_F3", XK_KP_F3, 0xFF93) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_KP_F3"); + FAIL; +#endif + +#ifdef XK_KP_F4 + if(test("XK_KP_F4", XK_KP_F4, 0xFF94) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_KP_F4"); + FAIL; +#endif + +#ifdef XK_KP_Multiply + if(test("XK_KP_Multiply", XK_KP_Multiply, 0xFFAA) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_KP_Multiply"); + FAIL; +#endif + +#ifdef XK_KP_Add + if(test("XK_KP_Add", XK_KP_Add, 0xFFAB) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_KP_Add"); + FAIL; +#endif + +#ifdef XK_KP_Separator + if(test("XK_KP_Separator", XK_KP_Separator, 0xFFAC) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_KP_Separator"); + FAIL; +#endif + +#ifdef XK_KP_Subtract + if(test("XK_KP_Subtract", XK_KP_Subtract, 0xFFAD) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_KP_Subtract"); + FAIL; +#endif + +#ifdef XK_KP_Decimal + if(test("XK_KP_Decimal", XK_KP_Decimal, 0xFFAE) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_KP_Decimal"); + FAIL; +#endif + +#ifdef XK_KP_Divide + if(test("XK_KP_Divide", XK_KP_Divide, 0xFFAF) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_KP_Divide"); + FAIL; +#endif + +#ifdef XK_KP_0 + if(test("XK_KP_0", XK_KP_0, 0xFFB0) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_KP_0"); + FAIL; +#endif + +#ifdef XK_KP_1 + if(test("XK_KP_1", XK_KP_1, 0xFFB1) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_KP_1"); + FAIL; +#endif + +#ifdef XK_KP_2 + if(test("XK_KP_2", XK_KP_2, 0xFFB2) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_KP_2"); + FAIL; +#endif + +#ifdef XK_KP_3 + if(test("XK_KP_3", XK_KP_3, 0xFFB3) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_KP_3"); + FAIL; +#endif + +#ifdef XK_KP_4 + if(test("XK_KP_4", XK_KP_4, 0xFFB4) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_KP_4"); + FAIL; +#endif + +#ifdef XK_KP_5 + if(test("XK_KP_5", XK_KP_5, 0xFFB5) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_KP_5"); + FAIL; +#endif + +#ifdef XK_KP_6 + if(test("XK_KP_6", XK_KP_6, 0xFFB6) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_KP_6"); + FAIL; +#endif + +#ifdef XK_KP_7 + if(test("XK_KP_7", XK_KP_7, 0xFFB7) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_KP_7"); + FAIL; +#endif + +#ifdef XK_KP_8 + if(test("XK_KP_8", XK_KP_8, 0xFFB8) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_KP_8"); + FAIL; +#endif + +#ifdef XK_KP_9 + if(test("XK_KP_9", XK_KP_9, 0xFFB9) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_KP_9"); + FAIL; +#endif + +#ifdef XK_KP_Equal + if(test("XK_KP_Equal", XK_KP_Equal, 0xFFBD) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_KP_Equal"); + FAIL; +#endif + +#ifdef XK_F1 + if(test("XK_F1", XK_F1, 0xFFBE) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_F1"); + FAIL; +#endif + +#ifdef XK_F2 + if(test("XK_F2", XK_F2, 0xFFBF) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_F2"); + FAIL; +#endif + +#ifdef XK_F3 + if(test("XK_F3", XK_F3, 0xFFC0) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_F3"); + FAIL; +#endif + +#ifdef XK_F4 + if(test("XK_F4", XK_F4, 0xFFC1) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_F4"); + FAIL; +#endif + +#ifdef XK_F5 + if(test("XK_F5", XK_F5, 0xFFC2) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_F5"); + FAIL; +#endif + +#ifdef XK_F6 + if(test("XK_F6", XK_F6, 0xFFC3) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_F6"); + FAIL; +#endif + +#ifdef XK_F7 + if(test("XK_F7", XK_F7, 0xFFC4) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_F7"); + FAIL; +#endif + +#ifdef XK_F8 + if(test("XK_F8", XK_F8, 0xFFC5) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_F8"); + FAIL; +#endif + +#ifdef XK_F9 + if(test("XK_F9", XK_F9, 0xFFC6) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_F9"); + FAIL; +#endif + +#ifdef XK_F10 + if(test("XK_F10", XK_F10, 0xFFC7) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_F10"); + FAIL; +#endif + +#ifdef XK_F11 + if(test("XK_F11", XK_F11, 0xFFC8) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_F11"); + FAIL; +#endif + +#ifdef XK_L1 + if(test("XK_L1", XK_L1, 0xFFC8) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_L1"); + FAIL; +#endif + +#ifdef XK_F12 + if(test("XK_F12", XK_F12, 0xFFC9) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_F12"); + FAIL; +#endif + +#ifdef XK_L2 + if(test("XK_L2", XK_L2, 0xFFC9) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_L2"); + FAIL; +#endif + +#ifdef XK_F13 + if(test("XK_F13", XK_F13, 0xFFCA) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_F13"); + FAIL; +#endif + +#ifdef XK_L3 + if(test("XK_L3", XK_L3, 0xFFCA) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_L3"); + FAIL; +#endif + +#ifdef XK_F14 + if(test("XK_F14", XK_F14, 0xFFCB) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_F14"); + FAIL; +#endif + +#ifdef XK_L4 + if(test("XK_L4", XK_L4, 0xFFCB) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_L4"); + FAIL; +#endif + +#ifdef XK_F15 + if(test("XK_F15", XK_F15, 0xFFCC) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_F15"); + FAIL; +#endif + +#ifdef XK_L5 + if(test("XK_L5", XK_L5, 0xFFCC) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_L5"); + FAIL; +#endif + +#ifdef XK_F16 + if(test("XK_F16", XK_F16, 0xFFCD) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_F16"); + FAIL; +#endif + +#ifdef XK_L6 + if(test("XK_L6", XK_L6, 0xFFCD) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_L6"); + FAIL; +#endif + +#ifdef XK_F17 + if(test("XK_F17", XK_F17, 0xFFCE) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_F17"); + FAIL; +#endif + +#ifdef XK_L7 + if(test("XK_L7", XK_L7, 0xFFCE) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_L7"); + FAIL; +#endif + +#ifdef XK_F18 + if(test("XK_F18", XK_F18, 0xFFCF) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_F18"); + FAIL; +#endif + +#ifdef XK_L8 + if(test("XK_L8", XK_L8, 0xFFCF) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_L8"); + FAIL; +#endif + +#ifdef XK_F19 + if(test("XK_F19", XK_F19, 0xFFD0) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_F19"); + FAIL; +#endif + +#ifdef XK_L9 + if(test("XK_L9", XK_L9, 0xFFD0) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_L9"); + FAIL; +#endif + +#ifdef XK_F20 + if(test("XK_F20", XK_F20, 0xFFD1) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_F20"); + FAIL; +#endif + +#ifdef XK_L10 + if(test("XK_L10", XK_L10, 0xFFD1) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_L10"); + FAIL; +#endif + +#ifdef XK_F21 + if(test("XK_F21", XK_F21, 0xFFD2) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_F21"); + FAIL; +#endif + +#ifdef XK_R1 + if(test("XK_R1", XK_R1, 0xFFD2) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_R1"); + FAIL; +#endif + +#ifdef XK_F22 + if(test("XK_F22", XK_F22, 0xFFD3) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_F22"); + FAIL; +#endif + +#ifdef XK_R2 + if(test("XK_R2", XK_R2, 0xFFD3) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_R2"); + FAIL; +#endif + +#ifdef XK_F23 + if(test("XK_F23", XK_F23, 0xFFD4) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_F23"); + FAIL; +#endif + +#ifdef XK_R3 + if(test("XK_R3", XK_R3, 0xFFD4) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_R3"); + FAIL; +#endif + +#ifdef XK_F24 + if(test("XK_F24", XK_F24, 0xFFD5) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_F24"); + FAIL; +#endif + +#ifdef XK_R4 + if(test("XK_R4", XK_R4, 0xFFD5) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_R4"); + FAIL; +#endif + +#ifdef XK_F25 + if(test("XK_F25", XK_F25, 0xFFD6) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_F25"); + FAIL; +#endif + +#ifdef XK_R5 + if(test("XK_R5", XK_R5, 0xFFD6) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_R5"); + FAIL; +#endif + +#ifdef XK_F26 + if(test("XK_F26", XK_F26, 0xFFD7) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_F26"); + FAIL; +#endif + +#ifdef XK_R6 + if(test("XK_R6", XK_R6, 0xFFD7) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_R6"); + FAIL; +#endif + +#ifdef XK_F27 + if(test("XK_F27", XK_F27, 0xFFD8) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_F27"); + FAIL; +#endif + +#ifdef XK_R7 + if(test("XK_R7", XK_R7, 0xFFD8) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_R7"); + FAIL; +#endif + +#ifdef XK_F28 + if(test("XK_F28", XK_F28, 0xFFD9) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_F28"); + FAIL; +#endif + +#ifdef XK_R8 + if(test("XK_R8", XK_R8, 0xFFD9) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_R8"); + FAIL; +#endif + +#ifdef XK_F29 + if(test("XK_F29", XK_F29, 0xFFDA) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_F29"); + FAIL; +#endif + +#ifdef XK_R9 + if(test("XK_R9", XK_R9, 0xFFDA) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_R9"); + FAIL; +#endif + +#ifdef XK_F30 + if(test("XK_F30", XK_F30, 0xFFDB) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_F30"); + FAIL; +#endif + +#ifdef XK_R10 + if(test("XK_R10", XK_R10, 0xFFDB) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_R10"); + FAIL; +#endif + +#ifdef XK_F31 + if(test("XK_F31", XK_F31, 0xFFDC) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_F31"); + FAIL; +#endif + +#ifdef XK_R11 + if(test("XK_R11", XK_R11, 0xFFDC) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_R11"); + FAIL; +#endif + +#ifdef XK_F32 + if(test("XK_F32", XK_F32, 0xFFDD) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_F32"); + FAIL; +#endif + +#ifdef XK_R12 + if(test("XK_R12", XK_R12, 0xFFDD) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_R12"); + FAIL; +#endif + +#ifdef XK_F33 + if(test("XK_F33", XK_F33, 0xFFDE) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_F33"); + FAIL; +#endif + +#ifdef XK_R13 + if(test("XK_R13", XK_R13, 0xFFDE) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_R13"); + FAIL; +#endif + +#ifdef XK_F34 + if(test("XK_F34", XK_F34, 0xFFDF) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_F34"); + FAIL; +#endif + +#ifdef XK_R14 + if(test("XK_R14", XK_R14, 0xFFDF) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_R14"); + FAIL; +#endif + +#ifdef XK_F35 + if(test("XK_F35", XK_F35, 0xFFE0) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_F35"); + FAIL; +#endif + +#ifdef XK_R15 + if(test("XK_R15", XK_R15, 0xFFE0) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_R15"); + FAIL; +#endif + +#ifdef XK_Shift_L + if(test("XK_Shift_L", XK_Shift_L, 0xFFE1) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Shift_L"); + FAIL; +#endif + +#ifdef XK_Shift_R + if(test("XK_Shift_R", XK_Shift_R, 0xFFE2) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Shift_R"); + FAIL; +#endif + +#ifdef XK_Control_L + if(test("XK_Control_L", XK_Control_L, 0xFFE3) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Control_L"); + FAIL; +#endif + +#ifdef XK_Control_R + if(test("XK_Control_R", XK_Control_R, 0xFFE4) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Control_R"); + FAIL; +#endif + +#ifdef XK_Caps_Lock + if(test("XK_Caps_Lock", XK_Caps_Lock, 0xFFE5) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Caps_Lock"); + FAIL; +#endif + +#ifdef XK_Shift_Lock + if(test("XK_Shift_Lock", XK_Shift_Lock, 0xFFE6) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Shift_Lock"); + FAIL; +#endif + +#ifdef XK_Meta_L + if(test("XK_Meta_L", XK_Meta_L, 0xFFE7) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Meta_L"); + FAIL; +#endif + +#ifdef XK_Meta_R + if(test("XK_Meta_R", XK_Meta_R, 0xFFE8) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Meta_R"); + FAIL; +#endif + +#ifdef XK_Alt_L + if(test("XK_Alt_L", XK_Alt_L, 0xFFE9) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Alt_L"); + FAIL; +#endif + +#ifdef XK_Alt_R + if(test("XK_Alt_R", XK_Alt_R, 0xFFEA) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Alt_R"); + FAIL; +#endif + +#ifdef XK_Super_L + if(test("XK_Super_L", XK_Super_L, 0xFFEB) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Super_L"); + FAIL; +#endif + +#ifdef XK_Super_R + if(test("XK_Super_R", XK_Super_R, 0xFFEC) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Super_R"); + FAIL; +#endif + +#ifdef XK_Hyper_L + if(test("XK_Hyper_L", XK_Hyper_L, 0xFFED) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Hyper_L"); + FAIL; +#endif + +#ifdef XK_Hyper_R + if(test("XK_Hyper_R", XK_Hyper_R, 0xFFEE) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Hyper_R"); + FAIL; +#endif + +#ifdef XK_Delete + if(test("XK_Delete", XK_Delete, 0xFFFF) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_Delete"); + FAIL; +#endif + + + CHECKPASS(148); +} diff --git a/xts5/Xopen/keysymdef/TestP.c b/xts5/Xopen/keysymdef/TestP.c new file mode 100644 index 00000000..8002adc5 --- /dev/null +++ b/xts5/Xopen/keysymdef/TestP.c @@ -0,0 +1,956 @@ +/* +Copyright (c) 2005 X.Org Foundation L.L.C. + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies +of the Software, and to permit persons to whom the Software is furnished to do +so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. +*/ +/* +* $Header: /cvs/xtest/xtest/xts5/tset/Xopen/keysymdef/TestP.c,v 1.2 2005-11-03 08:44:00 jmichael Exp $ +* +* Project: VSW5 +* +* File: xts5/tset/Xopen/keysymdef/TestP.c +* +* Description: +* Tests for keysymdef() +* +* Modifications: +* $Log: TestP.c,v $ +* Revision 1.2 2005-11-03 08:44:00 jmichael +* clean up all vsw5 paths to use xts5 instead. +* +* Revision 1.1.1.2 2005/04/15 14:05:40 anderson +* Reimport of the base with the legal name in the copyright fixed. +* +* Revision 8.0 1998/12/23 23:35:41 mar +* Branch point for Release 5.0.2 +* +* Revision 7.0 1998/10/30 22:58:17 mar +* Branch point for Release 5.0.2b1 +* +* Revision 6.0 1998/03/02 05:26:55 tbr +* Branch point for Release 5.0.1 +* +* Revision 5.0 1998/01/26 03:23:28 tbr +* Branch point for Release 5.0.1b1 +* +* Revision 4.1 1996/05/09 21:16:18 andy +* Fixed X includes +* +* Revision 4.0 1995/12/15 09:13:55 tbr +* Branch point for Release 5.0.0 +* +* Revision 3.1 1995/12/15 01:17:14 andy +* Prepare for GA Release +* +*/ +/* + * SCCS: @(#) TestP.c Rel 1.1 (11/28/91) + * + * UniSoft Ltd., London, England + * + * (C) Copyright 1991 X/Open Company Limited + * + * All rights reserved. No part of this source code may be reproduced, + * stored in a retrieval system, or transmitted, in any form or by any + * means, electronic, mechanical, photocopying, recording or otherwise, + * except as stated in the end-user licence agreement, without the prior + * permission of the copyright owners. + * + * X/Open and the 'X' symbol are trademarks of X/Open Company Limited in + * the UK and other countries. + */ + +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif + +#include <stdlib.h> +#include "xtest.h" +#include "X11/Xlib.h" +#include "X11/Xutil.h" +#include "X11/Xresource.h" +#include "tet_api.h" +#include "xtestlib.h" +#include "pixval.h" + +extern char *TestName; + +static int +test(name, val, aval) +char *name; +int val; +int aval; +{ + + if(val != aval) { + report("KeySym \"%s\" is defined to have value 0x%x instead of 0x%x.", name, val, aval); + return(0); + } + return(1); +} + + + +static void +reporterr(s) +char *s; +{ + report("Keysym \"%s\" is not defined.", s); +} + +#define XK_PUBLISHING +#include <X11/keysymdef.h> +#undef XK_PUBLISHING + +kysymdf12() +{ +int pass = 0, fail = 0; +#ifdef XK_emspace + if(test("XK_emspace", XK_emspace, 0xAA1) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_emspace"); + FAIL; +#endif + +#ifdef XK_enspace + if(test("XK_enspace", XK_enspace, 0xAA2) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_enspace"); + FAIL; +#endif + +#ifdef XK_em3space + if(test("XK_em3space", XK_em3space, 0xAA3) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_em3space"); + FAIL; +#endif + +#ifdef XK_em4space + if(test("XK_em4space", XK_em4space, 0xAA4) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_em4space"); + FAIL; +#endif + +#ifdef XK_digitspace + if(test("XK_digitspace", XK_digitspace, 0xAA5) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_digitspace"); + FAIL; +#endif + +#ifdef XK_punctspace + if(test("XK_punctspace", XK_punctspace, 0xAA6) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_punctspace"); + FAIL; +#endif + +#ifdef XK_thinspace + if(test("XK_thinspace", XK_thinspace, 0xAA7) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_thinspace"); + FAIL; +#endif + +#ifdef XK_hairspace + if(test("XK_hairspace", XK_hairspace, 0xAA8) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_hairspace"); + FAIL; +#endif + +#ifdef XK_emdash + if(test("XK_emdash", XK_emdash, 0xAA9) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_emdash"); + FAIL; +#endif + +#ifdef XK_endash + if(test("XK_endash", XK_endash, 0xAAA) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_endash"); + FAIL; +#endif + +#ifdef XK_signifblank + if(test("XK_signifblank", XK_signifblank, 0xAAC) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_signifblank"); + FAIL; +#endif + +#ifdef XK_ellipsis + if(test("XK_ellipsis", XK_ellipsis, 0xAAE) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_ellipsis"); + FAIL; +#endif + +#ifdef XK_doubbaselinedot + if(test("XK_doubbaselinedot", XK_doubbaselinedot, 0xAAF) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_doubbaselinedot"); + FAIL; +#endif + +#ifdef XK_onethird + if(test("XK_onethird", XK_onethird, 0xAB0) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_onethird"); + FAIL; +#endif + +#ifdef XK_twothirds + if(test("XK_twothirds", XK_twothirds, 0xAB1) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_twothirds"); + FAIL; +#endif + +#ifdef XK_onefifth + if(test("XK_onefifth", XK_onefifth, 0xAB2) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_onefifth"); + FAIL; +#endif + +#ifdef XK_twofifths + if(test("XK_twofifths", XK_twofifths, 0xAB3) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_twofifths"); + FAIL; +#endif + +#ifdef XK_threefifths + if(test("XK_threefifths", XK_threefifths, 0xAB4) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_threefifths"); + FAIL; +#endif + +#ifdef XK_fourfifths + if(test("XK_fourfifths", XK_fourfifths, 0xAB5) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_fourfifths"); + FAIL; +#endif + +#ifdef XK_onesixth + if(test("XK_onesixth", XK_onesixth, 0xAB6) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_onesixth"); + FAIL; +#endif + +#ifdef XK_fivesixths + if(test("XK_fivesixths", XK_fivesixths, 0xAB7) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_fivesixths"); + FAIL; +#endif + +#ifdef XK_careof + if(test("XK_careof", XK_careof, 0xAB8) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_careof"); + FAIL; +#endif + +#ifdef XK_figdash + if(test("XK_figdash", XK_figdash, 0xABB) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_figdash"); + FAIL; +#endif + +#ifdef XK_leftanglebracket + if(test("XK_leftanglebracket", XK_leftanglebracket, 0xABC) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_leftanglebracket"); + FAIL; +#endif + +#ifdef XK_decimalpoint + if(test("XK_decimalpoint", XK_decimalpoint, 0xABD) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_decimalpoint"); + FAIL; +#endif + +#ifdef XK_rightanglebracket + if(test("XK_rightanglebracket", XK_rightanglebracket, 0xABE) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_rightanglebracket"); + FAIL; +#endif + +#ifdef XK_marker + if(test("XK_marker", XK_marker, 0xABF) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_marker"); + FAIL; +#endif + +#ifdef XK_oneeighth + if(test("XK_oneeighth", XK_oneeighth, 0xAC3) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_oneeighth"); + FAIL; +#endif + +#ifdef XK_threeeighths + if(test("XK_threeeighths", XK_threeeighths, 0xAC4) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_threeeighths"); + FAIL; +#endif + +#ifdef XK_fiveeighths + if(test("XK_fiveeighths", XK_fiveeighths, 0xAC5) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_fiveeighths"); + FAIL; +#endif + +#ifdef XK_seveneighths + if(test("XK_seveneighths", XK_seveneighths, 0xAC6) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_seveneighths"); + FAIL; +#endif + +#ifdef XK_trademark + if(test("XK_trademark", XK_trademark, 0xAC9) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_trademark"); + FAIL; +#endif + +#ifdef XK_signaturemark + if(test("XK_signaturemark", XK_signaturemark, 0xACA) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_signaturemark"); + FAIL; +#endif + +#ifdef XK_trademarkincircle + if(test("XK_trademarkincircle", XK_trademarkincircle, 0xACB) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_trademarkincircle"); + FAIL; +#endif + +#ifdef XK_leftopentriangle + if(test("XK_leftopentriangle", XK_leftopentriangle, 0xACC) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_leftopentriangle"); + FAIL; +#endif + +#ifdef XK_rightopentriangle + if(test("XK_rightopentriangle", XK_rightopentriangle, 0xACD) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_rightopentriangle"); + FAIL; +#endif + +#ifdef XK_emopencircle + if(test("XK_emopencircle", XK_emopencircle, 0xACE) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_emopencircle"); + FAIL; +#endif + +#ifdef XK_emopenrectangle + if(test("XK_emopenrectangle", XK_emopenrectangle, 0xACF) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_emopenrectangle"); + FAIL; +#endif + +#ifdef XK_leftsinglequotemark + if(test("XK_leftsinglequotemark", XK_leftsinglequotemark, 0xAD0) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_leftsinglequotemark"); + FAIL; +#endif + +#ifdef XK_rightsinglequotemark + if(test("XK_rightsinglequotemark", XK_rightsinglequotemark, 0xAD1) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_rightsinglequotemark"); + FAIL; +#endif + +#ifdef XK_leftdoublequotemark + if(test("XK_leftdoublequotemark", XK_leftdoublequotemark, 0xAD2) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_leftdoublequotemark"); + FAIL; +#endif + +#ifdef XK_rightdoublequotemark + if(test("XK_rightdoublequotemark", XK_rightdoublequotemark, 0xAD3) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_rightdoublequotemark"); + FAIL; +#endif + +#ifdef XK_prescription + if(test("XK_prescription", XK_prescription, 0xAD4) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_prescription"); + FAIL; +#endif + +#ifdef XK_minutes + if(test("XK_minutes", XK_minutes, 0xAD6) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_minutes"); + FAIL; +#endif + +#ifdef XK_seconds + if(test("XK_seconds", XK_seconds, 0xAD7) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_seconds"); + FAIL; +#endif + +#ifdef XK_latincross + if(test("XK_latincross", XK_latincross, 0xAD9) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_latincross"); + FAIL; +#endif + +#ifdef XK_hexagram + if(test("XK_hexagram", XK_hexagram, 0xADA) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_hexagram"); + FAIL; +#endif + +#ifdef XK_filledrectbullet + if(test("XK_filledrectbullet", XK_filledrectbullet, 0xADB) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_filledrectbullet"); + FAIL; +#endif + +#ifdef XK_filledlefttribullet + if(test("XK_filledlefttribullet", XK_filledlefttribullet, 0xADC) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_filledlefttribullet"); + FAIL; +#endif + +#ifdef XK_filledrighttribullet + if(test("XK_filledrighttribullet", XK_filledrighttribullet, 0xADD) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_filledrighttribullet"); + FAIL; +#endif + +#ifdef XK_emfilledcircle + if(test("XK_emfilledcircle", XK_emfilledcircle, 0xADE) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_emfilledcircle"); + FAIL; +#endif + +#ifdef XK_emfilledrect + if(test("XK_emfilledrect", XK_emfilledrect, 0xADF) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_emfilledrect"); + FAIL; +#endif + +#ifdef XK_enopencircbullet + if(test("XK_enopencircbullet", XK_enopencircbullet, 0xAE0) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_enopencircbullet"); + FAIL; +#endif + +#ifdef XK_enopensquarebullet + if(test("XK_enopensquarebullet", XK_enopensquarebullet, 0xAE1) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_enopensquarebullet"); + FAIL; +#endif + +#ifdef XK_openrectbullet + if(test("XK_openrectbullet", XK_openrectbullet, 0xAE2) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_openrectbullet"); + FAIL; +#endif + +#ifdef XK_opentribulletup + if(test("XK_opentribulletup", XK_opentribulletup, 0xAE3) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_opentribulletup"); + FAIL; +#endif + +#ifdef XK_opentribulletdown + if(test("XK_opentribulletdown", XK_opentribulletdown, 0xAE4) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_opentribulletdown"); + FAIL; +#endif + +#ifdef XK_openstar + if(test("XK_openstar", XK_openstar, 0xAE5) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_openstar"); + FAIL; +#endif + +#ifdef XK_enfilledcircbullet + if(test("XK_enfilledcircbullet", XK_enfilledcircbullet, 0xAE6) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_enfilledcircbullet"); + FAIL; +#endif + +#ifdef XK_enfilledsqbullet + if(test("XK_enfilledsqbullet", XK_enfilledsqbullet, 0xAE7) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_enfilledsqbullet"); + FAIL; +#endif + +#ifdef XK_filledtribulletup + if(test("XK_filledtribulletup", XK_filledtribulletup, 0xAE8) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_filledtribulletup"); + FAIL; +#endif + +#ifdef XK_filledtribulletdown + if(test("XK_filledtribulletdown", XK_filledtribulletdown, 0xAE9) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_filledtribulletdown"); + FAIL; +#endif + +#ifdef XK_leftpointer + if(test("XK_leftpointer", XK_leftpointer, 0xAEA) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_leftpointer"); + FAIL; +#endif + +#ifdef XK_rightpointer + if(test("XK_rightpointer", XK_rightpointer, 0xAEB) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_rightpointer"); + FAIL; +#endif + +#ifdef XK_club + if(test("XK_club", XK_club, 0xAEC) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_club"); + FAIL; +#endif + +#ifdef XK_diamond + if(test("XK_diamond", XK_diamond, 0xAED) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_diamond"); + FAIL; +#endif + +#ifdef XK_heart + if(test("XK_heart", XK_heart, 0xAEE) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_heart"); + FAIL; +#endif + +#ifdef XK_maltesecross + if(test("XK_maltesecross", XK_maltesecross, 0xAF0) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_maltesecross"); + FAIL; +#endif + +#ifdef XK_dagger + if(test("XK_dagger", XK_dagger, 0xAF1) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_dagger"); + FAIL; +#endif + +#ifdef XK_doubledagger + if(test("XK_doubledagger", XK_doubledagger, 0xAF2) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_doubledagger"); + FAIL; +#endif + +#ifdef XK_checkmark + if(test("XK_checkmark", XK_checkmark, 0xAF3) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_checkmark"); + FAIL; +#endif + +#ifdef XK_ballotcross + if(test("XK_ballotcross", XK_ballotcross, 0xAF4) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_ballotcross"); + FAIL; +#endif + +#ifdef XK_musicalsharp + if(test("XK_musicalsharp", XK_musicalsharp, 0xAF5) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_musicalsharp"); + FAIL; +#endif + +#ifdef XK_musicalflat + if(test("XK_musicalflat", XK_musicalflat, 0xAF6) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_musicalflat"); + FAIL; +#endif + +#ifdef XK_malesymbol + if(test("XK_malesymbol", XK_malesymbol, 0xAF7) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_malesymbol"); + FAIL; +#endif + +#ifdef XK_femalesymbol + if(test("XK_femalesymbol", XK_femalesymbol, 0xAF8) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_femalesymbol"); + FAIL; +#endif + +#ifdef XK_telephone + if(test("XK_telephone", XK_telephone, 0xAF9) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_telephone"); + FAIL; +#endif + +#ifdef XK_telephonerecorder + if(test("XK_telephonerecorder", XK_telephonerecorder, 0xAFA) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_telephonerecorder"); + FAIL; +#endif + +#ifdef XK_phonographcopyright + if(test("XK_phonographcopyright", XK_phonographcopyright, 0xAFB) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_phonographcopyright"); + FAIL; +#endif + +#ifdef XK_caret + if(test("XK_caret", XK_caret, 0xAFC) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_caret"); + FAIL; +#endif + +#ifdef XK_singlelowquotemark + if(test("XK_singlelowquotemark", XK_singlelowquotemark, 0xAFD) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_singlelowquotemark"); + FAIL; +#endif + +#ifdef XK_doublelowquotemark + if(test("XK_doublelowquotemark", XK_doublelowquotemark, 0xAFE) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_doublelowquotemark"); + FAIL; +#endif + +#ifdef XK_cursor + if(test("XK_cursor", XK_cursor, 0xAFF) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_cursor"); + FAIL; +#endif + + + CHECKPASS(83); +} diff --git a/xts5/Xopen/keysymdef/TestS.c b/xts5/Xopen/keysymdef/TestS.c new file mode 100644 index 00000000..8435a403 --- /dev/null +++ b/xts5/Xopen/keysymdef/TestS.c @@ -0,0 +1,366 @@ +/* +Copyright (c) 2005 X.Org Foundation L.L.C. + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies +of the Software, and to permit persons to whom the Software is furnished to do +so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. +*/ +/* +* $Header: /cvs/xtest/xtest/xts5/tset/Xopen/keysymdef/TestS.c,v 1.2 2005-11-03 08:44:00 jmichael Exp $ +* +* Project: VSW5 +* +* File: xts5/tset/Xopen/keysymdef/TestS.c +* +* Description: +* Tests for keysymdef() +* +* Modifications: +* $Log: TestS.c,v $ +* Revision 1.2 2005-11-03 08:44:00 jmichael +* clean up all vsw5 paths to use xts5 instead. +* +* Revision 1.1.1.2 2005/04/15 14:05:40 anderson +* Reimport of the base with the legal name in the copyright fixed. +* +* Revision 8.0 1998/12/23 23:35:41 mar +* Branch point for Release 5.0.2 +* +* Revision 7.0 1998/10/30 22:58:18 mar +* Branch point for Release 5.0.2b1 +* +* Revision 6.0 1998/03/02 05:26:55 tbr +* Branch point for Release 5.0.1 +* +* Revision 5.0 1998/01/26 03:23:29 tbr +* Branch point for Release 5.0.1b1 +* +* Revision 4.1 1996/05/09 21:16:18 andy +* Fixed X includes +* +* Revision 4.0 1995/12/15 09:13:56 tbr +* Branch point for Release 5.0.0 +* +* Revision 3.1 1995/12/15 01:17:15 andy +* Prepare for GA Release +* +*/ +/* + * SCCS: @(#) TestS.c Rel 1.1 (11/28/91) + * + * UniSoft Ltd., London, England + * + * (C) Copyright 1991 X/Open Company Limited + * + * All rights reserved. No part of this source code may be reproduced, + * stored in a retrieval system, or transmitted, in any form or by any + * means, electronic, mechanical, photocopying, recording or otherwise, + * except as stated in the end-user licence agreement, without the prior + * permission of the copyright owners. + * + * X/Open and the 'X' symbol are trademarks of X/Open Company Limited in + * the UK and other countries. + */ + +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif + +#include <stdlib.h> +#include "xtest.h" +#include "X11/Xlib.h" +#include "X11/Xutil.h" +#include "X11/Xresource.h" +#include "tet_api.h" +#include "xtestlib.h" +#include "pixval.h" + +extern char *TestName; + +static int +test(name, val, aval) +char *name; +int val; +int aval; +{ + + if(val != aval) { + report("KeySym \"%s\" is defined to have value 0x%x instead of 0x%x.", name, val, aval); + return(0); + } + return(1); +} + + + +static void +reporterr(s) +char *s; +{ + report("Keysym \"%s\" is not defined.", s); +} + +#define XK_SPECIAL +#include <X11/keysymdef.h> +#undef XK_SPECIAL + +kysymdf13() +{ +int pass = 0, fail = 0; +#ifdef XK_blank + if(test("XK_blank", XK_blank, 0x9DF) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_blank"); + FAIL; +#endif + +#ifdef XK_soliddiamond + if(test("XK_soliddiamond", XK_soliddiamond, 0x9E0) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_soliddiamond"); + FAIL; +#endif + +#ifdef XK_checkerboard + if(test("XK_checkerboard", XK_checkerboard, 0x9E1) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_checkerboard"); + FAIL; +#endif + +#ifdef XK_ht + if(test("XK_ht", XK_ht, 0x9E2) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_ht"); + FAIL; +#endif + +#ifdef XK_ff + if(test("XK_ff", XK_ff, 0x9E3) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_ff"); + FAIL; +#endif + +#ifdef XK_cr + if(test("XK_cr", XK_cr, 0x9E4) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_cr"); + FAIL; +#endif + +#ifdef XK_lf + if(test("XK_lf", XK_lf, 0x9E5) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_lf"); + FAIL; +#endif + +#ifdef XK_nl + if(test("XK_nl", XK_nl, 0x9E8) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_nl"); + FAIL; +#endif + +#ifdef XK_vt + if(test("XK_vt", XK_vt, 0x9E9) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_vt"); + FAIL; +#endif + +#ifdef XK_lowrightcorner + if(test("XK_lowrightcorner", XK_lowrightcorner, 0x9EA) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_lowrightcorner"); + FAIL; +#endif + +#ifdef XK_uprightcorner + if(test("XK_uprightcorner", XK_uprightcorner, 0x9EB) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_uprightcorner"); + FAIL; +#endif + +#ifdef XK_upleftcorner + if(test("XK_upleftcorner", XK_upleftcorner, 0x9EC) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_upleftcorner"); + FAIL; +#endif + +#ifdef XK_lowleftcorner + if(test("XK_lowleftcorner", XK_lowleftcorner, 0x9ED) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_lowleftcorner"); + FAIL; +#endif + +#ifdef XK_crossinglines + if(test("XK_crossinglines", XK_crossinglines, 0x9EE) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_crossinglines"); + FAIL; +#endif + +#ifdef XK_horizlinescan1 + if(test("XK_horizlinescan1", XK_horizlinescan1, 0x9EF) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_horizlinescan1"); + FAIL; +#endif + +#ifdef XK_horizlinescan3 + if(test("XK_horizlinescan3", XK_horizlinescan3, 0x9F0) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_horizlinescan3"); + FAIL; +#endif + +#ifdef XK_horizlinescan5 + if(test("XK_horizlinescan5", XK_horizlinescan5, 0x9F1) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_horizlinescan5"); + FAIL; +#endif + +#ifdef XK_horizlinescan7 + if(test("XK_horizlinescan7", XK_horizlinescan7, 0x9F2) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_horizlinescan7"); + FAIL; +#endif + +#ifdef XK_horizlinescan9 + if(test("XK_horizlinescan9", XK_horizlinescan9, 0x9F3) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_horizlinescan9"); + FAIL; +#endif + +#ifdef XK_leftt + if(test("XK_leftt", XK_leftt, 0x9F4) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_leftt"); + FAIL; +#endif + +#ifdef XK_rightt + if(test("XK_rightt", XK_rightt, 0x9F5) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_rightt"); + FAIL; +#endif + +#ifdef XK_bott + if(test("XK_bott", XK_bott, 0x9F6) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_bott"); + FAIL; +#endif + +#ifdef XK_topt + if(test("XK_topt", XK_topt, 0x9F7) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_topt"); + FAIL; +#endif + +#ifdef XK_vertbar + if(test("XK_vertbar", XK_vertbar, 0x9F8) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_vertbar"); + FAIL; +#endif + + + CHECKPASS(24); +} diff --git a/xts5/Xopen/keysymdef/TestT.c b/xts5/Xopen/keysymdef/TestT.c new file mode 100644 index 00000000..68c148c0 --- /dev/null +++ b/xts5/Xopen/keysymdef/TestT.c @@ -0,0 +1,616 @@ +/* +Copyright (c) 2005 X.Org Foundation L.L.C. + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies +of the Software, and to permit persons to whom the Software is furnished to do +so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. +*/ +/* +* $Header: /cvs/xtest/xtest/xts5/tset/Xopen/keysymdef/TestT.c,v 1.2 2005-11-03 08:44:00 jmichael Exp $ +* +* Project: VSW5 +* +* File: xts5/tset/Xopen/keysymdef/TestT.c +* +* Description: +* Tests for keysymdef() +* +* Modifications: +* $Log: TestT.c,v $ +* Revision 1.2 2005-11-03 08:44:00 jmichael +* clean up all vsw5 paths to use xts5 instead. +* +* Revision 1.1.1.2 2005/04/15 14:05:40 anderson +* Reimport of the base with the legal name in the copyright fixed. +* +* Revision 8.0 1998/12/23 23:35:42 mar +* Branch point for Release 5.0.2 +* +* Revision 7.0 1998/10/30 22:58:19 mar +* Branch point for Release 5.0.2b1 +* +* Revision 6.0 1998/03/02 05:26:56 tbr +* Branch point for Release 5.0.1 +* +* Revision 5.0 1998/01/26 03:23:29 tbr +* Branch point for Release 5.0.1b1 +* +* Revision 4.1 1996/05/09 21:16:18 andy +* Fixed X includes +* +* Revision 4.0 1995/12/15 09:13:57 tbr +* Branch point for Release 5.0.0 +* +* Revision 3.1 1995/12/15 01:17:17 andy +* Prepare for GA Release +* +*/ +/* + * SCCS: @(#) TestT.c Rel 1.1 (11/28/91) + * + * UniSoft Ltd., London, England + * + * (C) Copyright 1991 X/Open Company Limited + * + * All rights reserved. No part of this source code may be reproduced, + * stored in a retrieval system, or transmitted, in any form or by any + * means, electronic, mechanical, photocopying, recording or otherwise, + * except as stated in the end-user licence agreement, without the prior + * permission of the copyright owners. + * + * X/Open and the 'X' symbol are trademarks of X/Open Company Limited in + * the UK and other countries. + */ + +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif + +#include <stdlib.h> +#include "xtest.h" +#include "X11/Xlib.h" +#include "X11/Xutil.h" +#include "X11/Xresource.h" +#include "tet_api.h" +#include "xtestlib.h" +#include "pixval.h" + +extern char *TestName; + +static int +test(name, val, aval) +char *name; +int val; +int aval; +{ + + if(val != aval) { + report("KeySym \"%s\" is defined to have value 0x%x instead of 0x%x.", name, val, aval); + return(0); + } + return(1); +} + + + +static void +reporterr(s) +char *s; +{ + report("Keysym \"%s\" is not defined.", s); +} + +#define XK_TECHNICAL +#include <X11/keysymdef.h> +#undef XK_TECHNICAL + +kysymdf14() +{ +int pass = 0, fail = 0; +#ifdef XK_leftradical + if(test("XK_leftradical", XK_leftradical, 0x8A1) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_leftradical"); + FAIL; +#endif + +#ifdef XK_topleftradical + if(test("XK_topleftradical", XK_topleftradical, 0x8A2) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_topleftradical"); + FAIL; +#endif + +#ifdef XK_horizconnector + if(test("XK_horizconnector", XK_horizconnector, 0x8A3) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_horizconnector"); + FAIL; +#endif + +#ifdef XK_topintegral + if(test("XK_topintegral", XK_topintegral, 0x8A4) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_topintegral"); + FAIL; +#endif + +#ifdef XK_botintegral + if(test("XK_botintegral", XK_botintegral, 0x8A5) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_botintegral"); + FAIL; +#endif + +#ifdef XK_vertconnector + if(test("XK_vertconnector", XK_vertconnector, 0x8A6) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_vertconnector"); + FAIL; +#endif + +#ifdef XK_topleftsqbracket + if(test("XK_topleftsqbracket", XK_topleftsqbracket, 0x8A7) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_topleftsqbracket"); + FAIL; +#endif + +#ifdef XK_botleftsqbracket + if(test("XK_botleftsqbracket", XK_botleftsqbracket, 0x8A8) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_botleftsqbracket"); + FAIL; +#endif + +#ifdef XK_toprightsqbracket + if(test("XK_toprightsqbracket", XK_toprightsqbracket, 0x8A9) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_toprightsqbracket"); + FAIL; +#endif + +#ifdef XK_botrightsqbracket + if(test("XK_botrightsqbracket", XK_botrightsqbracket, 0x8AA) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_botrightsqbracket"); + FAIL; +#endif + +#ifdef XK_topleftparens + if(test("XK_topleftparens", XK_topleftparens, 0x8AB) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_topleftparens"); + FAIL; +#endif + +#ifdef XK_botleftparens + if(test("XK_botleftparens", XK_botleftparens, 0x8AC) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_botleftparens"); + FAIL; +#endif + +#ifdef XK_toprightparens + if(test("XK_toprightparens", XK_toprightparens, 0x8AD) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_toprightparens"); + FAIL; +#endif + +#ifdef XK_botrightparens + if(test("XK_botrightparens", XK_botrightparens, 0x8AE) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_botrightparens"); + FAIL; +#endif + +#ifdef XK_leftmiddlecurlybrace + if(test("XK_leftmiddlecurlybrace", XK_leftmiddlecurlybrace, 0x8AF) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_leftmiddlecurlybrace"); + FAIL; +#endif + +#ifdef XK_rightmiddlecurlybrace + if(test("XK_rightmiddlecurlybrace", XK_rightmiddlecurlybrace, 0x8B0) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_rightmiddlecurlybrace"); + FAIL; +#endif + +#ifdef XK_topleftsummation + if(test("XK_topleftsummation", XK_topleftsummation, 0x8B1) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_topleftsummation"); + FAIL; +#endif + +#ifdef XK_botleftsummation + if(test("XK_botleftsummation", XK_botleftsummation, 0x8B2) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_botleftsummation"); + FAIL; +#endif + +#ifdef XK_topvertsummationconnector + if(test("XK_topvertsummationconnector", XK_topvertsummationconnector, 0x8B3) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_topvertsummationconnector"); + FAIL; +#endif + +#ifdef XK_botvertsummationconnector + if(test("XK_botvertsummationconnector", XK_botvertsummationconnector, 0x8B4) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_botvertsummationconnector"); + FAIL; +#endif + +#ifdef XK_toprightsummation + if(test("XK_toprightsummation", XK_toprightsummation, 0x8B5) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_toprightsummation"); + FAIL; +#endif + +#ifdef XK_botrightsummation + if(test("XK_botrightsummation", XK_botrightsummation, 0x8B6) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_botrightsummation"); + FAIL; +#endif + +#ifdef XK_rightmiddlesummation + if(test("XK_rightmiddlesummation", XK_rightmiddlesummation, 0x8B7) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_rightmiddlesummation"); + FAIL; +#endif + +#ifdef XK_lessthanequal + if(test("XK_lessthanequal", XK_lessthanequal, 0x8BC) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_lessthanequal"); + FAIL; +#endif + +#ifdef XK_notequal + if(test("XK_notequal", XK_notequal, 0x8BD) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_notequal"); + FAIL; +#endif + +#ifdef XK_greaterthanequal + if(test("XK_greaterthanequal", XK_greaterthanequal, 0x8BE) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_greaterthanequal"); + FAIL; +#endif + +#ifdef XK_integral + if(test("XK_integral", XK_integral, 0x8BF) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_integral"); + FAIL; +#endif + +#ifdef XK_therefore + if(test("XK_therefore", XK_therefore, 0x8C0) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_therefore"); + FAIL; +#endif + +#ifdef XK_variation + if(test("XK_variation", XK_variation, 0x8C1) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_variation"); + FAIL; +#endif + +#ifdef XK_infinity + if(test("XK_infinity", XK_infinity, 0x8C2) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_infinity"); + FAIL; +#endif + +#ifdef XK_nabla + if(test("XK_nabla", XK_nabla, 0x8C5) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_nabla"); + FAIL; +#endif + +#ifdef XK_approximate + if(test("XK_approximate", XK_approximate, 0x8C8) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_approximate"); + FAIL; +#endif + +#ifdef XK_similarequal + if(test("XK_similarequal", XK_similarequal, 0x8C9) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_similarequal"); + FAIL; +#endif + +#ifdef XK_ifonlyif + if(test("XK_ifonlyif", XK_ifonlyif, 0x8CD) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_ifonlyif"); + FAIL; +#endif + +#ifdef XK_implies + if(test("XK_implies", XK_implies, 0x8CE) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_implies"); + FAIL; +#endif + +#ifdef XK_identical + if(test("XK_identical", XK_identical, 0x8CF) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_identical"); + FAIL; +#endif + +#ifdef XK_radical + if(test("XK_radical", XK_radical, 0x8D6) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_radical"); + FAIL; +#endif + +#ifdef XK_includedin + if(test("XK_includedin", XK_includedin, 0x8DA) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_includedin"); + FAIL; +#endif + +#ifdef XK_includes + if(test("XK_includes", XK_includes, 0x8DB) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_includes"); + FAIL; +#endif + +#ifdef XK_intersection + if(test("XK_intersection", XK_intersection, 0x8DC) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_intersection"); + FAIL; +#endif + +#ifdef XK_union + if(test("XK_union", XK_union, 0x8DD) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_union"); + FAIL; +#endif + +#ifdef XK_logicaland + if(test("XK_logicaland", XK_logicaland, 0x8DE) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_logicaland"); + FAIL; +#endif + +#ifdef XK_logicalor + if(test("XK_logicalor", XK_logicalor, 0x8DF) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_logicalor"); + FAIL; +#endif + +#ifdef XK_partialderivative + if(test("XK_partialderivative", XK_partialderivative, 0x8EF) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_partialderivative"); + FAIL; +#endif + +#ifdef XK_function + if(test("XK_function", XK_function, 0x8F6) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_function"); + FAIL; +#endif + +#ifdef XK_leftarrow + if(test("XK_leftarrow", XK_leftarrow, 0x8FB) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_leftarrow"); + FAIL; +#endif + +#ifdef XK_uparrow + if(test("XK_uparrow", XK_uparrow, 0x8FC) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_uparrow"); + FAIL; +#endif + +#ifdef XK_rightarrow + if(test("XK_rightarrow", XK_rightarrow, 0x8FD) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_rightarrow"); + FAIL; +#endif + +#ifdef XK_downarrow + if(test("XK_downarrow", XK_downarrow, 0x8FE) == 0) + FAIL; + else + CHECK; +#else + reporterr("XK_downarrow"); + FAIL; +#endif + + + CHECKPASS(49); +} diff --git a/xts5/Xopen/keysymdef/keysymdef.m b/xts5/Xopen/keysymdef/keysymdef.m new file mode 100644 index 00000000..5d4f979d --- /dev/null +++ b/xts5/Xopen/keysymdef/keysymdef.m @@ -0,0 +1,1298 @@ +Copyright (c) 2005 X.Org Foundation L.L.C. + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies +of the Software, and to permit persons to whom the Software is furnished to do +so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. +$Header: /cvs/xtest/xtest/xts5/tset/Xopen/keysymdef/keysymdef.m,v 1.2 2005-11-03 08:44:00 jmichael Exp $ + +>># Project: VSW5 +>># +>># File: xts5/tset/XOPEN/keysymdef/keysymdef.m +>># +>># Description: +>># Tests for keysymdef() +>># +>># Modifications: +>># $Log: kysymdf.m,v $ +>># Revision 1.2 2005-11-03 08:44:00 jmichael +>># clean up all vsw5 paths to use xts5 instead. +>># +>># Revision 1.1.1.2 2005/04/15 14:05:40 anderson +>># Reimport of the base with the legal name in the copyright fixed. +>># +>># Revision 8.0 1998/12/23 23:35:43 mar +>># Branch point for Release 5.0.2 +>># +>># Revision 7.0 1998/10/30 22:58:20 mar +>># Branch point for Release 5.0.2b1 +>># +>># Revision 6.0 1998/03/02 05:26:57 tbr +>># Branch point for Release 5.0.1 +>># +>># Revision 5.0 1998/01/26 03:23:30 tbr +>># Branch point for Release 5.0.1b1 +>># +>># Revision 4.0 1995/12/15 09:13:59 tbr +>># Branch point for Release 5.0.0 +>># +>># Revision 3.1 1995/12/15 01:17:20 andy +>># Prepare for GA Release +>># +/* + * SCCS: @(#) kysymdf.m Rel 1.13 (7/17/92) + * + * UniSoft Ltd., London, England + * + * (C) Copyright 1991 X/Open Company Limited + * + * All rights reserved. No part of this source code may be reproduced, + * stored in a retrieval system, or transmitted, in any form or by any + * means, electronic, mechanical, photocopying, recording or otherwise, + * except as stated in the end-user licence agreement, without the prior + * permission of the copyright owners. + * + * X/Open and the 'X' symbol are trademarks of X/Open Company Limited in + * the UK and other countries. + */ +>>TITLE keysymdef Xopen +>>CFILES Test0.c Test1.c Test2.c Test3.c Test4.c TestA.c TestC.c TestG.c TestH.c TestK.c TestL.c TestM.c TestP.c TestS.c TestT.c +>>ASSERTION Good A +When the header file <X11/keysymdef.h> is included while the feature test macro +.S XK_LATIN1 +is defined, +then the symbols in the table which have code 1 +are defined to have the hexadecimal values given in the table. +.tL "Code" "Value" "Name" +.tL "1" "20" "XK_space" +.tL "1" "21" "XK_exclam" +.tL "1" "22" "XK_quotedbl" +.tL "1" "23" "XK_numbersign" +.tL "1" "24" "XK_dollar" +.tL "1" "25" "XK_percent" +.tL "1" "26" "XK_ampersand" +.tL "1" "27" "XK_apostrophe" +.tL "1" "27" "XK_quoteright" +.tL "1" "28" "XK_parenleft" +.tL "1" "29" "XK_parenright" +.tL "1" "2A" "XK_asterisk" +.tL "1" "2B" "XK_plus" +.tL "1" "2C" "XK_comma" +.tL "1" "2D" "XK_minus" +.tL "1" "2E" "XK_period" +.tL "1" "2F" "XK_slash" +.tL "1" "30" "XK_0" +.tL "1" "31" "XK_1" +.tL "1" "32" "XK_2" +.tL "1" "33" "XK_3" +.tL "1" "34" "XK_4" +.tL "1" "35" "XK_5" +.tL "1" "36" "XK_6" +.tL "1" "37" "XK_7" +.tL "1" "38" "XK_8" +.tL "1" "39" "XK_9" +.tL "1" "3A" "XK_colon" +.tL "1" "3B" "XK_semicolon" +.tL "1" "3C" "XK_less" +.tL "1" "3D" "XK_equal" +.tL "1" "3E" "XK_greater" +.tL "1" "3F" "XK_question" +.tL "1" "40" "XK_at" +.tL "1" "41" "XK_A" +.tL "1" "42" "XK_B" +.tL "1" "43" "XK_C" +.tL "1" "44" "XK_D" +.tL "1" "45" "XK_E" +.tL "1" "46" "XK_F" +.tL "1" "47" "XK_G" +.tL "1" "48" "XK_H" +.tL "1" "49" "XK_I" +.tL "1" "4A" "XK_J" +.tL "1" "4B" "XK_K" +.tL "1" "4C" "XK_L" +.tL "1" "4D" "XK_M" +.tL "1" "4E" "XK_N" +.tL "1" "4F" "XK_O" +.tL "1" "50" "XK_P" +.tL "1" "51" "XK_Q" +.tL "1" "52" "XK_R" +.tL "1" "53" "XK_S" +.tL "1" "54" "XK_T" +.tL "1" "55" "XK_U" +.tL "1" "56" "XK_V" +.tL "1" "57" "XK_W" +.tL "1" "58" "XK_X" +.tL "1" "59" "XK_Y" +.tL "1" "5A" "XK_Z" +.tL "1" "5B" "XK_bracketleft" +.tL "1" "5C" "XK_backslash" +.tL "1" "5D" "XK_bracketright" +.tL "1" "5E" "XK_asciicircum" +.tL "1" "5F" "XK_underscore" +.tL "1" "60" "XK_grave" +.tL "1" "60" "XK_quoteleft" +.tL "1" "61" "XK_a" +.tL "1" "62" "XK_b" +.tL "1" "63" "XK_c" +.tL "1" "64" "XK_d" +.tL "1" "65" "XK_e" +.tL "1" "66" "XK_f" +.tL "1" "67" "XK_g" +.tL "1" "68" "XK_h" +.tL "1" "69" "XK_i" +.tL "1" "6A" "XK_j" +.tL "1" "6B" "XK_k" +.tL "1" "6C" "XK_l" +.tL "1" "6D" "XK_m" +.tL "1" "6E" "XK_n" +.tL "1" "6F" "XK_o" +.tL "1" "70" "XK_p" +.tL "1" "71" "XK_q" +.tL "1" "72" "XK_r" +.tL "1" "73" "XK_s" +.tL "1" "74" "XK_t" +.tL "1" "75" "XK_u" +.tL "1" "76" "XK_v" +.tL "1" "77" "XK_w" +.tL "1" "78" "XK_x" +.tL "1" "79" "XK_y" +.tL "1" "7A" "XK_z" +.tL "1" "7B" "XK_braceleft" +.tL "1" "7C" "XK_bar" +.tL "1" "7D" "XK_braceright" +.tL "1" "7E" "XK_asciitilde" +.tL "1" "A0" "XK_nobreakspace" +.tL "1" "A1" "XK_exclamdown" +.tL "1" "A2" "XK_cent" +.tL "1" "A3" "XK_sterling" +.tL "1" "A4" "XK_currency" +.tL "1" "A5" "XK_yen" +.tL "1" "A6" "XK_brokenbar" +.tL "1" "A7" "XK_section" +.tL "1" "A8" "XK_diaeresis" +.tL "1" "A9" "XK_copyright" +.tL "1" "AA" "XK_ordfeminine" +.tL "1" "AB" "XK_guillemotleft" +.tL "1" "AC" "XK_notsign" +.tL "1" "AD" "XK_hyphen" +.tL "1" "AE" "XK_registered" +.tL "1" "AF" "XK_macron" +.tL "1" "B0" "XK_degree" +.tL "1" "B1" "XK_plusminus" +.tL "1" "B2" "XK_twosuperior" +.tL "1" "B3" "XK_threesuperior" +.tL "1" "B4" "XK_acute" +.tL "1" "B5" "XK_mu" +.tL "1" "B6" "XK_paragraph" +.tL "1" "B7" "XK_periodcentered" +.tL "1" "B8" "XK_cedilla" +.tL "1" "B9" "XK_onesuperior" +.tL "1" "BA" "XK_masculine" +.tL "1" "BB" "XK_guillemotright" +.tL "1" "BC" "XK_onequarter" +.tL "1" "BD" "XK_onehalf" +.tL "1" "BE" "XK_threequarters" +.tL "1" "BF" "XK_questiondown" +.tL "1" "C0" "XK_Agrave" +.tL "1" "C1" "XK_Aacute" +.tL "1" "C2" "XK_Acircumflex" +.tL "1" "C3" "XK_Atilde" +.tL "1" "C4" "XK_Adiaeresis" +.tL "1" "C5" "XK_Aring" +.tL "1" "C6" "XK_AE" +.tL "1" "C7" "XK_Ccedilla" +.tL "1" "C8" "XK_Egrave" +.tL "1" "C9" "XK_Eacute" +.tL "1" "CA" "XK_Ecircumflex" +.tL "1" "CB" "XK_Ediaeresis" +.tL "1" "CC" "XK_Igrave" +.tL "1" "CD" "XK_Iacute" +.tL "1" "CE" "XK_Icircumflex" +.tL "1" "CF" "XK_Idiaeresis" +.tL "1" "D0" "XK_ETH" +.tL "1" "D0" "XK_Eth" +.tL "1" "D1" "XK_Ntilde" +.tL "1" "D2" "XK_Ograve" +.tL "1" "D3" "XK_Oacute" +.tL "1" "D4" "XK_Ocircumflex" +.tL "1" "D5" "XK_Otilde" +.tL "1" "D6" "XK_Odiaeresis" +.tL "1" "D7" "XK_multiply" +.tL "1" "D8" "XK_Ooblique" +.tL "1" "D9" "XK_Ugrave" +.tL "1" "DA" "XK_Uacute" +.tL "1" "DB" "XK_Ucircumflex" +.tL "1" "DC" "XK_Udiaeresis" +.tL "1" "DD" "XK_Yacute" +.tL "1" "DE" "XK_THORN" +.tL "1" "DE" "XK_Thorn" +.tL "1" "DF" "XK_ssharp" +.tL "1" "E0" "XK_agrave" +.tL "1" "E1" "XK_aacute" +.tL "1" "E2" "XK_acircumflex" +.tL "1" "E3" "XK_atilde" +.tL "1" "E4" "XK_adiaeresis" +.tL "1" "E5" "XK_aring" +.tL "1" "E6" "XK_ae" +.tL "1" "E7" "XK_ccedilla" +.tL "1" "E8" "XK_egrave" +.tL "1" "E9" "XK_eacute" +.tL "1" "EA" "XK_ecircumflex" +.tL "1" "EB" "XK_ediaeresis" +.tL "1" "EC" "XK_igrave" +.tL "1" "ED" "XK_iacute" +.tL "1" "EE" "XK_icircumflex" +.tL "1" "EF" "XK_idiaeresis" +.tL "1" "F0" "XK_eth" +.tL "1" "F1" "XK_ntilde" +.tL "1" "F2" "XK_ograve" +.tL "1" "F3" "XK_oacute" +.tL "1" "F4" "XK_ocircumflex" +.tL "1" "F5" "XK_otilde" +.tL "1" "F6" "XK_odiaeresis" +.tL "1" "F7" "XK_division" +.tL "1" "F8" "XK_oslash" +.tL "1" "F9" "XK_ugrave" +.tL "1" "FA" "XK_uacute" +.tL "1" "FB" "XK_ucircumflex" +.tL "1" "FC" "XK_udiaeresis" +.tL "1" "FD" "XK_yacute" +.tL "1" "FE" "XK_thorn" +.tL "1" "FF" "XK_ydiaeresis" +>>STRATEGY +Define symbol XK_LATIN1. +Include header file <X11/keysymdef.h> +For each KeySym in table with code 1: + Verify that the symbol is defined using #ifdef. + Verify that the symbol has the expected value using #if. +>>CODE + + kysymdf1(); + +>>ASSERTION Good A +When the header file <X11/keysymdef.h> is included while the feature test macro +.S XK_LATIN2 +is defined, +then the symbols in the table which have code 2 +are defined to have the hexadecimal values given in the table. +.tL "Code" "Value" "Name" +.tL "2" "1A1" "XK_Aogonek" +.tL "2" "1A2" "XK_breve" +.tL "2" "1A3" "XK_Lstroke" +.tL "2" "1A5" "XK_Lcaron" +.tL "2" "1A6" "XK_Sacute" +.tL "2" "1A9" "XK_Scaron" +.tL "2" "1AA" "XK_Scedilla" +.tL "2" "1AB" "XK_Tcaron" +.tL "2" "1AC" "XK_Zacute" +.tL "2" "1AE" "XK_Zcaron" +.tL "2" "1AF" "XK_Zabovedot" +.tL "2" "1B1" "XK_aogonek" +.tL "2" "1B2" "XK_ogonek" +.tL "2" "1B3" "XK_lstroke" +.tL "2" "1B5" "XK_lcaron" +.tL "2" "1B6" "XK_sacute" +.tL "2" "1B7" "XK_caron" +.tL "2" "1B9" "XK_scaron" +.tL "2" "1BA" "XK_scedilla" +.tL "2" "1BB" "XK_tcaron" +.tL "2" "1BC" "XK_zacute" +.tL "2" "1BD" "XK_doubleacute" +.tL "2" "1BE" "XK_zcaron" +.tL "2" "1BF" "XK_zabovedot" +.tL "2" "1C0" "XK_Racute" +.tL "2" "1C3" "XK_Abreve" +.tL "2" "1C5" "XK_Lacute" +.tL "2" "1C6" "XK_Cacute" +.tL "2" "1C8" "XK_Ccaron" +.tL "2" "1CA" "XK_Eogonek" +.tL "2" "1CC" "XK_Ecaron" +.tL "2" "1CF" "XK_Dcaron" +.tL "2" "1D0" "XK_Dstroke" +.tL "2" "1D1" "XK_Nacute" +.tL "2" "1D2" "XK_Ncaron" +.tL "2" "1D5" "XK_Odoubleacute" +.tL "2" "1D8" "XK_Rcaron" +.tL "2" "1D9" "XK_Uring" +.tL "2" "1DB" "XK_Udoubleacute" +.tL "2" "1DE" "XK_Tcedilla" +.tL "2" "1E0" "XK_racute" +.tL "2" "1E3" "XK_abreve" +.tL "2" "1E5" "XK_lacute" +.tL "2" "1E6" "XK_cacute" +.tL "2" "1E8" "XK_ccaron" +.tL "2" "1EA" "XK_eogonek" +.tL "2" "1EC" "XK_ecaron" +.tL "2" "1EF" "XK_dcaron" +.tL "2" "1F0" "XK_dstroke" +.tL "2" "1F1" "XK_nacute" +.tL "2" "1F2" "XK_ncaron" +.tL "2" "1F5" "XK_odoubleacute" +.tL "2" "1F8" "XK_rcaron" +.tL "2" "1F9" "XK_uring" +.tL "2" "1FB" "XK_udoubleacute" +.tL "2" "1FE" "XK_tcedilla" +.tL "2" "1FF" "XK_abovedot" +>>STRATEGY +Define symbol XK_LATIN2. +Include header file <X11/keysymdef.h> +For each KeySym in table with code 2: + Verify that the symbol is defined using #ifdef. + Verify that the symbol has the expected value using #if. +>>CODE + + kysymdf2(); + +>>ASSERTION Good A +When the header file <X11/keysymdef.h> is included while the feature test macro +.S XK_LATIN3 +is defined, +then the symbols in the table which have code 3 +are defined to have the hexadecimal values given in the table. +.tL "Code" "Value" "Name" +.tL "3" "2A1" "XK_Hstroke" +.tL "3" "2A6" "XK_Hcircumflex" +.tL "3" "2A9" "XK_Iabovedot" +.tL "3" "2AB" "XK_Gbreve" +.tL "3" "2AC" "XK_Jcircumflex" +.tL "3" "2B1" "XK_hstroke" +.tL "3" "2B6" "XK_hcircumflex" +.tL "3" "2B9" "XK_idotless" +.tL "3" "2BB" "XK_gbreve" +.tL "3" "2BC" "XK_jcircumflex" +.tL "3" "2C5" "XK_Cabovedot" +.tL "3" "2C6" "XK_Ccircumflex" +.tL "3" "2D5" "XK_Gabovedot" +.tL "3" "2D8" "XK_Gcircumflex" +.tL "3" "2DD" "XK_Ubreve" +.tL "3" "2DE" "XK_Scircumflex" +.tL "3" "2E5" "XK_cabovedot" +.tL "3" "2E6" "XK_ccircumflex" +.tL "3" "2F5" "XK_gabovedot" +.tL "3" "2F8" "XK_gcircumflex" +.tL "3" "2FD" "XK_ubreve" +.tL "3" "2FE" "XK_scircumflex" +>>STRATEGY +Define symbol XK_LATIN3. +Include header file <X11/keysymdef.h> +For each KeySym in table with code 3: + Verify that the symbol is defined using #ifdef. + Verify that the symbol has the expected value using #if. +>>CODE + + kysymdf3(); + +>>ASSERTION Good A +When the header file <X11/keysymdef.h> is included while the feature test macro +.S XK_LATIN4 +is defined, +then the symbols in the table which have code 4 +are defined to have the hexadecimal values given in the table. +.tL "Code" "Value" "Name" +.tL "4" "3A2" "XK_kra" +.tL "4" "3A2" "XK_kappa" +.tL "4" "3A3" "XK_Rcedilla" +.tL "4" "3A5" "XK_Itilde" +.tL "4" "3A6" "XK_Lcedilla" +.tL "4" "3AA" "XK_Emacron" +.tL "4" "3AB" "XK_Gcedilla" +.tL "4" "3AC" "XK_Tslash" +.tL "4" "3B3" "XK_rcedilla" +.tL "4" "3B5" "XK_itilde" +.tL "4" "3B6" "XK_lcedilla" +.tL "4" "3BA" "XK_emacron" +.tL "4" "3BB" "XK_gcedilla" +.tL "4" "3BC" "XK_tslash" +.tL "4" "3BD" "XK_ENG" +.tL "4" "3BF" "XK_eng" +.tL "4" "3C0" "XK_Amacron" +.tL "4" "3C7" "XK_Iogonek" +.tL "4" "3CC" "XK_Eabovedot" +.tL "4" "3CF" "XK_Imacron" +.tL "4" "3D1" "XK_Ncedilla" +.tL "4" "3D2" "XK_Omacron" +.tL "4" "3D3" "XK_Kcedilla" +.tL "4" "3D9" "XK_Uogonek" +.tL "4" "3DD" "XK_Utilde" +.tL "4" "3DE" "XK_Umacron" +.tL "4" "3E0" "XK_amacron" +.tL "4" "3E7" "XK_iogonek" +.tL "4" "3EC" "XK_eabovedot" +.tL "4" "3EF" "XK_imacron" +.tL "4" "3F1" "XK_ncedilla" +.tL "4" "3F2" "XK_omacron" +.tL "4" "3F3" "XK_kcedilla" +.tL "4" "3F9" "XK_uogonek" +.tL "4" "3FD" "XK_utilde" +.tL "4" "3FE" "XK_umacron" +>>STRATEGY +Define symbol XK_LATIN4. +Include header file <X11/keysymdef.h> +For each KeySym in table with code 4: + Verify that the symbol is defined using #ifdef. + Verify that the symbol has the expected value using #if. +>>CODE + + kysymdf4(); + +>>ASSERTION Good A +When the header file <X11/keysymdef.h> is included while the feature test macro +.S XK_ARABIC +is defined, +then the symbols in the table which have code A +are defined to have the hexadecimal values given in the table. +.tL "Code" "Value" "Name" +.tL "A" "5AC" "XK_Arabic_comma" +.tL "A" "5BB" "XK_Arabic_semicolon" +.tL "A" "5BF" "XK_Arabic_question_mark" +.tL "A" "5C1" "XK_Arabic_hamza" +.tL "A" "5C2" "XK_Arabic_maddaonalef" +.tL "A" "5C3" "XK_Arabic_hamzaonalef" +.tL "A" "5C4" "XK_Arabic_hamzaonwaw" +.tL "A" "5C5" "XK_Arabic_hamzaunderalef" +.tL "A" "5C6" "XK_Arabic_hamzaonyeh" +.tL "A" "5C7" "XK_Arabic_alef" +.tL "A" "5C8" "XK_Arabic_beh" +.tL "A" "5C9" "XK_Arabic_tehmarbuta" +.tL "A" "5CA" "XK_Arabic_teh" +.tL "A" "5CB" "XK_Arabic_theh" +.tL "A" "5CC" "XK_Arabic_jeem" +.tL "A" "5CD" "XK_Arabic_hah" +.tL "A" "5CE" "XK_Arabic_khah" +.tL "A" "5CF" "XK_Arabic_dal" +.tL "A" "5D0" "XK_Arabic_thal" +.tL "A" "5D1" "XK_Arabic_ra" +.tL "A" "5D2" "XK_Arabic_zain" +.tL "A" "5D3" "XK_Arabic_seen" +.tL "A" "5D4" "XK_Arabic_sheen" +.tL "A" "5D5" "XK_Arabic_sad" +.tL "A" "5D6" "XK_Arabic_dad" +.tL "A" "5D7" "XK_Arabic_tah" +.tL "A" "5D8" "XK_Arabic_zah" +.tL "A" "5D9" "XK_Arabic_ain" +.tL "A" "5DA" "XK_Arabic_ghain" +.tL "A" "5E0" "XK_Arabic_tatweel" +.tL "A" "5E1" "XK_Arabic_feh" +.tL "A" "5E2" "XK_Arabic_qaf" +.tL "A" "5E3" "XK_Arabic_kaf" +.tL "A" "5E4" "XK_Arabic_lam" +.tL "A" "5E5" "XK_Arabic_meem" +.tL "A" "5E6" "XK_Arabic_noon" +.tL "A" "5E7" "XK_Arabic_ha" +.tL "A" "5E7" "XK_Arabic_heh" +.tL "A" "5E8" "XK_Arabic_waw" +.tL "A" "5E9" "XK_Arabic_alefmaksura" +.tL "A" "5EA" "XK_Arabic_yeh" +.tL "A" "5EB" "XK_Arabic_fathatan" +.tL "A" "5EC" "XK_Arabic_dammatan" +.tL "A" "5ED" "XK_Arabic_kasratan" +.tL "A" "5EE" "XK_Arabic_fatha" +.tL "A" "5EF" "XK_Arabic_damma" +.tL "A" "5F0" "XK_Arabic_kasra" +.tL "A" "5F1" "XK_Arabic_shadda" +.tL "A" "5F2" "XK_Arabic_sukun" +.tL "A" "FF7E" "XK_Arabic_switch" +>>STRATEGY +Define symbol XK_ARABIC. +Include header file <X11/keysymdef.h> +For each KeySym in table with code A: + Verify that the symbol is defined using #ifdef. + Verify that the symbol has the expected value using #if. +>>CODE + + kysymdf5(); + +>>ASSERTION Good A +When the header file <X11/keysymdef.h> is included while the feature test macro +.S XK_CYRILLIC +is defined, +then the symbols in the table which have code C +are defined to have the hexadecimal values given in the table. +.tL "Code" "Value" "Name" +.tL "C" "6A1" "XK_Serbian_dje" +.tL "C" "6A2" "XK_Macedonia_gje" +.tL "C" "6A3" "XK_Cyrillic_io" +.tL "C" "6A4" "XK_Ukrainian_ie" +.tL "C" "6A4" "XK_Ukranian_je" +.tL "C" "6A5" "XK_Macedonia_dse" +.tL "C" "6A6" "XK_Ukrainian_i" +.tL "C" "6A6" "XK_Ukranian_i" +.tL "C" "6A7" "XK_Ukrainian_yi" +.tL "C" "6A7" "XK_Ukranian_yi" +.tL "C" "6A8" "XK_Cyrillic_je" +.tL "C" "6A8" "XK_Serbian_je" +.tL "C" "6A9" "XK_Cyrillic_lje" +.tL "C" "6A9" "XK_Serbian_lje" +.tL "C" "6AA" "XK_Cyrillic_nje" +.tL "C" "6AA" "XK_Serbian_nje" +.tL "C" "6AB" "XK_Serbian_tshe" +.tL "C" "6AC" "XK_Macedonia_kje" +.tL "C" "6AE" "XK_Byelorussian_shortu" +.tL "C" "6AF" "XK_Cyrillic_dzhe" +.tL "C" "6AF" "XK_Serbian_dze" +.tL "C" "6B0" "XK_numerosign" +.tL "C" "6B1" "XK_Serbian_DJE" +.tL "C" "6B2" "XK_Macedonia_GJE" +.tL "C" "6B3" "XK_Cyrillic_IO" +.tL "C" "6B4" "XK_Ukrainian_IE" +.tL "C" "6B4" "XK_Ukranian_JE" +.tL "C" "6B5" "XK_Macedonia_DSE" +.tL "C" "6B6" "XK_Ukrainian_I" +.tL "C" "6B6" "XK_Ukranian_I" +.tL "C" "6B7" "XK_Ukrainian_YI" +.tL "C" "6B7" "XK_Ukranian_YI" +.tL "C" "6B8" "XK_Cyrillic_JE" +.tL "C" "6B8" "XK_Serbian_JE" +.tL "C" "6B9" "XK_Cyrillic_LJE" +.tL "C" "6B9" "XK_Serbian_LJE" +.tL "C" "6BA" "XK_Cyrillic_NJE" +.tL "C" "6BA" "XK_Serbian_NJE" +.tL "C" "6BB" "XK_Serbian_TSHE" +.tL "C" "6BC" "XK_Macedonia_KJE" +.tL "C" "6BE" "XK_Byelorussian_SHORTU" +.tL "C" "6BF" "XK_Cyrillic_DZHE" +.tL "C" "6BF" "XK_Serbian_DZE" +.tL "C" "6C0" "XK_Cyrillic_yu" +.tL "C" "6C1" "XK_Cyrillic_a" +.tL "C" "6C2" "XK_Cyrillic_be" +.tL "C" "6C3" "XK_Cyrillic_tse" +.tL "C" "6C4" "XK_Cyrillic_de" +.tL "C" "6C5" "XK_Cyrillic_ie" +.tL "C" "6C6" "XK_Cyrillic_ef" +.tL "C" "6C7" "XK_Cyrillic_ghe" +.tL "C" "6C8" "XK_Cyrillic_ha" +.tL "C" "6C9" "XK_Cyrillic_i" +.tL "C" "6CA" "XK_Cyrillic_shorti" +.tL "C" "6CB" "XK_Cyrillic_ka" +.tL "C" "6CC" "XK_Cyrillic_el" +.tL "C" "6CD" "XK_Cyrillic_em" +.tL "C" "6CE" "XK_Cyrillic_en" +.tL "C" "6CF" "XK_Cyrillic_o" +.tL "C" "6D0" "XK_Cyrillic_pe" +.tL "C" "6D1" "XK_Cyrillic_ya" +.tL "C" "6D2" "XK_Cyrillic_er" +.tL "C" "6D3" "XK_Cyrillic_es" +.tL "C" "6D4" "XK_Cyrillic_te" +.tL "C" "6D5" "XK_Cyrillic_u" +.tL "C" "6D6" "XK_Cyrillic_zhe" +.tL "C" "6D7" "XK_Cyrillic_ve" +.tL "C" "6D8" "XK_Cyrillic_softsign" +.tL "C" "6D9" "XK_Cyrillic_yeru" +.tL "C" "6DA" "XK_Cyrillic_ze" +.tL "C" "6DB" "XK_Cyrillic_sha" +.tL "C" "6DC" "XK_Cyrillic_e" +.tL "C" "6DD" "XK_Cyrillic_shcha" +.tL "C" "6DE" "XK_Cyrillic_che" +.tL "C" "6DF" "XK_Cyrillic_hardsign" +.tL "C" "6E0" "XK_Cyrillic_YU" +.tL "C" "6E1" "XK_Cyrillic_A" +.tL "C" "6E2" "XK_Cyrillic_BE" +.tL "C" "6E3" "XK_Cyrillic_TSE" +.tL "C" "6E4" "XK_Cyrillic_DE" +.tL "C" "6E5" "XK_Cyrillic_IE" +.tL "C" "6E6" "XK_Cyrillic_EF" +.tL "C" "6E7" "XK_Cyrillic_GHE" +.tL "C" "6E8" "XK_Cyrillic_HA" +.tL "C" "6E9" "XK_Cyrillic_I" +.tL "C" "6EA" "XK_Cyrillic_SHORTI" +.tL "C" "6EB" "XK_Cyrillic_KA" +.tL "C" "6EC" "XK_Cyrillic_EL" +.tL "C" "6ED" "XK_Cyrillic_EM" +.tL "C" "6EE" "XK_Cyrillic_EN" +.tL "C" "6EF" "XK_Cyrillic_O" +.tL "C" "6F0" "XK_Cyrillic_PE" +.tL "C" "6F1" "XK_Cyrillic_YA" +.tL "C" "6F2" "XK_Cyrillic_ER" +.tL "C" "6F3" "XK_Cyrillic_ES" +.tL "C" "6F4" "XK_Cyrillic_TE" +.tL "C" "6F5" "XK_Cyrillic_U" +.tL "C" "6F6" "XK_Cyrillic_ZHE" +.tL "C" "6F7" "XK_Cyrillic_VE" +.tL "C" "6F8" "XK_Cyrillic_SOFTSIGN" +.tL "C" "6F9" "XK_Cyrillic_YERU" +.tL "C" "6FA" "XK_Cyrillic_ZE" +.tL "C" "6FB" "XK_Cyrillic_SHA" +.tL "C" "6FC" "XK_Cyrillic_E" +.tL "C" "6FD" "XK_Cyrillic_SHCHA" +.tL "C" "6FE" "XK_Cyrillic_CHE" +.tL "C" "6FF" "XK_Cyrillic_HARDSIGN" +>>STRATEGY +Define symbol XK_CYRILLIC. +Include header file <X11/keysymdef.h> +For each KeySym in table with code C: + Verify that the symbol is defined using #ifdef. + Verify that the symbol has the expected value using #if. +>>CODE + + kysymdf6(); + +>>ASSERTION Good A +When the header file <X11/keysymdef.h> is included while the feature test macro +.S XK_GREEK +is defined, +then the symbols in the table which have code G +are defined to have the hexadecimal values given in the table. +.tL "Code" "Value" "Name" +.tL "G" "7A1" "XK_Greek_ALPHAaccent" +.tL "G" "7A2" "XK_Greek_EPSILONaccent" +.tL "G" "7A3" "XK_Greek_ETAaccent" +.tL "G" "7A4" "XK_Greek_IOTAaccent" +.tL "G" "7A5" "XK_Greek_IOTAdiaeresis" +.tL "G" "7A7" "XK_Greek_OMICRONaccent" +.tL "G" "7A8" "XK_Greek_UPSILONaccent" +.tL "G" "7A9" "XK_Greek_UPSILONdieresis" +.tL "G" "7AB" "XK_Greek_OMEGAaccent" +.tL "G" "7AE" "XK_Greek_accentdieresis" +.tL "G" "7AF" "XK_Greek_horizbar" +.tL "G" "7B1" "XK_Greek_alphaaccent" +.tL "G" "7B2" "XK_Greek_epsilonaccent" +.tL "G" "7B3" "XK_Greek_etaaccent" +.tL "G" "7B4" "XK_Greek_iotaaccent" +.tL "G" "7B5" "XK_Greek_iotadieresis" +.tL "G" "7B6" "XK_Greek_iotaaccentdieresis" +.tL "G" "7B7" "XK_Greek_omicronaccent" +.tL "G" "7B8" "XK_Greek_upsilonaccent" +.tL "G" "7B9" "XK_Greek_upsilondieresis" +.tL "G" "7BA" "XK_Greek_upsilonaccentdieresis" +.tL "G" "7BB" "XK_Greek_omegaaccent" +.tL "G" "7C1" "XK_Greek_ALPHA" +.tL "G" "7C2" "XK_Greek_BETA" +.tL "G" "7C3" "XK_Greek_GAMMA" +.tL "G" "7C4" "XK_Greek_DELTA" +.tL "G" "7C5" "XK_Greek_EPSILON" +.tL "G" "7C6" "XK_Greek_ZETA" +.tL "G" "7C7" "XK_Greek_ETA" +.tL "G" "7C8" "XK_Greek_THETA" +.tL "G" "7C9" "XK_Greek_IOTA" +.tL "G" "7CA" "XK_Greek_KAPPA" +.tL "G" "7CB" "XK_Greek_LAMBDA" +.tL "G" "7CB" "XK_Greek_LAMDA" +.tL "G" "7CC" "XK_Greek_MU" +.tL "G" "7CD" "XK_Greek_NU" +.tL "G" "7CE" "XK_Greek_XI" +.tL "G" "7CF" "XK_Greek_OMICRON" +.tL "G" "7D0" "XK_Greek_PI" +.tL "G" "7D1" "XK_Greek_RHO" +.tL "G" "7D2" "XK_Greek_SIGMA" +.tL "G" "7D4" "XK_Greek_TAU" +.tL "G" "7D5" "XK_Greek_UPSILON" +.tL "G" "7D6" "XK_Greek_PHI" +.tL "G" "7D7" "XK_Greek_CHI" +.tL "G" "7D8" "XK_Greek_PSI" +.tL "G" "7D9" "XK_Greek_OMEGA" +.tL "G" "7E1" "XK_Greek_alpha" +.tL "G" "7E2" "XK_Greek_beta" +.tL "G" "7E3" "XK_Greek_gamma" +.tL "G" "7E4" "XK_Greek_delta" +.tL "G" "7E5" "XK_Greek_epsilon" +.tL "G" "7E6" "XK_Greek_zeta" +.tL "G" "7E7" "XK_Greek_eta" +.tL "G" "7E8" "XK_Greek_theta" +.tL "G" "7E9" "XK_Greek_iota" +.tL "G" "7EA" "XK_Greek_kappa" +.tL "G" "7EB" "XK_Greek_lambda" +.tL "G" "7EB" "XK_Greek_lamda" +.tL "G" "7EC" "XK_Greek_mu" +.tL "G" "7ED" "XK_Greek_nu" +.tL "G" "7EE" "XK_Greek_xi" +.tL "G" "7EF" "XK_Greek_omicron" +.tL "G" "7F0" "XK_Greek_pi" +.tL "G" "7F1" "XK_Greek_rho" +.tL "G" "7F2" "XK_Greek_sigma" +.tL "G" "7F3" "XK_Greek_finalsmallsigma" +.tL "G" "7F4" "XK_Greek_tau" +.tL "G" "7F5" "XK_Greek_upsilon" +.tL "G" "7F6" "XK_Greek_phi" +.tL "G" "7F7" "XK_Greek_chi" +.tL "G" "7F8" "XK_Greek_psi" +.tL "G" "7F9" "XK_Greek_omega" +.tL "G" "FF7E" "XK_Greek_switch" +>>STRATEGY +Define symbol XK_GREEK. +Include header file <X11/keysymdef.h> +For each KeySym in table with code G: + Verify that the symbol is defined using #ifdef. + Verify that the symbol has the expected value using #if. +>>CODE + + kysymdf7(); + +>>ASSERTION Good A +When the header file <X11/keysymdef.h> is included while the feature test macro +.S XK_HEBREW +is defined, +then the symbols in the table which have code H +are defined to have the hexadecimal values given in the table. +.tL "Code" "Value" "Name" +.tL "H" "CDF" "XK_hebrew_doublelowline" +.tL "H" "CE0" "XK_hebrew_aleph" +.tL "H" "CE1" "XK_hebrew_bet" +.tL "H" "CE1" "XK_hebrew_beth" +.tL "H" "CE2" "XK_hebrew_gimel" +.tL "H" "CE2" "XK_hebrew_gimmel" +.tL "H" "CE3" "XK_hebrew_dalet" +.tL "H" "CE3" "XK_hebrew_daleth" +.tL "H" "CE4" "XK_hebrew_he" +.tL "H" "CE5" "XK_hebrew_waw" +.tL "H" "CE6" "XK_hebrew_zain" +.tL "H" "CE6" "XK_hebrew_zayin" +.tL "H" "CE7" "XK_hebrew_chet" +.tL "H" "CE7" "XK_hebrew_het" +.tL "H" "CE8" "XK_hebrew_tet" +.tL "H" "CE8" "XK_hebrew_teth" +.tL "H" "CE9" "XK_hebrew_yod" +.tL "H" "CEA" "XK_hebrew_finalkaph" +.tL "H" "CEB" "XK_hebrew_kaph" +.tL "H" "CEC" "XK_hebrew_lamed" +.tL "H" "CED" "XK_hebrew_finalmem" +.tL "H" "CEE" "XK_hebrew_mem" +.tL "H" "CEF" "XK_hebrew_finalnun" +.tL "H" "CF0" "XK_hebrew_nun" +.tL "H" "CF1" "XK_hebrew_samech" +.tL "H" "CF1" "XK_hebrew_samekh" +.tL "H" "CF2" "XK_hebrew_ayin" +.tL "H" "CF3" "XK_hebrew_finalpe" +.tL "H" "CF4" "XK_hebrew_pe" +.tL "H" "CF5" "XK_hebrew_finalzade" +.tL "H" "CF5" "XK_hebrew_finalzadi" +.tL "H" "CF6" "XK_hebrew_zade" +.tL "H" "CF6" "XK_hebrew_zadi" +.tL "H" "CF7" "XK_hebrew_qoph" +.tL "H" "CF7" "XK_hebrew_kuf" +.tL "H" "CF8" "XK_hebrew_resh" +.tL "H" "CF9" "XK_hebrew_shin" +.tL "H" "CFA" "XK_hebrew_taw" +.tL "H" "CFA" "XK_hebrew_taf" +.tL "H" "FF7E" "XK_Hebrew_switch" +>>STRATEGY +Define symbol XK_HEBREW. +Include header file <X11/keysymdef.h> +For each KeySym in table with code H: + Verify that the symbol is defined using #ifdef. + Verify that the symbol has the expected value using #if. +>>CODE + + kysymdf8(); + +>>ASSERTION Good A +When the header file <X11/keysymdef.h> is included while the feature test macro +.S XK_KATAKANA +is defined, +then the symbols in the table which have code K +are defined to have the hexadecimal values given in the table. +.tL "Code" "Value" "Name" +.tL "K" "47E" "XK_overline" +.tL "K" "4A1" "XK_kana_fullstop" +.tL "K" "4A2" "XK_kana_openingbracket" +.tL "K" "4A3" "XK_kana_closingbracket" +.tL "K" "4A4" "XK_kana_comma" +.tL "K" "4A5" "XK_kana_conjunctive" +.tL "K" "4A5" "XK_kana_middledot" +.tL "K" "4A6" "XK_kana_WO" +.tL "K" "4A7" "XK_kana_a" +.tL "K" "4A8" "XK_kana_i" +.tL "K" "4A9" "XK_kana_u" +.tL "K" "4AA" "XK_kana_e" +.tL "K" "4AB" "XK_kana_o" +.tL "K" "4AC" "XK_kana_ya" +.tL "K" "4AD" "XK_kana_yu" +.tL "K" "4AE" "XK_kana_yo" +.tL "K" "4AF" "XK_kana_tsu" +.tL "K" "4AF" "XK_kana_tu" +.tL "K" "4B0" "XK_prolongedsound" +.tL "K" "4B1" "XK_kana_A" +.tL "K" "4B2" "XK_kana_I" +.tL "K" "4B3" "XK_kana_U" +.tL "K" "4B4" "XK_kana_E" +.tL "K" "4B5" "XK_kana_O" +.tL "K" "4B6" "XK_kana_KA" +.tL "K" "4B7" "XK_kana_KI" +.tL "K" "4B8" "XK_kana_KU" +.tL "K" "4B9" "XK_kana_KE" +.tL "K" "4BA" "XK_kana_KO" +.tL "K" "4BB" "XK_kana_SA" +.tL "K" "4BC" "XK_kana_SHI" +.tL "K" "4BD" "XK_kana_SU" +.tL "K" "4BE" "XK_kana_SE" +.tL "K" "4BF" "XK_kana_SO" +.tL "K" "4C0" "XK_kana_TA" +.tL "K" "4C1" "XK_kana_CHI" +.tL "K" "4C1" "XK_kana_TI" +.tL "K" "4C2" "XK_kana_TSU" +.tL "K" "4C2" "XK_kana_TU" +.tL "K" "4C3" "XK_kana_TE" +.tL "K" "4C4" "XK_kana_TO" +.tL "K" "4C5" "XK_kana_NA" +.tL "K" "4C6" "XK_kana_NI" +.tL "K" "4C7" "XK_kana_NU" +.tL "K" "4C8" "XK_kana_NE" +.tL "K" "4C9" "XK_kana_NO" +.tL "K" "4CA" "XK_kana_HA" +.tL "K" "4CB" "XK_kana_HI" +.tL "K" "4CC" "XK_kana_FU" +.tL "K" "4CC" "XK_kana_HU" +.tL "K" "4CD" "XK_kana_HE" +.tL "K" "4CE" "XK_kana_HO" +.tL "K" "4CF" "XK_kana_MA" +.tL "K" "4D0" "XK_kana_MI" +.tL "K" "4D1" "XK_kana_MU" +.tL "K" "4D2" "XK_kana_ME" +.tL "K" "4D3" "XK_kana_MO" +.tL "K" "4D4" "XK_kana_YA" +.tL "K" "4D5" "XK_kana_YU" +.tL "K" "4D6" "XK_kana_YO" +.tL "K" "4D7" "XK_kana_RA" +.tL "K" "4D8" "XK_kana_RI" +.tL "K" "4D9" "XK_kana_RU" +.tL "K" "4DA" "XK_kana_RE" +.tL "K" "4DB" "XK_kana_RO" +.tL "K" "4DC" "XK_kana_WA" +.tL "K" "4DD" "XK_kana_N" +.tL "K" "4DE" "XK_voicedsound" +.tL "K" "4DF" "XK_semivoicedsound" +.tL "K" "FF7E" "XK_kana_switch" +>>STRATEGY +Define symbol XK_KATAKANA. +Include header file <X11/keysymdef.h> +For each KeySym in table with code K: + Verify that the symbol is defined using #ifdef. + Verify that the symbol has the expected value using #if. +>>CODE + + kysymdf9(); + +>>ASSERTION Good A +When the header file <X11/keysymdef.h> is included while the feature test macro +.S XK_APL +is defined, +then the symbols in the table which have code L +are defined to have the hexadecimal values given in the table. +.tL "Code" "Value" "Name" +.tL "L" "BA3" "XK_leftcaret" +.tL "L" "BA6" "XK_rightcaret" +.tL "L" "BA8" "XK_downcaret" +.tL "L" "BA9" "XK_upcaret" +.tL "L" "BC0" "XK_overbar" +.tL "L" "BC2" "XK_downtack" +.tL "L" "BC3" "XK_upshoe" +.tL "L" "BC4" "XK_downstile" +.tL "L" "BC6" "XK_underbar" +.tL "L" "BCA" "XK_jot" +.tL "L" "BCC" "XK_quad" +.tL "L" "BCE" "XK_uptack" +.tL "L" "BCF" "XK_circle" +.tL "L" "BD3" "XK_upstile" +.tL "L" "BD6" "XK_downshoe" +.tL "L" "BD8" "XK_rightshoe" +.tL "L" "BDA" "XK_leftshoe" +.tL "L" "BDC" "XK_lefttack" +.tL "L" "BFC" "XK_righttack" +>>STRATEGY +Define symbol XK_APL. +Include header file <X11/keysymdef.h> +For each KeySym in table with code L: + Verify that the symbol is defined using #ifdef. + Verify that the symbol has the expected value using #if. +>>CODE + + kysymdf10(); + +>>ASSERTION Good A +When the header file <X11/keysymdef.h> is included while the feature test macro +.S XK_MISCELLANY +is defined, +then the symbols in the table which have code M +are defined to have the hexadecimal values given in the table. +.tL "Code" "Value" "Name" +.tL "M" "FF08" "XK_BackSpace" +.tL "M" "FF09" "XK_Tab" +.tL "M" "FF0A" "XK_Linefeed" +.tL "M" "FF0B" "XK_Clear" +.tL "M" "FF0D" "XK_Return" +.tL "M" "FF13" "XK_Pause" +.tL "M" "FF14" "XK_Scroll_Lock" +.tL "M" "FF1B" "XK_Escape" +.tL "M" "FF20" "XK_Multi_key" +.tL "M" "FF21" "XK_Kanji" +.tL "M" "FF22" "XK_Muhenkan" +.tL "M" "FF23" "XK_Henkan" +.tL "M" "FF23" "XK_Henkan_Mode" +.tL "M" "FF24" "XK_Romaji" +.tL "M" "FF25" "XK_Hiragana" +.tL "M" "FF26" "XK_Katakana" +.tL "M" "FF27" "XK_Hiragana_Katakana" +.tL "M" "FF28" "XK_Zenkaku" +.tL "M" "FF29" "XK_Hankaku" +.tL "M" "FF2A" "XK_Zenkaku_Hankaku" +.tL "M" "FF2B" "XK_Touroku" +.tL "M" "FF2C" "XK_Massyo" +.tL "M" "FF2D" "XK_Kana_Lock" +.tL "M" "FF2E" "XK_Kana_Shift" +.tL "M" "FF2F" "XK_Eisu_Shift" +.tL "M" "FF30" "XK_Eisu_toggle" +.tL "M" "FF50" "XK_Home" +.tL "M" "FF51" "XK_Left" +.tL "M" "FF52" "XK_Up" +.tL "M" "FF53" "XK_Right" +.tL "M" "FF54" "XK_Down" +.tL "M" "FF55" "XK_Prior" +.tL "M" "FF56" "XK_Next" +.tL "M" "FF57" "XK_End" +.tL "M" "FF58" "XK_Begin" +.tL "M" "FF60" "XK_Select" +.tL "M" "FF61" "XK_Print" +.tL "M" "FF62" "XK_Execute" +.tL "M" "FF63" "XK_Insert" +.tL "M" "FF65" "XK_Undo" +.tL "M" "FF66" "XK_Redo" +.tL "M" "FF67" "XK_Menu" +.tL "M" "FF68" "XK_Find" +.tL "M" "FF69" "XK_Cancel" +.tL "M" "FF6A" "XK_Help" +.tL "M" "FF6B" "XK_Break" +.tL "M" "FF7E" "XK_Mode_switch" +.tL "M" "FF7E" "XK_script_switch" +.tL "M" "FF7F" "XK_Num_Lock" +.tL "M" "FF80" "XK_KP_Space" +.tL "M" "FF89" "XK_KP_Tab" +.tL "M" "FF8D" "XK_KP_Enter" +.tL "M" "FF91" "XK_KP_F1" +.tL "M" "FF92" "XK_KP_F2" +.tL "M" "FF93" "XK_KP_F3" +.tL "M" "FF94" "XK_KP_F4" +.tL "M" "FFAA" "XK_KP_Multiply" +.tL "M" "FFAB" "XK_KP_Add" +.tL "M" "FFAC" "XK_KP_Separator" +.tL "M" "FFAD" "XK_KP_Subtract" +.tL "M" "FFAE" "XK_KP_Decimal" +.tL "M" "FFAF" "XK_KP_Divide" +.tL "M" "FFB0" "XK_KP_0" +.tL "M" "FFB1" "XK_KP_1" +.tL "M" "FFB2" "XK_KP_2" +.tL "M" "FFB3" "XK_KP_3" +.tL "M" "FFB4" "XK_KP_4" +.tL "M" "FFB5" "XK_KP_5" +.tL "M" "FFB6" "XK_KP_6" +.tL "M" "FFB7" "XK_KP_7" +.tL "M" "FFB8" "XK_KP_8" +.tL "M" "FFB9" "XK_KP_9" +.tL "M" "FFBD" "XK_KP_Equal" +.tL "M" "FFBE" "XK_F1" +.tL "M" "FFBF" "XK_F2" +.tL "M" "FFC0" "XK_F3" +.tL "M" "FFC1" "XK_F4" +.tL "M" "FFC2" "XK_F5" +.tL "M" "FFC3" "XK_F6" +.tL "M" "FFC4" "XK_F7" +.tL "M" "FFC5" "XK_F8" +.tL "M" "FFC6" "XK_F9" +.tL "M" "FFC7" "XK_F10" +.tL "M" "FFC8" "XK_F11" +.tL "M" "FFC8" "XK_L1" +.tL "M" "FFC9" "XK_F12" +.tL "M" "FFC9" "XK_L2" +.tL "M" "FFCA" "XK_F13" +.tL "M" "FFCA" "XK_L3" +.tL "M" "FFCB" "XK_F14" +.tL "M" "FFCB" "XK_L4" +.tL "M" "FFCC" "XK_F15" +.tL "M" "FFCC" "XK_L5" +.tL "M" "FFCD" "XK_F16" +.tL "M" "FFCD" "XK_L6" +.tL "M" "FFCE" "XK_F17" +.tL "M" "FFCE" "XK_L7" +.tL "M" "FFCF" "XK_F18" +.tL "M" "FFCF" "XK_L8" +.tL "M" "FFD0" "XK_F19" +.tL "M" "FFD0" "XK_L9" +.tL "M" "FFD1" "XK_F20" +.tL "M" "FFD1" "XK_L10" +.tL "M" "FFD2" "XK_F21" +.tL "M" "FFD2" "XK_R1" +.tL "M" "FFD3" "XK_F22" +.tL "M" "FFD3" "XK_R2" +.tL "M" "FFD4" "XK_F23" +.tL "M" "FFD4" "XK_R3" +.tL "M" "FFD5" "XK_F24" +.tL "M" "FFD5" "XK_R4" +.tL "M" "FFD6" "XK_F25" +.tL "M" "FFD6" "XK_R5" +.tL "M" "FFD7" "XK_F26" +.tL "M" "FFD7" "XK_R6" +.tL "M" "FFD8" "XK_F27" +.tL "M" "FFD8" "XK_R7" +.tL "M" "FFD9" "XK_F28" +.tL "M" "FFD9" "XK_R8" +.tL "M" "FFDA" "XK_F29" +.tL "M" "FFDA" "XK_R9" +.tL "M" "FFDB" "XK_F30" +.tL "M" "FFDB" "XK_R10" +.tL "M" "FFDC" "XK_F31" +.tL "M" "FFDC" "XK_R11" +.tL "M" "FFDD" "XK_F32" +.tL "M" "FFDD" "XK_R12" +.tL "M" "FFDE" "XK_F33" +.tL "M" "FFDE" "XK_R13" +.tL "M" "FFDF" "XK_F34" +.tL "M" "FFDF" "XK_R14" +.tL "M" "FFE0" "XK_F35" +.tL "M" "FFE0" "XK_R15" +.tL "M" "FFE1" "XK_Shift_L" +.tL "M" "FFE2" "XK_Shift_R" +.tL "M" "FFE3" "XK_Control_L" +.tL "M" "FFE4" "XK_Control_R" +.tL "M" "FFE5" "XK_Caps_Lock" +.tL "M" "FFE6" "XK_Shift_Lock" +.tL "M" "FFE7" "XK_Meta_L" +.tL "M" "FFE8" "XK_Meta_R" +.tL "M" "FFE9" "XK_Alt_L" +.tL "M" "FFEA" "XK_Alt_R" +.tL "M" "FFEB" "XK_Super_L" +.tL "M" "FFEC" "XK_Super_R" +.tL "M" "FFED" "XK_Hyper_L" +.tL "M" "FFEE" "XK_Hyper_R" +.tL "M" "FFFF" "XK_Delete" +>>STRATEGY +Define symbol XK_MISCELLANY. +Include header file <X11/keysymdef.h> +For each KeySym in table with code M: + Verify that the symbol is defined using #ifdef. + Verify that the symbol has the expected value using #if. +>>CODE + + kysymdf11(); + +>>ASSERTION Good A +When the header file <X11/keysymdef.h> is included while the feature test macro +.S XK_PUBLISHING +is defined, +then the symbols in the table which have code P +are defined to have the hexadecimal values given in the table. +.tL "Code" "Value" "Name" +.tL "P" "AA1" "XK_emspace" +.tL "P" "AA2" "XK_enspace" +.tL "P" "AA3" "XK_em3space" +.tL "P" "AA4" "XK_em4space" +.tL "P" "AA5" "XK_digitspace" +.tL "P" "AA6" "XK_punctspace" +.tL "P" "AA7" "XK_thinspace" +.tL "P" "AA8" "XK_hairspace" +.tL "P" "AA9" "XK_emdash" +.tL "P" "AAA" "XK_endash" +.tL "P" "AAC" "XK_signifblank" +.tL "P" "AAE" "XK_ellipsis" +.tL "P" "AAF" "XK_doubbaselinedot" +.tL "P" "AB0" "XK_onethird" +.tL "P" "AB1" "XK_twothirds" +.tL "P" "AB2" "XK_onefifth" +.tL "P" "AB3" "XK_twofifths" +.tL "P" "AB4" "XK_threefifths" +.tL "P" "AB5" "XK_fourfifths" +.tL "P" "AB6" "XK_onesixth" +.tL "P" "AB7" "XK_fivesixths" +.tL "P" "AB8" "XK_careof" +.tL "P" "ABB" "XK_figdash" +.tL "P" "ABC" "XK_leftanglebracket" +.tL "P" "ABD" "XK_decimalpoint" +.tL "P" "ABE" "XK_rightanglebracket" +.tL "P" "ABF" "XK_marker" +.tL "P" "AC3" "XK_oneeighth" +.tL "P" "AC4" "XK_threeeighths" +.tL "P" "AC5" "XK_fiveeighths" +.tL "P" "AC6" "XK_seveneighths" +.tL "P" "AC9" "XK_trademark" +.tL "P" "ACA" "XK_signaturemark" +.tL "P" "ACB" "XK_trademarkincircle" +.tL "P" "ACC" "XK_leftopentriangle" +.tL "P" "ACD" "XK_rightopentriangle" +.tL "P" "ACE" "XK_emopencircle" +.tL "P" "ACF" "XK_emopenrectangle" +.tL "P" "AD0" "XK_leftsinglequotemark" +.tL "P" "AD1" "XK_rightsinglequotemark" +.tL "P" "AD2" "XK_leftdoublequotemark" +.tL "P" "AD3" "XK_rightdoublequotemark" +.tL "P" "AD4" "XK_prescription" +.tL "P" "AD6" "XK_minutes" +.tL "P" "AD7" "XK_seconds" +.tL "P" "AD9" "XK_latincross" +.tL "P" "ADA" "XK_hexagram" +.tL "P" "ADB" "XK_filledrectbullet" +.tL "P" "ADC" "XK_filledlefttribullet" +.tL "P" "ADD" "XK_filledrighttribullet" +.tL "P" "ADE" "XK_emfilledcircle" +.tL "P" "ADF" "XK_emfilledrect" +.tL "P" "AE0" "XK_enopencircbullet" +.tL "P" "AE1" "XK_enopensquarebullet" +.tL "P" "AE2" "XK_openrectbullet" +.tL "P" "AE3" "XK_opentribulletup" +.tL "P" "AE4" "XK_opentribulletdown" +.tL "P" "AE5" "XK_openstar" +.tL "P" "AE6" "XK_enfilledcircbullet" +.tL "P" "AE7" "XK_enfilledsqbullet" +.tL "P" "AE8" "XK_filledtribulletup" +.tL "P" "AE9" "XK_filledtribulletdown" +.tL "P" "AEA" "XK_leftpointer" +.tL "P" "AEB" "XK_rightpointer" +.tL "P" "AEC" "XK_club" +.tL "P" "AED" "XK_diamond" +.tL "P" "AEE" "XK_heart" +.tL "P" "AF0" "XK_maltesecross" +.tL "P" "AF1" "XK_dagger" +.tL "P" "AF2" "XK_doubledagger" +.tL "P" "AF3" "XK_checkmark" +.tL "P" "AF4" "XK_ballotcross" +.tL "P" "AF5" "XK_musicalsharp" +.tL "P" "AF6" "XK_musicalflat" +.tL "P" "AF7" "XK_malesymbol" +.tL "P" "AF8" "XK_femalesymbol" +.tL "P" "AF9" "XK_telephone" +.tL "P" "AFA" "XK_telephonerecorder" +.tL "P" "AFB" "XK_phonographcopyright" +.tL "P" "AFC" "XK_caret" +.tL "P" "AFD" "XK_singlelowquotemark" +.tL "P" "AFE" "XK_doublelowquotemark" +.tL "P" "AFF" "XK_cursor" +>>STRATEGY +Define symbol XK_PUBLISHING. +Include header file <X11/keysymdef.h> +For each KeySym in table with code P: + Verify that the symbol is defined using #ifdef. + Verify that the symbol has the expected value using #if. +>>CODE + + kysymdf12(); + +>>ASSERTION Good A +When the header file <X11/keysymdef.h> is included while the feature test macro +.S XK_SPECIAL +is defined, +then the symbols in the table which have code S +are defined to have the hexadecimal values given in the table. +.tL "Code" "Value" "Name" +.tL "S" "9DF" "XK_blank" +.tL "S" "9E0" "XK_soliddiamond" +.tL "S" "9E1" "XK_checkerboard" +.tL "S" "9E2" "XK_ht" +.tL "S" "9E3" "XK_ff" +.tL "S" "9E4" "XK_cr" +.tL "S" "9E5" "XK_lf" +.tL "S" "9E8" "XK_nl" +.tL "S" "9E9" "XK_vt" +.tL "S" "9EA" "XK_lowrightcorner" +.tL "S" "9EB" "XK_uprightcorner" +.tL "S" "9EC" "XK_upleftcorner" +.tL "S" "9ED" "XK_lowleftcorner" +.tL "S" "9EE" "XK_crossinglines" +.tL "S" "9EF" "XK_horizlinescan1" +.tL "S" "9F0" "XK_horizlinescan3" +.tL "S" "9F1" "XK_horizlinescan5" +.tL "S" "9F2" "XK_horizlinescan7" +.tL "S" "9F3" "XK_horizlinescan9" +.tL "S" "9F4" "XK_leftt" +.tL "S" "9F5" "XK_rightt" +.tL "S" "9F6" "XK_bott" +.tL "S" "9F7" "XK_topt" +.tL "S" "9F8" "XK_vertbar" +>>STRATEGY +Define symbol XK_SPECIAL. +Include header file <X11/keysymdef.h> +For each KeySym in table with code S: + Verify that the symbol is defined using #ifdef. + Verify that the symbol has the expected value using #if. +>>CODE + + kysymdf13(); + +>>ASSERTION Good A +When the header file <X11/keysymdef.h> is included while the feature test macro +.S XK_TECHNICAL +is defined, +then the symbols in the table which have code T +are defined to have the hexadecimal values given in the table. +.tL "Code" "Value" "Name" +.tL "T" "8A1" "XK_leftradical" +.tL "T" "8A2" "XK_topleftradical" +.tL "T" "8A3" "XK_horizconnector" +.tL "T" "8A4" "XK_topintegral" +.tL "T" "8A5" "XK_botintegral" +.tL "T" "8A6" "XK_vertconnector" +.tL "T" "8A7" "XK_topleftsqbracket" +.tL "T" "8A8" "XK_botleftsqbracket" +.tL "T" "8A9" "XK_toprightsqbracket" +.tL "T" "8AA" "XK_botrightsqbracket" +.tL "T" "8AB" "XK_topleftparens" +.tL "T" "8AC" "XK_botleftparens" +.tL "T" "8AD" "XK_toprightparens" +.tL "T" "8AE" "XK_botrightparens" +.tL "T" "8AF" "XK_leftmiddlecurlybrace" +.tL "T" "8B0" "XK_rightmiddlecurlybrace" +.tL "T" "8B1" "XK_topleftsummation" +.tL "T" "8B2" "XK_botleftsummation" +.tL "T" "8B3" "XK_topvertsummationconnector" +.tL "T" "8B4" "XK_botvertsummationconnector" +.tL "T" "8B5" "XK_toprightsummation" +.tL "T" "8B6" "XK_botrightsummation" +.tL "T" "8B7" "XK_rightmiddlesummation" +.tL "T" "8BC" "XK_lessthanequal" +.tL "T" "8BD" "XK_notequal" +.tL "T" "8BE" "XK_greaterthanequal" +.tL "T" "8BF" "XK_integral" +.tL "T" "8C0" "XK_therefore" +.tL "T" "8C1" "XK_variation" +.tL "T" "8C2" "XK_infinity" +.tL "T" "8C5" "XK_nabla" +.tL "T" "8C8" "XK_approximate" +.tL "T" "8C9" "XK_similarequal" +.tL "T" "8CD" "XK_ifonlyif" +.tL "T" "8CE" "XK_implies" +.tL "T" "8CF" "XK_identical" +.tL "T" "8D6" "XK_radical" +.tL "T" "8DA" "XK_includedin" +.tL "T" "8DB" "XK_includes" +.tL "T" "8DC" "XK_intersection" +.tL "T" "8DD" "XK_union" +.tL "T" "8DE" "XK_logicaland" +.tL "T" "8DF" "XK_logicalor" +.tL "T" "8EF" "XK_partialderivative" +.tL "T" "8F6" "XK_function" +.tL "T" "8FB" "XK_leftarrow" +.tL "T" "8FC" "XK_uparrow" +.tL "T" "8FD" "XK_rightarrow" +.tL "T" "8FE" "XK_downarrow" +>>STRATEGY +Define symbol XK_TECHNICAL. +Include header file <X11/keysymdef.h> +For each KeySym in table with code T: + Verify that the symbol is defined using #ifdef. + Verify that the symbol has the expected value using #if. +>>CODE + + kysymdf14(); + +>>ASSERTION Good A +When the header file <X11/keysymdef.h> is included, +then the symbols in the table +are defined to have the hexadecimal values given in the table. +.tL "Value" "Name" +.tL "FFFFFF" "XK_VoidSymbol" +>>STRATEGY +Include header file <X11/keysymdef.h> +For each KeySym in table: + Verify that the symbol is defined using #ifdef. + Verify that the symbol has the expected value using #if. +>>CODE + + kysymdf0(); |