Nested Views in different *.XIB files

2009-10-24 Thread Mazen M. Abdel-Rahman
Hi All, My goal is to have a split view with a left side pane containing an outline view - and 3 panes on the right on top of each other. To do this I did the following: 1) created a split view that is split horizontally into 3 parts. 2) I then created another split view that is split ver

Adding new rules to policy database

2009-11-09 Thread Mazen M. Abdel-Rahman
Hi All, I know that one can add a new right specification to the policy database via the function AuthorizationRightSet. Is there any functions or APIs for adding new rule specifications? I want to create a new group - and allow only members of that group to access parts of my applicatio

NSTreeController content array bindings

2009-11-22 Thread Mazen M. Abdel-Rahman
Hi All, I am having trouble binding an NSTreeController's content array to an NSMutableArray through interface builder. In the bindings inspector of Interface Builder I bind to file's owner - which in my case is a subclass of NSWindowController, and set the model key path the the name of the N

Re: NSTreeController content array bindings

2009-11-23 Thread Mazen M. Abdel-Rahman
ual/CocoaBindings/Concepts/Troubleshooting.html#//apple_ref/doc/uid/TP40002148 > > Don't bind to an NSMutableArray. Bind to an array property of an object. > > On 23 Nov 2009, at 03:20, Mazen M. Abdel-Rahman wrote: > >> Hi All, >> >> I am having trouble binding

CALayer Grid jerky animation

2010-03-29 Thread Mazen M. Abdel-Rahman
Hi All, I have a grid of equal sized CALayers in a parent layer - in my case it's a calendar grid - but it could also be a chess board for example. After adding all the cell (child) layers to the parent layer I iterate through them again to add constraints. The parent layer can have it's widt

CalendarStore Question

