all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* Re: master a739cab6637 2/2: ; * doc/lispref/display.texi (Image Descriptors): Insert missing text.
       [not found] ` <20240603083643.B2E29C009F4@vcs2.savannah.gnu.org>
@ 2024-06-03 11:27   ` Robert Pluim
  2024-06-06 12:01     ` Eli Zaretskii
  0 siblings, 1 reply; 12+ messages in thread
From: Robert Pluim @ 2024-06-03 11:27 UTC (permalink / raw)
  To: emacs-devel; +Cc: Po Lu

>>>>> On Mon,  3 Jun 2024 04:36:43 -0400 (EDT), Po Lu via Mailing list for Emacs changes <emacs-diffs@gnu.org> said:

    Po Lu> branch: master
    Po Lu> commit a739cab66378a367cef8fa3a59f7ccb70a56bbb4
    Po Lu> Author: Po Lu <luangruo@yahoo.com>
    Po Lu> Commit: Po Lu <luangruo@yahoo.com>


The text now reads

    @vindex image-scaling-factor
    Alternatively, the symbol @code{default} may be specified, indicating
    that the image should be scaled according as the value of the
    @code{image-scaling-factor} variable is the default @code{auto} or a
    number, which by default scales the image in proportion to the average
    widths (@pxref{Low-Level Font}) of the default faces of frames on which
    it happens to be displayed, if such widths should exceed @code{10}
    pixels.  If no other value is provided, @code{create-image} will specify
    this value in image specifications it creates.

which apart from saying 'according as' rather than 'according to' is
completely incomprehensible to me.

Robert
-- 



^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: master a739cab6637 2/2: ; * doc/lispref/display.texi (Image Descriptors): Insert missing text.
  2024-06-03 11:27   ` master a739cab6637 2/2: ; * doc/lispref/display.texi (Image Descriptors): Insert missing text Robert Pluim
@ 2024-06-06 12:01     ` Eli Zaretskii
  2024-06-06 13:18       ` Po Lu
  0 siblings, 1 reply; 12+ messages in thread
From: Eli Zaretskii @ 2024-06-06 12:01 UTC (permalink / raw)
  To: Robert Pluim, luangruo; +Cc: emacs-devel

> From: Robert Pluim <rpluim@gmail.com>
> Cc: Po Lu <luangruo@yahoo.com>
> Date: Mon, 03 Jun 2024 13:27:22 +0200
> 
> >>>>> On Mon,  3 Jun 2024 04:36:43 -0400 (EDT), Po Lu via Mailing list for Emacs changes <emacs-diffs@gnu.org> said:
> 
>     Po Lu> branch: master
>     Po Lu> commit a739cab66378a367cef8fa3a59f7ccb70a56bbb4
>     Po Lu> Author: Po Lu <luangruo@yahoo.com>
>     Po Lu> Commit: Po Lu <luangruo@yahoo.com>
> 
> 
> The text now reads
> 
>     @vindex image-scaling-factor
>     Alternatively, the symbol @code{default} may be specified, indicating
>     that the image should be scaled according as the value of the
>     @code{image-scaling-factor} variable is the default @code{auto} or a
>     number, which by default scales the image in proportion to the average
>     widths (@pxref{Low-Level Font}) of the default faces of frames on which
>     it happens to be displayed, if such widths should exceed @code{10}
>     pixels.  If no other value is provided, @code{create-image} will specify
>     this value in image specifications it creates.
> 
> which apart from saying 'according as' rather than 'according to' is
> completely incomprehensible to me.

Agreed.  Po Lu, can you please fix that text?



