From da55edac25ea1907da888f4c506cc20eac24d147 Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Sun, 5 Oct 2014 23:34:21 -0700 Subject: * package.texi (Package Menu): Package list was changed to not say "unsigned" --- doc/emacs/ChangeLog | 5 +++++ doc/emacs/package.texi | 2 +- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/doc/emacs/ChangeLog b/doc/emacs/ChangeLog index 773e3bb51e7..af7db4bf383 100644 --- a/doc/emacs/ChangeLog +++ b/doc/emacs/ChangeLog @@ -1,3 +1,8 @@ +2014-10-06 Glenn Morris + + * package.texi (Package Menu): The package list was changed to not + say "unsigned" any more. + 2014-10-04 Glenn Morris * misc.texi (Sorting): diff --git a/doc/emacs/package.texi b/doc/emacs/package.texi index 1af90edd953..136eff7e2fe 100644 --- a/doc/emacs/package.texi +++ b/doc/emacs/package.texi @@ -60,7 +60,7 @@ The package's version number (e.g., @samp{11.86}). @item The package's status---normally one of @samp{available} (can be downloaded from the package archive), @samp{installed}, -@samp{unsigned} (installed, but not signed; @pxref{Package Signing}), +@c @samp{unsigned} (installed, but not signed; @pxref{Package Signing}), or @samp{built-in} (included in Emacs by default). The status can also be @samp{new}. This is equivalent to -- cgit v1.2.1 From e76955cbb521aee4af70a8c93d9f1be5f1d3f4a6 Mon Sep 17 00:00:00 2001 From: Martin Rudalics Date: Mon, 6 Oct 2014 08:45:10 +0200 Subject: In term-window-width subtract 1 from width when any fringe has zero width. (Bug#18601) * term.el (term-window-width): Subtract 1 from the width when any fringe has zero width, not just the right fringe. (Bug#18601) --- lisp/ChangeLog | 5 +++++ lisp/term.el | 3 +++ 2 files changed, 8 insertions(+) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index d5eda032f74..5045e5d1469 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,8 @@ +2014-10-06 Martin Rudalics + + * term.el (term-window-width): Subtract 1 from the width when + any fringe has zero width, not just the right fringe. (Bug#18601) + 2014-10-05 Leo Liu * imenu.el (imenu-default-goto-function): Fix typo. diff --git a/lisp/term.el b/lisp/term.el index ce6125e2790..f361b983e48 100644 --- a/lisp/term.el +++ b/lisp/term.el @@ -974,6 +974,9 @@ is buffer-local." (if (and (not (featurep 'xemacs)) (display-graphic-p) overflow-newline-into-fringe + ;; Subtract 1 from the width when any fringe has zero width, + ;; not just the right fringe. Bug#18601. + (/= (frame-parameter nil 'left-fringe) 0) (/= (frame-parameter nil 'right-fringe) 0)) (window-body-width) (1- (window-body-width)))) -- cgit v1.2.1 From a7044030f39a7351507727421308c56d7771bebf Mon Sep 17 00:00:00 2001 From: Kenichi Handa Date: Wed, 8 Oct 2014 10:30:57 +0300 Subject: Fix bug #18610 with crashes when visiting files with ESC and 8-bit bytes. src/coding.c (detect_coding_iso_2022): Set coding->rejected correctly when an invalid escape sequence is found. Backported from trunk. --- src/ChangeLog | 5 +++++ src/coding.c | 34 ++++++++++++++++++++++++++-------- 2 files changed, 31 insertions(+), 8 deletions(-) diff --git a/src/ChangeLog b/src/ChangeLog index 9354aa09fa4..c6d78a5e8d1 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,8 @@ +2014-10-08 K. Handa + + * coding.c (detect_coding_iso_2022): Set coding->rejected + correctly when an invalid escape sequence is found (Bug#18610). + 2014-10-03 Dmitry Antipov * font.c (font_list_entities): Do not add empty vector to font cache. diff --git a/src/coding.c b/src/coding.c index 31303e2ba42..b0a9f6ef4cb 100644 --- a/src/coding.c +++ b/src/coding.c @@ -3078,8 +3078,13 @@ detect_coding_iso_2022 (struct coding_system *coding, ONE_MORE_BYTE (c1); if (c1 < ' ' || c1 >= 0x80 || (id = iso_charset_table[0][c >= ','][c1]) < 0) - /* Invalid designation sequence. Just ignore. */ - break; + { + /* Invalid designation sequence. Just ignore. */ + if (c1 >= 0x80) + rejected |= (CATEGORY_MASK_ISO_7BIT + | CATEGORY_MASK_ISO_7_ELSE); + break; + } } else if (c == '$') { @@ -3093,16 +3098,29 @@ detect_coding_iso_2022 (struct coding_system *coding, ONE_MORE_BYTE (c1); if (c1 < ' ' || c1 >= 0x80 || (id = iso_charset_table[1][c >= ','][c1]) < 0) - /* Invalid designation sequence. Just ignore. */ - break; + { + /* Invalid designation sequence. Just ignore. */ + if (c1 >= 0x80) + rejected |= (CATEGORY_MASK_ISO_7BIT + | CATEGORY_MASK_ISO_7_ELSE); + break; + } } else - /* Invalid designation sequence. Just ignore it. */ - break; + { + /* Invalid designation sequence. Just ignore it. */ + if (c >= 0x80) + rejected |= (CATEGORY_MASK_ISO_7BIT + | CATEGORY_MASK_ISO_7_ELSE); + break; + } } else { /* Invalid escape sequence. Just ignore it. */ + if (c >= 0x80) + rejected |= (CATEGORY_MASK_ISO_7BIT + | CATEGORY_MASK_ISO_7_ELSE); break; } @@ -3153,7 +3171,7 @@ detect_coding_iso_2022 (struct coding_system *coding, if (inhibit_iso_escape_detection) break; single_shifting = 0; - rejected |= CATEGORY_MASK_ISO_7BIT; + rejected |= CATEGORY_MASK_ISO_7BIT | CATEGORY_MASK_ISO_7_ELSE; if (CODING_ISO_FLAGS (&coding_categories[coding_category_iso_8_1]) & CODING_ISO_FLAG_SINGLE_SHIFT) { @@ -3180,9 +3198,9 @@ detect_coding_iso_2022 (struct coding_system *coding, single_shifting = 0; break; } + rejected |= CATEGORY_MASK_ISO_7BIT | CATEGORY_MASK_ISO_7_ELSE; if (c >= 0xA0) { - rejected |= CATEGORY_MASK_ISO_7BIT | CATEGORY_MASK_ISO_7_ELSE; found |= CATEGORY_MASK_ISO_8_1; /* Check the length of succeeding codes of the range 0xA0..0FF. If the byte length is even, we include -- cgit v1.2.1 From 28ec0a87ca43f6d62b1503bedfe25640269fd7ef Mon Sep 17 00:00:00 2001 From: Eli Zaretskii Date: Wed, 8 Oct 2014 13:16:45 +0300 Subject: Fix bug #18636 with documentation of multi-monitor displays. doc/lispref/frames.texi (Multiple Terminals): Improve the description of X display names. Add index entries. (Basic Parameters): Add a cross-reference to where X display names are described. (Position Parameters): Mention that positional parameters of the form (+ POS) can be negative if they are on a non-primary monitor of a multi-monitor display. (Creating Frames): Mention that on multi-monitor displays the frame might be positioned differently than specified by the frame parameters alist. lisp/faces.el (display-grayscale-p): Mention in the doc string that the argument can be either a display name or a frame. lisp/frame.el (display-pixel-height, display-pixel-width) (display-mm-height, display-mm-width, display-backing-store) (display-save-under, display-planes, display-color-cells) (display-visual-class, display-monitor-attributes-list) (display-screens): Mention in the doc string that the argument can be either a display name or a frame. Improve the docs of the monitor attributes. --- doc/lispref/ChangeLog | 13 ++++++++ doc/lispref/frames.texi | 89 +++++++++++++++++++++++++++++++++++++++---------- lisp/ChangeLog | 13 ++++++++ lisp/faces.el | 4 ++- lisp/frame.el | 19 +++++++++-- 5 files changed, 116 insertions(+), 22 deletions(-) diff --git a/doc/lispref/ChangeLog b/doc/lispref/ChangeLog index babcc22959e..36497470705 100644 --- a/doc/lispref/ChangeLog +++ b/doc/lispref/ChangeLog @@ -1,3 +1,16 @@ +2014-10-08 Eli Zaretskii + + * frames.texi (Multiple Terminals): Improve the description of X + display names. Add index entries. + (Basic Parameters): Add a cross-reference to where X display names + are described. + (Position Parameters): Mention that positional parameters of the + form (+ POS) can be negative if they are on a non-primary monitor + of a multi-monitor display. (Bug#18636) + (Creating Frames): Mention that on multi-monitor displays the + frame might be positioned differently than specified by the frame + parameters alist. + 2014-10-04 Glenn Morris * commands.texi (Generic Commands): Copyedits. diff --git a/doc/lispref/frames.texi b/doc/lispref/frames.texi index afbace34575..cb3fefd7115 100644 --- a/doc/lispref/frames.texi +++ b/doc/lispref/frames.texi @@ -131,6 +131,13 @@ applies any parameters listed in @code{frame-inherited-parameters} (see below) and not present in the argument, taking the values from the frame that was selected when @code{make-frame} was called. +Note that on multi-monitor displays (@pxref{Multiple Terminals}), the +window manager might position the frame differently than specified by +the positional parameters in @var{alist} (@pxref{Position +Parameters}). For example, some window managers have a policy of +displaying the frame on the monitor that contains the largest part of +the window (a.k.a.@: the @dfn{dominating} monitor). + This function itself does not make the new frame the selected frame. @xref{Input Focus}. The previously selected frame remains selected. On graphical terminals, however, the windowing system may select the @@ -258,13 +265,27 @@ of those frames is ``@emph{the} selected frame'' at any given moment terminals, by interacting with the @command{emacsclient} program. @xref{Emacs Server,,, emacs, The GNU Emacs Manual}. +@cindex X display names +@cindex display name on X A single X server can handle more than one display. Each X display -has a three-part name, @samp{@var{host}:@var{server}.@var{screen}}. -The first two parts, @var{host} and @var{server}, identify the X -server; the third part, @var{screen}, identifies a screen number on -that X server. When you use two or more screens belonging to one -server, Emacs knows by the similarity in their names that they share a -single keyboard. +has a three-part name, +@samp{@var{hostname}:@var{displaynumber}.@var{screennumber}}. The +first part, @var{hostname}, specifies the name of the machine to which +the display is physically connected. The second part, +@var{displaynumber}, is a zero-based number that identifies one or +more monitors connected to that machine that share a common keyboard +and pointing device (mouse, tablet, etc.). The third part, +@var{screennumber}, identifies a zero-based screen number (a separate +monitor) that is part of a single monitor collection on that X server. +When you use two or more screens belonging to one server, Emacs knows +by the similarity in their names that they share a single keyboard. + + Systems that don't use the X window system, such as MS-Windows, +don't support the notion of X displays, and have only one display on +each host. The display name on these systems doesn't follow the above +3-part format; for example, the display name on MS-Windows systems is +a constant string @samp{w32}, and exists for compatibility, so that +you could pass it to functions that expect a display name. @deffn Command make-frame-on-display display &optional parameters This function creates and returns a new frame on @var{display}, taking @@ -320,19 +341,27 @@ to obtain information about such setups. @defun display-monitor-attributes-list &optional display This function returns a list of physical monitor attributes on -@var{display}, which defaults to that of the selected frame. -Each element of the list is an association list, representing the -attributes of a physical monitor. The first element corresponds to -the primary monitor. The attribute keys and values are: +@var{display}, which can be a display name (a string), a terminal, or +a frame; if omitted or @code{nil}, it defaults to the selected frame's +display. Each element of the list is an association list, +representing the attributes of a physical monitor. The first element +corresponds to the primary monitor. The attribute keys and values +are: @table @samp @item geometry -Position and size in pixels as @samp{(@var{x} @var{y} -@var{width} @var{height})}. +Position of the top-left corner of the monitor's screen and its size, +in pixels, as @samp{(@var{x} @var{y} @var{width} @var{height})}. Note +that, if the monitor is not the primary monitor, some of the +coordinates might be negative. @item workarea -Position and size of the work area in pixels as -@samp{(@var{x} @var{y} @var{width} @var{height})}. +Position of the top-left corner and size of the work area in pixels as +@samp{(@var{x} @var{y} @var{width} @var{height})}. This is different +from @samp{geometry} in that the various system windows, such as the +task bar and side bar, are excluded from the work area. Note that, if +the monitor is not the primary monitor, some of the coordinates might +be negative. @item mm-size Width and height in millimeters as @samp{(@var{width} @var{height})} @@ -353,6 +382,27 @@ does not intersect any physical monitors) that monitor is the closest to the frame. Every (non-tooltip) frame (whether visible or not) in a graphical display is dominated by exactly one physical monitor at a time, though the frame can span multiple (or no) physical monitors. + +Here's an example of the data produced by this function on a 2-monitor +display: + +@smalllisp + (display-monitor-attributes-list) + @result{} + (((geometry 0 0 1920 1080) ;; Left hand monitor + (workarea 0 0 1920 1050) ;; Bottom of screen used for task bar + task bar + (mm-size 677 381) + (name . "\\\\.\\DISPLAY1") + (frames # + #)) + ((geometry 1920 0 1680 1050) ;; Right hand monitor + (workarea 1920 0 1680 1050) ;; Whole screen can be used + (mm-size 593 370) + (name . "\\\\.\\DISPLAY2") + (frames))) +@end smalllisp + @end defun @defun frame-monitor-attributes &optional frame @@ -529,8 +579,9 @@ frame. @code{title} and @code{name} are meaningful on all terminals. @vindex display, a frame parameter @item display The display on which to open this frame. It should be a string of the -form @code{"@var{host}:@var{dpy}.@var{screen}"}, just like the -@env{DISPLAY} environment variable. +form @samp{@var{host}:@var{dpy}.@var{screen}}, just like the +@env{DISPLAY} environment variable. @xref{Multiple Terminals}, for +more details about display names. @vindex display-type, a frame parameter @item display-type @@ -586,12 +637,14 @@ right screen edge. @item @code{(+ @var{pos})} This specifies the position of the left frame edge relative to the left screen edge. The integer @var{pos} may be positive or negative; a -negative value specifies a position outside the screen. +negative value specifies a position outside the screen or on a monitor +other than the primary one (for multi-monitor displays). @item @code{(- @var{pos})} This specifies the position of the right frame edge relative to the right screen edge. The integer @var{pos} may be positive or negative; a -negative value specifies a position outside the screen. +negative value specifies a position outside the screen or on a monitor +other than the primary one (for multi-monitor displays). @end table Some window managers ignore program-specified positions. If you want to diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 5045e5d1469..e8fd37925fa 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,16 @@ +2014-10-08 Eli Zaretskii + + * faces.el (display-grayscale-p): Mention in the doc string that + the argument can be either a display name or a frame. + + * frame.el (display-pixel-height, display-pixel-width) + (display-mm-height, display-mm-width, display-backing-store) + (display-save-under, display-planes, display-color-cells) + (display-visual-class, display-monitor-attributes-list) + (display-screens): Mention in the doc string that the argument can + be either a display name or a frame. Improve the docs of the + monitor attributes. (Bug#18636) + 2014-10-06 Martin Rudalics * term.el (term-window-width): Subtract 1 from the width when diff --git a/lisp/faces.el b/lisp/faces.el index f316245d165..20665286b4f 100644 --- a/lisp/faces.el +++ b/lisp/faces.el @@ -1814,7 +1814,9 @@ If omitted or nil, that stands for the selected frame's display." (declare-function x-display-grayscale-p "xfns.c" (&optional terminal)) (defun display-grayscale-p (&optional display) - "Return non-nil if frames on DISPLAY can display shades of gray." + "Return non-nil if frames on DISPLAY can display shades of gray. +DISPLAY should be either a frame or a display name (a string). +If omitted or nil, that stands for the selected frame's display." (let ((frame-type (framep-on-display display))) (cond ((memq frame-type '(x w32 ns)) diff --git a/lisp/frame.el b/lisp/frame.el index f4d7622e662..9ab24cefc0f 100644 --- a/lisp/frame.el +++ b/lisp/frame.el @@ -1381,6 +1381,7 @@ frame's display)." (defun display-screens (&optional display) "Return the number of screens associated with DISPLAY. +DISPLAY should be either a frame or a display name (a string). If DISPLAY is omitted or nil, it defaults to the selected frame's display." (let ((frame-type (framep-on-display display))) (cond @@ -1393,6 +1394,7 @@ If DISPLAY is omitted or nil, it defaults to the selected frame's display." (defun display-pixel-height (&optional display) "Return the height of DISPLAY's screen in pixels. +DISPLAY can be a display name or a frame. If DISPLAY is omitted or nil, it defaults to the selected frame's display. For character terminals, each character counts as a single pixel. @@ -1412,6 +1414,7 @@ with DISPLAY. To get information for each physical monitor, use (defun display-pixel-width (&optional display) "Return the width of DISPLAY's screen in pixels. +DISPLAY can be a display name or a frame. If DISPLAY is omitted or nil, it defaults to the selected frame's display. For character terminals, each character counts as a single pixel. @@ -1450,6 +1453,7 @@ not explicitly specified." (defun display-mm-height (&optional display) "Return the height of DISPLAY's screen in millimeters. If the information is unavailable, this function returns nil. +DISPLAY can be a display name or a frame. If DISPLAY is omitted or nil, it defaults to the selected frame's display. You can override what the system thinks the result should be by @@ -1470,6 +1474,7 @@ monitor, use `display-monitor-attributes-list'." (defun display-mm-width (&optional display) "Return the width of DISPLAY's screen in millimeters. If the information is unavailable, this function returns nil. +DISPLAY can be a display name or a frame. If DISPLAY is omitted or nil, it defaults to the selected frame's display. You can override what the system thinks the result should be by @@ -1493,6 +1498,7 @@ monitor, use `display-monitor-attributes-list'." "Return the backing store capability of DISPLAY's screen. The value may be `always', `when-mapped', `not-useful', or nil if the question is inapplicable to a certain kind of display. +DISPLAY can be a display name or a frame. If DISPLAY is omitted or nil, it defaults to the selected frame's display." (let ((frame-type (framep-on-display display))) (cond @@ -1505,6 +1511,7 @@ If DISPLAY is omitted or nil, it defaults to the selected frame's display." (defun display-save-under (&optional display) "Return non-nil if DISPLAY's screen supports the SaveUnder feature. +DISPLAY can be a display name or a frame. If DISPLAY is omitted or nil, it defaults to the selected frame's display." (let ((frame-type (framep-on-display display))) (cond @@ -1517,6 +1524,7 @@ If DISPLAY is omitted or nil, it defaults to the selected frame's display." (defun display-planes (&optional display) "Return the number of planes supported by DISPLAY. +DISPLAY can be a display name or a frame. If DISPLAY is omitted or nil, it defaults to the selected frame's display." (let ((frame-type (framep-on-display display))) (cond @@ -1531,6 +1539,7 @@ If DISPLAY is omitted or nil, it defaults to the selected frame's display." (defun display-color-cells (&optional display) "Return the number of color cells supported by DISPLAY. +DISPLAY can be a display name or a frame. If DISPLAY is omitted or nil, it defaults to the selected frame's display." (let ((frame-type (framep-on-display display))) (cond @@ -1547,6 +1556,7 @@ If DISPLAY is omitted or nil, it defaults to the selected frame's display." "Return the visual class of DISPLAY. The value is one of the symbols `static-gray', `gray-scale', `static-color', `pseudo-color', `true-color', or `direct-color'. +DISPLAY can be a display name or a frame. If DISPLAY is omitted or nil, it defaults to the selected frame's display." (let ((frame-type (framep-on-display display))) (cond @@ -1567,6 +1577,7 @@ If DISPLAY is omitted or nil, it defaults to the selected frame's display." (defun display-monitor-attributes-list (&optional display) "Return a list of physical monitor attributes on DISPLAY. +DISPLAY can be a display name, a terminal name, or a frame. If DISPLAY is omitted or nil, it defaults to the selected frame's display. Each element of the list represents the attributes of a physical monitor. The first element corresponds to the primary monitor. @@ -1576,14 +1587,16 @@ of attribute keys and values as follows: geometry -- Position and size in pixels in the form of (X Y WIDTH HEIGHT) workarea -- Position and size of the work area in pixels in the - form of (X Y WIDTH HEIGHT) + form of (X Y WIDTH HEIGHT); this excludes task bar etc. mm-size -- Width and height in millimeters in the form of (WIDTH HEIGHT) frames -- List of frames dominated by the physical monitor name (*) -- Name of the physical monitor as a string -where X, Y, WIDTH, and HEIGHT are integers. Keys labeled -with (*) are optional. +where X, Y, WIDTH, and HEIGHT are integers, which might be negative +for monitors other than the primary one. X and Y are coordinates +of the top-left corner of the rectange. Keys labeled with (*) are +optional. A frame is dominated by a physical monitor when either the largest area of the frame resides in the monitor, or the monitor -- cgit v1.2.1 From c7bfd98a574f9a502f2144271333521aabd58f02 Mon Sep 17 00:00:00 2001 From: Eli Zaretskii Date: Wed, 8 Oct 2014 14:17:13 +0300 Subject: doc/lispref/frames.texi: (Multiple Terminals): Fix last commit. --- doc/lispref/frames.texi | 1 - 1 file changed, 1 deletion(-) diff --git a/doc/lispref/frames.texi b/doc/lispref/frames.texi index cb3fefd7115..97c7b4b0505 100644 --- a/doc/lispref/frames.texi +++ b/doc/lispref/frames.texi @@ -391,7 +391,6 @@ display: @result{} (((geometry 0 0 1920 1080) ;; Left hand monitor (workarea 0 0 1920 1050) ;; Bottom of screen used for task bar - task bar (mm-size 677 381) (name . "\\\\.\\DISPLAY1") (frames # -- cgit v1.2.1 From 285dc437722044fe106f48d202607e4373d795ee Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Wed, 8 Oct 2014 15:37:37 -0400 Subject: * lisp/frame.el: Fix doc typo in previous --- lisp/frame.el | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lisp/frame.el b/lisp/frame.el index 9ab24cefc0f..55e5899ca4c 100644 --- a/lisp/frame.el +++ b/lisp/frame.el @@ -1595,7 +1595,7 @@ of attribute keys and values as follows: where X, Y, WIDTH, and HEIGHT are integers, which might be negative for monitors other than the primary one. X and Y are coordinates -of the top-left corner of the rectange. Keys labeled with (*) are +of the top-left corner of the rectangle. Keys labeled with (*) are optional. A frame is dominated by a physical monitor when either the -- cgit v1.2.1 From 01058f734a96e6da949c200fb908f06ab8a74909 Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Wed, 8 Oct 2014 20:47:30 -0400 Subject: Doc tweaks * doc/lispref/frames.texi (Multiple Terminals): Copyedits. * lisp/frame.el (display-monitor-attributes-list): Doc tweaks. * nt/README.W32, src/ChangeLog.10, src/w32term.c: Standardize on "taskbar" rather than "task bar", since that is what most references seem to use; e.g. http://en.wikipedia.org/wiki/Taskbar http://windows.microsoft.com/en-us/windows7/products/features/windows-taskbar --- doc/lispref/ChangeLog | 4 ++++ doc/lispref/frames.texi | 28 +++++++++++++++++----------- lisp/ChangeLog | 4 ++++ lisp/frame.el | 19 ++++++++++++++----- nt/README.W32 | 2 +- src/ChangeLog.10 | 2 +- src/w32term.c | 2 +- 7 files changed, 42 insertions(+), 19 deletions(-) diff --git a/doc/lispref/ChangeLog b/doc/lispref/ChangeLog index 36497470705..2ebd1bc9e52 100644 --- a/doc/lispref/ChangeLog +++ b/doc/lispref/ChangeLog @@ -1,3 +1,7 @@ +2014-10-09 Glenn Morris + + * frames.texi (Multiple Terminals): Copyedits. + 2014-10-08 Eli Zaretskii * frames.texi (Multiple Terminals): Improve the description of X diff --git a/doc/lispref/frames.texi b/doc/lispref/frames.texi index 97c7b4b0505..78679b877e4 100644 --- a/doc/lispref/frames.texi +++ b/doc/lispref/frames.texi @@ -356,12 +356,14 @@ that, if the monitor is not the primary monitor, some of the coordinates might be negative. @item workarea -Position of the top-left corner and size of the work area in pixels as -@samp{(@var{x} @var{y} @var{width} @var{height})}. This is different -from @samp{geometry} in that the various system windows, such as the -task bar and side bar, are excluded from the work area. Note that, if -the monitor is not the primary monitor, some of the coordinates might -be negative. +Position of the top-left corner and size of the work area (``usable'' +space) in pixels as @samp{(@var{x} @var{y} @var{width} @var{height})}. +This may be different from @samp{geometry} in that space occupied by +various window manager features (docks, taskbars, etc.) may be +excluded from the work area. Whether or not such features actually +subtract from the work area depends on the platform and environment. +Again, if the monitor is not the primary monitor, some of the +coordinates might be negative. @item mm-size Width and height in millimeters as @samp{(@var{width} @var{height})} @@ -371,10 +373,14 @@ List of frames that this physical monitor dominates (see below). @item name Name of the physical monitor as @var{string}. + +@item source +Source of the multi-monitor information as @var{string}; +e.g., @samp{XRandr} or @samp{Xinerama}. @end table @var{x}, @var{y}, @var{width}, and @var{height} are integers. -@samp{name} may not be present. +@samp{name} and @samp{source} may be absent. A frame is @dfn{dominated} by a physical monitor when either the largest area of the frame resides in that monitor, or (if the frame @@ -389,14 +395,14 @@ display: @smalllisp (display-monitor-attributes-list) @result{} - (((geometry 0 0 1920 1080) ;; Left hand monitor - (workarea 0 0 1920 1050) ;; Bottom of screen used for task bar + (((geometry 0 0 1920 1080) ;; @r{Left-hand, primary monitor} + (workarea 0 0 1920 1050) ;; @r{A taskbar occupies some of the height} (mm-size 677 381) (name . "\\\\.\\DISPLAY1") (frames # #)) - ((geometry 1920 0 1680 1050) ;; Right hand monitor - (workarea 1920 0 1680 1050) ;; Whole screen can be used + ((geometry 1920 0 1680 1050) ;; @r{Right-hand monitor} + (workarea 1920 0 1680 1050) ;; @r{Whole screen can be used} (mm-size 593 370) (name . "\\\\.\\DISPLAY2") (frames))) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index e8fd37925fa..6831c0efb42 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,7 @@ +2014-10-09 Glenn Morris + + * frame.el (display-monitor-attributes-list): Doc tweaks. + 2014-10-08 Eli Zaretskii * faces.el (display-grayscale-p): Mention in the doc string that diff --git a/lisp/frame.el b/lisp/frame.el index 55e5899ca4c..08d4a136e1c 100644 --- a/lisp/frame.el +++ b/lisp/frame.el @@ -1587,16 +1587,25 @@ of attribute keys and values as follows: geometry -- Position and size in pixels in the form of (X Y WIDTH HEIGHT) workarea -- Position and size of the work area in pixels in the - form of (X Y WIDTH HEIGHT); this excludes task bar etc. + form of (X Y WIDTH HEIGHT) mm-size -- Width and height in millimeters in the form of (WIDTH HEIGHT) frames -- List of frames dominated by the physical monitor name (*) -- Name of the physical monitor as a string + source (*) -- Source of multi-monitor information as a string -where X, Y, WIDTH, and HEIGHT are integers, which might be negative -for monitors other than the primary one. X and Y are coordinates -of the top-left corner of the rectangle. Keys labeled with (*) are -optional. +where X, Y, WIDTH, and HEIGHT are integers. X and Y are coordinates +of the top-left corner, and might be negative for monitors other than +the primary one. Keys labeled with (*) are optional. + +The \"work area\" is a measure of the \"usable\" display space. +It may be less than the total screen size, owing to space taken up +by window manager features (docks, taskbars, etc.). The precise +details depend on the platform and environment. + +The `source' attribute describes the source from which the information +was obtained. On X, this may be one of: \"Gdk\", \"XRandr\", \"Xinerama\", +or \"fallback\". A frame is dominated by a physical monitor when either the largest area of the frame resides in the monitor, or the monitor diff --git a/nt/README.W32 b/nt/README.W32 index c4e4cf351d4..c73b3b3ad09 100644 --- a/nt/README.W32 +++ b/nt/README.W32 @@ -220,7 +220,7 @@ See the end of the file for license conditions. key in HKEY_CURRENT_USER. Just delete the whole Software\GNU\Emacs key. - The Start menu entry can be removed by right-clicking on the Task bar + The Start menu entry can be removed by right-clicking on the Taskbar and selecting Properties, then using the Remove option on the Start Menu Programs page. (If you installed under an account with administrator privileges, then you need to click the Advanced button diff --git a/src/ChangeLog.10 b/src/ChangeLog.10 index 19adb22b869..1b77eaf5803 100644 --- a/src/ChangeLog.10 +++ b/src/ChangeLog.10 @@ -3264,7 +3264,7 @@ * w32term.c (x_make_frame_visible): Use SystemParametersInfo with SPI_GETWORKAREA to find the dimensions of the screen work area, and adjust vertical position of the frame in order to avoid being - covered by the task bar. + covered by the taskbar. * w32fns.c (w32_createwindow): Use CW_USEDEFAULT instead of f->left_pos and SH_SHOW instead of f->top_pos in the call to diff --git a/src/w32term.c b/src/w32term.c index 5a053b4fc0d..66cdbfaecb0 100644 --- a/src/w32term.c +++ b/src/w32term.c @@ -5959,7 +5959,7 @@ x_make_frame_visible (struct frame *f) RECT window_rect; /* Adjust vertical window position in order to avoid being - covered by a task bar placed at the bottom of the desktop. */ + covered by a taskbar placed at the bottom of the desktop. */ SystemParametersInfo (SPI_GETWORKAREA, 0, &workarea_rect, 0); GetWindowRect (FRAME_W32_WINDOW (f), &window_rect); if (window_rect.bottom > workarea_rect.bottom -- cgit v1.2.1 From 942a57a2a5c56575a15dd22e1feebd1825f281b0 Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Wed, 8 Oct 2014 21:09:10 -0400 Subject: * doc/lispref/frames.texi: Tweak previous tweaks. --- doc/lispref/frames.texi | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/doc/lispref/frames.texi b/doc/lispref/frames.texi index 78679b877e4..d5617ed3cfd 100644 --- a/doc/lispref/frames.texi +++ b/doc/lispref/frames.texi @@ -392,21 +392,21 @@ time, though the frame can span multiple (or no) physical monitors. Here's an example of the data produced by this function on a 2-monitor display: -@smalllisp +@lisp (display-monitor-attributes-list) @result{} (((geometry 0 0 1920 1080) ;; @r{Left-hand, primary monitor} (workarea 0 0 1920 1050) ;; @r{A taskbar occupies some of the height} (mm-size 677 381) - (name . "\\\\.\\DISPLAY1") - (frames # - #)) + (name . "DISPLAY1") + (frames # + #)) ((geometry 1920 0 1680 1050) ;; @r{Right-hand monitor} (workarea 1920 0 1680 1050) ;; @r{Whole screen can be used} (mm-size 593 370) - (name . "\\\\.\\DISPLAY2") + (name . "DISPLAY2") (frames))) -@end smalllisp +@end lisp @end defun -- cgit v1.2.1