emacs-pretest-bug
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Abort in x_produce_glyphs


From: Gerd Moellmann
Subject: Abort in x_produce_glyphs
Date: Tue, 23 Sep 2003 21:12:30 +0200 (CEST)

In GNU Emacs 21.3.50.9 (i386-unknown-freebsd4.8, X toolkit, Xaw3d scroll bars)
 of 2003-09-13

I've encountered an abort from displaying an image today, from

  /* Accumulate dimensions.  Note: can't assume that it->descent > 0
     because this isn't true for images with `:ascent 100'.  */
  xassert (it->ascent >= 0 && it->descent >= 0);

in x_produce_glyphs, it->descent being negative.  The glyph being 
produced is an image (from a web page):

(gdb) p *it->f->output_data.x->display_info->image_cache->images[50]
$4 = {
  timestamp = 1064342618, 
  pixmap = 12584259, 
  mask = 0, 
  colors = 0x0, 
  ncolors = 0, 
  background = 0, 
  background_transparent = 0, 
  background_valid = 1, 
  background_transparent_valid = 0, 
  width = 1, 
  height = 1, 
  ascent = -1, 
  spec = -1466058376, 
  relief = 0, 
  hmargin = 0, 
  vmargin = 0, 
  type = 0x83df2e8, 
  load_failed_p = 0, 
  data = {
    int_val = 0, 
    ptr_val = 0x0, 
    lisp_val = 675065868
---Type <return> to continue, or q <return> to quit---
  }, 
  hash = 147449696, 
  id = 50, 
  next = 0x0, 
  prev = 0x0

(gdb) p it->ascent
$5 = 6
(gdb) p it->descent
$6 = -5

This is apparently the result of produce_image_glyph computing the
ascent with image_ascent, which gives an ascent of 6 because it
computes the value taking the font of the face under the image into
account, and computing the descent from the image's height and the
computed ascent.

Not sure what to do here, but Miles might know.  IIRC, he added the
image-centering feature.




reply via email to

[Prev in Thread] Current Thread [Next in Thread]