^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: master a739cab6637 2/2: ; * doc/lispref/display.texi (Image Descriptors): Insert missing text.
  2024-06-06 12:01     ` Eli Zaretskii
@ 2024-06-06 13:18       ` Po Lu
  2024-06-06 13:39         ` Eli Zaretskii
  0 siblings, 1 reply; 12+ messages in thread
From: Po Lu @ 2024-06-06 13:18 UTC (permalink / raw)
  To: Eli Zaretskii; +Cc: Robert Pluim, emacs-devel

Eli Zaretskii <eliz@gnu.org> writes:

>> From: Robert Pluim <rpluim@gmail.com>
>> Cc: Po Lu <luangruo@yahoo.com>
>> Date: Mon, 03 Jun 2024 13:27:22 +0200
>> 
>> >>>>> On Mon, 3 Jun 2024 04:36:43 -0400 (EDT), Po Lu via Mailing
>> list for Emacs changes <emacs-diffs@gnu.org> said:
>> 
>>     Po Lu> branch: master
>>     Po Lu> commit a739cab66378a367cef8fa3a59f7ccb70a56bbb4
>>     Po Lu> Author: Po Lu <luangruo@yahoo.com>
>>     Po Lu> Commit: Po Lu <luangruo@yahoo.com>
>> 
>> 
>> The text now reads
>> 
>>     @vindex image-scaling-factor
>>     Alternatively, the symbol @code{default} may be specified, indicating
>>     that the image should be scaled according as the value of the
>>     @code{image-scaling-factor} variable is the default @code{auto} or a
>>     number, which by default scales the image in proportion to the average
>>     widths (@pxref{Low-Level Font}) of the default faces of frames on which
>>     it happens to be displayed, if such widths should exceed @code{10}
>>     pixels.  If no other value is provided, @code{create-image} will specify
>>     this value in image specifications it creates.
>> 
>> which apart from saying 'according as' rather than 'according to' is
>> completely incomprehensible to me.
>
> Agreed.  Po Lu, can you please fix that text?

Is it "according as XXX or YYY" that is incomprehensible to both of you,
or just the punctuation?  "According to whether XXX or YYY" is not
appropriate in this context, I think, as it implies that the choice
between the two options is the only factor that affects the image's
scaling, while there is really also the value of the variable that the
latter option refers to, whose values and their effects are elaborated
immediately afterwards.



^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: master a739cab6637 2/2: ; * doc/lispref/display.texi (Image Descriptors): Insert missing text.
  2024-06-06 13:18       ` Po Lu
@ 2024-06-06 13:39         ` Eli Zaretskii
  2024-06-06 13:58           ` Po Lu
  0 siblings, 1 reply; 12+ messages in thread
From: Eli Zaretskii @ 2024-06-06 13:39 UTC (permalink / raw)
  To: Po Lu; +Cc: rpluim, emacs-devel

> From: Po Lu <luangruo@yahoo.com>
> Cc: Robert Pluim <rpluim@gmail.com>,  emacs-devel@gnu.org
> Date: Thu, 06 Jun 2024 21:18:44 +0800
> 
> Eli Zaretskii <eliz@gnu.org> writes:
> 
> >>     @vindex image-scaling-factor
> >>     Alternatively, the symbol @code{default} may be specified, indicating
> >>     that the image should be scaled according as the value of the
> >>     @code{image-scaling-factor} variable is the default @code{auto} or a
> >>     number, which by default scales the image in proportion to the average
> >>     widths (@pxref{Low-Level Font}) of the default faces of frames on which
> >>     it happens to be displayed, if such widths should exceed @code{10}
> >>     pixels.  If no other value is provided, @code{create-image} will specify
> >>     this value in image specifications it creates.
> >> 
> >> which apart from saying 'according as' rather than 'according to' is
> >> completely incomprehensible to me.
> >
> > Agreed.  Po Lu, can you please fix that text?
> 
> Is it "according as XXX or YYY" that is incomprehensible to both of you,
> or just the punctuation?

The entire paragraph is incomprehensible.  I simply don't understand
what you wanted to say there.  Perhaps explain it in simple words, and
then I will be able to suggest how to rephrase.



^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: master a739cab6637 2/2: ; * doc/lispref/display.texi (Image Descriptors): Insert missing text.
  2024-06-06 13:39         ` Eli Zaretskii
@ 2024-06-06 13:58           ` Po Lu
  2024-06-06 14:04             ` Robert Pluim
  2024-06-06 15:08             ` Eli Zaretskii
  0 siblings, 2 replies; 12+ messages in thread
From: Po Lu @ 2024-06-06 13:58 UTC (permalink / raw)
  To: Eli Zaretskii; +Cc: rpluim, emacs-devel

Eli Zaretskii <eliz@gnu.org> writes:

>> From: Po Lu <luangruo@yahoo.com>
>> Cc: Robert Pluim <rpluim@gmail.com>,  emacs-devel@gnu.org
>> Date: Thu, 06 Jun 2024 21:18:44 +0800
>> 
>> Eli Zaretskii <eliz@gnu.org> writes:
>> 
>> >>     @vindex image-scaling-factor
>> >>     Alternatively, the symbol @code{default} may be specified, indicating
>> >>     that the image should be scaled according as the value of the
>> >>     @code{image-scaling-factor} variable is the default @code{auto} or a
>> >>     number, which by default scales the image in proportion to the average
>> >>     widths (@pxref{Low-Level Font}) of the default faces of frames on which
>> >>     it happens to be displayed, if such widths should exceed @code{10}
>> >>     pixels.  If no other value is provided, @code{create-image} will specify
>> >>     this value in image specifications it creates.
>> >> 
>> >> which apart from saying 'according as' rather than 'according to' is
>> >> completely incomprehensible to me.
>> >
>> > Agreed.  Po Lu, can you please fix that text?
>> 
>> Is it "according as XXX or YYY" that is incomprehensible to both of you,
>> or just the punctuation?
>
> The entire paragraph is incomprehensible.  I simply don't understand
> what you wanted to say there.  Perhaps explain it in simple words, and
> then I will be able to suggest how to rephrase.

