• 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: Keeping a drawer to a fixed size
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Keeping a drawer to a fixed size


  • Subject: Re: Keeping a drawer to a fixed size
  • From: Jeffrey Drake <email@hidden>
  • Date: Mon, 16 Dec 2002 11:44:31 -0500

Here is what I have tried:

- (NSSize)windowWillResize:(NSWindow *)sender
toSize:(NSSize)proposedFrameSize
{
[oStatusDrawer setLeadingOffset: 10];
[oStatusDrawer setTrailingOffset: proposedFrameSize.height - 359];
[oStatusDrawer setContentSize: NSMakeSize(254, 359)];
[oStatusDrawer setMaxContentSize: NSMakeSize(254, 359)];
[oStatusDrawer setMinContentSize: NSMakeSize(254, 359)];
return proposedFrameSize;
}

It does some really wierd resizing. The window can't go smaller height
and is always growing when you attempt to resize it, width is fine
however. The drawer itself is resizing the view so that it is covering
part of the first row of controls. It also looks very wierd when doing
this.

I want to make sure that the drawer looks smooth when it is updated.

Thank you for your help,
Jeffrey

On Monday, December 16, 2002, at 03:42 AM, Rakesh Pandey wrote:

> You will have to calculate the offsets for the drawer. The drawer size
> is
> detrmined byt its offsets from the top and bottom of window. As the
> window
> is growing calculate and adjust the offsets fro the drawer. Hope it
> works.
>
> //-----------------PART of code from my application ------------//
> unsigned int halfHeight = frameSize.height / 2, remainder =
> frameSize.height - 2 * halfHeight;
> [notesDrawer setLeadingOffset:0];
> [notesDrawer setTrailingOffset:halfHeight];
> [notesDrawer setMinContentSize:NSMakeSize(250, 350)];
> [notesDrawer setMaxContentSize:NSMakeSize(250, 350)];
> //-------------------------------------------------------------//
>
> Regards
> Rakesh
>
>
> On 16/12/02 1:44 PM, "Jeffrey Drake" <email@hidden> wrote:
>
>> I am trying to make a drawer that is on the left or right side that
>> keeps its hieght fixed, instead of automatically growing and
>> shrinking.
>> I have tried a few of the resize delegates on the window and on the
>> drawer and trying to setContentSize, but not working. I am thinking it
>> is that content size isn't the drawer size. I have run out of ideas
>> though.
>>
>> The reason is the data is not potentially bottomless, but more like a
>> fixed dialog would be. I am not using a panel because I want this to
>> be
>> attached to the window.
>>
>> Any help would be appreciated,
>> Jeffrey Drake
>> _______________________________________________
>> 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.
_______________________________________________
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.

  • Follow-Ups:
    • Re: Keeping a drawer to a fixed size
      • From: Rakesh Pandey <email@hidden>
References: 
 >Re: Keeping a drawer to a fixed size (From: Rakesh Pandey <email@hidden>)

  • Prev by Date: (a bit off topic) drive optimization
  • Next by Date: Re: "First Run" installation of Application support stuff?
  • Previous by thread: Re: Keeping a drawer to a fixed size
  • Next by thread: Re: Keeping a drawer to a fixed size
  • Index(es):
    • Date
    • Thread