Re: OT: Re: null values in NSArray ???
Re: OT: Re: null values in NSArray ???
- Subject: Re: OT: Re: null values in NSArray ???
- From: Rakesh Pandey <email@hidden>
- Date: Sat, 18 Jan 2003 02:29:48 +0530
Hi,
An NSWindow's style is set when the object is initialized. Once set, it
can't be changed.
However if you want to change the window background color to aqua theme
you can do like this:
[[self window] setBackgroundColor:[NSColor windowBackgroundColor]];
But the window will still have the style of textured windows.
Thanks & Regards
Rakesh
On Saturday, Jan 18, 2003, at 00:58 Asia/Calcutta, The Amazing Llama
wrote:
>
This becomes somewhat problematic, however, as soon as you start using
>
databases, where NULL != NULL.
>
>
Then you have to go right back rolling your own class. It would be
>
nice if NSNull had:
>
>
+ (BOOL)treatAsSingleton;
>
+ (void)setTreatAsSingleton:(BOOL)flag;
>
>
which would not actually make NSNull a singleton, but would simply
>
make instances return no to the isEqualTo: message.
>
>
This is what I'm planning on doing next week (in a category), when I
>
have to tackle the problem for myself.
>
>
On Friday, January 17, 2003, at 11:18 AM, Daniel Hedrick wrote:
>
>
> Sayeth Brian Webster on Fri, Jan 17, 2003 at 11:29:38AM -0600:
>
>> On Friday, January 17, 2003, at 09:56 AM,
>
>> email@hidden wrote:
>
>>
>
>>> Can anyone tell me if it is possible to manage an NSMutableArray
>
>>> that
>
>>> contains null values for objects at any given index ?
>
>>
>
>>> I don't want to incur
>
>>> the overhead of the NSNull object allocation(s) in a large grid.
>
>>
>
>> I haven't tested this, but I always assumed that calling [NSNull
>
>> null]
>
>> will return you a single instance of NSNull instead of creating a new
>
>> instance of NSNull, since there's really no reason to have more than
>
>> one around.
>
>
>
> Funny story, although not really topical...
>
>
>
> As I read the original post, I was thinking, "Hrm... it _would_
>
> be cool if you could use nil." Then I remembered a similar
>
> problem I had in Java and how I solved that problem, using a
>
> homemade class similar to NSNull. I had made my Empty class
>
> a singleton, and I thought to myself, "well, it would be
>
> really cool if NSNull were a singleton and that overhead
>
> could be incurred once."
>
>
>
> Being fairly unfamiliar with Cocoa still, when I saw the
>
> follow-ups that explained that NSNull _WAS_ singleton, I
>
> thought, "Wow! Good call."
>
>
>
> Sorry to relate this. I'm just such a goof-ball programmer
>
> that I get a kick from any time I manage to pull one
>
> outta my hat like that and I get it right.
>
>
>
> 8-)
>
>
>
> Thx,
>
> -daniel
>
> email@hidden
>
> --
>
> There are 10 types of people in this world...
>
> those who understand binary, and those who don't.
>
> _______________________________________________
>
> cocoa-dev mailing list | email@hidden
>
> Help/Unsubscribe/Archives:
>
> http://www.lists.apple.com/mailman/listinfo/cocoa-dev
>
> Do not post admin requests to the list. They will be ignored.
>
>
>
>
>
>
Seth A. Roby The Amazing Llama < mail or AIM me at tallama at mac
>
dot com>
>
"Life is like an exploded clown. It's really funny until you figure
>
out what just happened."
>
_______________________________________________
>
cocoa-dev mailing list | email@hidden
>
Help/Unsubscribe/Archives:
>
http://www.lists.apple.com/mailman/listinfo/cocoa-dev
>
Do not post admin requests to the list. They will be ignored.
>
Rakesh Pandey
------------------------------------------------------------------------
--------
Windows) 98 (n) - 32-bit extensions and graphical shell
for a 16-bit patch to an 8-bit operating system
originally coded for a 4-bit microprocessor
written by a 2-bit company
that can't stand 1 bit of competition.
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.