bug-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#10165: [PATCH] Allow setting corner in mouse avoidance mode.


From: Juri Linkov
Subject: bug#10165: [PATCH] Allow setting corner in mouse avoidance mode.
Date: Wed, 07 Dec 2011 19:30:45 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/24.0.92 (x86_64-pc-linux-gnu)

>> Thanks.  I think names like `frame-or-window' and `top-or-bottom-pos'
>> are quite confusing.
>
> Yes, if you have better names tell me.

I think better names would be similar to geometry specification
like in (info "(emacs) Window Size X").

Then we could have such names (with possible values):

  x-side     `left' or `right'
  y-side     `top' or `bottom'
  x-offset   integer (positive, negative or zero)
  y-offset   integer (positive, negative or zero)

So for example it would be possible to customize
`mouse-avoidance-banish-position' to the following setting:

  '((frame-or-window . frame)
    (x-side          . right)
    (x-offset        . 3)
    (y-side          . bottom)
    (y-offset        . -1))

Also `frame-or-window' is too long name, but currently I have no idea
what a shorter name would be better.

>> But fortunately we could avoid them.
>
> Can you develop this?

I think that instead of an alist it would be simpler to use a list
with the fixed meaning of each list element.  I mean something like:

(defcustom mouse-avoidance-banish-position '(frame right 3 bottom -1)
  :type '(list (choice (const frame :tag "Relative to frame coordinates")
                       (const window :tag "Relative to window coordinates"))
               (choice (const left :tag "Relative to left edge")
                       (const right :tag "Relative to right edge"))
               (integer :tag "Horizontal offset")
               (choice (const top :tag "Relative to top edge")
                       (const bottom :tag "Relative to bottom edge"))
               (integer :tag "Vertical offset")))





reply via email to

[Prev in Thread] Current Thread [Next in Thread]