Re: NSButton ical Like

2008-11-19 Thread Nick Zitzmann
On Nov 19, 2008, at 12:37 PM, Emmanuel Pinault wrote: How do I make a button like the mini calendar in ical (the one that show the days and when one is selected , it shows the day with a blue gradient)? You've got to write one yourself and do all of the drawing, calendrical calculations

Question about NSThread?

2008-11-19 Thread Jean-Nicolas Jolivet
I have an app that generates a bunch of images... the process can be long so I wanted to start it in a separate thread so that the UI can be responsive etc... basically the only thing I did was: [NSThread detachNewThreadSelector:@selector(doLongProcess) toTarget:self withObject:nil]; and

Re: Cocoa apps protection software

2008-11-19 Thread Robert Černý
2008/11/19 Nick Zitzmann <[EMAIL PROTECTED]>: > > On Nov 19, 2008, at 9:53 AM, Donnie Lee wrote: > >> Does anybody know software protection systems for Cocoa apps and >> bundles? Like in Windows ASProtect, Themida, etc. > > > You're best off making your own. The only one I know of that's out there

NSButton ical Like

2008-11-19 Thread Emmanuel Pinault
How do I make a button like the mini calendar in ical (the one that show the days and when one is selected , it shows the day with a blue gradient)? I looked at the NSButton and NSButtonCell and nothing can set the background directly nor having an image and text on top... My understandin

Decomposing an interface into separate nibs

2008-11-19 Thread Frank Wilson
I'm a newbie to cocoa development and this is my first post to this list, so please bear with me! :) What I want to do is be able to decompose a particular interface into several nibs. Sometimes this feels right to me because I feel that one component on the interface can be reused separately.

Programmatic NSTableView selection changes

2008-11-19 Thread Brent Burton
Hi, I think I have this figured out, but I wanted to bounce it off the list to see if there's a better way. I wrote a small app that reads in a text file containing a chat log, which contains lines in the format "Speaker: something they said", like a script. The application allows you to select

RE:Window title bar accessory view

2008-11-19 Thread [EMAIL PROTECTED]
There is already some info in the list on this. http://www.cocoabuilder.com/archive/message/cocoa/2004/11/11/121369 The following can be added to an NSWindow category /* window toolbar height */ - (float) toolbarHeight { return NSHeight([NSWindow contentRectForFrameRect:[self frame]

Re: How to get notification of rerun application

2008-11-19 Thread Macarov Anatoli
No. The program starts up automatically upon system logon, and the icon appears in the system tray (near clock). A user may not notice the icon , thus he/she starts the program manually, and then pops up program's main window. Вы у

Re: Input Managers perspective

2008-11-19 Thread Charles Srstka
On Nov 19, 2008, at 10:06 AM, Donnie Lee wrote: 3. Since there's already an "Input Methods" folder in Leopard that replaces the (supported) functionality of input managers and which developers are encouraged to use instead of input managers, since Apple clearly disapproves of this sort of h

Re: SOLVED Re: NSAttributedString rendering bugs when rendered with Cocoa Text (rdar://6379047)

2008-11-19 Thread Rua Haszard Morris
Even better... thanks for the tip. A much simpler approach... On Nov 19, 2008, at 12:53 pm, 11(November)/19/08, Douglas Davidson wrote: On Nov 18, 2008, at 1:57 PM, Rua Haszard Morris wrote: What are the different options for flipping the coordinates of the destination view? I've tried d

Simple single file renaming application ...

2008-11-19 Thread vince
Thanks for the help ... I want to build a simple single file re-namer. Just a window and a textField that displays the current filename, and a text Field and Save option for the edit. So right click a file/"open with" ... the app runs and loads up the current file name prepared for the edit. D

Re: editWithFrame:inView:editor:delegate:event: in mouseDown:

2008-11-19 Thread Kyle Sluder
On Wed, Nov 19, 2008 at 7:51 AM, Alexander Spohr <[EMAIL PROTECTED]> wrote: > I am trying to make a subclass of NSControl that is capable of showing > variable width (and maybe height) content. Not entirely sure what you're trying to describe here. It almost sounds like you just want to embed you

Re: NSNumberFormatter problem with percentage

2008-11-19 Thread Quincey Morris
On Nov 19, 2008, at 03:37, Graham Cox wrote: I'm a bit puzzled by NSNumberFormatter when trying to use it to display values from 0-1 as 0-100% in a text field. In IB, I'm simply choosing the 'Percent' preset from the menu, and using it with floats from 0 to 1, but the field ends up displayi

Re: Cocoa apps protection software

2008-11-19 Thread Nick Zitzmann
On Nov 19, 2008, at 9:53 AM, Donnie Lee wrote: Does anybody know software protection systems for Cocoa apps and bundles? Like in Windows ASProtect, Themida, etc. You're best off making your own. The only one I know of that's out there is AquaticPrime, and it's trivial to crack globally.

Re: Info request on developing codec

2008-11-19 Thread Jean-Daniel Dupas
Le 19 nov. 08 à 17:49, Arnab Ganguly a écrit : Hi All, I am planning to write a Codec for my application.Can you help on the things I need to take care also please let me know how to integrate the codec. Thanks in advance. Arnab Image Codec ? Audio Codec ? Video Codec ? Codec for Quic

Cocoa apps protection software

2008-11-19 Thread Donnie Lee
Hi! Does anybody know software protection systems for Cocoa apps and bundles? Like in Windows ASProtect, Themida, etc. Donnie. ___ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) Please do not post admin requests or moderator comments to the list.

