unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
From: YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
To: Eli Zaretskii <eliz@gnu.org>
Cc: emacs-devel@gnu.org
Subject: Re: x-display-pixel-width/height inconsistency
Date: Sun, 24 Mar 2013 08:58:29 +0900	[thread overview]
Message-ID: <wl620hvfbu.wl%mituharu@math.s.chiba-u.ac.jp> (raw)
In-Reply-To: <83mwtu4p7c.fsf@gnu.org>

>>>>> On Sat, 23 Mar 2013 08:15:03 +0200, Eli Zaretskii <eliz@gnu.org> said:

>> > How did you deduce that SM_CXVIRTUALSCREEN and SM_CYVIRTUALSCREEN
>> > are not available on those old systems?  Can you point me to some
>> > documentation which has the details?
>> 
>> http://msdn.microsoft.com/ja-jp/library/cc429812.aspx (in Japanese.
>> But probably you can find "Window 98" and "Windows 2000" around
>> SM_CXVIRTUALSCREEN/SM_CYVIRTUALSCREEN)

> Does it say something like "Starting from Windows 98 and Windows
> 2000"?  That's what I get from other sources on the Internet that
> talk about this subject.

It says "Window 98 AND Windows 2000".  Probably because this document
was written before XP or Me.

> I actually think we should always call GetSystemMetrics, and if that
> returns a failure indication, call the old code.  Testing versions
> is usually less desirable.

