GNU bug report logs - #56538
29.0.50; [PATCH] Colored highlight in Lucid backend

Previous Next

Package: emacs;

Reported by: Manuel Giraud <manuel <at> ledu-giraud.fr>

Date: Wed, 13 Jul 2022 13:39:02 UTC

Severity: wishlist

Tags: patch

Found in version 29.0.50

Done: Po Lu <luangruo <at> yahoo.com>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: Po Lu <luangruo <at> yahoo.com>
To: Manuel Giraud <manuel <at> ledu-giraud.fr>
Cc: 56538 <at> debbugs.gnu.org
Subject: bug#56538: 29.0.50; [PATCH] Colored highlight in Lucid backend
Date: Thu, 14 Jul 2022 18:34:43 +0800
Manuel Giraud <manuel <at> ledu-giraud.fr> writes:

> I have attached a new version of my patch taking your remarks into
> account but I did not remove this comment.  I think it could be useful
> to understand that "top_gc = something_bottom_gc" is not a typo here.

We have the same general pattern (random_gc = random_opposite_gc) in
most of the X code, so it is redundant IMHO.  But I won't insist.

> I have also done the following testing with Xft/cairo/PseudoColor
> combinations:
>
> |-------------+-----------------+-----------------+-----------------+---------------------|
> |             | Xft + cairo     | Xft only        | cairo only      | None                |
> |-------------+-----------------+-----------------+-----------------+---------------------|
> | X Truecolor | ok              | ok              | ok              | ok but with a       |
> |             |                 |                 |                 | default tiny face   |
> |-------------+-----------------+-----------------+-----------------+---------------------|
> | Xephyr      | ok but color    | ok but color    | ok but color    | ok, colors ok, but  |
> | Pseudocolor | not quite right | not quite right | not quite right | with a default tiny |
> |             | around each     | around menu     | around each     | face [fn:2]         |
> |             | glyph [fn:1]    | labels [fn:2]   | glyph [fn:1]    |                     |
> |-------------+-----------------+-----------------+-----------------+---------------------|
>
> * Footnotes
> [fn:1] Aside from the Lucid widget, the emacs buffer is completly
> blank.

Yes, that isn't expected to work, because Cairo is broken.  Also, you
can't build Emacs with both Xft and Cairo, since they're mutually
exclusive.

> [fn:2] This time the emacs buffer is here. tool-bar icons are ugly.

Could you please describe how the colors are "not quite right"?

One last nit:

> +static void
> +draw_highlight (XlwMenuWidget mw,
> +		Window window,
> +		int x,
> +		int y,
> +		int width,
> +		int height)

[...]

>  static void
> -make_shadow_gcs (XlwMenuWidget mw)
> +compute_shadow_colors (XlwMenuWidget mw,
> +		       Pixel *top_color,
> +		       Pixel *bottom_color,
> +		       Boolean *free_top_p,
> +		       Boolean *free_bottom_p,
> +		       Pixmap *top_pixmap,
> +		       Pixmap *bottom_pixmap,
> +		       Pixel fore_color,
> +		       Pixel back_color)

Here and elsewhere new functions are added, the argument list should be
reformatted to not place each argument on its own line.

Thanks.




This bug report was last modified 3 years and 4 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.