• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Table Column Drawing Weirdness
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Table Column Drawing Weirdness


  • Subject: Re: Table Column Drawing Weirdness
  • From: "Stan Soria" <email@hidden>
  • Date: Thu, 3 Mar 2005 09:24:59 -0800
  • Organization: 36N 121W

Seth Willits < email@hidden >wrote on 3/3/05:

>On Mar 3, 2005, at 4:53 AM, Darkshadow wrote:
>
>>> http://www.freaksw.com/Funky.jpg
>>>
>>> Any idea what could be causing this? The only thing special about the
>>> table is that its columns were created dynamically.
>>
>> Looks like the tablecolumns' data cells are drawing their backgrounds.
>>  When they do, it covers up the alternating background pattern the
>> table view uses.
>
>Well, yes of course, but why is it doing that and how can I solve it is
>the question. Questions...
>

>Seth Willits

Hi Seth,
This is what I use in the awakeFromNib Method (the original solution came
from the list archives but I don't recall the poster):

// Fixes the data cells that have "drawsBackground" set ON (Project
Builder bug)

NSArray* columns = [myTableView tableColumns];
int i;
for ( i = 0; i < [columns count]; i ++ ) {
	id cell = [[columns objectAtIndex: i] dataCell];
	if ( [cell respondsToSelector:@selector(setDrawsBackground:)] ) {
	    [cell setDrawsBackground: NO];
	 }
}


Stan Soria
36N  121W


 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

References: 
 >Re: Table Column Drawing Weirdness (From: Seth Willits <email@hidden>)

  • Prev by Date: Re: keyDown:not receiving Command + key events, space bar, left/right arrows
  • Next by Date: Re: Table Column Drawing Weirdness
  • Previous by thread: Re: Table Column Drawing Weirdness
  • Next by thread: Re: Table Column Drawing Weirdness
  • Index(es):
    • Date
    • Thread