unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
From: Drew Adams <drew.adams@oracle.com>
To: Eli Zaretskii <eliz@gnu.org>
Cc: 20540@debbugs.gnu.org
Subject: bug#20540: 25.0.50; Document tooltip woes, including `help-echo'
Date: Sun, 10 May 2015 09:11:49 -0700 (PDT)	[thread overview]
Message-ID: <f201cc3e-4e6b-4b4a-bce5-08d0ee41c13e@default> (raw)
In-Reply-To: <<83bnhso5u8.fsf@gnu.org>>

> > 3. ... the defcustom for `tooltip-frame-parameters' has no :type...
> 
> I cannot reproduce this one: my tooltip.el has this:

Sorry, my bad.

(Perhaps it was the gratuitous extra blank line after the first
doc-string line that threw me off and made me think the doc string
and definition ended there.  Dunno why such lines are added sometimes.
Those are (minor) bugs, AFAICT.  I don't mean this as an excuse for
my not reading the defcustom more carefully, but it might be the
reason that I was mistaken.)

And I see now that the doc string says that "font and color parameters
are ignored, and the attributes of the `tooltip' face are used instead."
It would be good to add info that to the doc in the manual, IMO.

So yes, there is a :type.  But the :type value should, I think, be
something more like this, not just `sexp':

:type '(alist :key-type   (symbol :tag "Parameter")
              :value-type (sexp :tag "Value"))

The :tag's are not required, but at least the type should be
:alist, I think.  Unless I'm missing something - can it ever be
something besides an alist?

Especially if only some frame parameters are allowed as keys (the
others are ignored, so why allow them for customization?), maybe a
more restrictive type than `symbol' should be used - e.g.
`restricted-sexp' with matching for the allowed symbols.

(You will perhaps argue that we didn't exclude including ignored
parameters before, so this would be an incompatible change.  I can't
really argue against that, except to say that it still might not be
bad to start now, raising an error when you try to add an "ignored"
parameter.)

> > 4. `help-echo': No doc saying whether the string can be
> > propertized, and if so, which properties have any effect.
> > Although `x-show-tip' seems to let you change the char size, color,
> > background color, etc., and you can use property `display' with
> > `help-echo', apparently you cannot change the face attributes of
> > the `help-echo' string so that the appearance
> > changes.  This is quite a limitation, AFAICT.
> 
> See above: the doc string of tooltip-frame-parameters says font and
> color parameters are ignored.

#4 is about `help-echo'.  Search the Elisp manual for `help-echo'.
See node `Special Properties', for instance.  Nowhere does it specify
such limitations, AFAICT.

And font and color parameters are not the only ones ignored.

And see the rest of the bug report, including the part about
`x-show-tip' - which face attributes and which frame parameters
have no effect?  And why is `help-echo' more limited wrt specifying
tooltip appearance than is `x-show-tip'?

There are several things said in the doc or doc strings here and
there about tooltips, but (a) the doc is incomplete and (b) it's not
clear what the relations between the various things are: `help-echo'
string properties, `x-show-tip' frame, `tooltip-frame-parameters'.

Apparently (from experimentation) `x-show-tip' does not bother with
`tooltip-frame-parameters'.

But you seem to be suggesting that a `help-echo' tooltip does, and
that `help-echo' string properties are overridden by
`tooltip-frame-parameters' frame-parameter limitations, and that
all of this should be obvious.  At least that's my guess, based on
your repeating, for #4 (`help-echo'), the info about the doc string
of `tooltip-frame-parameters'.





  parent reply	other threads:[~2015-05-10 16:11 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <<795eb88f-e9e7-4728-82d8-32d0caea52fb@default>
     [not found] ` <<83d229no4x.fsf@gnu.org>
2015-05-10 14:36   ` bug#20540: 25.0.50; Document tooltip woes, including `help-echo' Drew Adams
2015-05-10 15:26     ` Eli Zaretskii
     [not found] ` <<83bnhso5u8.fsf@gnu.org>
2015-05-10 16:11   ` Drew Adams [this message]
2015-05-09 23:27 Drew Adams
2015-05-10  2:48 ` Eli Zaretskii
2015-05-10 14:38 ` Eli Zaretskii
2021-06-22 14:42 ` Lars Ingebrigtsen

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=f201cc3e-4e6b-4b4a-bce5-08d0ee41c13e@default \
    --to=drew.adams@oracle.com \
    --cc=20540@debbugs.gnu.org \
    --cc=eliz@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).