Mercurial > hg > xemacs-beta
changeset 5046:d4f666cda5e6
some random fixups
-------------------- ChangeLog entries follow: --------------------
man/ChangeLog addition:
2010-02-20 Ben Wing <ben@xemacs.org>
* internals/internals.texi (Intro to Window and Frame Geometry):
Shrink diagram to fit when offset by five spaces as a result of
quoting.
src/ChangeLog addition:
2010-02-20 Ben Wing <ben@xemacs.org>
* syswindows.h:
Add table about GNU Emacs -> XEmacs Windows constants from
the internals manual.
* frame.c:
Shrink size of diagram consistent with internals manual.
* alloc.c:
* compiler.h:
* console.c:
* events.c:
* gc.c (gc_stat_start_new_gc):
* gc.c (gc_stat_resume_gc):
* gc.c (kkcc_marking):
* gc.c (gc_1):
* gc.c (gc):
* objects-tty.c:
* redisplay-msw.c:
* redisplay-msw.c (mswindows_clear_region):
* syntax.c:
* syntax.c (ST_COMMENT_STYLE):
* sysdep.c:
Fix various compiler warnings.
author | Ben Wing <ben@xemacs.org> |
---|---|
date | Sat, 20 Feb 2010 03:24:08 -0600 |
parents | c3cc3fa503a2 |
children | 07dcc7000bbf |
files | man/ChangeLog man/internals/internals.texi src/ChangeLog src/alloc.c src/compiler.h src/console.c src/events.c src/frame.c src/gc.c src/objects-tty.c src/redisplay-msw.c src/syntax.c src/sysdep.c src/syswindows.h |
diffstat | 14 files changed, 205 insertions(+), 172 deletions(-) [+] |
line wrap: on
line diff
--- a/man/ChangeLog Tue Feb 16 01:21:32 2010 -0600 +++ b/man/ChangeLog Sat Feb 20 03:24:08 2010 -0600 @@ -1,3 +1,9 @@ +2010-02-20 Ben Wing <ben@xemacs.org> + + * internals/internals.texi (Intro to Window and Frame Geometry): + Shrink diagram to fit when offset by five spaces as a result of + quoting. + 2010-02-16 Ben Wing <ben@xemacs.org> * internals/internals.texi (Top):
--- a/man/internals/internals.texi Tue Feb 16 01:21:32 2010 -0600 +++ b/man/internals/internals.texi Sat Feb 20 03:24:08 2010 -0600 @@ -17883,55 +17883,55 @@ Here is an ASCII diagram: @example -+-----------------------------------------------------------------------------| -| window-manager decoration | -| +-------------------------------------------------------------------------+ | -| | menubar | | -| ########################################################################### | -| # toolbar # | -| #-------------------------------------------------------------------------# | -| # | gutter | # | -| # |-------------------------------------------------------------------| # | -| # | | internal border width | | # | -| # | |-*************************************************************-| | # | -|w# | | * |s|v* |s* | | #w| -|i# | | * |c|e* |c* | | #i| -|n# | | * |r|r* |r* | | #n| -|d# | | * |o|t* |o* | | #d| -|o# | | * text area |l|.* text area |l* | | #o| -|w# | |i* |l| * |l*i| | #w| -|-# | |n* |b|d* |b*n| | #-| -|m# | |t* |a|i* |a*t| | #m| -|a# | |.* |r|v* |r*.| | #a| -|n# t| | *--------------------------+-|i*--------------------------+-* | |t #n| -|a# o|g|b* scrollbar | |d* scrollbar | *b|g|o #a| -|g# o|u|o*--------------------------+-|e*--------------------------+-*o|u|o #g| -|e# l|t|r* modeline |r* modeline *r|t|l #e| -|r# b|t|d*************************************************************d|t|b #r| -| # a|e|e* =...texttexttex....= |s|v* |s*e|e|a # | -|d# r|r|r*o m=...texttexttextt..=o m|c|e* |c*r|r|r #d| -|e# | | *u a=.texttexttextte...=u a|r|r* |r* | | #e| -|c# | |w*t r=.....texttexttex..=t r|o|t* |o*w| | #c| -|o# | |i*s g= etc. =s g|l|.* text area |l*i| | #o| -|r# | |d*i i= =i i|l| * |l*d| | #r| -|a# | |t*d n= =d n|b|d* |b*t| | #a| -|t# | |h*e = inner text area =e |a|i* |a*h| | #t| -|i# | | * = = |r|v* |r* | | #i| -|o# | | *---====================---+-|i*--------------------------+-* | | #o| -|n# | | * scrollbar | |d* scrollbar | * | | #n| -| # | | *--------------------------+-|e*--------------------------+-* | | # | -| # | | * modeline |r* modeline * | | # | -| # | | ************************************************************* | | # | -| # | | * minibuffer * | | # | -| # | | ************************************************************* | | # | -| # | | internal border width | | # | -| # |-------------------------------------------------------------------| # | -| # | gutter | # | -| #-------------------------------------------------------------------------# | -| # toolbar # | -| ########################################################################### | -| window manager decoration | -+-----------------------------------------------------------------------------+ ++------------------------------------------------------------------------| +| window-manager decoration | +| +--------------------------------------------------------------------+ | +| | menubar | | +| ###################################################################### | +| # toolbar # | +| #--------------------------------------------------------------------# | +| # | gutter | # | +| # |--------------------------------------------------------------| # | +| # | | internal border width | | # | +| # | | ******************************************************** | | # | +|w# | | * |s|v* |s* | | #w| +|i# | | * |c|e* |c* | | #i| +|n# | | * |r|r* |r* | | #n| +|d# | | * |o|t* |o* | | #d| +|o# | | * text area |l|.* text area |l* | | #o| +|w# | |i* |l| * |l*i| | #w| +|-# | |n* |b|d* |b*n| | #-| +|m# | |t* |a|i* |a*t| | #m| +|a# | |.* |r|v* |r*.| | #a| +|n# t| | *-------------------------+-|i*----------------------+-* | |t #n| +|a# o|g|b* scrollbar | |d* scrollbar | *b|g|o #a| +|g# o|u|o*-------------------------+-|e*----------------------+-*o|u|o #g| +|e# l|t|r* modeline |r* modeline *r|t|l #e| +|r# b|t|d********************************************************d|t|b #r| +| # a|e|e* =..texttexttex....= |s|v* |s*e|e|a # | +|d# r|r|r*o m=..texttexttextt..=o m|c|e* |c*r|r|r #d| +|e# | | *u a=.exttexttextte...=u a|r|r* |r* | | #e| +|c# | |w*t r=....texttexttex..=t r|o|t* |o*w| | #c| +|o# | |i*s g= etc. =s g|l|.* text area |l*i| | #o| +|r# | |d*i i= =i i|l| * |l*d| | #r| +|a# | |t*d n= =d n|b|d* |b*t| | #a| +|t# | |h*e = inner text area =e |a|i* |a*h| | #t| +|i# | | * = = |r|v* |r* | | #i| +|o# | | *---===================---+-|i*----------------------+-* | | #o| +|n# | | * scrollbar | |d* scrollbar | * | | #n| +| # | | *-------------------------+-|e*----------------------+-* | | # | +| # | | * modeline |r* modeline * | | # | +| # | | ******************************************************** | | # | +| # | | * minibuffer * | | # | +| # | | ******************************************************** | | # | +| # | | internal border width | | # | +| # |--------------------------------------------------------------| # | +| # | gutter | # | +| #--------------------------------------------------------------------# | +| # toolbar # | +| ###################################################################### | +| window manager decoration | ++------------------------------------------------------------------------+ # = boundary of client area; * = window boundaries, boundary of paned area = = boundary of inner text area; . = inside margin area
--- a/src/ChangeLog Tue Feb 16 01:21:32 2010 -0600 +++ b/src/ChangeLog Sat Feb 20 03:24:08 2010 -0600 @@ -1,3 +1,29 @@ +2010-02-20 Ben Wing <ben@xemacs.org> + + * syswindows.h: + Add table about GNU Emacs -> XEmacs Windows constants from + the internals manual. + + * frame.c: + Shrink size of diagram consistent with internals manual. + + * alloc.c: + * compiler.h: + * console.c: + * events.c: + * gc.c (gc_stat_start_new_gc): + * gc.c (gc_stat_resume_gc): + * gc.c (kkcc_marking): + * gc.c (gc_1): + * gc.c (gc): + * objects-tty.c: + * redisplay-msw.c: + * redisplay-msw.c (mswindows_clear_region): + * syntax.c: + * syntax.c (ST_COMMENT_STYLE): + * sysdep.c: + Fix various compiler warnings. + 2010-02-16 Ben Wing <ben@xemacs.org> * frame-impl.h:
--- a/src/alloc.c Tue Feb 16 01:21:32 2010 -0600 +++ b/src/alloc.c Sat Feb 20 03:24:08 2010 -0600 @@ -3438,6 +3438,8 @@ Dynarr_add (mcpro_names, varname); } +const Ascbyte *mcpro_name (int count); + /* External debugging function: Return the name of the variable at offset COUNT. */ const Ascbyte *
--- a/src/compiler.h Tue Feb 16 01:21:32 2010 -0600 +++ b/src/compiler.h Sat Feb 20 03:24:08 2010 -0600 @@ -1,7 +1,7 @@ /* Compiler-specific definitions for XEmacs. Copyright (C) 1998-1999, 2003 Free Software Foundation, Inc. Copyright (C) 1994 Richard Mlynarik. - Copyright (C) 1995, 1996, 2000-2004 Ben Wing. + Copyright (C) 1995, 1996, 2000-2004, 2010 Ben Wing. This file is part of XEmacs. @@ -233,23 +233,44 @@ # define ATTRIBUTE_UNUSED # endif # define UNUSED(decl) UNUSED_ARG (decl) ATTRIBUTE_UNUSED -# ifdef MULE -# define USED_IF_MULE(decl) decl -# else -# define USED_IF_MULE(decl) UNUSED (decl) -# endif -# ifdef HAVE_XFT -# define USED_IF_XFT(decl) decl -# else -# define USED_IF_XFT(decl) UNUSED (decl) -# endif -# ifdef HAVE_SCROLLBARS -# define USED_IF_SCROLLBARS(decl) decl -# else -# define USED_IF_SCROLLBARS(decl) UNUSED (decl) -# endif #endif /* UNUSED */ +/* Various macros for params/variables used or unused depending on + config flags. */ + +#ifdef MULE +# define USED_IF_MULE(decl) decl +#else +# define USED_IF_MULE(decl) UNUSED (decl) +#endif +#ifdef HAVE_XFT +# define USED_IF_XFT(decl) decl +#else +# define USED_IF_XFT(decl) UNUSED (decl) +#endif +#ifdef HAVE_SCROLLBARS +# define USED_IF_SCROLLBARS(decl) decl +#else +# define USED_IF_SCROLLBARS(decl) UNUSED (decl) +#endif +#ifdef NEW_GC +# define USED_IF_NEW_GC(decl) decl +# define UNUSED_IF_NEW_GC(decl) UNUSED (decl) +#else +# define USED_IF_NEW_GC(decl) UNUSED (decl) +# define UNUSED_IF_NEW_GC(decl) decl +#endif +#ifdef HAVE_TTY +#define USED_IF_TTY(decl) decl +#else +#define USED_IF_TTY(decl) UNUSED (decl) +#endif +#ifdef HAVE_TOOLBARS +#define USED_IF_TOOLBARS(decl) decl +#else +#define USED_IF_TOOLBARS(decl) UNUSED (decl) +#endif + /* Declaration that variable or expression X is "used" to defeat "unused variable" warnings. DON'T DO THIS FOR PARAMETERS IF IT ALL POSSIBLE. Use an UNUSED() or USED_IF_*() declaration on the parameter
--- a/src/console.c Tue Feb 16 01:21:32 2010 -0600 +++ b/src/console.c Sat Feb 20 03:24:08 2010 -0600 @@ -1,6 +1,6 @@ /* The console object. Copyright (C) 1992, 1993, 1994 Free Software Foundation, Inc. - Copyright (C) 1996, 2002 Ben Wing. + Copyright (C) 1996, 2002, 2010 Ben Wing. This file is part of XEmacs. @@ -43,12 +43,6 @@ #include "console-tty-impl.h" #endif -#ifdef HAVE_TTY -#define USED_IF_TTY(decl) decl -#else -#define USED_IF_TTY(decl) UNUSED (decl) -#endif - Lisp_Object Vconsole_list, Vselected_console; Lisp_Object Vcreate_console_hook, Vdelete_console_hook;
--- a/src/events.c Tue Feb 16 01:21:32 2010 -0600 +++ b/src/events.c Sat Feb 20 03:24:08 2010 -0600 @@ -1,7 +1,7 @@ /* Events: printing them, converting them to and from characters. Copyright (C) 1991, 1992, 1993, 1994 Free Software Foundation, Inc. Copyright (C) 1994, 1995 Board of Trustees, University of Illinois. - Copyright (C) 2001, 2002, 2005 Ben Wing. + Copyright (C) 2001, 2002, 2005, 2010 Ben Wing. This file is part of XEmacs. @@ -41,18 +41,6 @@ #include "console-tty-impl.h" /* for stuff in character_to_event */ -#ifdef HAVE_TTY -#define USED_IF_TTY(decl) decl -#else -#define USED_IF_TTY(decl) UNUSED (decl) -#endif - -#ifdef HAVE_TOOLBARS -#define USED_IF_TOOLBARS(decl) decl -#else -#define USED_IF_TOOLBARS(decl) UNUSED (decl) -#endif - /* Where old events go when they are explicitly deallocated. The event chain here is cut loose before GC, so these will be freed eventually.
--- a/src/frame.c Tue Feb 16 01:21:32 2010 -0600 +++ b/src/frame.c Sat Feb 20 03:24:08 2010 -0600 @@ -28,55 +28,55 @@ Here is an ASCII diagram: -+-----------------------------------------------------------------------------| -| window-manager decoration | -| +-------------------------------------------------------------------------+ | -| | menubar | | -| ########################################################################### | -| # toolbar # | -| #-------------------------------------------------------------------------# | -| # | gutter | # | -| # |-------------------------------------------------------------------| # | -| # | | internal border width | | # | -| # | |-*************************************************************-| | # | -|w# | | * |s|v* |s* | | #w| -|i# | | * |c|e* |c* | | #i| -|n# | | * |r|r* |r* | | #n| -|d# | | * |o|t* |o* | | #d| -|o# | | * text area |l|.* text area |l* | | #o| -|w# | |i* |l| * |l*i| | #w| -|-# | |n* |b|d* |b*n| | #-| -|m# | |t* |a|i* |a*t| | #m| -|a# | |.* |r|v* |r*.| | #a| -|n# t| | *--------------------------+-|i*--------------------------+-* | |t #n| -|a# o|g|b* scrollbar | |d* scrollbar | *b|g|o #a| -|g# o|u|o*--------------------------+-|e*--------------------------+-*o|u|o #g| -|e# l|t|r* modeline |r* modeline *r|t|l #e| -|r# b|t|d*************************************************************d|t|b #r| -| # a|e|e* =...texttexttex....= |s|v* |s*e|e|a # | -|d# r|r|r*o m=...texttexttextt..=o m|c|e* |c*r|r|r #d| -|e# | | *u a=.texttexttextte...=u a|r|r* |r* | | #e| -|c# | |w*t r=.....texttexttex..=t r|o|t* |o*w| | #c| -|o# | |i*s g= etc. =s g|l|.* text area |l*i| | #o| -|r# | |d*i i= =i i|l| * |l*d| | #r| -|a# | |t*d n= =d n|b|d* |b*t| | #a| -|t# | |h*e = inner text area =e |a|i* |a*h| | #t| -|i# | | * = = |r|v* |r* | | #i| -|o# | | *---====================---+-|i*--------------------------+-* | | #o| -|n# | | * scrollbar | |d* scrollbar | * | | #n| -| # | | *--------------------------+-|e*--------------------------+-* | | # | -| # | | * modeline |r* modeline * | | # | -| # | | ************************************************************* | | # | -| # | | * minibuffer * | | # | -| # | | ************************************************************* | | # | -| # | | internal border width | | # | -| # |-------------------------------------------------------------------| # | -| # | gutter | # | -| #-------------------------------------------------------------------------# | -| # toolbar # | -| ########################################################################### | -| window manager decoration | -+-----------------------------------------------------------------------------+ ++------------------------------------------------------------------------| +| window-manager decoration | +| +--------------------------------------------------------------------+ | +| | menubar | | +| ###################################################################### | +| # toolbar # | +| #--------------------------------------------------------------------# | +| # | gutter | # | +| # |--------------------------------------------------------------| # | +| # | | internal border width | | # | +| # | | ******************************************************** | | # | +|w# | | * |s|v* |s* | | #w| +|i# | | * |c|e* |c* | | #i| +|n# | | * |r|r* |r* | | #n| +|d# | | * |o|t* |o* | | #d| +|o# | | * text area |l|.* text area |l* | | #o| +|w# | |i* |l| * |l*i| | #w| +|-# | |n* |b|d* |b*n| | #-| +|m# | |t* |a|i* |a*t| | #m| +|a# | |.* |r|v* |r*.| | #a| +|n# t| | *-------------------------+-|i*----------------------+-* | |t #n| +|a# o|g|b* scrollbar | |d* scrollbar | *b|g|o #a| +|g# o|u|o*-------------------------+-|e*----------------------+-*o|u|o #g| +|e# l|t|r* modeline |r* modeline *r|t|l #e| +|r# b|t|d********************************************************d|t|b #r| +| # a|e|e* =..texttexttex....= |s|v* |s*e|e|a # | +|d# r|r|r*o m=..texttexttextt..=o m|c|e* |c*r|r|r #d| +|e# | | *u a=.exttexttextte...=u a|r|r* |r* | | #e| +|c# | |w*t r=....texttexttex..=t r|o|t* |o*w| | #c| +|o# | |i*s g= etc. =s g|l|.* text area |l*i| | #o| +|r# | |d*i i= =i i|l| * |l*d| | #r| +|a# | |t*d n= =d n|b|d* |b*t| | #a| +|t# | |h*e = inner text area =e |a|i* |a*h| | #t| +|i# | | * = = |r|v* |r* | | #i| +|o# | | *---===================---+-|i*----------------------+-* | | #o| +|n# | | * scrollbar | |d* scrollbar | * | | #n| +| # | | *-------------------------+-|e*----------------------+-* | | # | +| # | | * modeline |r* modeline * | | # | +| # | | ******************************************************** | | # | +| # | | * minibuffer * | | # | +| # | | ******************************************************** | | # | +| # | | internal border width | | # | +| # |--------------------------------------------------------------| # | +| # | gutter | # | +| #--------------------------------------------------------------------# | +| # toolbar # | +| ###################################################################### | +| window manager decoration | ++------------------------------------------------------------------------+ # = boundary of client area; * = window boundaries, boundary of paned area = = boundary of inner text area; . = inside margin area
--- a/src/gc.c Tue Feb 16 01:21:32 2010 -0600 +++ b/src/gc.c Sat Feb 20 03:24:08 2010 -0600 @@ -184,7 +184,7 @@ gc_state.stat[GC_STAT_IN_THIS_GC] = 0; \ GC_STAT_RESUME (stat) -void +static void gc_stat_start_new_gc (void) { gc_state.n_gc[GC_STAT_TOTAL]++; @@ -201,7 +201,7 @@ GC_STAT_RESTART (freed); } -void +static void gc_stat_resume_gc (void) { gc_state.n_cycles[GC_STAT_TOTAL]++; @@ -1022,20 +1022,14 @@ on the kkcc_gc_stack. This function processes all elements on the stack according to their descriptions. */ static void -kkcc_marking ( -#ifdef NEW_GC - int cnt -#else /* not NEW_GC */ - int UNUSED(cnt) -#endif /* not NEW_GC */ - ) +kkcc_marking (USED_IF_NEW_GC (cnt)) { kkcc_gc_stack_entry *stack_entry = 0; void *data = 0; const struct memory_description *desc = 0; int pos; #ifdef NEW_GC - int count = cnt; + int obj_count = cnt; #endif /* NEW_GC */ #ifdef DEBUG_XEMACS int level = 0; @@ -1182,7 +1176,7 @@ #ifdef NEW_GC if (cnt) - if (!--count) + if (!--obj_count) break; #endif /* NEW_GC */ } @@ -1894,7 +1888,7 @@ } -void +static void gc_1 (int incremental) { switch (GC_PHASE) @@ -1930,7 +1924,8 @@ } } -void gc (int incremental) +static void +gc (int incremental) { if (gc_currently_forbidden || in_display
--- a/src/objects-tty.c Tue Feb 16 01:21:32 2010 -0600 +++ b/src/objects-tty.c Sat Feb 20 03:24:08 2010 -0600 @@ -30,12 +30,6 @@ #include "device.h" #include "charset.h" -#ifdef NEW_GC -# define UNUSED_IF_NEW_GC(decl) UNUSED (decl) -#else -# define UNUSED_IF_NEW_GC(decl) decl -#endif - /* An alist mapping from color names to a cons of (FG-STRING, BG-STRING). */ Lisp_Object Vtty_color_alist; #if 0 /* This stuff doesn't quite work yet */
--- a/src/redisplay-msw.c Tue Feb 16 01:21:32 2010 -0600 +++ b/src/redisplay-msw.c Sat Feb 20 03:24:08 2010 -0600 @@ -2,7 +2,7 @@ Copyright (C) 1994, 1995 Board of Trustees, University of Illinois. Copyright (C) 1994 Lucid, Inc. Copyright (C) 1995 Sun Microsystems, Inc. - Copyright (C) 2001, 2002, 2003 Ben Wing. + Copyright (C) 2001, 2002, 2003, 2010 Ben Wing. This file is part of XEmacs. @@ -1208,12 +1208,7 @@ given face. ****************************************************************************/ static void -mswindows_clear_region ( -#ifdef HAVE_SCROLLBARS - Lisp_Object locale, -#else - Lisp_Object UNUSED (locale), -#endif +mswindows_clear_region (Lisp_Object USED_IF_SCROLLBARS (locale), struct device *UNUSED (d), struct frame *f, face_index UNUSED (findex), int x, int y, int width, int height, Lisp_Object fcolor,
--- a/src/syntax.c Tue Feb 16 01:21:32 2010 -0600 +++ b/src/syntax.c Sat Feb 20 03:24:08 2010 -0600 @@ -31,12 +31,6 @@ #include "syntax.h" #include "extents.h" -#ifdef NEW_GC -# define UNUSED_IF_NEW_GC(decl) UNUSED (decl) -#else -# define UNUSED_IF_NEW_GC(decl) decl -#endif - #define ST_COMMENT_STYLE 0x101 #define ST_STRING_STYLE 0x102
--- a/src/sysdep.c Tue Feb 16 01:21:32 2010 -0600 +++ b/src/sysdep.c Sat Feb 20 03:24:08 2010 -0600 @@ -108,12 +108,6 @@ #endif -#ifdef HAVE_TTY -#define USED_IF_TTY(decl) decl -#else -#define USED_IF_TTY(decl) UNUSED (decl) -#endif - /************************************************************************/ /* subprocess control */
--- a/src/syswindows.h Tue Feb 16 01:21:32 2010 -0600 +++ b/src/syswindows.h Sat Feb 20 03:24:08 2010 -0600 @@ -130,6 +130,30 @@ In fact, in general, it's possible to compile with support for all of these at the same time. + + + Here is a table mapping from GNU Emacs constants to XEmacs constants for + use in porting code. + + + Old Constant New Constant + --------------------------------------------------------------- + `WINDOWSNT' `WIN32_NATIVE' + `WIN32' `WIN32_NATIVE' + `_WIN32' `WIN32_NATIVE' + `HAVE_WIN32' `WIN32_NATIVE' + `DOS_NT' `WIN32_NATIVE' + `HAVE_NTGUI' `WIN32_NATIVE', unless it ends up already bracketed + by this + `HAVE_FACES' always true + `MSDOS' determine whether this code is really specific to + MS-DOS (and not Windows - e.g. DJGPP code); if so, + delete the code; otherwise, convert to `WIN32_NATIVE' + (we do not support MS-DOS w/DOS Extender under XEmacs) + `__CYGWIN__' `CYGWIN' + `__CYGWIN32__' `CYGWIN' + `__MINGW32__' `MINGW' + */ /* ------------------------- Basic includes ------------------------- */