[Top][All Lists]

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

Re: Slow frame creation when many faces defined

From: David Reitter
Subject: Re: Slow frame creation when many faces defined
Date: Mon, 14 Nov 2005 08:33:09 +0000

On 13 Nov 2005, at 23:38, Kim F. Storm wrote:

It would be interesting if someone would do some profiling of the
relevant code to see if there is a specific loop that accounts for
most of the time spent here.  It could be something which was easy
to optimize once we know what it is.

This is the loop you're looking for. It's in face-set-after-frame- default (faces.el):

(dolist (face (face-list))
    ;; Don't let frame creation fail because of an invalid face spec.
    (condition-case ()
        (when (not (equal face 'default))
          (face-spec-set face (face-user-default-spec face) frame)
          (internal-merge-in-global-face face frame)
           (when (and (memq window-system '(x w32 mac))
                     (or (not (boundp 'inhibit-default-face-x-resources))
                         (not (eq face 'default))))
            (make-face-x-resource-internal face frame))
      (error nil)))

Note: (not (eq face 'default)) is always t inside the (or ...),

reply via email to

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