Now on revision 112734. ------------------------------------------------------------ revno: 112734 committer: Eli Zaretskii branch nick: trunk timestamp: Sat 2013-05-25 19:05:19 +0300 message: Rename unmsys--filename to unmsys--file-name. diff: === modified file 'leim/ChangeLog' --- leim/ChangeLog 2013-05-25 07:19:50 +0000 +++ leim/ChangeLog 2013-05-25 16:05:19 +0000 @@ -1,7 +1,7 @@ 2013-05-25 Eli Zaretskii * Makefile.in (leim-list.el, check-declare): Replace - reveal-filename with unmsys--filename. + reveal-filename with unmsys--file-name. 2013-05-16 Eli Zaretskii === modified file 'leim/Makefile.in' --- leim/Makefile.in 2013-05-25 07:19:50 +0000 +++ leim/Makefile.in 2013-05-25 16:05:19 +0000 @@ -140,7 +140,7 @@ --eval "(update-leim-list-file \".\")" ; \ else \ ${RUN_EMACS} -l ${buildlisppath}/international/quail \ - --eval "(update-leim-list-file \".\" (unmsys--filename \"${srcdir}\"))" ; \ + --eval "(update-leim-list-file \".\" (unmsys--file-name \"${srcdir}\"))" ; \ fi sed -n '/^[^;]/ p' < ${srcdir}/leim-ext.el >> $@ @@ -199,4 +199,4 @@ check-declare: $(RUN_EMACS) -l $(buildlisppath)/emacs-lisp/check-declare \ - --eval '(check-declare-directory (unmsys--filename "$(srcdir)"))' + --eval '(check-declare-directory (unmsys--file-name "$(srcdir)"))' === modified file 'lisp/ChangeLog' --- lisp/ChangeLog 2013-05-25 07:19:50 +0000 +++ lisp/ChangeLog 2013-05-25 16:05:19 +0000 @@ -1,6 +1,6 @@ 2013-05-25 Eli Zaretskii - * subr.el (unmsys--filename): Renamed from reveal-filename. + * subr.el (unmsys--file-name): Renamed from reveal-filename. * Makefile.in (custom-deps, finder-data, autoloads) ($(MH_E_DIR)/mh-loaddefs.el, $(TRAMP_DIR)/tramp-loaddefs.el) === modified file 'lisp/Makefile.in' --- lisp/Makefile.in 2013-05-25 07:19:50 +0000 +++ lisp/Makefile.in 2013-05-25 16:05:19 +0000 @@ -164,21 +164,21 @@ custom-deps: doit cd $(lisp); $(setwins_almost); \ echo Directories: $$wins; \ - $(emacs) -l cus-dep --eval '(setq generated-custom-dependencies-file (unmsys--filename "$(lisp)/cus-load.el"))' -f custom-make-dependencies $$wins + $(emacs) -l cus-dep --eval '(setq generated-custom-dependencies-file (unmsys--file-name "$(lisp)/cus-load.el"))' -f custom-make-dependencies $$wins $(lisp)/finder-inf.el: $(MAKE) $(MFLAGS) finder-data finder-data: doit cd $(lisp); $(setwins_almost); \ echo Directories: $$wins; \ - $(emacs) -l finder --eval '(setq generated-finder-keywords-file (unmsys--filename "$(lisp)/finder-inf.el"))' -f finder-compile-keywords-make-dist $$wins + $(emacs) -l finder --eval '(setq generated-finder-keywords-file (unmsys--file-name "$(lisp)/finder-inf.el"))' -f finder-compile-keywords-make-dist $$wins # The chmod +w is to handle env var CVSREAD=1. autoloads: $(LOADDEFS) doit cd $(lisp) && chmod +w $(AUTOGEN_VCS) cd $(lisp); $(setwins_almost); \ echo Directories: $$wins; \ - $(emacs) -l autoload --eval '(setq generated-autoload-file (unmsys--filename "$(lisp)/loaddefs.el"))' -f batch-update-autoloads $$wins + $(emacs) -l autoload --eval '(setq generated-autoload-file (unmsys--file-name "$(lisp)/loaddefs.el"))' -f batch-update-autoloads $$wins # This is required by the bootstrap-emacs target in ../src/Makefile, so # we know that if we have an emacs executable, we also have a subdirs.el. @@ -373,7 +373,7 @@ $(MH_E_DIR)/mh-loaddefs.el: $(MH_E_SRC) $(emacs) -l autoload \ --eval "(setq generate-autoload-cookie \";;;###mh-autoload\")" \ - --eval "(setq generated-autoload-file (unmsys--filename \"$@\"))" \ + --eval "(setq generated-autoload-file (unmsys--file-name \"$@\"))" \ --eval "(setq make-backup-files nil)" \ -f batch-update-autoloads $(MH_E_DIR) @@ -391,7 +391,7 @@ $(TRAMP_DIR)/tramp-loaddefs.el: $(TRAMP_SRC) $(emacs) -l autoload \ --eval "(setq generate-autoload-cookie \";;;###tramp-autoload\")" \ - --eval "(setq generated-autoload-file (unmsys--filename \"$@\"))" \ + --eval "(setq generated-autoload-file (unmsys--file-name \"$@\"))" \ --eval "(setq make-backup-files nil)" \ -f batch-update-autoloads $(TRAMP_DIR) @@ -413,21 +413,21 @@ $(CAL_DIR)/cal-loaddefs.el: $(CAL_SRC) $(emacs) -l autoload \ --eval "(setq generate-autoload-cookie \";;;###cal-autoload\")" \ - --eval "(setq generated-autoload-file (unmsys--filename \"$@\"))" \ + --eval "(setq generated-autoload-file (unmsys--file-name \"$@\"))" \ --eval "(setq make-backup-files nil)" \ -f batch-update-autoloads $(CAL_DIR) $(CAL_DIR)/diary-loaddefs.el: $(CAL_SRC) $(emacs) -l autoload \ --eval "(setq generate-autoload-cookie \";;;###diary-autoload\")" \ - --eval "(setq generated-autoload-file (unmsys--filename \"$@\"))" \ + --eval "(setq generated-autoload-file (unmsys--file-name \"$@\"))" \ --eval "(setq make-backup-files nil)" \ -f batch-update-autoloads $(CAL_DIR) $(CAL_DIR)/hol-loaddefs.el: $(CAL_SRC) $(emacs) -l autoload \ --eval "(setq generate-autoload-cookie \";;;###holiday-autoload\")" \ - --eval "(setq generated-autoload-file (unmsys--filename \"$@\"))" \ + --eval "(setq generated-autoload-file (unmsys--file-name \"$@\"))" \ --eval "(setq make-backup-files nil)" \ -f batch-update-autoloads $(CAL_DIR) === modified file 'lisp/subr.el' --- lisp/subr.el 2013-05-25 07:19:50 +0000 +++ lisp/subr.el 2013-05-25 16:05:19 +0000 @@ -4697,7 +4697,7 @@ ;; This is used in lisp/Makefile.in and in leim/Makefile.in to ;; generate file names for autoloads, custom-deps, and finder-data. -(defun unmsys--filename (file) +(defun unmsys--file-name (file) "Produce the canonical file name for FILE from its MSYS form. On systems other than MS-Windows, just returns FILE. ------------------------------------------------------------ revno: 112733 committer: Jan D. branch nick: trunk timestamp: Sat 2013-05-25 13:14:38 +0200 message: Factor out common code for multimonitors, for Gtk+, non-Gtk+ X11 and NS. * frame.c (Qgeometry, Qworkarea, Qmm_size, Qframes, Qsource): New Lisp_Object:s. (free_monitors, make_monitor_attribute_list): New functions. (syms_of_frame): DEFSYM Qgeometry, Qworkarea, Qmm_size, Qframes, Qsource. * frame.h (Qgeometry, Qworkarea, Qmm_size, Qframes, Qsource): Declare. (struct MonitorInfo): New struct. (free_monitors, make_monitor_attribute_list): Declare. * nsfns.m (Qgeometry, Qworkarea, Qmm_size, Qframes, Qsource): Remove. (struct MonitorInfo, free_monitors): Remove. (ns_screen_name): Make static. (ns_make_monitor_attribute_list): Call make_monitor_attribute_list. (syms_of_nsfns): Remove DEFSYM for Qgeometry, Qworkarea, Qmm_size, Qframes, Qsource. * xfns.c (Qgeometry, Qworkarea, Qmm_size, Qframes, Qsource): Remove. (struct MonitorInfo, free_monitors): Remove. (x_make_monitor_attribute_list): Call make_monitor_attribute_list. (Fx_display_monitor_attributes_list): Call make_monitor_attribute_list. (syms_of_xfns): Remove DEFSYM for Qgeometry, Qworkarea, Qmm_size, Qframes, Qsource. diff: === modified file 'src/ChangeLog' --- src/ChangeLog 2013-05-25 01:55:00 +0000 +++ src/ChangeLog 2013-05-25 11:14:38 +0000 @@ -1,3 +1,29 @@ +2013-05-25 Jan Djärv + + * xfns.c (Qgeometry, Qworkarea, Qmm_size, Qframes, Qsource): Remove. + (struct MonitorInfo, free_monitors): Remove. + (x_make_monitor_attribute_list): Call make_monitor_attribute_list. + (Fx_display_monitor_attributes_list): Call make_monitor_attribute_list. + (syms_of_xfns): Remove DEFSYM for Qgeometry, Qworkarea, Qmm_size, + Qframes, Qsource. + + * nsfns.m (Qgeometry, Qworkarea, Qmm_size, Qframes, Qsource): Remove. + (struct MonitorInfo, free_monitors): Remove. + (ns_screen_name): Make static. + (ns_make_monitor_attribute_list): Call make_monitor_attribute_list. + (syms_of_nsfns): Remove DEFSYM for Qgeometry, Qworkarea, Qmm_size, + Qframes, Qsource. + + * frame.h (Qgeometry, Qworkarea, Qmm_size, Qframes, Qsource): Declare. + (struct MonitorInfo): New struct. + (free_monitors, make_monitor_attribute_list): Declare. + + * frame.c (Qgeometry, Qworkarea, Qmm_size, Qframes, Qsource): New + Lisp_Object:s. + (free_monitors, make_monitor_attribute_list): New functions. + (syms_of_frame): DEFSYM Qgeometry, Qworkarea, Qmm_size, Qframes, + Qsource. + 2013-05-25 Xue Fuqiao * callproc.c (call_process): Refine the doc string. (Bug#14045) === modified file 'src/frame.c' --- src/frame.c 2013-04-10 15:38:20 +0000 +++ src/frame.c 2013-05-25 11:14:38 +0000 @@ -76,7 +76,6 @@ Lisp_Object Qauto_raise, Qauto_lower; Lisp_Object Qborder_color, Qborder_width; Lisp_Object Qcursor_color, Qcursor_type; -static Lisp_Object Qgeometry; /* Not used */ Lisp_Object Qheight, Qwidth; Lisp_Object Qleft, Qright; Lisp_Object Qicon_left, Qicon_top, Qicon_type, Qicon_name; @@ -115,6 +114,8 @@ static Lisp_Object Qdelete_frame_functions; +Lisp_Object Qgeometry, Qworkarea, Qmm_size, Qframes, Qsource; + #ifdef HAVE_WINDOW_SYSTEM static void x_report_frame_params (struct frame *, Lisp_Object *); #endif @@ -4129,6 +4130,73 @@ return decode_any_frame (frame)->pointer_invisible ? Qnil : Qt; } + + +/*********************************************************************** + Multimonitor data + ***********************************************************************/ + +#ifdef HAVE_WINDOW_SYSTEM + +void +free_monitors (struct MonitorInfo *monitors, int n_monitors) +{ + int i; + for (i = 0; i < n_monitors; ++i) + xfree (monitors[i].name); + xfree (monitors); +} + +Lisp_Object +make_monitor_attribute_list (struct MonitorInfo *monitors, + int n_monitors, + int primary_monitor, + Lisp_Object monitor_frames, + const char *source) +{ + Lisp_Object attributes_list = Qnil; + Lisp_Object primary_monitor_attributes = Qnil; + int i; + + for (i = 0; i < n_monitors; ++i) + { + Lisp_Object geometry, workarea, attributes = Qnil; + struct MonitorInfo *mi = &monitors[i]; + + if (mi->geom.width == 0) continue; + + workarea = list4i (mi->work.x, mi->work.y, + mi->work.width, mi->work.height); + geometry = list4i (mi->geom.x, mi->geom.y, + mi->geom.width, mi->geom.height); + attributes = Fcons (Fcons (Qsource, + make_string (source, strlen (source))), + attributes); + attributes = Fcons (Fcons (Qframes, AREF (monitor_frames, i)), + attributes); + attributes = Fcons (Fcons (Qmm_size, + list2i (mi->mm_width, mi->mm_height)), + attributes); + attributes = Fcons (Fcons (Qworkarea, workarea), attributes); + attributes = Fcons (Fcons (Qgeometry, geometry), attributes); + if (mi->name) + attributes = Fcons (Fcons (Qname, make_string (mi->name, + strlen (mi->name))), + attributes); + + if (i == primary_monitor) + primary_monitor_attributes = attributes; + else + attributes_list = Fcons (attributes, attributes_list); + } + + if (!NILP (primary_monitor_attributes)) + attributes_list = Fcons (primary_monitor_attributes, attributes_list); + return attributes_list; +} + +#endif /* HAVE_WINDOW_SYSTEM */ + /*********************************************************************** Initialization @@ -4187,6 +4255,12 @@ DEFSYM (Qterminal, "terminal"); DEFSYM (Qterminal_live_p, "terminal-live-p"); + DEFSYM (Qgeometry, "geometry"); + DEFSYM (Qworkarea, "workarea"); + DEFSYM (Qmm_size, "mm-size"); + DEFSYM (Qframes, "frames"); + DEFSYM (Qsource, "source"); + #ifdef HAVE_NS DEFSYM (Qns_parse_geometry, "ns-parse-geometry"); #endif === modified file 'src/frame.h' --- src/frame.h 2013-04-15 07:27:56 +0000 +++ src/frame.h 2013-05-25 11:14:38 +0000 @@ -1198,6 +1198,8 @@ extern Lisp_Object Qrun_hook_with_args; +extern Lisp_Object Qgeometry, Qworkarea, Qmm_size, Qframes, Qsource; + #ifdef HAVE_WINDOW_SYSTEM /* The class of this X application. */ @@ -1288,6 +1290,28 @@ extern void x_query_color (struct frame *f, XColor *); #endif /* HAVE_WINDOW_SYSTEM */ + +/*********************************************************************** + Multimonitor data + ***********************************************************************/ + +#ifdef HAVE_WINDOW_SYSTEM + +struct MonitorInfo { + XRectangle geom, work; + int mm_width, mm_height; + char *name; +}; + +extern void free_monitors (struct MonitorInfo *monitors, int n_monitors); +extern Lisp_Object make_monitor_attribute_list (struct MonitorInfo *monitors, + int n_monitors, + int primary_monitor, + Lisp_Object monitor_frames, + const char *source); + +#endif /* HAVE_WINDOW_SYSTEM */ + INLINE_HEADER_END === modified file 'src/nsfns.m' --- src/nsfns.m 2013-05-20 08:27:56 +0000 +++ src/nsfns.m 2013-05-25 11:14:38 +0000 @@ -105,7 +105,6 @@ static ptrdiff_t image_cache_refcount; #endif -static Lisp_Object Qgeometry, Qworkarea, Qmm_size, Qframes, Qsource; /* ========================================================================== @@ -2328,27 +2327,12 @@ return make_number (x_display_pixel_height (dpyinfo)); } -struct MonitorInfo { - XRectangle geom, work; - int mm_width, mm_height; - char *name; -}; - -static void -free_monitors (struct MonitorInfo *monitors, int n_monitors) -{ - int i; - for (i = 0; i < n_monitors; ++i) - xfree (monitors[i].name); - xfree (monitors); -} - #ifdef NS_IMPL_COCOA /* Returns the name for the screen that DICT came from, or NULL. Caller must free return value. */ -char * +static char * ns_screen_name (CGDirectDisplayID did) { char *name = NULL; @@ -2377,8 +2361,7 @@ const char *source) { Lisp_Object monitor_frames = Fmake_vector (make_number (n_monitors), Qnil); - Lisp_Object frame, rest, attributes_list = Qnil; - Lisp_Object primary_monitor_attributes = Qnil; + Lisp_Object frame, rest; NSArray *screens = [NSScreen screens]; int i; @@ -2404,41 +2387,8 @@ } } - for (i = 0; i < n_monitors; ++i) - { - Lisp_Object geometry, workarea, attributes = Qnil; - struct MonitorInfo *mi = &monitors[i]; - - if (mi->geom.width == 0) continue; - - workarea = list4i (mi->work.x, mi->work.y, - mi->work.width, mi->work.height); - geometry = list4i (mi->geom.x, mi->geom.y, - mi->geom.width, mi->geom.height); - attributes = Fcons (Fcons (Qsource, - make_string (source, strlen (source))), - attributes); - attributes = Fcons (Fcons (Qframes, AREF (monitor_frames, i)), - attributes); - attributes = Fcons (Fcons (Qmm_size, - list2i (mi->mm_width, mi->mm_height)), - attributes); - attributes = Fcons (Fcons (Qworkarea, workarea), attributes); - attributes = Fcons (Fcons (Qgeometry, geometry), attributes); - if (mi->name) - attributes = Fcons (Fcons (Qname, make_string (mi->name, - strlen (mi->name))), - attributes); - - if (i == primary_monitor) - primary_monitor_attributes = attributes; - else - attributes_list = Fcons (attributes, attributes_list); - } - - if (!NILP (primary_monitor_attributes)) - attributes_list = Fcons (primary_monitor_attributes, attributes_list); - return attributes_list; + return make_monitor_attribute_list (monitors, n_monitors, primary_monitor, + monitor_frames, source); } DEFUN ("ns-display-monitor-attributes-list", @@ -2922,11 +2872,6 @@ void syms_of_nsfns (void) { - DEFSYM (Qgeometry, "geometry"); - DEFSYM (Qworkarea, "workarea"); - DEFSYM (Qmm_size, "mm-size"); - DEFSYM (Qframes, "frames"); - DEFSYM (Qsource, "source"); Qfontsize = intern_c_string ("fontsize"); staticpro (&Qfontsize); === modified file 'src/xfns.c' --- src/xfns.c 2013-05-20 03:15:20 +0000 +++ src/xfns.c 2013-05-25 11:14:38 +0000 @@ -133,7 +133,6 @@ static Lisp_Object Qsuppress_icon; static Lisp_Object Qundefined_color; static Lisp_Object Qcompound_text, Qcancel_timer; -static Lisp_Object Qgeometry, Qworkarea, Qmm_size, Qframes, Qsource; Lisp_Object Qfont_param; #ifdef GLYPH_DEBUG @@ -3882,24 +3881,6 @@ #ifndef USE_GTK -struct MonitorInfo { - XRectangle geom, work; - int mm_width, mm_height; - char *name; -}; - -#if defined HAVE_XINERAMA || defined HAVE_XRANDR -static void -free_monitors (struct MonitorInfo *monitors, int n_monitors) -{ - int i; - for (i = 0; i < n_monitors; ++i) - xfree (monitors[i].name); - xfree (monitors); -} -#endif /* HAVE_XINERAMA || HAVE_XRANDR */ - - /* Return monitor number where F is "most" or closest to. */ static int x_get_monitor_for_frame (struct frame *f, @@ -3971,9 +3952,7 @@ const char *source) { Lisp_Object monitor_frames = Fmake_vector (make_number (n_monitors), Qnil); - Lisp_Object frame, rest, attributes_list = Qnil; - Lisp_Object primary_monitor_attributes = Qnil; - int i; + Lisp_Object frame, rest; FOR_EACH_FRAME (rest, frame) { @@ -3982,46 +3961,13 @@ if (FRAME_X_P (f) && FRAME_X_DISPLAY_INFO (f) == dpyinfo && !EQ (frame, tip_frame)) { - i = x_get_monitor_for_frame (f, monitors, n_monitors); + int i = x_get_monitor_for_frame (f, monitors, n_monitors); ASET (monitor_frames, i, Fcons (frame, AREF (monitor_frames, i))); } } - for (i = 0; i < n_monitors; ++i) - { - Lisp_Object geometry, workarea, attributes = Qnil; - struct MonitorInfo *mi = &monitors[i]; - - if (mi->geom.width == 0) continue; - - workarea = list4i (mi->work.x, mi->work.y, - mi->work.width, mi->work.height); - geometry = list4i (mi->geom.x, mi->geom.y, - mi->geom.width, mi->geom.height); - attributes = Fcons (Fcons (Qsource, - make_string (source, strlen (source))), - attributes); - attributes = Fcons (Fcons (Qframes, AREF (monitor_frames, i)), - attributes); - attributes = Fcons (Fcons (Qmm_size, - list2i (mi->mm_width, mi->mm_height)), - attributes); - attributes = Fcons (Fcons (Qworkarea, workarea), attributes); - attributes = Fcons (Fcons (Qgeometry, geometry), attributes); - if (mi->name) - attributes = Fcons (Fcons (Qname, make_string (mi->name, - strlen (mi->name))), - attributes); - - if (i == primary_monitor) - primary_monitor_attributes = attributes; - else - attributes_list = Fcons (attributes, attributes_list); - } - - if (!NILP (primary_monitor_attributes)) - attributes_list = Fcons (primary_monitor_attributes, attributes_list); - return attributes_list; + return make_monitor_attribute_list (monitors, n_monitors, primary_monitor, + monitor_frames, source); } static Lisp_Object @@ -4270,9 +4216,9 @@ GdkDisplay *gdpy; GdkScreen *gscreen; gint primary_monitor = 0, n_monitors, i; - Lisp_Object primary_monitor_attributes = Qnil; Lisp_Object monitor_frames, rest, frame; static const char *source = "Gdk"; + struct MonitorInfo *monitors; block_input (); mm_width_per_pixel = ((double) WidthMMOfScreen (dpyinfo->screen) @@ -4286,6 +4232,8 @@ #endif n_monitors = gdk_screen_get_n_monitors (gscreen); monitor_frames = Fmake_vector (make_number (n_monitors), Qnil); + monitors = (struct MonitorInfo *) xzalloc (n_monitors * sizeof (*monitors)); + FOR_EACH_FRAME (rest, frame) { struct frame *f = XFRAME (frame); @@ -4300,21 +4248,13 @@ } } - i = n_monitors; - while (i-- > 0) + for (i = 0; i < n_monitors; ++i) { - Lisp_Object geometry, workarea, attributes = Qnil; gint width_mm = -1, height_mm = -1; - GdkRectangle rec; - - attributes = Fcons (Fcons (Qsource, - make_string (source, strlen (source))), - attributes); - attributes = Fcons (Fcons (Qframes, AREF (monitor_frames, i)), - attributes); + GdkRectangle rec, work; + struct MonitorInfo *mi = &monitors[i]; gdk_screen_get_monitor_geometry (gscreen, i, &rec); - geometry = list4i (rec.x, rec.y, rec.width, rec.height); #if GTK_CHECK_VERSION (2, 14, 0) width_mm = gdk_screen_get_monitor_width_mm (gscreen, i); @@ -4324,54 +4264,50 @@ width_mm = rec.width * mm_width_per_pixel + 0.5; if (height_mm < 0) height_mm = rec.height * mm_height_per_pixel + 0.5; - attributes = Fcons (Fcons (Qmm_size, - list2i (width_mm, height_mm)), - attributes); #if GTK_CHECK_VERSION (3, 4, 0) - gdk_screen_get_monitor_workarea (gscreen, i, &rec); - workarea = list4i (rec.x, rec.y, rec.width, rec.height); + gdk_screen_get_monitor_workarea (gscreen, i, &work); #else /* Emulate the behavior of GTK+ 3.4. */ { XRectangle workarea_r; - workarea = Qnil; if (i == primary_monitor && x_get_net_workarea (dpyinfo, &workarea_r)) { - GdkRectangle work; - work.x = workarea_r.x; work.y = workarea_r.y; work.width = workarea_r.width; work.height = workarea_r.height; - if (gdk_rectangle_intersect (&rec, &work, &work)) - workarea = list4i (work.x, work.y, work.width, work.height); - } - if (NILP (workarea)) - workarea = geometry; + if (! gdk_rectangle_intersect (&rec, &work, &work)) + work = rec; + } + else + work = rec; } #endif - attributes = Fcons (Fcons (Qworkarea, workarea), attributes); - - attributes = Fcons (Fcons (Qgeometry, geometry), attributes); + + + mi->geom.x = rec.x; + mi->geom.y = rec.y; + mi->geom.width = rec.width; + mi->geom.height = rec.height; + mi->work.x = work.x; + mi->work.y = work.y; + mi->work.width = work.width; + mi->work.height = work.height; + mi->mm_width = width_mm; + mi->mm_height = height_mm; + #if GTK_CHECK_VERSION (2, 14, 0) - { - char *name = gdk_screen_get_monitor_plug_name (gscreen, i); - if (name) - attributes = Fcons (Fcons (Qname, make_string (name, strlen (name))), - attributes); - } + mi->name = gdk_screen_get_monitor_plug_name (gscreen, i); #endif - - if (i == primary_monitor) - primary_monitor_attributes = attributes; - else - attributes_list = Fcons (attributes, attributes_list); } - if (!NILP (primary_monitor_attributes)) - attributes_list = Fcons (primary_monitor_attributes, attributes_list); + attributes_list = make_monitor_attribute_list (monitors, + n_monitors, + primary_monitor, + monitor_frames, + source); unblock_input (); #else /* not USE_GTK */ @@ -6294,11 +6230,6 @@ DEFSYM (Qundefined_color, "undefined-color"); DEFSYM (Qcompound_text, "compound-text"); DEFSYM (Qcancel_timer, "cancel-timer"); - DEFSYM (Qgeometry, "geometry"); - DEFSYM (Qworkarea, "workarea"); - DEFSYM (Qmm_size, "mm-size"); - DEFSYM (Qframes, "frames"); - DEFSYM (Qsource, "source"); DEFSYM (Qfont_param, "font-parameter"); /* This is the end of symbol initialization. */ ------------------------------------------------------------ revno: 112732 committer: Eli Zaretskii branch nick: trunk timestamp: Sat 2013-05-25 12:26:53 +0300 message: Fix a typo in the last commit. diff: === modified file 'nt/INSTALL.MSYS' --- nt/INSTALL.MSYS 2013-05-25 07:34:34 +0000 +++ nt/INSTALL.MSYS 2013-05-25 09:26:53 +0000 @@ -333,7 +333,7 @@ Such a single-tree installation makes sure all the other programs and packages ported from GNU or Unix systems will work seemlessly together. Where exactly is the root of that tree on your system is - soimething only you, the user who builds Emacs, can know, and the + something only you, the user who builds Emacs, can know, and the Emacs build process cannot guess, because usually there's no '/usr/local' directory on any drive on Windows systems. ------------------------------------------------------------ revno: 112731 committer: Eli Zaretskii branch nick: trunk timestamp: Sat 2013-05-25 10:34:34 +0300 message: Explain in nt/INSTALL.MSYS why --prefix should be used with Windows builds. diff: === modified file 'nt/INSTALL.MSYS' --- nt/INSTALL.MSYS 2013-05-16 17:14:21 +0000 +++ nt/INSTALL.MSYS 2013-05-25 07:34:34 +0000 @@ -46,7 +46,8 @@ It is always preferable to use --prefix to configure Emacs for some specific location of its installed tree; the default - /usr/local is not suitable for Windows. + /usr/local is not suitable for Windows (see the detailed + instructions for the reasons). You can pass other options to the configure script. Here's a typical example (for an in-place debug build): @@ -324,7 +325,17 @@ ./nt/msysconfig.sh --prefix=PREFIX ... Here PREFIX is the place where you eventually want to install Emacs - once built, e.g. d:/usr. + once built, e.g. d:/usr. We recommend to always use --prefix when + building Emacs on Windows, because the default '/usr/local' is not + appropriate for Windows: it will be mapped by MSYS to something like + C:\MSYS\local, and it will defeat the purpose of PREFIX, which is to + install programs in a single coherent tree resembling Posix systems. + Such a single-tree installation makes sure all the other programs + and packages ported from GNU or Unix systems will work seemlessly + together. Where exactly is the root of that tree on your system is + soimething only you, the user who builds Emacs, can know, and the + Emacs build process cannot guess, because usually there's no + '/usr/local' directory on any drive on Windows systems. You can pass additional options to the configure script, for the full list type ------------------------------------------------------------ revno: 112730 committer: Eli Zaretskii branch nick: trunk timestamp: Sat 2013-05-25 10:19:50 +0300 message: Rename reveal-filename into unmsys--filename. lisp/subr.el (unmsys--filename): Renamed from reveal-filename. lisp/Makefile.in (custom-deps, finder-data, autoloads) ($(MH_E_DIR)/mh-loaddefs.el, $(TRAMP_DIR)/tramp-loaddefs.el) ($(CAL_DIR)/cal-loaddefs.el, $(CAL_DIR)/diary-loaddefs.el) ($(CAL_DIR)/hol-loaddefs.el): All users changed. leim/Makefile.in (leim-list.el, check-declare): Replace reveal-filename with unmsys--filename. diff: === modified file 'leim/ChangeLog' --- leim/ChangeLog 2013-05-16 12:48:54 +0000 +++ leim/ChangeLog 2013-05-25 07:19:50 +0000 @@ -1,3 +1,8 @@ +2013-05-25 Eli Zaretskii + + * Makefile.in (leim-list.el, check-declare): Replace + reveal-filename with unmsys--filename. + 2013-05-16 Eli Zaretskii * Makefile.in (leim-list.el, check-declare): Use reveal-filename. === modified file 'leim/Makefile.in' --- leim/Makefile.in 2013-04-20 18:34:44 +0000 +++ leim/Makefile.in 2013-05-25 07:19:50 +0000 @@ -140,7 +140,7 @@ --eval "(update-leim-list-file \".\")" ; \ else \ ${RUN_EMACS} -l ${buildlisppath}/international/quail \ - --eval "(update-leim-list-file \".\" (reveal-filename \"${srcdir}\"))" ; \ + --eval "(update-leim-list-file \".\" (unmsys--filename \"${srcdir}\"))" ; \ fi sed -n '/^[^;]/ p' < ${srcdir}/leim-ext.el >> $@ @@ -199,4 +199,4 @@ check-declare: $(RUN_EMACS) -l $(buildlisppath)/emacs-lisp/check-declare \ - --eval '(check-declare-directory (reveal-filename "$(srcdir)"))' + --eval '(check-declare-directory (unmsys--filename "$(srcdir)"))' === modified file 'lisp/ChangeLog' --- lisp/ChangeLog 2013-05-25 03:08:04 +0000 +++ lisp/ChangeLog 2013-05-25 07:19:50 +0000 @@ -1,3 +1,12 @@ +2013-05-25 Eli Zaretskii + + * subr.el (unmsys--filename): Renamed from reveal-filename. + + * Makefile.in (custom-deps, finder-data, autoloads) + ($(MH_E_DIR)/mh-loaddefs.el, $(TRAMP_DIR)/tramp-loaddefs.el) + ($(CAL_DIR)/cal-loaddefs.el, $(CAL_DIR)/diary-loaddefs.el) + ($(CAL_DIR)/hol-loaddefs.el): All users changed. + 2013-05-25 Stefan Monnier * emacs-lisp/lisp.el (lisp-completion-at-point): Don't use === modified file 'lisp/Makefile.in' --- lisp/Makefile.in 2013-05-01 17:47:50 +0000 +++ lisp/Makefile.in 2013-05-25 07:19:50 +0000 @@ -164,21 +164,21 @@ custom-deps: doit cd $(lisp); $(setwins_almost); \ echo Directories: $$wins; \ - $(emacs) -l cus-dep --eval '(setq generated-custom-dependencies-file (reveal-filename "$(lisp)/cus-load.el"))' -f custom-make-dependencies $$wins + $(emacs) -l cus-dep --eval '(setq generated-custom-dependencies-file (unmsys--filename "$(lisp)/cus-load.el"))' -f custom-make-dependencies $$wins $(lisp)/finder-inf.el: $(MAKE) $(MFLAGS) finder-data finder-data: doit cd $(lisp); $(setwins_almost); \ echo Directories: $$wins; \ - $(emacs) -l finder --eval '(setq generated-finder-keywords-file (reveal-filename "$(lisp)/finder-inf.el"))' -f finder-compile-keywords-make-dist $$wins + $(emacs) -l finder --eval '(setq generated-finder-keywords-file (unmsys--filename "$(lisp)/finder-inf.el"))' -f finder-compile-keywords-make-dist $$wins # The chmod +w is to handle env var CVSREAD=1. autoloads: $(LOADDEFS) doit cd $(lisp) && chmod +w $(AUTOGEN_VCS) cd $(lisp); $(setwins_almost); \ echo Directories: $$wins; \ - $(emacs) -l autoload --eval '(setq generated-autoload-file (reveal-filename "$(lisp)/loaddefs.el"))' -f batch-update-autoloads $$wins + $(emacs) -l autoload --eval '(setq generated-autoload-file (unmsys--filename "$(lisp)/loaddefs.el"))' -f batch-update-autoloads $$wins # This is required by the bootstrap-emacs target in ../src/Makefile, so # we know that if we have an emacs executable, we also have a subdirs.el. @@ -373,7 +373,7 @@ $(MH_E_DIR)/mh-loaddefs.el: $(MH_E_SRC) $(emacs) -l autoload \ --eval "(setq generate-autoload-cookie \";;;###mh-autoload\")" \ - --eval "(setq generated-autoload-file (reveal-filename \"$@\"))" \ + --eval "(setq generated-autoload-file (unmsys--filename \"$@\"))" \ --eval "(setq make-backup-files nil)" \ -f batch-update-autoloads $(MH_E_DIR) @@ -391,7 +391,7 @@ $(TRAMP_DIR)/tramp-loaddefs.el: $(TRAMP_SRC) $(emacs) -l autoload \ --eval "(setq generate-autoload-cookie \";;;###tramp-autoload\")" \ - --eval "(setq generated-autoload-file (reveal-filename \"$@\"))" \ + --eval "(setq generated-autoload-file (unmsys--filename \"$@\"))" \ --eval "(setq make-backup-files nil)" \ -f batch-update-autoloads $(TRAMP_DIR) @@ -413,21 +413,21 @@ $(CAL_DIR)/cal-loaddefs.el: $(CAL_SRC) $(emacs) -l autoload \ --eval "(setq generate-autoload-cookie \";;;###cal-autoload\")" \ - --eval "(setq generated-autoload-file (reveal-filename \"$@\"))" \ + --eval "(setq generated-autoload-file (unmsys--filename \"$@\"))" \ --eval "(setq make-backup-files nil)" \ -f batch-update-autoloads $(CAL_DIR) $(CAL_DIR)/diary-loaddefs.el: $(CAL_SRC) $(emacs) -l autoload \ --eval "(setq generate-autoload-cookie \";;;###diary-autoload\")" \ - --eval "(setq generated-autoload-file (reveal-filename \"$@\"))" \ + --eval "(setq generated-autoload-file (unmsys--filename \"$@\"))" \ --eval "(setq make-backup-files nil)" \ -f batch-update-autoloads $(CAL_DIR) $(CAL_DIR)/hol-loaddefs.el: $(CAL_SRC) $(emacs) -l autoload \ --eval "(setq generate-autoload-cookie \";;;###holiday-autoload\")" \ - --eval "(setq generated-autoload-file (reveal-filename \"$@\"))" \ + --eval "(setq generated-autoload-file (unmsys--filename \"$@\"))" \ --eval "(setq make-backup-files nil)" \ -f batch-update-autoloads $(CAL_DIR) === modified file 'lisp/subr.el' --- lisp/subr.el 2013-05-17 02:43:41 +0000 +++ lisp/subr.el 2013-05-25 07:19:50 +0000 @@ -4697,14 +4697,14 @@ ;; This is used in lisp/Makefile.in and in leim/Makefile.in to ;; generate file names for autoloads, custom-deps, and finder-data. -(defun reveal-filename (file) - "Produce the real file name for FILE. +(defun unmsys--filename (file) + "Produce the canonical file name for FILE from its MSYS form. On systems other than MS-Windows, just returns FILE. On MS-Windows, converts /d/foo/bar form of file names passed by MSYS Make into d:/foo/bar that Emacs can grok. -This function is called from lisp/Makefile." +This function is called from lisp/Makefile and leim/Makefile." (when (and (eq system-type 'windows-nt) (string-match "\\`/[a-zA-Z]/" file)) (setq file (concat (substring file 1 2) ":" (substring file 2)))) ------------------------------------------------------------ revno: 112729 fixes bug: http://debbugs.gnu.org/cgi/bugreport.cgi?bug=14446 committer: Stefan Monnier branch nick: trunk timestamp: Fri 2013-05-24 23:08:04 -0400 message: * lisp/emacs-lisp/lisp.el (lisp-completion-at-point): Don't burp at EOB. diff: === modified file 'lisp/ChangeLog' --- lisp/ChangeLog 2013-05-25 03:00:13 +0000 +++ lisp/ChangeLog 2013-05-25 03:08:04 +0000 @@ -2,6 +2,7 @@ * emacs-lisp/lisp.el (lisp-completion-at-point): Don't use error-completion on the first 2 args of condition-case (bug#14446). + Don't burp at EOB. 2013-05-25 Leo Liu === modified file 'lisp/emacs-lisp/lisp.el' --- lisp/emacs-lisp/lisp.el 2013-05-25 03:00:13 +0000 +++ lisp/emacs-lisp/lisp.el 2013-05-25 03:08:04 +0000 @@ -726,7 +726,7 @@ (let ((tail (if (null (car table-etc)) (cdr table-etc) (cons - (if (memq (char-syntax (char-after end)) + (if (memq (char-syntax (or (char-after end) ?\s)) '(?\s ?>)) (cadr table-etc) (apply-partially 'completion-table-with-terminator