emacs-diffs
[Top][All Lists]
Advanced

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

[Emacs-diffs] Changes to emacs/src/xterm.c


From: Kenichi Handa
Subject: [Emacs-diffs] Changes to emacs/src/xterm.c
Date: Tue, 25 Feb 2003 01:19:37 -0500

Index: emacs/src/xterm.c
diff -c emacs/src/xterm.c:1.772 emacs/src/xterm.c:1.773
*** emacs/src/xterm.c:1.772     Sat Feb  8 06:18:32 2003
--- emacs/src/xterm.c   Tue Feb 18 16:30:06 2003
***************
*** 14536,14543 ****
        {
          /* We try at least 10 fonts because XListFonts will return
             auto-scaled fonts at the head.  */
!         names = XListFonts (dpy, SDATA (pattern), max (maxnames, 10),
!                             &num_fonts);
          if (x_had_errors_p (dpy))
            {
              /* This error is perhaps due to insufficient memory on X
--- 14536,14563 ----
        {
          /* We try at least 10 fonts because XListFonts will return
             auto-scaled fonts at the head.  */
!           if (maxnames < 0)
!             {
!               int limit;
! 
!               for (limit = 500;;)
!                 {
!                   names = XListFonts (dpy, SDATA (pattern), limit, 
&num_fonts);
!                   if (num_fonts == limit)
!                     {
!                       BLOCK_INPUT;
!                       XFreeFontNames (names);
!                       UNBLOCK_INPUT;
!                       limit *= 2;
!                     }
!                   else
!                     break;
!                 }
!             }
!           else
!             names = XListFonts (dpy, SDATA (pattern), max (maxnames, 10),
!                                 &num_fonts);
! 
          if (x_had_errors_p (dpy))
            {
              /* This error is perhaps due to insufficient memory on X




reply via email to

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