How's this?

Alternatively, the symbol @code{default} may be specified, indicating
that the image should be scaled in one of two ways, selected by the
value of the @code{image-scaling-factor} variable.  This value is either
a number providing a constant scale factor, or the default, @code{auto},
in which case the image will be scaled in proportion to the average
widths (@pxref{Low-Level Font}) of the default faces of frames on which
it is displayed and where this default width exceeds @code{10} pixels.
If no other value is provided, @code{create-image} will specify
@code{default} in image specifications it creates.



^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: master a739cab6637 2/2: ; * doc/lispref/display.texi (Image Descriptors): Insert missing text.
  2024-06-06 13:58           ` Po Lu
@ 2024-06-06 14:04             ` Robert Pluim
  2024-06-06 15:08             ` Eli Zaretskii
  1 sibling, 0 replies; 12+ messages in thread
From: Robert Pluim @ 2024-06-06 14:04 UTC (permalink / raw)
  To: Po Lu; +Cc: Eli Zaretskii, emacs-devel

>>>>> On Thu, 06 Jun 2024 21:58:20 +0800, Po Lu <luangruo@yahoo.com> said:

    Po Lu> Eli Zaretskii <eliz@gnu.org> writes:
    >>> From: Po Lu <luangruo@yahoo.com>
    >>> Cc: Robert Pluim <rpluim@gmail.com>,  emacs-devel@gnu.org
    >>> Date: Thu, 06 Jun 2024 21:18:44 +0800
    >>> 
    >>> Eli Zaretskii <eliz@gnu.org> writes:
    >>> 
    >>> >>     @vindex image-scaling-factor
    >>> >>     Alternatively, the symbol @code{default} may be specified, indicating
    >>> >>     that the image should be scaled according as the value of the
    >>> >>     @code{image-scaling-factor} variable is the default @code{auto} or a
    >>> >>     number, which by default scales the image in proportion to the average
    >>> >>     widths (@pxref{Low-Level Font}) of the default faces of frames on which
    >>> >>     it happens to be displayed, if such widths should exceed @code{10}
    >>> >>     pixels.  If no other value is provided, @code{create-image} will specify
    >>> >>     this value in image specifications it creates.
    >>> >> 
    >>> >> which apart from saying 'according as' rather than 'according to' is
    >>> >> completely incomprehensible to me.
    >>> >
    >>> > Agreed.  Po Lu, can you please fix that text?
    >>> 
    >>> Is it "according as XXX or YYY" that is incomprehensible to both of you,
    >>> or just the punctuation?
    >> 
    >> The entire paragraph is incomprehensible.  I simply don't understand
    >> what you wanted to say there.  Perhaps explain it in simple words, and
    >> then I will be able to suggest how to rephrase.

    Po Lu> How's this?

    Po Lu> Alternatively, the symbol @code{default} may be specified, indicating
    Po Lu> that the image should be scaled in one of two ways, selected by the
    Po Lu> value of the @code{image-scaling-factor} variable.  This value is either
    Po Lu> a number providing a constant scale factor, or the default, @code{auto},
    Po Lu> in which case the image will be scaled in proportion to the average
    Po Lu> widths (@pxref{Low-Level Font}) of the default faces of frames on which
    Po Lu> it is displayed and where this default width exceeds @code{10} pixels.
    Po Lu> If no other value is provided, @code{create-image} will specify
    Po Lu> @code{default} in image specifications it creates.

That reads a lot better, thanks.

Robert
-- 



^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: master a739cab6637 2/2: ; * doc/lispref/display.texi (Image Descriptors): Insert missing text.
  2024-06-06 13:58           ` Po Lu
  2024-06-06 14:04             ` Robert Pluim
@ 2024-06-06 15:08             ` Eli Zaretskii
  2024-06-07  0:14               ` Po Lu
  1 sibling, 1 reply; 12+ messages in thread
From: Eli Zaretskii @ 2024-06-06 15:08 UTC (permalink / raw)
  To: Po Lu; +Cc: rpluim, emacs-devel

> From: Po Lu <luangruo@yahoo.com>
> Cc: rpluim@gmail.com,  emacs-devel@gnu.org
> Date: Thu, 06 Jun 2024 21:58:20 +0800
> 
> How's this?
> 
> Alternatively, the symbol @code{default} may be specified, indicating
> that the image should be scaled in one of two ways, selected by the
> value of the @code{image-scaling-factor} variable.  This value is either
> a number providing a constant scale factor, or the default, @code{auto},
> in which case the image will be scaled in proportion to the average
> widths (@pxref{Low-Level Font}) of the default faces of frames on which
> it is displayed and where this default width exceeds @code{10} pixels.
> If no other value is provided, @code{create-image} will specify
> @code{default} in image specifications it creates.

Better, but still "needs work".  Here's my suggestion:

  @var{scale} can also be the symbol @code{default}, which means to
  use the value of @code{image-scaling-factor}.  If that value is a
  number, it is the scale factor to use; if it is @code{auto} (the
  default), it means to compute the scaling factor based on pixel size
  of the font used by the frame's default face (@pxref{Low-Level
  Font}).

And I would like to explain more about "computing the scaling factor
based on pixel size of the font used by the frame's default face", and
what happens if the default font's width is 10 pixels or below, but
your text doesn't really tell that story.  I think it should.  (Btw,
the default width of the font in "emacs -Q" on Windows is 8, so it
will always hit the case which was left unexplained.)

Thanks.



^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: master a739cab6637 2/2: ; * doc/lispref/display.texi (Image Descriptors): Insert missing text.
  2024-06-06 15:08             ` Eli Zaretskii
