xterm/xterm-decomposed_bitmaps.patch
Petr Cerny 85c2100f4c Accepting request 528278 from home:pcerny:factory
- Patch #330 - 2017/06/20
  * updates for ReGIS (Ross Combs):
     + remove redundant text command error check which broke
       T(B) and T(E).
     + retain the loading alphabet number across multiple “L”
       commands.
     + add S(T) delay handler.
     + fix some color handling error messages.
     + add stubbed-out macrograph handling.
     + use fragment_remaining() and fragment_consumed() instead
       of manually checking position / length in various places.
     + rename some local variables in string / extent / option
       parsing
     + wrap some long lines.
     + move macrograph command handling out of the top-level.
  * add a summary of the italic fonts loaded to -report-fonts
    option.
  * modify the font-lookup for italics to allow for “-i-” if no
    match is found with slant “-o-” (prompted by patch by Ben
    Wong).
  * change default values for mkSamplePass and mkSampleSize to
    reflect generally-improved locale support in various
    operating systems (FreeBSD #219800).
  * modify wcwidth.c to return -1 for non-Unicode values, and
    adjust a couple of blocks to better match assumptions about
    ambiguous-width characters in other implementations. Also
    modify wcwidth.c to support configurable soft-hyphen, so
    there is no drawback to using this version rather than a
    system wcwidth.
  * amend change made in patch #328 for cursor-visibility to

OBS-URL: https://build.opensuse.org/request/show/528278
OBS-URL: https://build.opensuse.org/package/show/X11:terminals/xterm?expand=0&rev=146
2017-09-22 12:05:44 +00:00

43 lines
1.1 KiB
Diff

From: Egbert Eich <eich@suse.de>
Date: Tue Jun 3 18:17:07 2014 +0200
Subject: [PATCH]Fix number of colormap entries for DirectColor and TrueColor visuals
Patch-mainline: to be upstreamed
Git-commit: 071525466531009223f1c21a40aa2e081d5ef99a
Git-repo:
References: bnc#
Signed-off-by: Egbert Eich <eich@suse.com>
DirectColor and TrueColor have a decomposed colormap,
therefore the colormap_size field in the XVisualInfo
structure is meant per sub-field (take a look at the output
of xdpyinfo).
With 3 sub-fields there are colormap_size^3 entires.
Signed-off-by: Egbert Eich <eich@suse.de>
---
xterm-299/misc.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/misc.c b/misc.c
--- a/misc.c
+++ b/misc.c
@@ -2260,16 +2260,18 @@ ReportAnsiColorRequest(XtermWidget xw, i
}
static void
getColormapInfo(XtermWidget xw, unsigned *typep, unsigned *sizep)
{
if (getVisualInfo(xw)) {
*typep = (unsigned) xw->visInfo->class;
*sizep = (unsigned) xw->visInfo->colormap_size;
+ if (*typep > 3)
+ *sizep = (*sizep)*(*sizep)*(*sizep);
} else {
*typep = 0;
*sizep = 0;
}
}
#define MAX_COLORTABLE 4096