emacs-diffs
[Top][All Lists]
Advanced

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

[Emacs-diffs] /srv/bzr/emacs/trunk r105813: src/.gdbinit (pgx): Fix refe


From: Eli Zaretskii
Subject: [Emacs-diffs] /srv/bzr/emacs/trunk r105813: src/.gdbinit (pgx): Fix references to fields of `struct glyph'.
Date: Sun, 18 Sep 2011 03:33:04 -0400
User-agent: Bazaar (2.3.1)

------------------------------------------------------------
revno: 105813
committer: Eli Zaretskii <address@hidden>
branch nick: trunk
timestamp: Sun 2011-09-18 03:33:04 -0400
message:
  src/.gdbinit (pgx): Fix references to fields of `struct glyph'.
modified:
  src/.gdbinit
  src/ChangeLog
  src/xdisp.c
=== modified file 'src/.gdbinit'
--- a/src/.gdbinit      2011-06-18 13:28:53 +0000
+++ b/src/.gdbinit      2011-09-18 07:33:04 +0000
@@ -483,83 +483,83 @@
 define pgx
   set $g = $arg0
   # CHAR_GLYPH
-  if ($g->type == 0)
-    if ($g->u.ch >= ' ' && $g->u.ch < 127)
-      printf "CHAR[%c]", $g->u.ch
+  if ($g.type == 0)
+    if ($g.u.ch >= ' ' && $g.u.ch < 127)
+      printf "CHAR[%c]", $g.u.ch
     else
-      printf "CHAR[0x%x]", $g->u.ch
+      printf "CHAR[0x%x]", $g.u.ch
     end
   end
   # COMPOSITE_GLYPH
-  if ($g->type == 1)
-    printf "COMP[%d (%d..%d)]", $g->u.cmp.id, $g->slice.cmp.from, 
$g->slice.cmp.to
+  if ($g.type == 1)
+    printf "COMP[%d (%d..%d)]", $g.u.cmp.id, $g.slice.cmp.from, $g.slice.cmp.to
   end
   # GLYPHLESS_GLYPH
-  if ($g->type == 2)
+  if ($g.type == 2)
     printf "GLYPHLESS["
-    if ($g->u.glyphless.method == 0)
+    if ($g.u.glyphless.method == 0)
       printf "THIN]"
     end
-    if ($g->u.glyphless.method == 1)
+    if ($g.u.glyphless.method == 1)
       printf "EMPTY]"
     end
-    if ($g->u.glyphless.method == 2)
+    if ($g.u.glyphless.method == 2)
       printf "ACRO]"
     end
-    if ($g->u.glyphless.method == 3)
+    if ($g.u.glyphless.method == 3)
       printf "HEX]"
     end
   end
   # IMAGE_GLYPH
-  if ($g->type == 3)
-    printf "IMAGE[%d]", $g->u.img_id
+  if ($g.type == 3)
+    printf "IMAGE[%d]", $g.u.img_id
   end
   # STRETCH_GLYPH
-  if ($g->type == 4)
-    printf "STRETCH[%d+%d]", $g->u.stretch.height, $g->u.stretch.ascent
+  if ($g.type == 4)
+    printf "STRETCH[%d+%d]", $g.u.stretch.height, $g.u.stretch.ascent
   end
-  xgettype ($g->object)
+  xgettype ($g.object)
   if ($type == Lisp_String)
-    printf " str=%x[%d]", $g->object, $g->charpos
+    printf " str=%x[%d]", $g.object, $g.charpos
   else
-    printf " pos=%d", $g->charpos
+    printf " pos=%d", $g.charpos
   end
   # For characters, print their resolved level and bidi type
-  if ($g->type == 0)
-    printf " blev=%d,btyp=", $g->resolved_level
-    pbiditype $g->bidi_type
+  if ($g.type == 0)
+    printf " blev=%d,btyp=", $g.resolved_level
+    pbiditype $g.bidi_type
   end
-  printf " w=%d a+d=%d+%d", $g->pixel_width, $g->ascent, $g->descent
+  printf " w=%d a+d=%d+%d", $g.pixel_width, $g.ascent, $g.descent
   # If not DEFAULT_FACE_ID