Could you check GetSystemMetrics safely returns 0 for unknown
arguments (because I can't test it)?  If so, avoiding version tests
would be better.

>> As I've already mentioned, the elisp info already contains the
>> description about the semantics under multi-monitor setups.
>> 
>> http://lists.gnu.org/archive/html/emacs-devel/2013-03/msg00469.html

> That talks about display-pixel-width/height, while I was talking
> about x-display-pixel-width/height, the primitives where you propose
> the changes.  The latter are not mentioned in the ELisp manual at
> all, so their doc strings are the only source of documentation for
> them.

> Moreover, your changes touch x-display-mm-width/height as well, so
> now display-mm-width/height, whose documentation in the ELisp manual
> doesn't mention multiple terminals at all, will behave differently
> as well.

If these functions behave differently among the platforms on
multi-monitor setups, then they should be named with different
prefixes (i.e., w32-display-*, ns-display-*.  Note that the current
behavior is different even between W32 and NS).  Of course, I prefer
consistent behavior rather than having the different prefix.

>> Please look at my other posts:
>> 
>> http://lists.gnu.org/archive/html/emacs-devel/2013-03/msg00553.html
>> http://lists.gnu.org/archive/html/emacs-devel/2013-03/msg00555.html

> I've read all the thread, and I'm still asking the question, because
> nothing there seems to provide the answer.  Maybe you should re-read
> my question.

> What you say in those messages boils down to

>   . the X11 behavior is documented in the manual

>   . Emacs on X11 cannot distinguish between physical monitors that
> belong to the same display

> As I write above, the first point is only partially true
> (display-mm-width/height are not documented as describing the
> virtual screen, and the x-display-* primitives are not documented at
> all).  As for the second point, I don't see how it can be any
> guideline to make a decision, since both NS and W32 _can_
> distinguish between physical monitors (if we include the appropriate
> code).

> So the question still stands: which behavior should be considered
> "correct" and which a "missing feature".

My whole point is that functions for obtaining properties of each
physical monitor on multi-monitor setups should be provided as a new
function (or a new group of functions), rather than abusing the
existing functions x-display-* on displays primarily designed after
the notion of X11 "display" or "screen".  Users would want to know
several kinds of information about each monitor, such as the geometry
(including the origin) or the workarea, not just about size in pixels.
Tweeking x-display-pixel-width/height in a platform-specific way or
adding functions such as display-usable-bounds in the NS port without
considering the whole design for operations on monitors looks rather
ad hoc to me.

				     YAMAMOTO Mitsuharu
				mituharu@math.s.chiba-u.ac.jp



  parent reply	other threads:[~2013-03-23 23:58 UTC|newest]

Thread overview: 97+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-03-21  0:58 x-display-pixel-width/height inconsistency grischka
2013-03-21  1:05 ` YAMAMOTO Mitsuharu
2013-03-21  1:09   ` grischka
2013-03-21  1:44     ` YAMAMOTO Mitsuharu
2013-03-21 23:29       ` YAMAMOTO Mitsuharu
2013-03-22 10:33         ` Eli Zaretskii
2013-03-23  0:32           ` YAMAMOTO Mitsuharu
2013-03-23  6:15             ` Eli Zaretskii
2013-03-23 13:35               ` Jan Djärv
2013-03-23 23:58               ` YAMAMOTO Mitsuharu [this message]
2013-03-24  3:53                 ` Eli Zaretskii
2013-03-24  4:36                   ` YAMAMOTO Mitsuharu
2013-03-24 16:19                     ` Eli Zaretskii
2013-04-27  5:13                     ` YAMAMOTO Mitsuharu
2013-04-27  8:04                       ` Jan Djärv
2013-04-28  1:40                         ` YAMAMOTO Mitsuharu
2013-04-28 17:16                           ` Jan D.
2013-04-29  2:27                             ` YAMAMOTO Mitsuharu
2013-04-29  2:42                               ` YAMAMOTO Mitsuharu
2013-05-01  9:58                               ` Jan Djärv
2013-05-02  4:09                                 ` YAMAMOTO Mitsuharu
2013-05-06  1:04                                   ` YAMAMOTO Mitsuharu
2013-05-06  1:55                                     ` Stefan Monnier
2013-05-06  6:15                                       ` YAMAMOTO Mitsuharu
2013-05-06 13:37                                         ` Stefan Monnier
2013-05-08 10:46                                         ` YAMAMOTO Mitsuharu
2013-05-08 11:24                                           ` YAMAMOTO Mitsuharu
2013-05-08 17:41                                           ` Eli Zaretskii
2013-05-09  0:09                                             ` YAMAMOTO Mitsuharu
2013-05-09  1:52                                               ` Glenn Morris
2013-05-09  3:19                                                 ` YAMAMOTO Mitsuharu
2013-05-09  6:27                                                   ` Glenn Morris
2013-05-09  2:53                                               ` Eli Zaretskii
2013-05-09  8:14                                               ` Jan Djärv
2013-05-09  8:43                                                 ` YAMAMOTO Mitsuharu
2013-05-09 15:18                                                   ` Jan Djärv
2013-05-09 20:03                                               ` Eli Zaretskii
2013-05-09 21:28                                                 ` Stefan Monnier
2013-05-10  6:00                                                 ` YAMAMOTO Mitsuharu
2013-05-10  6:05                                                   ` YAMAMOTO Mitsuharu
2013-05-10  7:06                                                   ` Eli Zaretskii
2013-05-10  7:47                                                     ` YAMAMOTO Mitsuharu
2013-05-10  8:41                                                       ` Eli Zaretskii
2013-05-10  8:55                                                         ` YAMAMOTO Mitsuharu
2013-05-10  9:15                                                           ` Eli Zaretskii
2013-05-10  9:27                                                             ` YAMAMOTO Mitsuharu
2013-05-14 10:39                                                               ` YAMAMOTO Mitsuharu
2013-07-01  6:49                                                                 ` martin rudalics
2013-07-02  1:30                                                                   ` YAMAMOTO Mitsuharu
2013-07-02 10:38                                                                     ` martin rudalics
2013-07-02 10:53                                                                       ` Juanma Barranquero
2013-07-02 13:11                                                                         ` martin rudalics
2013-07-02 14:05                                                                           ` Juanma Barranquero
2013-07-03  9:27                                                                             ` martin rudalics
2013-07-03 10:49                                                                               ` Juanma Barranquero
2013-07-03 12:44                                                                                 ` martin rudalics
2013-07-03 13:43                                                                                   ` Juanma Barranquero
2013-07-04  9:34                                                                                     ` martin rudalics
     [not found]                                                                                       ` <5987E3>
2013-07-04 22:32                                                                                       ` Juanma Barranquero
2013-07-05  7:44                                                                                         ` martin rudalics
2013-07-05  9:32                                                                                           ` Juanma Barranquero
2013-07-05  9:34                                                                                         ` Jan Djärv
2013-07-05  9:41                                                                                           ` Juanma Barranquero
2013-07-05 11:25                                                                                             ` Jan Djärv
2013-07-05 11:56                                                                                               ` Juanma Barranquero
2013-07-05 12:12                                                                                                 ` Jan Djärv
2013-07-05 12:16                                                                                                   ` Juanma Barranquero
2013-07-05 15:30                                                                                                     ` Drew Adams
2013-07-05 15:53                                                                                                       ` Juanma Barranquero
2013-07-05 16:58                                                                                                         ` Drew Adams
2013-07-06 14:48                                                                                                           ` Juanma Barranquero
2013-07-06 19:25                                                                                                             ` Drew Adams
2013-07-05 15:27                                                                                                   ` Drew Adams
2013-07-04 10:28                                                                                     ` YAMAMOTO Mitsuharu
2013-05-10  7:44                                                   ` Jan Djärv
2013-04-28  1:48                       ` YAMAMOTO Mitsuharu
  -- strict thread matches above, loose matches on Subject: below --
2013-03-19  0:39 YAMAMOTO Mitsuharu
2013-03-19  1:34 ` Leo Liu
2013-03-19  4:54   ` Xue Fuqiao
2013-03-19 15:41     ` Drew Adams
2013-03-19 15:51       ` Leo Liu
2013-03-19 15:58         ` Drew Adams
2013-03-20  0:55           ` Leo Liu
2013-03-19 22:25 ` YAMAMOTO Mitsuharu
2013-03-19 23:15   ` Dmitry Gutov
2013-03-19 23:52     ` YAMAMOTO Mitsuharu
2013-03-20  0:12       ` Dmitry Gutov
2013-03-20  0:20         ` YAMAMOTO Mitsuharu
2013-03-20  1:41           ` Dmitry Gutov
2013-03-20  3:58             ` YAMAMOTO Mitsuharu
2013-03-20 14:05               ` Dmitry Gutov
2013-03-20 23:28                 ` YAMAMOTO Mitsuharu
2013-03-21  1:27                   ` Dmitry Gutov
2013-03-21  1:51                     ` YAMAMOTO Mitsuharu
2013-03-21  2:43                       ` Dmitry Gutov
2013-03-21  3:47                         ` YAMAMOTO Mitsuharu
2013-03-21  4:22                           ` YAMAMOTO Mitsuharu

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=wl620hvfbu.wl%mituharu@math.s.chiba-u.ac.jp \
    --to=mituharu@math.s.chiba-u.ac.jp \
    --cc=eliz@gnu.org \
    --cc=emacs-devel@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).