@ 2024-06-07  0:14               ` Po Lu
  2024-06-07  6:29                 ` Eli Zaretskii
  0 siblings, 1 reply; 12+ messages in thread
From: Po Lu @ 2024-06-07  0:14 UTC (permalink / raw)
  To: Eli Zaretskii; +Cc: rpluim, emacs-devel

Eli Zaretskii <eliz@gnu.org> writes:

> And I would like to explain more about "computing the scaling factor
> based on pixel size of the font used by the frame's default face", and
> what happens if the default font's width is 10 pixels or below, but
> your text doesn't really tell that story.  I think it should.  (Btw,
> the default width of the font in "emacs -Q" on Windows is 8, so it
> will always hit the case which was left unexplained.)

Below 10 pixels, the image is not scaled unless a numeric scale be
provided in image-scaling-factor.  As for the reasoning behind this
arbitrary value, you'll need to ask Lars, whose code I've merely
reproduced in C.

Thanks.



^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: master a739cab6637 2/2: ; * doc/lispref/display.texi (Image Descriptors): Insert missing text.
  2024-06-07  0:14               ` Po Lu
@ 2024-06-07  6:29                 ` Eli Zaretskii
  2024-06-07  8:50                   ` Po Lu
  0 siblings, 1 reply; 12+ messages in thread
From: Eli Zaretskii @ 2024-06-07  6:29 UTC (permalink / raw)
  To: Po Lu; +Cc: rpluim, emacs-devel

> From: Po Lu <luangruo@yahoo.com>
> Cc: rpluim@gmail.com,  emacs-devel@gnu.org
> Date: Fri, 07 Jun 2024 08:14:36 +0800
> 
> Eli Zaretskii <eliz@gnu.org> writes:
> 
> > And I would like to explain more about "computing the scaling factor
> > based on pixel size of the font used by the frame's default face", and
> > what happens if the default font's width is 10 pixels or below, but
> > your text doesn't really tell that story.  I think it should.  (Btw,
> > the default width of the font in "emacs -Q" on Windows is 8, so it
> > will always hit the case which was left unexplained.)
> 
> Below 10 pixels, the image is not scaled unless a numeric scale be
> provided in image-scaling-factor.  As for the reasoning behind this
> arbitrary value, you'll need to ask Lars, whose code I've merely
> reproduced in C.

So this means at least on Windows, where the default font's width is
8, the image will never be scaled in "emacs -Q", am I right?

I think on macOS the default width is 7, so the same will happen there
as well?

What is the default width of the font on GNU/Linux?

And finally, can you tell more about how the scale factor is computed
"based on the font's pixel size"?  Or point me to the code which does
that?  I think some of that should be in the manual, to give the users
some idea of what will happen.

Thanks.



^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: master a739cab6637 2/2: ; * doc/lispref/display.texi (Image Descriptors): Insert missing text.
  2024-06-07  6:29                 ` Eli Zaretskii
