• 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: Drawing a custom NSTabView Border
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Drawing a custom NSTabView Border


  • Subject: Re: Drawing a custom NSTabView Border
  • From: Kyle Sluder <email@hidden>
  • Date: Sat, 18 Sep 2010 10:29:26 -0700

On Sep 18, 2010, at 9:40 AM, "Mr. Gecko" <email@hidden> wrote:

> I was right about these lists not being useful anymore. None has done a custom Tab View border? Really?

Do you plan on acknowledging Seth Willits's reply?

--Kyle Sluder

>
> On Sep 17, 2010, at 5:29 PM, Mr. Gecko wrote:
>
>> Hello I'm wondering what will be the best way to draw a custom NSTabView Border. I have tried many things and it always ends up that I fail. The border gets drawn, but the objects in the Tab View, if you focus them, has a black edge around them, that is not elegant at all. Is there any examples on the internet that I could look at? This is my code below.
>>
>> - (void)awakeFromNib {
>>   [self setTabViewType:NSNoTabsNoBorder];
>>   [self setDrawsBackground:NO];
>> }
>>
>> - (void)drawRect:(NSRect)frameRect {
>>   float lineSize = 2.0;
>>   float transparentcy = 0.87;
>>   NSBezierPath *strokePath = [NSBezierPath bezierPathWithRect:frameRect];
>>   [strokePath setLineWidth:lineSize];
>>   NSBezierPath *path = [NSBezierPath bezierPathWithRect:frameRect];
>>
>>   [[NSColor colorWithCalibratedWhite:1.0 alpha:transparentcy] set];
>>   [path fill];
>>   [[NSColor colorWithCalibratedWhite:transparentcy-0.3 alpha:1.0] set];
>>   [strokePath stroke];
>>   [super drawRect:frameRect];
>> }
>>
>> Thanks for any help,
>> Mr. Gecko
>
> _______________________________________________
>
> Cocoa-dev mailing list (email@hidden)
>
> Please do not post admin requests or moderator comments to the list.
> Contact the moderators at cocoa-dev-admins(at)lists.apple.com
>
> Help/Unsubscribe/Update your Subscription:
>
> This email sent to email@hidden

_______________________________________________

Cocoa-dev mailing list (email@hidden)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

  • Follow-Ups:
    • Re: Drawing a custom NSTabView Border
      • From: "Mr. Gecko" <email@hidden>
References: 
 >Drawing a custom NSTabView Border (From: Mr.Gecko <email@hidden>)
 >Re: Drawing a custom NSTabView Border (From: "Mr. Gecko" <email@hidden>)

  • Prev by Date: Re: Drawing a custom NSTabView Border
  • Next by Date: Re: Drawing a custom NSTabView Border
  • Previous by thread: Re: Drawing a custom NSTabView Border
  • Next by thread: Re: Drawing a custom NSTabView Border
  • Index(es):
    • Date
    • Thread