On Thu, Feb 11, 2010 at 10:00 PM, Graham Cox wrote:
> I don't think that's true. Surely by definition "THE designated initializer"
> is a single specific method.
No.
http://developer.apple.com/iphone/library/documentation/Cocoa/Conceptual/CodingGuidelines/Articles/FrameworkImpl.html
--Kyle Slu
On 12/02/2010, at 4:52 PM, Quincey Morris wrote:
> since classes are allowed to have multiple designated initializers.
I don't think that's true. Surely by definition "THE designated initializer" is
a single specific method.
The docs state:
"The designated initializer is the method in each c
On Feb 11, 2010, at 21:19, Michael Ash wrote:
> You override the one that's documented to be the designated initializer.
Or, all of the ones that are documented to be the designated initializers,
since classes are allowed to have multiple designated initializers.
The point I tried to make earli
On Feb 11, 2010, at 12:29 AM, Adam Warski wrote:
> Hello,
>
> I've got a NSMenu with NSMenuItem-s and I would like to support drag&drop
> from the menu - so that the users are able to drag the menu items out.
> However I'm having problems attaching the even listener - can it be done? The
> NS
On Feb 11, 2010, at 20:33, William Peters wrote:
> My application contains several records displayed to the user in an
> NSTableView bound to an NSArrayController. Because these records are
> complicated (containing around thirty fields), I have implemented an Edit
> option where the user can s
On Fri, Feb 12, 2010 at 12:07 AM, Charles Srstka
wrote:
> On Feb 11, 2010, at 10:28 PM, Graham Cox wrote:
>
>> On 12/02/2010, at 1:43 PM, Gordon Apple wrote:
>>
>>> My point was that if all Cocoa classes called "init"
>>> somewhere in their other initializers (or had a two-step initialization
>>>
On Feb 11, 2010, at 10:28 PM, Graham Cox wrote:
> On 12/02/2010, at 1:43 PM, Gordon Apple wrote:
>
>> My point was that if all Cocoa classes called "init"
>> somewhere in their other initializers (or had a two-step initialization
>> similar to what MacApp did), then you could simply override (not
On 12/02/2010, at 3:23 PM, Graham Cox wrote:
> That folder can be found using NSApplicationSupportDirectory
Scratch that - this returns the /Library/Application Support, not
~/Library/Application Support
Gideon's right - use NSSearchPathForDirectoriesInDomains()
--Graham
__
Hello everyone,
I'm a bit of a newbie here, but hopefully this question won't be too annoying.
:-)
My application contains several records displayed to the user in an NSTableView
bound to an NSArrayController. Because these records are complicated
(containing around thirty fields), I have impl
On 10 Feb 2010, at 9:44 PM, Paul Johnson wrote:
> I have a function "- (NSString *)applicationSupportFolder" that
> returns the desired folder name, properly localized. I call this
> function and then use NSFileManager to check for the existence of the
> folder. Because there can be a file (NOT a
On 12/02/2010, at 1:43 PM, Gordon Apple wrote:
> My point was that if all Cocoa classes called "init"
> somewhere in their other initializers (or had a two-step initialization
> similar to what MacApp did), then you could simply override (not call)
> "init" for simple ivar initialization in a sub
On 11/02/2010, at 2:44 PM, Paul Johnson wrote:
> I'm trying to find a best way to create the Application Support
> folder. I'm rather new at Cocoa so it's taking me a while to do even
> this simple thing. I'm also interested in ensuring my application can
> be localized easily.
>
> I have a func
Hi Paul
Firstly, are you using the
NSSearchPathForDirectoriesInDomains(NSApplicationSupportDirectory,
NSUserDomainMask, YES);
function to find the application support folder?
That would get you the base path, then you can use the
stringByAppendingPathComponent:
method to add your folder nam
> My point was that if all Cocoa classes called "init"
> somewhere in their other initializers (or had a two-step initialization
> similar to what MacApp did), then you could simply override (not call)
> "init" for simple ivar initialization in a subclass, which would in no way
> interfere with a d
On 12/02/2010, at 3:12 PM, Jonathan Chacón wrote:
> is there any method to get the list of controls (buttons, labels, splitters,
> etc) of a NSView?
[NSView subViews]
--Graham
___
Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)
Please do not
Hello everybody,
is there any method to get the list of controls (buttons, labels, splitters,
etc) of a NSView?
thanks and regards
Jonathan Chacón
Follow me in twitter:
http://www.twitter.com/jonathanchacon___
Cocoa-dev mailing list
Hi,
I am trying to emulate a scrolling behavior within a NSView.
I am calling scrollRect:by: and as the documentation specifies:
--
Discussion
This method is useful during scrolling or translation of the coordinate system
to efficiently move as much of the receiver’s rendered ima
Hello,
I've got a NSMenu with NSMenuItem-s and I would like to support drag&drop from
the menu - so that the users are able to drag the menu items out. However I'm
having problems attaching the even listener - can it be done? The NSMenuItem
only supports an action: message.
--
Adam Warski
htt
I am writing an application that wants to perform some basic computer vision
computation, and I want a class that offers pixel-level access to an image.
What would be the best way to approach this?
Alex___
Cocoa-dev mailing list (Cocoa-dev@lists.appl
I'm trying to find a best way to create the Application Support
folder. I'm rather new at Cocoa so it's taking me a while to do even
this simple thing. I'm also interested in ensuring my application can
be localized easily.
I have a function "- (NSString *)applicationSupportFolder" that
returns th
I have read it. My point was that if all Cocoa classes called "init"
somewhere in their other initializers (or had a two-step initialization
similar to what MacApp did), then you could simply override (not call)
"init" for simple ivar initialization in a subclass, which would in no way
interfere w
On Feb 11, 2010, at 4:54 PM, PCWiz wrote:
> The gradient works fine. Now this view has a subview (custom UIView subclass,
> added in Interface Builder) that draws a line. The problem is that the
> CAGradientLayer goes OVER the subview of the main view. If I comment out the
> code that creates t
Thanks, setting the layer frame to an appropriate size did the trick :)
Independent Cocoa Developer, Macatomy Software
http://macatomy.com
On 2010-02-11, at 5:55 PM, David Duncan wrote:
> On Feb 11, 2010, at 4:50 PM, PCWiz wrote:
>
>> Yep, I just tried that (sent a reply a minute ago) but the
On Feb 11, 2010, at 4:50 PM, PCWiz wrote:
> Yep, I just tried that (sent a reply a minute ago) but the drawInContext:
> method still isn't being called.
Its because your layer is still sized 0,0. Not much you can draw into a layer
that size :).
--
David Duncan
Apple DTS Animation and Printing
In my UIViewController I create a CAGradientLayer in the viewDidLoad method:
CAGradientLayer *gradient = [CAGradientLayer layer];
gradient.frame = CGRectMake(self.view.bounds.origin.x,
self.view.bounds.origin.y + 44.0, self.view.bounds.size.width,
self.view.bounds.size.height - 44.0);
The Reload All Class files did it!. Thanks!
On Feb 11, 2010, at 4:46 PM, Jerry Krinock wrote:
>
> On 2010 Feb 11, at 13:25, Tony Romano wrote:
>
>> Thanks for the reply Fritz.
>>
>> It shows NSArrayController and it is greyed out. It list two options in the
>> drop down, NSArrayController a
Yep, I just tried that (sent a reply a minute ago) but the drawInContext:
method still isn't being called.
Independent Cocoa Developer, Macatomy Software
http://macatomy.com
On 2010-02-11, at 5:47 PM, David Duncan wrote:
> On Feb 11, 2010, at 3:44 PM, PCWiz wrote:
>
>> I'm trying to do some
Tried it, my code looks like this now:
CustomLayer *lines = [CustomLayer layer];
[self.view.layer addSublayer:lines];
[lines setNeedsDisplay];
Still nothing. Am I calling setNeedsDisplay at the wrong place?
On 2010-02-11, at 5:39 PM, Bob Barnes wrote:
> Have you tried calling setNeedsDisplay
On Feb 11, 2010, at 3:44 PM, PCWiz wrote:
> I'm trying to do some custom drawing in a CALayer subclass by overriding the
> drawInContext: method, but it appears that its not being called. In my
> subclass I just have this:
>
> However, the drawInContext method is never called. What am I doing w
On 2010 Feb 11, at 13:25, Tony Romano wrote:
> Thanks for the reply Fritz.
>
> It shows NSArrayController and it is greyed out. It list two options in the
> drop down, NSArrayController and NSDictionaryController. If I try to add my
> controller class's name, IB beeps and won't accept the n
Have you tried calling setNeedsDisplay on the view? You need to request that
a view redraw when the data or state used for drawing a view changes.
Bob
On Feb 11, 2010, at 3:44 PM, PCWiz wrote:
> I'm trying to do some custom drawing in a CALayer subclass by overriding the
> drawInContext: met
On Thu, Feb 11, 2010 at 3:48 PM, Mike Abdullah
wrote:
> Fair enough. The main reason why such a thing is legal is that you sometimes
> need a method like -URL or -HTMLString, so the system supports this.
Makes perfect sense. Filed doc bug rdar://problem/7640544.
--Kyle Sluder
__
On 11 Feb 2010, at 21:50, Kyle Sluder wrote:
> On Thu, Feb 11, 2010 at 9:55 AM, Mike Abdullah
> wrote:
>> Not true, they are KVC-compliant. However, they *are* unwise and you should
>> follow Kyle's advice.
>
> I can't find anywhere that specifically addresses the capitalization
> issue. The o
I'm trying to do some custom drawing in a CALayer subclass by overriding the
drawInContext: method, but it appears that its not being called. In my subclass
I just have this:
- (void)drawInContext:(CGContextRef)theContext
{
NSLog(@"drawInContext called");
}
Then in the viewDidLoad method of
On Feb 10, 2010, at 7:07 pm, Jerry Krinock wrote:
>> Yes, basically. There is only going to be one in-memory object at a time
>> that represents the same managed object.
>
> It certainly seems to be sensible, but I just wish someone could find such
> documentation. I can't.
>
Uniquing:
Thanks for your input, atze. I believe you. But to confirm it, we need the
documentation.
On 2010 Feb 11, at 00:19, Alexander Spohr wrote:
> Every NSManagedObjectContext holds its own but unique copy of your object.
I understand that each managed object context makes separate copies, but I
w
On Thu, Feb 11, 2010 at 9:55 AM, Mike Abdullah
wrote:
> Not true, they are KVC-compliant. However, they *are* unwise and you should
> follow Kyle's advice.
I can't find anywhere that specifically addresses the capitalization
issue. The only thing I've found that comes close is the note on
typogr
I fixed it - the problem lies when the UIWebView is loaded, but it's not on
screen - it's center is off screen. When I animate it into view on the
Touch, it's blank until I scroll it a little. Now, before I call my
animation, I have the webView reload, then its' animated into view and it
works.
Er
Thanks for the reply Fritz.
It shows NSArrayController and it is greyed out. It list two options in the
drop down, NSArrayController and NSDictionaryController. If I try to add my
controller class's name, IB beeps and won't accept the name. (I forgot to
mention in my original post that the
Hi Eric,
can you post how your web view is animated?
If I setup quick test case:
@implementation WebViewController
@synthesize webView;
- (void)viewDidLoad
{
[super viewDidLoad];
self.webView.delegate = self;
NSString *path = [[NSBundle mainBundle] pathForResource:@"index"
ofType:@"
On Feb 11, 2010, at 12:08 pm, Gordon Apple wrote:
> My point was that if you could count on "init" being called internally and
> all you needed was to initialize some ivars, you could override "init" and
> not have to override the (sometimes more involved) designated initializer
> and possibly ot
My point was that if you could count on "init" being called internally and
all you needed was to initialize some ivars, you could override "init" and
not have to override the (sometimes more involved) designated initializer
and possibly other initializers. You could still use the (superclass)
desi
On Feb 11, 2010, at 9:03 AM, Gordon Apple wrote:
> It's unfortunate that all initializers don't at least call "init"
> internally. That would make subclassing easier if all one needs is to set a
> few ivars. In the earlier days of MacApp (Pascal and first C++ versions)
> there was a basic initial
I am animating a UIWebView after it's loaded - but it doesn't display
anything unless I scroll it a little bit. If I call [webView reload]; my
webViewDidFinishLoad gets called - and that is where I put my [webView
reload] call to fix the display. What is the workaround aside from placing
the UIWebV
On 11 Feb 2010, at 1:20 PM, Tony Romano wrote:
> Environment:
>
> 1. Core Data, Document based app.
> 2. UI contains a NSTableView, Add, Remove, ...
> 3. NSArrayController.
>
> The App works fine, I can Add/Remove objects, Save/Load Works, Undo Works.
>
> Problem:
>
> I am trying to overrid
Environment:
1. Core Data, Document based app.
2. UI contains a NSTableView, Add, Remove, ...
3. NSArrayController.
The App works fine, I can Add/Remove objects, Save/Load Works, Undo Works.
Problem:
I am trying to override the -(id)newObject method to change one of the UI
elements in the
> ...but it still would have been useful, sometimes
> eliminating the need to override multiple initializers.
Are you missing the point of the designated initializer? Or have you dealt
with classes that did not have one, or did not use it properly?
--
Scott Ribe
scott_r...@killerbytes.com
http:/
How to change the width of the pop-up list in NSComboBox? When a long string is
added to the NSComboBox, it can't displayed completely. how to extend the width
of the pop-up list?
-John___
Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)
Please do n
On 2/10/2010 8:38 PM, Quincey Morris wrote:
On Feb 10, 2010, at 12:23 PM, James Walker wrote:
I think at times I've written things like [[NSMutableArray alloc]
init] with no apparent ill effects, but now I notice that the docs for
NSMutableArray and NSArray don't say that there is an init metho
On 10 Feb 2010, at 20:03, Kyle Sluder wrote:
> On Wed, Feb 10, 2010 at 9:26 AM, Matthew Miller wrote:
>> @property (nonatomic, retain) NSDate *DateOfBirth;
>> @property (nonatomic, retain) NSString *FirstName;
>> @property (nonatomic, retain) NSString *LastName;
>> @property (nonatomic, retain)
WebDocumentSearching is your man.
On 11 Feb 2010, at 04:12, Peter N Lewis wrote:
> Is there any way to add support for the normal Cocoa Find functionality in a
> WebKit view?
>
> Failing that, is there any other way to get search functionality in a WebKit
> view? I want to do some in-app docu
On Feb 11, 2010, at 8:47 AM, Ricky Sharp wrote:
> Basically Bonjour is used to have the server (Mac app) and client (iPhone)
> discover each other. Then use whatever networking protocol you want to send
> data.
I wrote an open-source Mac/iPhone networking framework that makes this job
easier
To clarify what I'm looking to do...
I have a wifi router attached to the back of my Mac. My Touch connects to
that router.
I'd like to run an app on the Touch and an app on the Mac. I'd like to be
able to send a simple string from either app to the other and acknowledge
receipt of that.
Swipe o
It's unfortunate that all initializers don't at least call "init"
internally. That would make subclassing easier if all one needs is to set a
few ivars. In the earlier days of MacApp (Pascal and first C++ versions)
there was a basic initializer, similar to "init", called by all classes,
just for
It the copy failing because these are read-only properties?
-Michael
On Feb 11, 2010, at 11:29 AM, Michael A. Crawford wrote:
> Here is the code (pertinent snippets)
>
> @interface BlueSLRGPS ()
> @property (copy) CLHeading* currentHeading;
> @property (copy) CLLocation* currentLocation;
> @pro
I would begin with Apple's picture-sharing sample code. I think that
sample has two parts - server and client. Ther is also an iPhone
sample dealing with locating Bonjour services.
Basically Bonjour is used to have the server (Mac app) and client
(iPhone) discover each other. Then use whate
Hey Eric!
Over what timeframe did you want the iPhone app and the desktop app to
be in sync? Immediately? ASAP? When iPhone is tether sync'd?
Something else?
Is this one iPhone app to one desktop, all with the same user? Or is
this many to many with many users? Something inbetween?
What b
I am looking at prototyping something and would like an iPhone app to be
able to talk with a desktop OS X app. Do something on the iPhone app, it's
reflected in the OS X application. And vice-versa. Where might I start for a
project like this?
Eric
___
Here is the code (pertinent snippets)
@interface BlueSLRGPS ()
@property (copy) CLHeading* currentHeading;
@property (copy) CLLocation* currentLocation;
@property (retain) CLLocation* previousLocation;
- (NSString*)compassPointForHeading:(double)heading;
- (void)locationManager:(CLLocationManage
On Feb 11, 2010, at 2:45 AM, Gustavo Pizano wrote:
> [(XWSDefaultComponentView *)[component view] setString:[valueString string]];
The -setString: method takes a plain NSString. So you stripped out your
formatting when calling it.
To put an NSAttributedString into an NSTextView, you replace the
It's objectAtIndex not objectForIndex ;) Sorry - it's working now.
On Thu, Feb 11, 2010 at 9:21 AM, Eric E. Dolecki wrote:
> Ok - I hooked it up to the appdelegate... from another class I am doing
> this (which bombs):
>
> MyAppDelegate *ad = (MyAppDelegate *)[[UIApplication sharedApplication]
>
Ok - I hooked it up to the appdelegate... from another class I am doing this
(which bombs):
MyAppDelegate *ad = (MyAppDelegate *)[[UIApplication sharedApplication]
delegate];
UITabBar *tb = ad.tabBar;//works fine
UITabBarItem *tbi = [tb.items objectForIndex:1];*//bombs...*
So still trying to ac
The class is UIApplication in IB. So it seems I can't do that?
On Thu, Feb 11, 2010 at 9:01 AM, Roland King wrote:
> add UIBarButtonItem outlets to whatever class Files Owner is
>
> eg
>
>@property( readwrite, retain ) IBOutlet UIBarButtonItem
> *item1;
>
> then you will be able to hook
add UIBarButtonItem outlets to whatever class Files Owner is
eg
@property( readwrite, retain ) IBOutlet UIBarButtonItem *item1;
then you will be able to hook them up in IB.
On 11-Feb-2010, at 9:57 PM, Eric E. Dolecki wrote:
> Awesome - thank you!
>
> Now I am looking at how
Awesome - thank you!
Now I am looking at how to access a certain UIBarButtonItem so I can set
it's badge.
In my app delegate I have a UITabBarController. In IB I can't seem to create
an IBOutlet and wire the button I want up so I can set it's badge string.
When I attempt to wire it up from File'
See UITabBarItem's badgeValue property.
Regards
Mark
On 11 Feb 2010, at 13:40, Eric E. Dolecki wrote:
> I know about placing a badge on the homescreen application icon, but is
> there a way to set this up for a button in a toolbar... or do I just use my
> own UIView to do the same thing and floa
I know about placing a badge on the homescreen application icon, but is
there a way to set this up for a button in a toolbar... or do I just use my
own UIView to do the same thing and float it over the toolbar?
Eric
___
Cocoa-dev mailing list (Cocoa-dev
On 11/02/2010, at 9:45 PM, Gustavo Pizano wrote:
> [(XWSDefaultComponentView *)[component view] setString:[valueString string]];
>
>
> But when I display the NSTextViuew all the string its without any style, no
> bold, no colors no nothing..
>
> Any ideas what might I being doing wrong?
Sur
Hello,
Im creating an HTMLString form a NSTextView like this:
NSArray * exclude = [NSArray arrayWithObjects:@"doctype", @"html", @"head",
@"body",@"xml",nil];
NSDictionary * htmlAtt = [NSDictionary
dictionaryWithObjectsAndKeys:NSHTMLTextDocumentType,NSDocumentTypeDocumentAttribute,excl
Done: rdar://7637393
Kai
>
> On Feb 10, 2010, at 5:52 AM, Kai Brüning wrote:
>
>> Could somebody with insight confirm whether this is a documentation bug?
>
> This is indeed an error in the documentation. Please file a bug against the
> documentation with the information you have provided.
>
On 4 févr. 2010, at 10:50, Guillaume Cerquant wrote:
> Hi,
>
> This message is about the CocoaHeads Paris group:
> Our 10th meeting is planned for next week: thursday, 11th of february 2010.
>
> Session starts at 7pm inside the school IESA: 5, rue Saint-Augustin - 75002
> Paris - France.
> The
Hi John,
NSInvocation can be invoked on main thread as any NSObject subclass
simply by performing selector on itself on main thread,
However I think you're looking for custom additions similar to that
one blogged here (Dave Dribin's blog):
http://www.dribin.org/dave/blog/archives/2008/05/22/invoke_
Am 11.02.2010 um 04:07 schrieb Jerry Krinock:
>
> On 2010 Feb 10, at 18:05, Jens Alfke wrote:
>
>>> I've always wondered if I insert a managed object, then later fetch it
>>> repeatedly from the same managed object context, do I get the same object
>>> every time?
>>
>> Yes, basically. There
73 matches
Mail list logo