Re: Build Issue?

2009-09-01 Thread Ricky Sharp
On Sep 1, 2009, at 4:10 PM, Thomas Willson wrote: Is there anything else I can include to help someone answer my question? My next step might have to be reinstalling the OS. Begin forwarded message: From: Thomas Willson Date: August 31, 2009 10:53:50 PM PDT To: cocoa-dev@lists.apple.com S

Re: UITableView Custom cell with image

2009-09-22 Thread Ricky Sharp
Please post your code. One app I have displays a list of 1,089 items. Three rows are visible on the screen and each row displays an image of size 89 x 128. I use the standard method of reusing table cells and simply assign the image only when the cell is to be displayed. There is some stutt

Re: iPhone to Mac Synchronization

2009-09-24 Thread Ricky Sharp
This is possible, but only over WiFi. I'm currently working on a feature to do bi-directional syncing between the Mac and iPhone versions of my app. I'm also using Bonjour for self-discovery (if you go this route, make sure to register your service at www.dns-sd.org) Feel free to file an en

Re: UIControl touchInside property

2009-09-29 Thread Ricky Sharp
I believe there is some "slop" area for controls in general. For example, the Edit button in the nav bar in Mail when in a list of messages. The initial tap must be within the defined bounds. But when tracking off or back in, the bounds used to determine in vs out is larger. That property a

Re: NSURLRequest

2009-10-10 Thread Ricky Sharp
On Oct 10, 2009, at 9:36 AM, DKJ wrote: I've got an NSArray that I initialise with data from a plist stored on a remote webserver. I've been doing it like this: NSURL *url = [NSURL URLWithString:@"http://www.server.com/ data.plist"]; NSArray *myArray = [NSArray arrayWithContentsOf

Re: Language based scanning

2009-10-13 Thread Ricky Sharp
You probably do not want to approach things this way. Arabic is bidirectional and you may have situations where you have a mixture of languages. What you should look at instead is to just localize your app to Arabic. In the Arabic version of your nibs, make the necessary adjustments. Se

Re: language based scaning

2009-10-15 Thread Ricky Sharp
On Oct 15, 2009, at 1:11 PM, Nz Gmail wrote: what I'm trying to do is sort of Twitter client, in which the tweets can be English or Arabic so in case of Arabic the alignment should be from right to left, i hope I made it clear this time cheers In that case, you can probably scan the te

Re: sizeWithAttributes Cutting Off Drop Shadow, Italic Mask?

2009-10-30 Thread Ricky Sharp
On Oct 30, 2009, at 10:10 AM, Chunk 1978 wrote: does sizeWithAttributes not take into account the offset of an NSDropShadow or italic font mask? i have a dictionary of attributes for a string, and i'm trying to produce an image for the drag that doesn't crop the image with these attribut

Re: Where are the interface builder components?

2009-11-17 Thread Ricky Sharp
On Nov 16, 2009, at 9:28 PM, Sandro Noël wrote: > I guess i'll have to make my own. > I just find it sad to have to duplicate work, it's unproductive. True, but keep in mind the amount of effort that Apple would need to do if they provided the custom control, etc: * Must work with localized c

Re: Locale based font

2009-11-23 Thread Ricky Sharp
I am about to play around with something similar. In my iPhone app, I have some calls with boldSystemFontOfSize. But, for certain locales, it should be a plain font and the size may need to be tweaked. I then had an idea to write a static method to obtain a font style and size based on loca

Re: iPad: UIImagePickerController

2010-04-07 Thread Ricky Sharp
On Apr 7, 2010, at 3:37 PM, Development wrote: > How do you use the image picker controller on the iPad? My iphone version > works fine but I get a UI Mess on the iPad. > And now it crashes telling me I have to use a popover: > > *** Terminating app due to uncaught exception 'NSInvalidArgumen

Re: [iPhone] File coping application

2010-04-26 Thread Ricky Sharp
On Apr 26, 2010, at 11:40 AM, Kyle Sluder wrote: > On Mon, Apr 26, 2010 at 9:04 AM, Arun wrote: >> Is it possible to copy files form iPhone on to a Mac when iPhone is >> connected to USB? > > No. Just to add though that you _can_ transfer files via WiFi. But of course, only for those files

Re: [iPhone] Frustrated by a simple task

2010-05-12 Thread Ricky Sharp
On May 12, 2010, at 5:25 PM, WT wrote: > The client I'm writing an app for wants a splash screen with some information > that cannot go in the launch image (because it's dynamically generated), > meaning that the first view controller to ever be instantiated will have in > its view an image vi

Re: Original iPhone animation performance