@ 2024-06-07  8:50                   ` Po Lu
  2024-06-08 13:20                     ` Eli Zaretskii
  0 siblings, 1 reply; 12+ messages in thread
From: Po Lu @ 2024-06-07  8:50 UTC (permalink / raw)
  To: Eli Zaretskii; +Cc: rpluim, emacs-devel

Eli Zaretskii <eliz@gnu.org> writes:

> So this means at least on Windows, where the default font's width is
> 8, the image will never be scaled in "emacs -Q", am I right?
>
> I think on macOS the default width is 7, so the same will happen there
> as well?
>
> What is the default width of the font on GNU/Linux?

8, though all this is only true when there is no display scale
configured, even on MS-Windows, correct?  This code isn't supposed to
activate when the display density isn't so high as to require font
scaling, and in the other case the default font width will be scaled
beyond 10 pixels.

> And finally, can you tell more about how the scale factor is computed
> "based on the font's pixel size"?  Or point me to the code which does
> that?  I think some of that should be in the manual, to give the users
> some idea of what will happen.

See line 2699 of image.c.



^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: master a739cab6637 2/2: ; * doc/lispref/display.texi (Image Descriptors): Insert missing text.
  2024-06-07  8:50                   ` Po Lu
@ 2024-06-08 13:20                     ` Eli Zaretskii
  2024-06-08 13:28                       ` Po Lu
  0 siblings, 1 reply; 12+ messages in thread
From: Eli Zaretskii @ 2024-06-08 13:20 UTC (permalink / raw)
  To: Po Lu; +Cc: rpluim, emacs-devel

> From: Po Lu <luangruo@yahoo.com>
> Cc: rpluim@gmail.com,  emacs-devel@gnu.org
> Date: Fri, 07 Jun 2024 16:50:55 +0800
> 
> Eli Zaretskii <eliz@gnu.org> writes:
> 
> > So this means at least on Windows, where the default font's width is
> > 8, the image will never be scaled in "emacs -Q", am I right?
> >
> > I think on macOS the default width is 7, so the same will happen there
> > as well?
> >
> > What is the default width of the font on GNU/Linux?
> 
> 8, though all this is only true when there is no display scale
> configured, even on MS-Windows, correct?  This code isn't supposed to
> activate when the display density isn't so high as to require font
> scaling, and in the other case the default font width will be scaled
> beyond 10 pixels.
> 
> > And finally, can you tell more about how the scale factor is computed
> > "based on the font's pixel size"?  Or point me to the code which does
> > that?  I think some of that should be in the manual, to give the users
> > some idea of what will happen.
> 
> See line 2699 of image.c.

Thanks, I installed some clarifications of this text.



^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: master a739cab6637 2/2: ; * doc/lispref/display.texi (Image Descriptors): Insert missing text.
  2024-06-08 13:20                     ` Eli Zaretskii
@ 2024-06-08 13:28                       ` Po Lu
  0 siblings, 0 replies; 12+ messages in thread
From: Po Lu @ 2024-06-08 13:28 UTC (permalink / raw)
  To: Eli Zaretskii; +Cc: rpluim, emacs-devel

Eli Zaretskii <eliz@gnu.org> writes:

> Thanks, I installed some clarifications of this text.

Thanks.



^ permalink raw reply	[flat|nested] 12+ messages in thread

end of thread, other threads:[~2024-06-08 13:28 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
     [not found] <171740380294.31568.538114951586755322@vcs2.savannah.gnu.org>
     [not found] ` <20240603083643.B2E29C009F4@vcs2.savannah.gnu.org>
2024-06-03 11:27   ` master a739cab6637 2/2: ; * doc/lispref/display.texi (Image Descriptors): Insert missing text Robert Pluim
2024-06-06 12:01     ` Eli Zaretskii
2024-06-06 13:18       ` Po Lu
2024-06-06 13:39         ` Eli Zaretskii
2024-06-06 13:58           ` Po Lu
2024-06-06 14:04             ` Robert Pluim
2024-06-06 15:08             ` Eli Zaretskii
2024-06-07  0:14               ` Po Lu
2024-06-07  6:29                 ` Eli Zaretskii
2024-06-07  8:50                   ` Po Lu
2024-06-08 13:20                     ` Eli Zaretskii
2024-06-08 13:28                       ` Po Lu

Code repositories for project(s) associated with this external index

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

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.