Re: Passing TableView information into a new dialog

2008-11-19 Thread Corbin Dunn
Le Nov 18, 2008 à 1:22 PM, Luis a écrit : Hello My objective is to when a user right-clicks on a row in a TableView and selects from the context menu an option, to show a new dialog that handles that option. How would I go to let the new dialog to know the information that was present in

Info request on developing codec

2008-11-19 Thread Arnab Ganguly
Hi All, I am planning to write a Codec for my application.Can you help on the things I need to take care also please let me know how to integrate the codec. Thanks in advance. Arnab ___ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) Please do not po

Re: OpenGL + NSTextView/NSTextContainer?

2008-11-19 Thread Jean-Daniel Dupas
Le 19 nov. 08 à 17:16, Karan, Cem (Civ, ARL/CISD) a écrit : On Wednesday, November 19, 2008 9:04 AM Jean-Daniel Dupas wrote: Do you need text editing capability, or just text drawing ? If this is text drawing, I don't see what NSTextView provide that is not possible with NSAttributedString,

UITextView textViewDidBeginEditing issue

2008-11-19 Thread Bob Sabiston
Hi, I've got a UITextView and I am trying to add a "save" button to the top bar when the user clicks it to start editing. The UIView which contains the textview is a delegate for the TextView, so I have a textViewDidBeginEditing function something like this: - (void)textViewDidBeginEdi

RE: OpenGL + NSTextView/NSTextContainer?

2008-11-19 Thread Karan, Cem (Civ, ARL/CISD)
On Wednesday, November 19, 2008 9:04 AM Jean-Daniel Dupas wrote: > Do you need text editing capability, or just text drawing ? > > If this is text drawing, I don't see what NSTextView provide > that is not possible with NSAttributedString, and so, with > the GLString class that convert an attri

Re: Outlets / IBOutlet declarations (was Re: Interface Builder & Wiring Objects)

2008-11-19 Thread Brian Stern
On Nov 19, 2008, at 10:29 AM, Greg Titus wrote: On Nov 19, 2008, at 7:00 AM, Brian Stern wrote: This leaves us for now with two solutions: (a) Greg's (override setView:) which is more future-proof but is in many respects academically unsatisfying. (b) For non-top-level-object, specify an a

-(BOOL)handleEvent:(NSEvent*)event client:(id)sender doesn't work

2008-11-19 Thread BirdSong
Hi all,As the documents said, there are three ways to receive input from the client.one of them is keybinding(-(BOOL)inputText:(NSString*)string client:(id)sender;) which works in the sample code.another is -(BOOL) handleEvent:(NSEvent*)event client:(id)sender;I tried to use this one instead o

Re: Writing a more usable AppleEvent logger