2010-05-19 Thread Ricky Sharp
On May 19, 2010, at 3:01 AM, Andrew wrote: > Im writing some code to animate an image moving up the display, just a simple > thing moving from the bottom to the top. > > the image is 75x75, and Im displaying that in a CALayer sized to 45x45 by > setting its .contents property to the .CGImage o

Re: Cracks in image using NSDrawThreePartImage

2010-05-19 Thread Ricky Sharp
On May 19, 2010, at 4:30 PM, Ken Ferry wrote: > File a bug with a test case that shows the problem. > > I would expect there to be seams due to rounding error if you look in pixie, > but I have never seen a case where it was visible to the eye at actual > scale. I only recall seeing this when

Re: -[NSMutableSet randomObject]

2010-05-25 Thread Ricky Sharp
On May 25, 2010, at 11:49 AM, Michael A. Crawford wrote: >// If the array is empty, throw an exception. The caller should know > better. >// If there is only one, return object zero every time. >// If there are only two, alternate with every access. >// If there are three or mor

Re: six things I wasn't able to do with Cocoa

2010-05-28 Thread Ricky Sharp
On May 28, 2010, at 11:20 AM, Bill Appleton wrote: > on printing, the problem is that i have to port an enterprise application > that expects to be able to call a fx for the page layout and the page setup > dialog, a fx to begin/end a page, and a fx to begin/end printing. > > so Cocoa has this a

Re: Button width should accomodate localized string

2009-11-30 Thread Ricky Sharp
On Nov 29, 2009, at 9:52 AM, glenn andreas wrote: > On Nov 29, 2009, at 9:38 AM, Symadept wrote: > >> How can I scale my button or Label to be able to accomodate the localized >> string? > > That's the whole purpose of being able to localize the nib/xib... Exactly. It's not possible to create

Localization strategies?

2009-12-20 Thread Ricky Sharp
In getting quotes from many localization companies, I've found that some have different processes. For example, one company would prefer if I just provide .string files. During their QA process, they'll then run the app and look at everything in context. While generating .strings from nibs i

Re: Localization strategies?

2009-12-22 Thread Ricky Sharp
Thank you all for the replies. Here's my final plan: (1) Have separate nibs for each language. I agree with those that say you cannot have a one-size-fits-all layout. Each nib will thus carry layout, font size, style, etc. that makes sense for a particular language. I've already "pseudo-loca

Re: Localization strategies?

2009-12-23 Thread Ricky Sharp
On Tuesday, December 22, 2009, at 09:59PM, "Kyle Sluder" wrote: >On Tue, Dec 22, 2009 at 11:54 AM, Ricky Sharp wrote: >> (2) Externalize all strings from the nibs and put them into >> Localizable.strings.  This allows me to have a single file to hand off to >>

Re: Localization strategies?

2009-12-23 Thread Ricky Sharp
On Dec 23, 2009, at 7:38 AM, Jerry Krinock wrote: > > Well, Ricky I see you're one of the few who has really thought through all > the issues. > > On 2009 Dec 22, at 19:59, Kyle Sluder wrote: > >> On Tue, Dec 22, 2009 at 11:54 AM, Ricky Sharp wrote: >>

Re: Resolution Independence

2010-01-05 Thread Ricky Sharp
On Jan 5, 2010, at 2:50 PM, Todd Heberlein wrote: > A friend of mine loves her new 27" iMac but has complained at how small > everything is. Searching around on the net I found that it has about a 109 > dpi pixel density. I also saw today that the new Nexus phone has a pixel size > of 800x480