2010-04-19 Thread Mazen M. Abdel-Rahman
Hi All, I am having difficulty with modifying recurring events in iCal using the Calendar Store framework. I can take a single event (non recurring) event and make it repeating - including specifying an end date or number of repeats. To do that I use the following line: [[CalCalendarStore d

Custom View Binding, Arrays, and observeValueForKeyPath

2010-05-19 Thread Mazen M. Abdel-Rahman
Hi all, I have a general question about bindings - and I feel like there's something I'm not quite getting. I have a custom view class with an array property. I want to bind that array property to a model - which in my case is an array that is in a container/manager object. The binding is do

Re: Custom View Binding, Arrays, and observeValueForKeyPath (solved)

2010-05-25 Thread Mazen M. Abdel-Rahman
values of the array. Thank! Mazen Abdel-Rahman On May 19, 2010, at 3:00 AM, Ken Thomases wrote: > On May 19, 2010, at 2:05 AM, Mazen M. Abdel-Rahman wrote: > >> I have a custom view class with an array property. I want to bind that >> array property to a model - which in my cas

Having trouble with eventWithUID:occurrence: CalCalendarStore method

2010-06-08 Thread Mazen M. Abdel-Rahman
Hi All, The eventWithUID:occurrence: method of CalCalendarStore is not working for me as expected when retrieving a recurring event. I am not sure if there is a disconnect between the documentation and the CalCalendarStore documentation or if perhaps there is something I am not seeing. Accord

Adding objects from one array to another and and Key Value Observing

2010-06-09 Thread Mazen M. Abdel-Rahman
Hi All, I have a view class that observes changes in a model class's array via KVO. Unfortunately - when ever the array is updated - the updates are sent to the view one at at a time. In my model class I have the following line: NSMutableArray * eventsArrayProxy = [self mutableArrayV

Re: Adding objects from one array to another and and Key Value Observing [SOLVED]

2010-06-09 Thread Mazen M. Abdel-Rahman
with KVO then addObjectsFromArray: Thanks! Mazen Abdel-Rahman On Jun 9, 2010, at 3:13 PM, Ken Thomases wrote: > On Jun 9, 2010, at 3:19 PM, Mazen M. Abdel-Rahman wrote: > >> I have a view class that observes changes in a model class's array via KVO. >> Unfortunately

Confused about Memory Management with Collections

2009-11-28 Thread Mazen M. Abdel-Rahman
Hi All, I am trying to find out how memory is retained/released when using different Cocoa collection classes. Is there a good resource on this anyone can connect me to? Here is some detailed questions about what I am trying to find out: If I create a dictionary in the following manner (where

Control Appearance on Textured Window Sheet

2009-12-01 Thread Mazen M. Abdel-Rahman
Hi All, First of all - I want to thank everyone for helping me with my previous questions. Now for my next question - I have an application where I place the window in a separate *.xib (I called "MyWindow.xib") file from the Main Menu. I deleted the window that's in MainMenu.xib. When the

Control Appearance on Textured Window Sheet (Solution)

2009-12-02 Thread Mazen M. Abdel-Rahman
> > Message: 15 > Date: Tue, 01 Dec 2009 15:50:45 -0700 > From: "Mazen M. Abdel-Rahman" > Subject: Control Appearance on Textured Window Sheet > To: cocoa-dev@lists.apple.com > Message-ID: > Content-Type: text/plain; charset=us-ascii > > Hi All, >

Re: Control Appearance on Textured Window Sheet (Solution)

2009-12-02 Thread Mazen M. Abdel-Rahman
Hi All, There was a problem with my last solution - it does not work if a user types in anything into one of the controls. This time I had to call the superview's display function - so for everything to always display properly both the currently selected tabviewitem's view and it's superview n

unrecognized selector error when calling -stringValue on NSNumber

2009-12-06 Thread Mazen M. Abdel-Rahman
Hi all, I am getting a very confusing error when I try to send a -stringValue message to an NSNumber object. Here is my code: NSNumber * primaryLanguageNumber = [self primaryLanguageID]; NSString * primaryLanguageString = [primaryLanguageNumber stringValue]; primaryLanguageID is of type NSNumb

Re: unrecognized selector error when calling -stringValue on NSNumber

2009-12-06 Thread Mazen M. Abdel-Rahman
09, at 15.58, Mazen M. Abdel-Rahman wrote: > >> 2009-12-06 16:51:24.525 Averroes[21013:a0f] -[NSCFString stringValue]: >> unrecognized selector sent to instance 0x1001d8a70 >> >> Doesn't that mean that it thinks primaryLanguageNumber is a string? And why >> wou

binding NSComboBox default selection

2010-01-07 Thread Mazen M. Abdel-Rahman
Hi All, I have an NSComboBox that is bound to a datasource. I want to programatically select a default selection when the sheet the combobox is in is first displayed. To do so I am doing the following: NSString * defaultSelectionValue = [myDS defaultSelectionValue]; NSUInteger defaultSelecti

Re: binding NSComboBox default selection

2010-01-07 Thread Mazen M. Abdel-Rahman
From: Quincey Morris Subject: Re: binding NSComboBox default selection To: cocoa-dev Message-ID: Content-Type: text/plain; charset=us-ascii > > > On Jan 7, 2010, at 09:02, Mazen M. Abdel-Rahman wrote: > >> NSString * defaultSelectionValue = [myDS defaultSelectionValue];

How to detect if mouse on border of view

2010-02-18 Thread Mazen M. Abdel-Rahman
Hi All, I was wondering if there is a straight forward away to know if the mouse is on the border of a view? I know how to detect if the mouse enters a view area by using NSTrackingArea - but how can I tell if the mouse is on a border? I would like to replicate iCal's behavior where a user ca

Re: How to detect if mouse on border of view

2010-02-19 Thread Mazen M. Abdel-Rahman
> > -- > > Message: 11 > Date: Thu, 18 Feb 2010 21:44:27 -0700 > From: "Mazen M. Abdel-Rahman" > Subject: How to detect if mouse on border of view > To: cocoa-dev@lists.apple.com > Message-ID: > Content-Type: text/plain; charset=us

xcode-debug style toolbar above editor area

2010-03-03 Thread Mazen M. Abdel-Rahman
Hi All, Thanks to everyone for helping me with my previous question. I had another one though. When in a debugging session in xcode - but not in the main debug view - a small "toolbar" appears above the editor. In my case it's between the editor and the the file name list, and contains debug

Re: xcode-debug style toolbar above editor area

2010-03-03 Thread Mazen M. Abdel-Rahman
eems like to me. Thanks, Mazen On Mar 3, 2010, at 1:17 PM, Abhinay Kartik Reddyreddy wrote: > Look for NSToolbar in Interface Builder... > > > On Mar 3, 2010, at 2:01 PM, Mazen M. Abdel-Rahman wrote: > >> Hi All, >> >> Thanks to everyone for helping me with my

Core Animation vs. Basic Cocoa Graphics

2010-03-10 Thread Mazen M. Abdel-Rahman
Hi All, I was able to write a simple calendar view that uses basic cocoa graphics to draw directly on the view (NSBezierPath, etc.). I actually use several different paths for drawing the calendar (it's a weekly calendar) to allow different horizontal line widths (hour, half hour, etc.). The

CAKeyframeAnimation and NSView frame property

2010-03-10 Thread Mazen M. Abdel-Rahman
Hi All, I had another question about core animation. I am trying to animate my view's frame size so that it gets smaller - and then in the same animation goes back to the same size. I was able to get it to succesfully animate to a smaller size - but am having difficulty with getting to work u

Re: Core Animation vs. Basic Cocoa Graphics

2010-03-11 Thread Mazen M. Abdel-Rahman
...@mugginsoft.com wrote: > > > On 10 Mar 2010, at 17:13, Mazen M. Abdel-Rahman wrote: > >> Hi All, >> >> I was able to write a simple calendar view that uses basic cocoa graphics to >> draw directly on the view (NSBezierPath, etc.). I actually use several