unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
From: Chong Yidong <cyd@stupidchicken.com>
To: David Whetstone <dwhetstone@gmail.com>
Cc: emacs-devel@gnu.org
Subject: Re: Cocoa Emacs crashes when background color is set
Date: Fri, 18 Jul 2008 14:15:14 -0400	[thread overview]
Message-ID: <87abgft5xp.fsf@stupidchicken.com> (raw)
In-Reply-To: <3DB26FC9-EDDC-4E6B-B956-6E0ACD2FD4C2@gmail.com> (David Whetstone's message of "Fri, 18 Jul 2008 08:25:37 -0700")

David Whetstone <dwhetstone@gmail.com> writes:

>> I checked out Emacs from CVS yesterday, built and installed on Mac
>> OS X
>> Leopard --with-ns
>>
>> With emacs -q, this call
>>
>> (set-background-color "black")
>>
>> exits the whole application.  I can provide detailed tracing next
>> week if it can't be replicated by Adrian or anyone else; I won't have
>> access to Leopard until then (and yesterday I only had a few minutes,
>> sorry this is a very barebones bug report).
>
> Just so we don't duplicate effort, I've already traced the source of
> the problem which I reported this last month before the merge on both
> the emacs-app-dev-@lists.sourceforge.net mailing list:

Maybe the following patch fixes this (1000% untested).

*** trunk/src/nsfns.m.~1.6.~	2008-07-17 10:49:13.000000000 -0400
--- trunk/src/nsfns.m	2008-07-18 14:13:27.000000000 -0400
***************
*** 400,406 ****
        face = FRAME_DEFAULT_FACE (f);
        if (face)
          {
!           col = NS_FACE_BACKGROUND (face);
            face->background
  	     = (EMACS_UINT) [[col colorWithAlphaComponent: alpha] retain];
            [col release];
--- 400,406 ----
        face = FRAME_DEFAULT_FACE (f);
        if (face)
          {
!           col = ns_lookup_indexed_color (NS_FACE_BACKGROUND (face), f);
            face->background
  	     = (EMACS_UINT) [[col colorWithAlphaComponent: alpha] retain];
            [col release];




  reply	other threads:[~2008-07-18 18:15 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-07-18 13:36 Cocoa Emacs crashes when background color is set Ted Zlatanov
2008-07-18 15:25 ` David Whetstone
2008-07-18 18:15   ` Chong Yidong [this message]
2008-07-19 17:01     ` Adrian Robert
2008-07-22 13:16     ` Ted Zlatanov

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87abgft5xp.fsf@stupidchicken.com \
    --to=cyd@stupidchicken.com \
    --cc=dwhetstone@gmail.com \
    --cc=emacs-devel@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).