-  if ($g->face_id != 0)
-    printf " face=%d", $g->face_id
-  end
-  if ($g->voffset)
-    printf " vof=%d", $g->voffset
-  end
-  if ($g->multibyte_p)
+  if ($g.face_id != 0)
+    printf " face=%d", $g.face_id
+  end
+  if ($g.voffset)
+    printf " vof=%d", $g.voffset
+  end
+  if ($g.multibyte_p)
     printf " MB"
   end
-  if ($g->padding_p)
+  if ($g.padding_p)
     printf " PAD"
   end
-  if ($g->glyph_not_available_p)
+  if ($g.glyph_not_available_p)
     printf " N/A"
   end
-  if ($g->overlaps_vertically_p)
+  if ($g.overlaps_vertically_p)
     printf " OVL"
   end
-  if ($g->avoid_cursor_p)
+  if ($g.avoid_cursor_p)
     printf " AVOID"
   end
-  if ($g->left_box_line_p)
+  if ($g.left_box_line_p)
     printf " ["
   end
-  if ($g->right_box_line_p)
+  if ($g.right_box_line_p)
     printf " ]"
   end
-  if ($g->slice.img.x || $g->slice.img.y || $g->slice.img.width || 
$g->slice.img.height)
-    printf " slice=%d,%d,%d,%d" ,$g->slice.img.x, $g->slice.img.y, 
$g->slice.img.width, $g->slice.img.height
+  if ($g.slice.img.x || $g.slice.img.y || $g.slice.img.width || 
$g.slice.img.height)
+    printf " slice=%d,%d,%d,%d" ,$g.slice.img.x, $g.slice.img.y, 
$g.slice.img.width, $g.slice.img.height
   end
   printf "\n"
 end

=== modified file 'src/ChangeLog'
--- a/src/ChangeLog     2011-09-17 18:21:24 +0000
+++ b/src/ChangeLog     2011-09-18 07:33:04 +0000
@@ -1,3 +1,7 @@
+2011-09-18  Eli Zaretskii  <address@hidden>
+
+       * .gdbinit (pgx): Fix references to fields of `struct glyph'.
+
 2011-09-17  Eli Zaretskii  <address@hidden>
 
        * xdisp.c (produce_stretch_glyph): Another fix for changes made on

=== modified file 'src/xdisp.c'
--- a/src/xdisp.c       2011-09-17 18:21:24 +0000
+++ b/src/xdisp.c       2011-09-18 07:33:04 +0000
@@ -18703,11 +18703,6 @@
                      it->current_x = new_x;
                      it->continuation_lines_width += new_x;
                      ++it->hpos;
-                     /* Record the maximum and minimum buffer
-                        positions seen so far in glyphs that will be
-                        displayed by this row.  */
-                     if (it->bidi_p)
-                       RECORD_MAX_MIN_POS (it);
                      if (i == nglyphs - 1)
                        {
                          /* If line-wrap is on, check if a previous
@@ -18722,6 +18717,11 @@
                                  || IT_DISPLAYING_WHITESPACE (it)))
                            goto back_to_wrap;
 
+                         /* Record the maximum and minimum buffer
+                            positions seen so far in glyphs that will be
+                            displayed by this row.  */
+                         if (it->bidi_p)
+                           RECORD_MAX_MIN_POS (it);
                          set_iterator_to_next (it, 1);
                          if (IT_OVERFLOW_NEWLINE_INTO_FRINGE (it))
                            {
@@ -18739,6 +18739,8 @@
                                }
                            }
                        }
+                     else if (it->bidi_p)
+                       RECORD_MAX_MIN_POS (it);
                    }
                  else if (CHAR_GLYPH_PADDING_P (*glyph)
                           && !FRAME_WINDOW_P (it->f))
@@ -18869,6 +18871,10 @@
                  xassert (it->first_visible_x <= it->last_visible_x);
                }
            }
+         /* Even if this display element produced no glyphs at all,
+            we want to record its position.  */
+         if (it->bidi_p && nglyphs == 0)
+           RECORD_MAX_MIN_POS (it);
 
          row->ascent = max (row->ascent, it->max_ascent);
          row->height = max (row->height, it->max_ascent + it->max_descent);


reply via email to

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