2008-11-19 Thread Jean-Daniel Dupas
Le 19 nov. 08 à 16:42, Jean-Daniel Dupas a écrit : Le 19 nov. 08 à 15:43, Ken Tozier a écrit : On Nov 19, 2008, at 8:52 AM, Jean-Daniel Dupas wrote: The logging is performed by the application itself (I guess this is done in AESendMessage or a lower level private function for send event

Re: display callbacks

2008-11-19 Thread Alexander Cohen
Excellent. I did read the docs but i guess i stopped reading before the end of the page. thx AC On Nov 19, 2008, at 10:24 AM, Etienne Guérard wrote: Did you read the documentation reference for NSWindow? NSWindowDidChangeScreenNotification Posted whenever a portion of an NSWindow object's

Re: Writing a more usable AppleEvent logger

2008-11-19 Thread Jean-Daniel Dupas
Le 19 nov. 08 à 15:43, Ken Tozier a écrit : On Nov 19, 2008, at 8:52 AM, Jean-Daniel Dupas wrote: The logging is performed by the application itself (I guess this is done in AESendMessage or a lower level private function for send events and in AEDecodeMessage or a lower level private fun

Re: Outlets / IBOutlet declarations (was Re: Interface Builder & Wiring Objects)

2008-11-19 Thread Greg Titus
On Nov 19, 2008, at 7:00 AM, Brian Stern wrote: This leaves us for now with two solutions: (a) Greg's (override setView:) which is more future-proof but is in many respects academically unsatisfying. (b) For non-top-level-object, specify an assign attribute for the property -- and risk dang

RE: display callbacks

2008-11-19 Thread Etienne Guérard
Did you read the documentation reference for NSWindow? NSWindowDidChangeScreenNotification Posted whenever a portion of an NSWindow object's frame moves onto or off of a screen. NSWindowDidChangeScreenProfileNotification Posted whenever the display profile for the screen containing the window c

RE: placing a window in the top left corner

2008-11-19 Thread Etienne Guérard
Did you look at -[NSScreen visibleFrame]? "The returned rectangle is always based on the current user-interface settings and does not include the area currently occupied by the dock and menu bar. Because it is based on the current user -interface settings, the returned rectangle can change betw

display callbacks

2008-11-19 Thread Alexander Cohen
Hi, Is there a callback available when the display profile is changed by the user or programmatically? Also, is there a calllabck available when the user drags a window between different screens? thx AC ___ Cocoa-dev mailing list (Cocoa-dev@list

Re: Outlets / IBOutlet declarations (was Re: Interface Builder & Wiring Objects)

2008-11-19 Thread Brian Stern
On Nov 19, 2008, at 3:59 AM, mmalcolm crawford wrote: On Nov 18, 2008, at 10:01 AM, Brian Stern wrote: OK Erik, I'll bite. What you describe above is correct as far as it goes. However, when you say all the memory management is handled in one place, of course it's two. The object has t

Re: placing a window in the top left corner

2008-11-19 Thread Joseph Crawford
Wouldn't the point just be 0, 0 in that case? I'm a beginner so I am not positive. On Nov 19, 2008, at 9:47 AM, Nick Rogers wrote: Hi, whenever my app opens a second preview window, I want it to be positioned at the top left corner of the desktop screen. I have come across two methods in NS

placing a window in the top left corner

2008-11-19 Thread Nick Rogers
Hi, whenever my app opens a second preview window, I want it to be positioned at the top left corner of the desktop screen. I have come across two methods in NSWindow, they are: – setFrameTopLeftPoint: and – cascadeTopLeftFromPoint: But these require a point as input. How do I calculate this p

Re: InputManagers in Leopard

2008-11-19 Thread Michael Ash
On Wed, Nov 19, 2008 at 7:04 AM, Gerriet M. Denkmann <[EMAIL PROTECTED]> wrote: > I know that InputManagers are "now officially unsupported." And also that > "this functionality is likely to be disabled in a future release." > But while it is still possible I would like to continue using them. > >

Re: Writing a more usable AppleEvent logger

2008-11-19 Thread Ken Tozier
On Nov 19, 2008, at 8:52 AM, Jean-Daniel Dupas wrote: The logging is performed by the application itself (I guess this is done in AESendMessage or a lower level private function for send events and in AEDecodeMessage or a lower level private function for received event). I guess the ea

Re: OpenGL + NSTextView/NSTextContainer?

2008-11-19 Thread Jean-Daniel Dupas
Le 19 nov. 08 à 13:39, Karan, Cem (Civ, ARL/CISD) a écrit : On Tue, 18 Nov 2008 12:26:04 -0800 (PST) Erik Buck wrote: Open GL has no built-in capability for drawing text. Open GL provides lower level primitives like lines and curves and meshes. Open GL also provides texture compositing. Th

Re: Writing a more usable AppleEvent logger

2008-11-19 Thread Jean-Daniel Dupas
Le 19 nov. 08 à 13:36, Ken Tozier a écrit : On Nov 17, 2008, at 3:51 AM, Jean-Daniel Dupas wrote: Le 17 nov. 08 à 08:06, Ken Tozier a écrit : What do you mean by "this tool" ? export is used to set an environment variable. I guess that system functions that send and receive event just

Re: [MyClass class] returning superclass's class

2008-11-19 Thread Andy Lee
On Nov 19, 2008, at 7:32 AM, Ken Tozier wrote: I wrote a subclass of NSCharacterSet and at runtime, when I do [MyClass class] it returns the superclass's class rather than the class value. I suspect this is "normal" but was wondering if there is a way to get my subclass's class rather than i

Re: [MyClass class] returning superclass's class

2008-11-19 Thread Jean-Daniel Dupas
Le 19 nov. 08 à 13:32, Ken Tozier a écrit : Hi I wrote a subclass of NSCharacterSet and at runtime, when I do [MyClass class] it returns the superclass's class rather than the class value. I suspect this is "normal" What make you think this is normal ? How do you create your instance ?

Changing Services HotKey at Runtime

2008-11-19 Thread Xavier Snark
Greetings, In my application I would like to change the Services Hotkey combination at runtime. So far, the only Apple documentation that I have found states that the hotkey is configured via the Info.plist file in the application bundle. http://developer.apple.com/documentation/Cocoa/Concep

editWithFrame:inView:editor:delegate:event: in mouseDown:

2008-11-19 Thread Alexander Spohr
Hi list, I am trying to make a subclass of NSControl that is capable of showing variable width (and maybe height) content. Something like a one-row NSTableView without a header. Or like an NSMatrix with variable cell sizes. I tried to do it with only one cell to draw the content which works

Re: OpenGL + NSTextView/NSTextContainer?

2008-11-19 Thread Karan, Cem (Civ, ARL/CISD)
On Tue, 18 Nov 2008 12:26:04 -0800 (PST) Erik Buck wrote: > Open GL has no built-in capability for drawing text. Open GL > provides lower level primitives like lines and curves and > meshes. Open GL also provides texture compositing. > > There are some free and some open text drawing/font so

Re: Writing a more usable AppleEvent logger

2008-11-19 Thread Ken Tozier
On Nov 17, 2008, at 3:51 AM, Jean-Daniel Dupas wrote: Le 17 nov. 08 à 08:06, Ken Tozier a écrit : What do you mean by "this tool" ? export is used to set an environment variable. I guess that system functions that send and receive event just check if the env var is set and log appropriat

[MyClass class] returning superclass's class

2008-11-19 Thread Ken Tozier
Hi I wrote a subclass of NSCharacterSet and at runtime, when I do [MyClass class] it returns the superclass's class rather than the class value. I suspect this is "normal" but was wondering if there is a way to get my subclass's class rather than it's superclass. __

InputManagers in Leopard

2008-11-19 Thread Gerriet M. Denkmann
I know that InputManagers are "now officially unsupported." And also that "this functionality is likely to be disabled in a future release." But while it is still possible I would like to continue using them. So I copied my thing into the /Library/InputManagers folder. Then did sudo chown -R r

Binding to managedObjectContexts using dictionary hangs

2008-11-19 Thread Arthur C.
I have a Core Data application with a double Core Data implementation, that is, there are two managedObjectModels, persistentStoreCoordinators and managedObjectContexts. These are referenced by the following methods: // appDelegate.h - (NSPersistentStoreCoordinator *) persistentStoreCoordinatorFor

Re: NSDecimalNumber & NSString question

2008-11-19 Thread Steven Riggs
I would like to add, if you don't use something to validate the user input of your text fields you, will crash with non numeric characters. Steven Riggs On Nov 19, 2008, at 2:36 AM, Ashley Clark <[EMAIL PROTECTED]> wrote: On Nov 18, 2008, at 4:28 PM, Brooke Gravitt wrote: Hello, I'm tryin

RE: Core data save error with multiple persistent stores [SOLVED]

2008-11-19 Thread Arthur C.
A solution is to have 2 persistentStoreCoordinators and 2 managedObjectContexts, with the Coordinators each having one single persistent store. It is clear that there can be no reassignment problems anymore. However, I don't understand why this seems to be required; that is, why can't I have two m

NSNumberFormatter problem with percentage

2008-11-19 Thread Graham Cox
I'm a bit puzzled by NSNumberFormatter when trying to use it to display values from 0-1 as 0-100% in a text field. In IB, I'm simply choosing the 'Percent' preset from the menu, and using it with floats from 0 to 1, but the field ends up displaying everything 100x too big, i.e. input is 0.5

Re: Opening Ports in Leopard

2008-11-19 Thread Gerriet M. Denkmann
On 19 Nov 2008, at 15:59, Kyle Sluder wrote: On Wed, Nov 19, 2008 at 12:08 AM, Gerriet M. Denkmann <[EMAIL PROTECTED]> wrote: In an other programm (doing Distributed Objects between computers) I found out that int y = bind( newSocket, (struct sockaddr *)&serverAddress, sizeof(serverAd

Re: Window title bar accessory view

2008-11-19 Thread Houdah - ML Pierre Bernard
Hi Kyle! Thanks a lot. This sounds like a great idea. I will give it a try ASAP. Pierre On 19 Nov 2008, at 04:03, Kyle Sluder wrote: On Tue, Nov 18, 2008 at 9:26 PM, Houdah - ML Pierre Bernard <[EMAIL PROTECTED]> wrote: I would like to replicate the accessory views found in the top right o

Re: Window title bar accessory view

2008-11-19 Thread Houdah - ML Pierre Bernard
Hi Andrew, No I am not talking about the toolbar. I am referring to the lock icon and the new green certificate information text displayed by Safari in the window's title bar. iCal displays a pop-up menu where one can pick the time zone. Pierre On 19 Nov 2008, at 03:52, Andrew Merenbach wr

Re: Noobie Question: NSTableView and XML-RPC

2008-11-19 Thread Kyle Sluder
On Tue, Nov 18, 2008 at 1:42 PM, Kennard Smith <[EMAIL PROTECTED]> wrote: > I'd imagine just setting a dataSource then querying the XML-RPC server for > data when tableView:objectValueForTableColumn:row: is called. The documentation tells you this is a very bad idea: "Note: tableView:objectValue

Re: Binding a CoreData string value to an NSTextView

2008-11-19 Thread mmalcolm crawford
On Nov 18, 2008, at 8:42 PM, John Joyce wrote: Has anyone had any success Binding a CoreData string value to an NSTextView? Everything I try seems to be flumoxed by the NSAttributedString of the NSTextStorage backing store.

Re: release and reference counting query

2008-11-19 Thread mmalcolm crawford
On Nov 18, 2008, at 10:33 AM, Marc Stibane wrote: Lets forget for a moment that the dealloc never get's called at all on the iPhone This is simply untrue. viewController = [[UIViewController alloc] initWithNibName:@"MoveMeView" bundle:[NSBundle mainBundle]]; since "viewC

Re: Outlets / IBOutlet declarations (was Re: Interface Builder & Wiring Objects)

2008-11-19 Thread mmalcolm crawford
On Nov 17, 2008, at 9:33 PM, Jeff Laing wrote: How about: http://developer.apple.com/samplecode/CacheInfo-MacOSX/listing1.html (for example) which has the IBOutlet tag on the instance variables rather than the properties; I'll bet its different because properties and instance vars have the same

Re: Opening Ports in Leopard

2008-11-19 Thread Kyle Sluder
On Wed, Nov 19, 2008 at 12:08 AM, Gerriet M. Denkmann <[EMAIL PROTECTED]> wrote: > In an other programm (doing Distributed Objects between computers) I found > out that >int y = bind( newSocket, (struct sockaddr *)&serverAddress, > sizeof(serverAddress) ); > wants to have the data in "truc

Re: Outlets / IBOutlet declarations (was Re: Interface Builder & Wiring Objects)

2008-11-19 Thread mmalcolm crawford
On Nov 18, 2008, at 10:01 AM, Brian Stern wrote: OK Erik, I'll bite. What you describe above is correct as far as it goes. However, when you say all the memory management is handled in one place, of course it's two. The object has to be released. The normal place to release objects is

Re: release and reference counting query

2008-11-19 Thread Marc Stibane
Am 18.11.2008 um 20:05 schrieb Andy Lee: On Nov 18, 2008, at 1:33 PM, Marc Stibane wrote: Am 07.11.2008 um 13:17 schrieb Roland King: On Nov 7, 2008, at 7:59 PM, Calum Robertson wrote: Below is a snippet of code from the "Creating an iPhone Application" document from the iPhone DevCenter.

Re: Input Managers perspective

2008-11-19 Thread Charles Srstka
On Nov 18, 2008, at 12:42 PM, Donnie Lee wrote: I plan to use Input Managers hack to add functionality to closed-source software. I know that these hacks are not a good programming technics, but there is no other way except using it. I have only one question: will Input Managers be available in

<    1   2