Re: Dead iPhone Simulator :-(

2010-01-14 Thread Ricky Sharp
On Jan 14, 2010, at 3:27 PM, Michael Rogers wrote: > I'm running Mac OS X 10.6.2, and just installed the iPhone SDK 3.1.2. When I > launch anything in the simulator, it crashes, and I get a message complaining > about the Telephony state (which I believe is California :-) > > Jan 14 15:25:01

Re: Make sheets open instantly

2010-01-18 Thread Ricky Sharp
On Jan 18, 2010, at 7:19 PM, Chris Hanson wrote: > On Jan 18, 2010, at 2:43 PM, David Catmull wrote: > >> Is there any way to make sheets open instantly, instead of animating? I'd >> just like to speed up my unit tests. > > Why do your unit tests need to bring up sheets? Can't speak for the

Re: Using NSKeyedArchiver to save and restore state on iPhone apps

2010-02-10 Thread Ricky Sharp
On Feb 10, 2010, at 12:40 PM, Jason Bobier wrote: > As many of you know, saving and restoring complex navigation hierarchies on > the iPhone can be a real chore. So, I had this brilliant idea of setting up > my app delegate like this: > > applicationDidFinishLaunching > if userdefaults c

Re: iPhone and OS X apps question

2010-02-11 Thread Ricky Sharp
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

Re: Hot to move focus to a button?

2010-03-07 Thread Ricky Sharp
On Mar 7, 2010, at 3:53 AM, Joanna Carter wrote: > Hi Kyle > >> Buttons don't accept keyboard focus. See the documentation for >> -[NSView canBecomeKeyView] and the related conceptual documentation. > > I realise this to be what the docs say but, if you use -makeFirstResponder: > the focus rin

Re: Touchscreens and control scaling

2009-06-04 Thread Ricky Sharp
On Jun 4, 2009, at 2:51 AM, Joe Ranieri wrote: On Jun 4, 2009, at 03:44, Ben wrote: Hi list, I've been sketching out an application and could do with a little advice on which cocoa-direction to take. It's a full-screen (kiosk) type app, running in a very controlled environment (not for

Re: What is the best way to store some kind of identifying string in an interface builder object?

2009-06-18 Thread Ricky Sharp
On Jun 18, 2009, at 5:15 PM, Chilton Webb wrote: Hi Greg! Thanks for writing back. On Jun 18, 2009, at 4:52 PM, Greg Guerin wrote: Is there a way to add a tag an IB object in such a way that it is not visible to the user, but in such a way that I could reference it from my app? Maybe the

Re: Yet another memory management question

2009-07-05 Thread Ricky Sharp
On Jul 5, 2009, at 4:02 AM, Benjamin Dobson wrote: On 5 Jul 2009, at 05:10:12, mmalc Crawford wrote: If you manipulate an instance variable anywhere other than in an initialiser or a dealloc method, you should use a suitable accessor method. Does this apply to instance variables that ar

Re: Clarification on accessors? (was: Yet another memory management question)

2009-07-09 Thread Ricky Sharp
On Jul 8, 2009, at 10:16 PM, Jeff Laing wrote: No, it doesn't. It would in fact violate the encapsulation principle if your -dealloc method required your accessors to not rely on certain state. The "ability to override accessors violates encapsulation" because it adds additional restric

Re: Japanese Language

2009-07-15 Thread Ricky Sharp
On Jul 15, 2009, at 5:36 PM, Development wrote: Ok, I lucked out and got a great chance at releasing a bit of software in japan. The problem is that it is 50/50 client to web. My primary concerns are string translation from iPhoneOS to data being stored in a mysql database. I have spent qu

Re: Where to release in UIView

2009-07-18 Thread Ricky Sharp
On Jul 18, 2009, at 1:09 PM, DKJ wrote: On 18-Jul-09, at 8:50 , Fritz Anderson wrote: You have to release shadingAreas. You alloc'ed it, you own it. Yes, I realise that. What I'm wondering is where to do it, since it's initialised in the awakeFromNib method, rather than in initWithFrame

Re: Borderless window and focus

2009-07-21 Thread Ricky Sharp
On Jul 21, 2009, at 4:56 PM, ss2 cire wrote: I have the following code to initialize a borderless window for "fullscreen" - (void)initFullScreenWindow { NSScreen *theScreen = [[NSScreen screens] objectAtIndex:0]; NSRect screenRect = NSMakeRect(0, 0, [theScreen frame].size.width, [

Re: Disabling Exposé in SystemUIMode

2009-08-05 Thread Ricky Sharp
On Aug 5, 2009, at 8:45 PM, Pierce Freeman wrote: I am wondering if anyone knows of a way to disable Exposé in SystemUIMode. I am using this class to create a kiosk-based application and don't want the user to be able to switch between other windows. If there isn't a way to do this insid

Re: Disabling Exposé in SystemUIMode

2009-08-06 Thread Ricky Sharp
On Aug 5, 2009, at 9:39 PM, Pierce Freeman wrote: Which version of OS X are you using? With the latest of Leopard, it just doesn't seem to work. When writing my initial response to this thread, it was 10.5.7. Just tested with 10.5.8 and all is still well (no Expose, no process switchin

Re: Disabling Exposé in SystemUIMode

2009-08-06 Thread Ricky Sharp
On Aug 6, 2009, at 10:10 AM, Pierce Freeman wrote: Yeah, I completely copied his code and inserted it into my project. Even odder, it doesn't allow the Apple-Tab function (which is what it is supposed to do) but lets Exposé work just fine. I don't mean that it broke in the latest version

Re: NSKeyedArchiver on OSX to NSKeyedUnarchiver iOS

2010-08-11 Thread Ricky Sharp
On Aug 11, 2010, at 4:32 PM, glenn andreas wrote: > > On Aug 11, 2010, at 3:53 PM, Sandro Noël wrote: > >> Greetings >> >> I'm having problems unarchiving my data in the iphone. >> >> here is the workout. >> >> 1: I archive a AttributedString to my CoreData NSData property using >> NSKeyeda

Re: [iPhone] How to change Default.png Image Dynamically

2010-08-21 Thread Ricky Sharp
On Aug 21, 2010, at 7:39 AM, Tharindu Madushanka wrote: > But it seems like iPhone Phone app has some different Default.png images.. > When you exit from Keypad menu.. it will load one image.. > > When you exit from other tabs, Default image is some other.. Is it possible > to do similar thing ?

Re: NSCoding between iOS and Mac OS X

2010-08-25 Thread Ricky Sharp
A similar question came up recently. While some objects (e.g. NSNumber) things should be binary compatible. But you may run into issues. Also depends upon what objects you are coding. Mac OS X uses NSColor whereas iOS uses UIColor. I would recommend using an intermediate normalized format in

Re: UIView animation

2010-09-02 Thread Ricky Sharp
On Sep 2, 2010, at 5:11 PM, Christian Ziegler wrote: > I could use your help because I'm running out of ideas! > > Here's the situation. I got this custom view on screen which I want to remove > from the screen by moving it outside the left border of the screen. However > at the same time, I w

Re: Declaring a property named "private" and ObjC++

2010-09-28 Thread Ricky Sharp
On Sep 28, 2010, at 6:19 PM, Nick Zitzmann wrote: > Okay, I tried searching, and didn't find anything pertinent... > > How do I create a property for a class named "private" and not have the > Objective-C++ compiler trip on it? > > Here's what I first tried: > > @property(assign,getter=isPriv

Re: Help with Basics (Was: help with bindings)

2010-11-21 Thread Ricky Sharp
On Nov 21, 2010, at 2:59 AM, Rounak Jain wrote: > Thanks Jerry, > I have used the dictionaryWithObjectsAndKeys: method. > I have implemented your suggestions regarding "convenience constructors" and > myKeys object. Regarding your comment about making everything "mutable", I > think, at the mom

Re: NSString/NSFont/Dingbats and the SnowFlake symbol

2010-11-24 Thread Ricky Sharp
On Nov 24, 2010, at 1:58 PM, Kyle Sluder wrote: > On Wed, Nov 24, 2010 at 11:35 AM, Stephen Blinkhorn > wrote: >> On 24 Nov 2010, at 12:56, Murat Konar wrote: >> >>> Beware the user that has removed all fonts that contain a snowflake... >> >> Yeah, I did wonder about such a thing. But why wou

Re: iPad: UI Implications

2010-11-26 Thread Ricky Sharp
On Nov 26, 2010, at 9:02 AM, Phillip Mills wrote: > I don't have any specific questions or problems associated with this but I'm > curious about attitudes, techniques, patterns, or tools that others have > found helpful going from Mac to iOS. At a high level, you don't "go from Mac to iOS". i

Re: Getting current mouse position after scroll

2010-12-01 Thread Ricky Sharp
On Dec 1, 2010, at 9:19 PM, Rick Mann wrote: > I have a view that shows the coordinates of the current mouse location in it. > I update this via -mouseMoved: But if the user scrolls the view with a scroll > ball, I don't get mouse moved events. > > 1) What's the best way to react to scroll cha

Re: Obscuring an NSString

2010-12-05 Thread Ricky Sharp
On Dec 5, 2010, at 4:31 PM, Adam Gerson wrote: > Thanks to all who responded. Let me explain my situation a little > better. I am storing several string values into an XML file. I want to > obscure one of them. When I encrpyt the NSString to an NSdata I can > store the data as a string in XML, ho

Re: Getting nextKeyView to work

2010-12-10 Thread Ricky Sharp
On Dec 9, 2010, at 9:25 PM, Stevo Brock wrote: > Hi All, > > I'm having trouble getting things set up so that I can tab between my > NSTextViews properly. I have a window that has a TabView as the only > top-level view. When I put 3 TextViews in the first tab, I have not yet been > able to

Re: assign property behaves differently from simple instance variable???

2010-12-13 Thread Ricky Sharp
On Dec 13, 2010, at 1:31 PM, Wim Lewis wrote: > > On 13 Dec 2010, at 11:01 AM, Matt Neuburg wrote: >> How can this seemingly minor change make such a big difference? I'm not even >> *using* the synthesized accessor! Yet its mere presence breaks the project. >> How can this be? m. >> >> PS A n

Re: NSKeyedArchiver on iOS and Cocoa

2010-12-20 Thread Ricky Sharp
On Dec 20, 2010, at 8:22 PM, lorenzo7...@gmail.com wrote: > Are these two compatible? Can something archived one platform be unarchived > on the other? I can't find anything in docs that addresses this, but I'm > havig trouble doing precisely this (archived on iPhone, unarchived on > MacOSX).

Re: Text rendering/editing on OSX & iOS

2010-12-21 Thread Ricky Sharp
On Dec 21, 2010, at 7:04 AM, Kenneth Baxter wrote: > Hi, I have an application which I plan to roll out on both iOS and MacOS X, > and it needs to display text in various places on a series of views. I am > doing all the drawing using the Core technologies (CGContext drawing) to make > the max

Re: Function-Key Unicodes

2010-12-22 Thread Ricky Sharp
On Dec 22, 2010, at 1:44 PM, k...@highrolls.net wrote: > I call: > > NSString *chars = [theEvent charactersIgnoringModifiers]; > > in -keyDown > > The docs say > > Function-Key Unicodes > > These constants represent Unicode characters (0xF700–0xF8FF) that are > reserved for function k

Re: UITableView with only 1 row selectable

2010-12-24 Thread Ricky Sharp
On Dec 24, 2010, at 4:01 AM, Roland King wrote: > Why not do it the other way around. Set allowsSelection to YES and then > implement the delegate method tableView:willSelectRowAtIndexPath: to return > nil for any row you do NOT want selected (see the documentation). That seems > to be apple's

Re: UITableView with only 1 row selectable

2010-12-24 Thread Ricky Sharp
On Dec 24, 2010, at 11:28 AM, Remco Poelstra wrote: > Hi, > > I'm unable to find that method. Is it still available? > > Kind regards, > > Remco > > Op 24 dec. 2010 om 14:01 heeft Ricky Sharp het volgende > geschreven: > >> >> On Dec 24

Re: Sending multiple files via Bluetooth using GameKit

2011-01-20 Thread Ricky Sharp
You can but keep in mind the following: The max packet size is 87K so for larger blocks of data, you will have to break things up. You will need a mini state machine to keep track of what was sent vs. what is left to send. And will of course need all the logic to handle error conditions, retr

Re: Guidance for Cocoa's steep learning curve

2008-05-14 Thread Ricky Sharp
On May 14, 2008, at 8:19 PM, Erik Buck wrote: I would just like to add the following: (1) It also depends upon prior framework experience as to how easy or difficult it will be to dive into Cocoa. I learned event-driven programming very early and had the advantage of either using or a

Localization and plural rules revisited

2008-05-19 Thread Ricky Sharp
There was a very short thread on NSLocalizedString regarding plural rules: My app is mainly localization ready, but I still need to modify some problem code regarding plurals. Specifically, I have code which takes some qu

Re: Localization and plural rules revisited

2008-05-20 Thread RICKY SHARP
On Tuesday, May 20, 2008, at 04:54AM, "Horst Hoesel" <[EMAIL PROTECTED]> wrote: > >Am 20.05.2008 um 05:02 schrieb Ricky Sharp: > >> There was a very short thread on NSLocalizedString regarding plural >> rules: >> >> [snip] > >> In Rus

Re: Localization and plural rules revisited

2008-05-20 Thread Ricky Sharp
On May 20, 2008, at 12:08 PM, Peter Edberg wrote: CLDR (Common Locale Data Repository) has some draft data on plural forms for various languages. See for specific rules and

Re: Localization and plural rules revisited

2008-05-20 Thread Ricky Sharp
On May 20, 2008, at 3:40 PM, Gary L. Wade wrote: On May 20, 2008, at 12:08 PM, Peter Edberg wrote: CLDR (Common Locale Data Repository) has some draft data on plural forms for various languages. See

Re: Localization and plural rules revisited

2008-05-20 Thread Ricky Sharp
On May 20, 2008, at 3:27 PM, Peter Edberg wrote: On May 20, 2008, at 12:48 PM, Ricky Sharp wrote: On May 20, 2008, at 12:08 PM, Peter Edberg wrote: CLDR (Common Locale Data Repository) has some draft data on plural forms for various languages. See <http://unicode.org/cldr/data/cha

Re: Localization and plural rules revisited

2008-05-20 Thread Ricky Sharp
On May 20, 2008, at 5:20 PM, Gerriet M. Denkmann wrote: What is to be done for "Move %d units to the right and %d steps up" ? So far, I don't have any strings that have two or more phrases within them. But I can see the potential issue. I suppose one would just need to do all permutat

Re: Garbage collector vs variable lifetime

2008-06-06 Thread Ricky Sharp
On Jun 6, 2008, at 5:48 PM, Bill Bumgarner wrote: On Jun 6, 2008, at 3:23 PM, Quincey Morris wrote: In a GC-only app, I frequently use a pattern along these lines: NSData* data = ; const unsigned char* bytes = [data bytes]; NSUInteger count = [data length]; for

Re: Garbage collector vs variable lifetime

2008-06-06 Thread Ricky Sharp
On Jun 6, 2008, at 6:42 PM, Bill Bumgarner wrote: Sorry -- let me clarify. If the was either released in a different thread or if were explicitly released in the above code, then you would see the same crash. I didn't mean to imply that would be released under non-GC without some

Re: Garbage collector vs variable lifetime

2008-06-07 Thread Ricky Sharp
On Jun 7, 2008, at 8:18 AM, Michael Ash wrote: It *does* do this. The error is not in the GC, but rather in the assumption that "declared in the current scope" is equivalent to "is on the stack frame". This assumption is not valid. The fact that you can't make this assumption is extremely incon

Re: Garbage collector vs variable lifetime

2008-06-07 Thread Ricky Sharp
On Jun 7, 2008, at 1:30 PM, Michael Ash wrote: On Sat, Jun 7, 2008 at 9:59 AM, Ricky Sharp <[EMAIL PROTECTED]> wrote: Finally, I think that usages of NSMutableData may also be a bit tricky. In my case I'll probably just obtain a copy of its bytes, manipulate them and then copy

Re: Garbage collector vs variable lifetime

2008-06-07 Thread Ricky Sharp
On Jun 7, 2008, at 2:07 PM, Jean-Daniel Dupas wrote: Le 7 juin 08 à 20:30, Michael Ash a écrit : On Sat, Jun 7, 2008 at 9:59 AM, Ricky Sharp <[EMAIL PROTECTED]> wrote: I will hope though that within the context of say memcpy, that the GC thread could not collect data. For exampl

Re: Converting string to encoding

2008-06-14 Thread Ricky Sharp
On Jun 14, 2008, at 9:43 AM, Dex Morgan wrote: I need to encode a quoted-printable text and convert it to given encoding according to the headers of a message. I've used some code but the result is wrong. For example =C3=A8 should be 'è' but the result is two symbols (the sqrt symbol and an

Re: NSSound thread-safety?

2008-06-16 Thread Ricky Sharp
On Jun 16, 2008, at 7:07 PM, Jens Alfke wrote: This has mostly been working fine, but now I'm occasionally getting crashes. Is NSSound thread-safe? Now that I look, I can't find any documentation; the Cocoa thread safety docs don't refer to NSSound at all. It's been the practice such th

Re: Newbie interface questions - multiple "modal" windows

2008-06-17 Thread Ricky Sharp
On Jun 17, 2008, at 9:30 AM, Matthew Youney wrote: The screens in out operator interfaces have to be mutually exclusive for a number of reasons. Configuration in one area cannot be altered unless configuration in another area has been completed. Product configuration cannot be taking pla

Re: Grand Central Details

2008-06-17 Thread Ricky Sharp
On Jun 17, 2008, at 7:17 PM, Pierce T. Wetter III wrote: I had a release the week before, plus we didn't have enough tickets since WWDC was sold out, so I didn't go. Are there any details on Grand Central? First, Snow Leopard is under NDA; cannot discuss it here. If you've ever used

Re: NSTextField: is it possible to avoid selecting contents on focus?

2008-07-04 Thread Ricky Sharp
On Jul 4, 2008, at 6:01 AM, Paul Hoadley wrote: The default behaviour of an NSTextField is apparently to select its contents on gaining focus. Is there any way to avoid this, and, say, put the cursor at the end of any content instead? You should be able to set a delegate and use contro

Re: Working with Paragraphs in Core Text

2008-07-08 Thread Ricky Sharp
On Jul 8, 2008, at 3:23 PM, Iain Delaney wrote: I'm trying to format some text using the new Leopard Core Text API. Paragraphs, and the CTParagraphStyle object seem to have been passed over in the documentation, getting just a cursory mention. Has anyone else managed to get paragraph styl

Re: Working with Paragraphs in Core Text

2008-07-08 Thread Ricky Sharp
On Jul 8, 2008, at 6:13 PM, Iain Delaney wrote: I was having problems with both the creation of the style and the application of it. I think you example will work once I have the style defined, but I'm still not clear on how you make the style. The documentation is short of examples on this

Re: the 11th can't come soon enough :-)

2008-07-10 Thread Ricky Sharp
... s many questions I have, mostly to do with media APIs. I'm bursting at the seams with inquiries, and I look very forward to being able to discuss them with others :-) Please wait until an official communication comes from Apple. The NDA may still be in place even after the 11th.

Re: Any good advice for naming parameters of init methods?

2008-07-10 Thread Ricky Sharp
On Jul 10, 2008, at 11:19 AM, glenn andreas wrote: The problem is that while when you recompile you'll see the conflict, for existing users (who won't be compiling from source), if they use KVC they'll have the problem. @interface NSFoo { id _reserved; } @end @interface MyFoo: NSFo

Re: IBPlugin cannot load

2008-07-16 Thread Ricky Sharp
On Jul 16, 2008, at 2:44 PM, Anders Lassen wrote: The answers to your questions are: 1) Principals Class name is: "MyControls". That is also the name of the IBPlugin class. 2) I only have one class description file, that is "MyControlsView.classdescription". Note that I have only one cus

Re: [Newbie] Extracting a specific character number from a string

2008-08-06 Thread Ricky Sharp
On Aug 6, 2008, at 5:23 PM, Phil Faber wrote: I'm trying to learn more about string manipulation and want to be able to extract a single character from a string. I think I need to use subStringWithRange (exacting from and to the same character location) but I'm not sure and I'm also unsur

Re: Question about respondsToSelector

2008-08-18 Thread Ricky Sharp
On Aug 18, 2008, at 1:17 PM, Carmen Cerino Jr. wrote: Does the id type have enough information for the respondsToSelector method to work. I have a class with an ivar of type id, and when I invoke the respondsToSelector method it fails when it should succeed. I am assuming it should work fi

Re: Using Flex/Lex in a Cocoa project

2008-08-18 Thread Ricky Sharp
On Aug 18, 2008, at 3:40 PM, mm w wrote: to avoid the splitting problem (c < 128) ? "%c" : "\\u%04x", c); I'm not sure what this solves. Per Michael's e-mail below, this is indeed a difficult problem. UTF-8 is just a particular scheme to store Unicode strings. Operating on individual

Re: Using Flex/Lex in a Cocoa project

2008-08-18 Thread Ricky Sharp
On Aug 18, 2008, at 8:01 PM, John Joyce wrote: On Aug 18, 2008, at 7:01 PM, [EMAIL PROTECTED] wrote: to avoid the splitting problem (c < 128) ? "%c" : "\\u%04x", c); Not quite sure what this is doing. I see it's checking for ASCII range if ( c < 128 ) The conditional is obvious, but what'

Re: Using Flex/Lex in a Cocoa project

2008-08-19 Thread Ricky Sharp
On Aug 18, 2008, at 10:57 PM, Michael Ash wrote: Note that depending on what kind of results you want, even if all of your data is within the BMP, this *still* won't save you. As a really basic example, consider a simple, obvious character like é. (That's an e with an acute accent on it if you

Re: Preventing windows from being dragged

2008-08-21 Thread Ricky Sharp
On Aug 21, 2008, at 9:46 PM, Mike wrote: Yeah, I've read that technote and am familiar with it. It doesn't have what I need. And there's no setting in IB to create a window without a titlebar (and I don't want to create one programatically). Then you're out-of-luck. Creating a non-movab

