unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
From: Cecilio Pardo <cpardo@imayhem.com>
To: Eli Zaretskii <eliz@gnu.org>
Cc: 73730@debbugs.gnu.org, kbrown@cornell.edu
Subject: bug#73730: 31.0.50; Support for color fonts on MS-Windows
Date: Thu, 17 Oct 2024 12:38:31 +0200	[thread overview]
Message-ID: <c1683be2-86c7-4ad3-ac59-adc678179766@imayhem.com> (raw)
In-Reply-To: <86bjzjp7vv.fsf@gnu.org>

On 17/10/2024 8:21, Eli Zaretskii wrote:

>> Still not done with this, but I am sending a new patch to fix the bug
>> with w32-find-non-USB-fonts.  It calls text_extents with a font of size
>> 0. Checking for that seems to solve the problem.
> 
> Is that really TRT?  What does it mean font_size = 0 in this case?

No, I was wrong, sorry. DirectDwrite is failing to create a font from 
certain GDI fonts. I need to then fall back to w32font. I'm on it.

>> BTW, why does that variable show as undocumented with
>> describe-variables? What am I doing wrong?
> 
> You used DEFVAR_BOOL inside a function.  It should be on the top level
> (look at other places where we define such variables), then
> make-docfile will collect its definition and it will be written to
> etc/DOC.

Thanks.

>> - Instead of aborting on failure, just disable DirectWrite and let emacs
>> continue. This will take some work.
> 
> Instead of disabling DirectWrite, it might be better to fall back on
> previous code -- that way, the glyphs will be shown, but without
> colors.  The trick is to detect this early enough, because some fonts
> AFAIR cannot be displayed using non-dwrite code.

Ok.

>>>> +void *w32_font_get_dwrite_cache (struct font *font, float *font_size);
>>>> +void w32_font_set_dwrite_cache (struct font *font, void *cache, float font_size);
>>>
>>> Why aren't these functions defined in w32dwrite.c?
>>
>> They need to know about the uniscribe_font struct, which is defined there.
> 
> If that's the only reason, we could perhaps move the definition of
> uniscribe_font struct to w32font.h.

Will do that.







  reply	other threads:[~2024-10-17 10:38 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-10-10 11:16 bug#73730: 31.0.50; Support for color fonts on MS-Windows Cecilio Pardo
2024-10-10 13:08 ` Eli Zaretskii
2024-10-10 15:14   ` Cecilio Pardo
2024-10-10 16:33     ` Eli Zaretskii
2024-10-10 16:46       ` Cecilio Pardo
2024-10-15 22:18   ` Cecilio Pardo
2024-10-16 11:01     ` Eli Zaretskii
2024-10-16 11:32       ` Eli Zaretskii
2024-10-16 21:35       ` Cecilio Pardo
2024-10-17  6:21         ` Eli Zaretskii
2024-10-17 10:38           ` Cecilio Pardo [this message]
2024-10-10 21:50 ` Cecilio Pardo
2024-10-11  3:36   ` Eli Zaretskii
2024-10-11  6:28     ` Eli Zaretskii
2024-10-11  7:19       ` Cecilio Pardo

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=c1683be2-86c7-4ad3-ac59-adc678179766@imayhem.com \
    --to=cpardo@imayhem.com \
    --cc=73730@debbugs.gnu.org \
    --cc=eliz@gnu.org \
    --cc=kbrown@cornell.edu \
    /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).