diff options
author | Kaleb Keithley <kaleb@freedesktop.org> | 2003-11-25 19:29:15 +0000 |
---|---|---|
committer | Kaleb Keithley <kaleb@freedesktop.org> | 2003-11-25 19:29:15 +0000 |
commit | ef18ebade29f85a228da73a3ad13fe800cb7b62b (patch) | |
tree | 41123e3c0eefe5958e873eb5d11314dea956cc5e | |
parent | 491b5e903ad3091687ae39159aba3e434476f8d4 (diff) |
XFree86 4.3.99.16 Bring the tree up to date for the Cygwin folksxf86-4_3_99_903_specialxf86-4_3_99_902xf86-4_3_99_901xf86-4_3_99_16xf86-012804-2330
-rw-r--r-- | dsimple.c | 4 | ||||
-rw-r--r-- | dsimple.h | 24 | ||||
-rw-r--r-- | xlsfonts.c | 24 |
3 files changed, 17 insertions, 35 deletions
@@ -26,7 +26,7 @@ other dealings in this Software without prior written authorization from The Open Group. */ -/* $XFree86: xc/programs/xlsfonts/dsimple.c,v 3.6 2001/12/14 20:02:09 dawes Exp $ */ +/* $XFree86: xc/programs/xlsfonts/dsimple.c,v 3.7 2003/09/24 02:43:38 dawes Exp $ */ #include <X11/Xos.h> #include <X11/Xlib.h> @@ -306,7 +306,7 @@ Window Select_Window_Args(rargc, argv) w=0; sscanf(OPTION, "0x%lx", &w); if (!w) - sscanf(OPTION, "%ld", &w); + sscanf(OPTION, "%lu", &w); if (!w) Fatal_Error("Invalid window id format: %s.", OPTION); continue; @@ -26,7 +26,7 @@ other dealings in this Software without prior written authorization from The Open Group. */ -/* $XFree86: xc/programs/xlsfonts/dsimple.h,v 1.8 2002/12/24 17:43:01 tsi Exp $ */ +/* $XFree86: xc/programs/xlsfonts/dsimple.h,v 1.9 2003/11/17 22:20:54 dawes Exp $ */ /* * Just_display.h: This file contains the definitions needed to use the @@ -50,7 +50,6 @@ extern int screen; /* The current screen */ /* Declaritions for functions in just_display.c */ -#if NeedFunctionPrototypes char *Malloc(unsigned); char *Realloc(char *, int); char *Get_Display_Name(int *, char **); @@ -62,19 +61,6 @@ Pixmap ReadBitmapFile(Drawable, char *, int *, int *, int *, int *); void WriteBitmapFile(char *, Pixmap, int, int, int, int); Window Select_Window_Args(int *, char **); void usage(void); -#else -char *Malloc(); -char *Realloc(); -char *Get_Display_Name(); -Display *Open_Display(); -void Setup_Display_And_Screen(); -XFontStruct *Open_Font(); -void Beep(); -Pixmap ReadBitmapFile(); -void WriteBitmapFile(); -Window Select_Window_Args(); -void usage(); -#endif #define X_USAGE "[host:display]" /* X arguments handled by Get_Display_Name */ @@ -87,19 +73,11 @@ void usage(); * Send bugs, etc. to chariot@athena.mit.edu. */ -#if NeedFunctionPrototypes unsigned long Resolve_Color(Window, char *); Pixmap Bitmap_To_Pixmap(Display *, Drawable, GC, Pixmap, int, int); Window Select_Window(Display *); void blip(void); Window Window_With_Name(Display *, Window, char *); -#else -unsigned long Resolve_Color(); -Pixmap Bitmap_To_Pixmap(); -Window Select_Window(); -void blip(); -Window Window_With_Name(); -#endif #ifdef __GNUC__ void Fatal_Error(char *, ...) __attribute__((__noreturn__)); #else @@ -24,7 +24,7 @@ Except as contained in this notice, the name of The Open Group shall not be used in advertising or otherwise to promote the sale, use or other dealings in this Software without prior written authorization from The Open Group. * */ -/* $XFree86: xc/programs/xlsfonts/xlsfonts.c,v 1.8 2001/12/14 20:02:10 dawes Exp $ */ +/* $XFree86: xc/programs/xlsfonts/xlsfonts.c,v 1.10 2003/09/13 21:33:11 dawes Exp $ */ #include <X11/Xlib.h> #include <X11/Xutil.h> @@ -57,13 +57,10 @@ typedef struct { FontList *font_list; -#if NeedFunctionPrototypes -extern void usage(void); -extern int main(int, char **); -extern void get_list(char *); -extern void show_fonts(void); -extern void copy_number(char **, char **, int, int); -extern void do_query_font(Display *, char *); +static void get_list(char *); +static void show_fonts(void); +static void copy_number(char **, char **, int, int); +static void do_query_font(Display *, char *); static int compare(const void *, const void *); #ifndef max static int max(int, int); @@ -72,7 +69,6 @@ static int IgnoreError(Display *, XErrorEvent *); static void PrintProperty(XFontProp *); static void ComputeFontType(XFontStruct *); static void print_character_metrics(register XFontStruct *); -#endif void @@ -477,6 +473,9 @@ static char* stringValued [] = { /* values are atoms */ "RASTERIZER_NAME", "RASTERIZER_VERSION", + /* other registered font properties (see the X.org Registry, sec. 15) */ + "_ADOBE_POSTSCRIPT_FONTNAME", + /* unregistered font properties */ "CHARSET_COLLECTIONS", "CLASSIFICATION", @@ -504,7 +503,12 @@ static void PrintProperty (prop) (void)sprintf (atom, "No such atom = %ld", prop->name); } printf (" %s", atom); - for (i = strlen(atom); i < 22; i++) printf (" "); + + /* Pad out to a column width of 22, but ensure there is always at + least one space between property name & value. */ + for (i = strlen(atom); i < 21; i++) putchar (' '); + putchar(' '); + for (i = 0; ; i++) { if (stringValued[i] == NULL) { printf ("%ld\n", prop->card32); |