Re: Preventing windows from being dragged

2008-08-22 Thread Ricky Sharp
On Aug 22, 2008, at 2:13 PM, Charles Srstka wrote: On Aug 21, 2008, at 10:02 PM, Ricky Sharp wrote: Creating a non-movable, non-titled window is _trivial_. Just create a tiny subclass and away you go. I do this myself, along with following the guidelines of that technote. Why would it

Re: Preventing windows from being dragged

2008-08-22 Thread Ricky Sharp
On Aug 22, 2008, at 2:46 PM, Charles Srstka wrote: On Aug 21, 2008, at 10:02 PM, Ricky Sharp wrote: (1) never ever ever capture the display when using AppKit. This appears to be incorrect, as Apple seems to endorse and even provides sample code for capturing the screen while using AppKit

Re: Semi-transparent, blurred NSWindow background?

2008-08-25 Thread Ricky Sharp
On Aug 25, 2008, at 12:57 PM, David Duncan wrote: On 25/08/2008, at 2:45 AM, Tim Andersson wrote: Is there any way of creating a NSWindow that has a semi- transparent, blurred background? With "blurred background" I mean that whatever you see through the window/background is distorted (bl

Re: Convert unicode string into ascii

2008-08-28 Thread Ricky Sharp
Just to point this out, the sequence of ASCII may not be useful at all if the file is say Unicode. The actual bytes making up each char could be "ASCII" values themselves. Sent from my iPhone On Aug 28, 2008, at 1:53 PM, Martin Stoufer <[EMAIL PROTECTED]> wrote: The simplest way I've accom

Re: Undocumented Leopard support for overlapping sibling views

2008-08-28 Thread Ricky Sharp
On Aug 28, 2008, at 3:28 PM, Nathan Vander Wilt wrote: According to two list postings (http://lists.apple.com/archives/cocoa-dev/2007/Nov/msg01760.html , http://lists.apple.com/archives/cocoa-dev/2007/Nov/msg01764.html) both by Apple employees, overlapping sibling subviews are fully support

Re: Convert unicode string into ascii

2008-08-28 Thread Ricky Sharp
On Aug 28, 2008, at 3:40 PM, Andrew Farmer wrote: On 28 Aug 08, at 12:08, Ricky Sharp wrote: Just to point this out, the sequence of ASCII may not be useful at all if the file is say Unicode. The actual bytes making up each char could be "ASCII" values themselves. Unicode is a

Re: programatically quit a program

2008-08-28 Thread Ricky Sharp
On Aug 28, 2008, at 3:49 PM, Ken Thomases wrote: On Aug 28, 2008, at 3:38 PM, Wayne Shao wrote: But the terminate function takes an id for sender. What shall I use? In this case, you're the sender so you can pass "self". Or, if you're within an action method (IBAction) you can forward t

Re: Accessibility Voiceover questions

2008-09-10 Thread Ricky Sharp
On Sep 10, 2008, at 2:44 PM, Matthew Mashyna wrote: I have a custom view that is a subclass of NSView with a bunch of subviews. When Voiceover is on it will speak the text that is in the subviews but that's not what I want. I would like my view class to control what is spoken but I can't

Re: [ABAddressBook addressBook] vs. [ABAddressBook sharedAddressBook]

2008-09-23 Thread Ricky Sharp
On Sep 23, 2008, at 5:44 PM, David Riggle wrote: What is the use of the new Leopard call [ABAddressBook addressBook]? I played around with it, and it seems to be functionally equivalent to [ABAddressBook sharedAddressBook]. From the docs, the former gives you a new instance of an address

Re: Fastest color detection in image?

2008-09-26 Thread Ricky Sharp
On Friday, September 26, 2008, at 09:04AM, "Christian Klotz" <[EMAIL PROTECTED]> wrote: >I'm trying to scan an image for existence of a given color. So I was >wondering what the most performing way is to achieve this goal. You probably want to look into direct-pixel access (there are some co

Re: 10.5.2 release notes?

2008-03-06 Thread Ricky Sharp
On Mar 6, 2008, at 8:48 AM, Sean McBride wrote: On 3/6/08 12:23 PM, Jonathan Dann said: Hi Guys, Does anyone know if there are some release notes specific for 10.5.2? I remember reading on some blog that there was an NSTreeController bugfix. I can't seem to be able to find any details on Go

Re: NSUserDefaults and mutability

2008-03-09 Thread Ricky Sharp
On Mar 9, 2008, at 5:58 AM, Trygve Inda wrote: On 8 Mar '08, at 1:57 PM, Trygve Inda wrote: Is this expected? Can I rely on it? I will never need to change dict, but I am modifying items within a known sub Dictionary. Don't rely on this; it's entirely possible this behavior could change in

Re: How to get this bundle with identifier

2008-03-09 Thread Ricky Sharp
On Mar 9, 2008, at 6:48 AM, Nick Rogers wrote: In my app I need to get the icon for my HDD. For this I need to get the bundle with identifier "com.apple.iokit.IOStorageFamily". How can i get this bundle? Any help would be greatly appreciated. Please do at least some minimal searching. H

Re: What's the trick to eliminating 'halos' on buttons?

2008-03-14 Thread RICKY SHARP
On Thursday, March 13, 2008, at 11:11PM, "Dave Hersey" <[EMAIL PROTECTED]> wrote: >Set the control's focus ring to "none" in IB. Please don't do that as this will not make your app fully accessible. >On Mar 13, 2008, at 11:56 PM, Todd Blanchard wrote: > >> I've got this pane with a bunch of ch

Re: Creating Custom Views in Interface Builder

2008-03-14 Thread Ricky Sharp
On Mar 14, 2008, at 1:51 PM, Jeff LaMarche wrote: I wrote an article for MacTech a while back on doing this... it may be a little outdated by now since it was written when Tiger was new, but may still contain some useful info: http://www.mactech.com/articles/mactech/Vol.21/21.10/Palettes/i

Re: Disable Exposé / Spaces / Dashboard

2008-03-15 Thread Ricky Sharp
On Mar 15, 2008, at 7:21 PM, Mike Abdullah wrote: I'd suggest a readup on the SetSystemUIMode() function. Should do what you want I think. That function works very well to disable Expose. I've used it in my app for a few years now. It will also disable things like Command-Tab (to swit

  1   2   >