diff options
author | Alan Coopersmith <alan.coopersmith@oracle.com> | 2015-12-04 22:20:53 -0800 |
---|---|---|
committer | Ulrich Sibiller <uli42@gmx.de> | 2016-10-19 21:40:29 +0200 |
commit | b912a4042d884ccc2f226ab80ddc7272967d58b2 (patch) | |
tree | c33f6d45d3cadc1b332647a388910102b66db7c2 /nx-X11/lib/X11 | |
parent | 9dec6c18bc5289d86a1a25c71c86e82e8ad37332 (diff) | |
download | nx-libs-b912a4042d884ccc2f226ab80ddc7272967d58b2.tar.gz nx-libs-b912a4042d884ccc2f226ab80ddc7272967d58b2.tar.bz2 nx-libs-b912a4042d884ccc2f226ab80ddc7272967d58b2.zip |
Delete #if 0 hunks of code
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
Backported-to-NX-by: Ulrich Sibiller <uli42@gmx.de>
Diffstat (limited to 'nx-X11/lib/X11')
-rw-r--r-- | nx-X11/lib/X11/XDefaultOMIF.c | 83 | ||||
-rw-r--r-- | nx-X11/lib/X11/cmsTrig.c | 11 | ||||
-rw-r--r-- | nx-X11/lib/X11/omGeneric.c | 54 | ||||
-rw-r--r-- | nx-X11/lib/X11/omImText.c | 4 |
4 files changed, 0 insertions, 152 deletions
diff --git a/nx-X11/lib/X11/XDefaultOMIF.c b/nx-X11/lib/X11/XDefaultOMIF.c index 6af1c8015..f9469feca 100644 --- a/nx-X11/lib/X11/XDefaultOMIF.c +++ b/nx-X11/lib/X11/XDefaultOMIF.c @@ -182,61 +182,6 @@ check_charset( return (FontData) NULL; } -#if 0 /* Unused */ -static int -check_fontname( - XOC oc, - char *name) -{ - Display *dpy = oc->core.om->core.display; - XOCGenericPart *gen = XOC_GENERIC(oc); - FontData data; - FontSet font_set; - XFontStruct *fs_list; - char **fn_list, *fname, *prop_fname = NULL; - int list_num, i; - int list2_num; - char **fn2_list = NULL; - int found_num = 0; - - fn_list = XListFonts(dpy, name, MAXFONTS, &list_num); - if (fn_list == NULL) - return found_num; - - for (i = 0; i < list_num; i++) { - fname = fn_list[i]; - - font_set = gen->font_set; - - if ((data = check_charset(font_set, fname)) == NULL) { - if ((fn2_list = XListFontsWithInfo(dpy, name, MAXFONTS, - &list2_num, &fs_list)) - && (prop_fname = get_prop_name(dpy, fs_list)) - && (data = check_charset(font_set, prop_fname))) - fname = prop_fname; - } - if (data) { - font_set->font_name = strdup(fname); - if (font_set->font_name) { - found_num++; - } - } - if (fn2_list) { - XFreeFontInfo(fn2_list, fs_list, list2_num); - fn2_list = NULL; - if (prop_fname) { - Xfree(prop_fname); - prop_fname = NULL; - } - } - if (found_num == 1) - break; - } - XFreeFontNames(fn_list); - return found_num; -} -#endif - static Bool load_font( XOC oc) @@ -256,34 +201,6 @@ load_font( return True; } -#if 0 -static Bool -load_font_info( - XOC oc) -{ - Display *dpy = oc->core.om->core.display; - XOCGenericPart *gen = XOC_GENERIC(oc); - FontSet font_set = gen->font_set; - char **fn_list; - int fn_num; - - if (font_set->font_name == NULL) - return False; - - if (font_set->info == NULL) { - fn_list = XListFontsWithInfo(dpy, font_set->font_name, 1, &fn_num, - &font_set->info); - if (font_set->info == NULL) - return False; - if (fn_num > 0) - font_set->info->fid = XLoadFont(dpy, font_set->font_name); - - if (fn_list) XFreeFontNames(fn_list); - } - return True; -} -#endif - static void set_fontset_extents( XOC oc) diff --git a/nx-X11/lib/X11/cmsTrig.c b/nx-X11/lib/X11/cmsTrig.c index a917b78db..b23033aa8 100644 --- a/nx-X11/lib/X11/cmsTrig.c +++ b/nx-X11/lib/X11/cmsTrig.c @@ -375,21 +375,10 @@ static double _XcmsPolynomial( { auto double rtn_value; -#if 0 - auto double curr_coeff; - if (order <= 0) { - rtn_value = *coeffs; - } else { - curr_coeff = *coeffs; /* Bug in Unisoft's compiler. Does not */ - coeffs++; /* generate good code for *coeffs++ */ - rtn_value = curr_coeff + x * _XcmsPolynomial (--order, coeffs, x); - } -#else /* ++jrb -- removed tail recursion */ coeffs += order; rtn_value = *coeffs--; while(order-- > 0) rtn_value = *coeffs-- + (x * rtn_value); -#endif return(rtn_value); } diff --git a/nx-X11/lib/X11/omGeneric.c b/nx-X11/lib/X11/omGeneric.c index 31575d85d..68eec01c0 100644 --- a/nx-X11/lib/X11/omGeneric.c +++ b/nx-X11/lib/X11/omGeneric.c @@ -65,32 +65,6 @@ #define CHARSET_ENCODING_FIELD 14 #define XLFD_MAX_LEN 255 -#if 0 -extern int _XmbDefaultTextEscapement(), _XwcDefaultTextEscapement(), - _Xutf8DefaultTextEscapement(); -extern int _XmbDefaultTextExtents(), _XwcDefaultTextExtents(), - _Xutf8DefaultTextExtents(); -extern Status _XmbDefaultTextPerCharExtents(), _XwcDefaultTextPerCharExtents(), - _Xutf8DefaultTextPerCharExtents(); -extern int _XmbDefaultDrawString(), _XwcDefaultDrawString(), - _Xutf8DefaultDrawString(); -extern void _XmbDefaultDrawImageString(), _XwcDefaultDrawImageString(), - _Xutf8DefaultDrawImageString(); - -extern int _XmbGenericTextEscapement(), _XwcGenericTextEscapement(), - _Xutf8GenericTextEscapement(); -extern int _XmbGenericTextExtents(), _XwcGenericTextExtents(), - _Xutf8GenericTextExtents(); -extern Status _XmbGenericTextPerCharExtents(), _XwcGenericTextPerCharExtents(), - _Xutf8GenericTextPerCharExtents(); -extern int _XmbGenericDrawString(), _XwcGenericDrawString(), - _Xutf8GenericDrawString(); -extern void _XmbGenericDrawImageString(), _XwcGenericDrawImageString(), - _Xutf8GenericDrawImageString(); - -extern void _XlcDbg_printValue (const char *str, char **value, int num); -#endif - /* For VW/UDC start */ static FontData @@ -635,34 +609,6 @@ is_match_charset( return False; } -#if 0 -static char * -get_font_name_from_list( - XOC oc, - char *pattern, - FontData font_data) -{ - char **list, *name = (char *)NULL, *fname; - int count = 0, i; - - list = XListFonts(oc->core.om->core.display, pattern, MAXFONTS, &count); - if (list == NULL) - return NULL; - - for (i = 0; i < count; i++) { - fname = list[i]; - if(is_match_charset(font_data, fname) == True) { - name = strdup(fname); - break; - } - } - - XFreeFontNames(list); - - return name; -} -#endif - static int parse_all_name( XOC oc, diff --git a/nx-X11/lib/X11/omImText.c b/nx-X11/lib/X11/omImText.c index 1bc08bc25..9cfb5497d 100644 --- a/nx-X11/lib/X11/omImText.c +++ b/nx-X11/lib/X11/omImText.c @@ -29,10 +29,6 @@ #include "Xlibint.h" #include "XomGeneric.h" -#if 0 -extern int _XomGenericTextExtents(), _XomGenericDrawString(); -#endif - #define GET_VALUE_MASK (GCFunction | GCForeground | GCBackground | GCFillStyle) #define SET_VALUE_MASK (GCFunction | GCForeground | GCFillStyle) |