Re: iOS: encoding a custom view with a shape in it

2011-06-11 Thread Steve Christensen
How do the results differ between what you saw before and after saving the document? Is everything wrong? or just the scaling, the rotation, what? And to draw an object, are you using an affine transform just to rotate it or for scaling and/or translation as well? On Jun 9, 2011, at 4:25 PM, D

Re: iOS: encoding a custom view with a shape in it

2011-06-11 Thread Steve Christensen
And also to clarify, are you "freeze drying" a view or the objects it draws? You should be doing the latter since that's part of your model. On Jun 11, 2011, at 6:47 PM, Steve Christensen wrote: > How do the results differ between what you saw before and after saving t

Re: iOS: encoding a custom view with a shape in it

2011-06-15 Thread Steve Christensen
ngles and ellipses. I had assumed that you created shape classes to hold the properties (frame, rotation, color, etc.) and to draw those shapes. > On Jun 11, 2011, at 6:49 PM, Steve Christensen wrote: > >> And also to clarify, are you "freeze drying" a view or the objects it d

Re: Animating handwriting

2011-06-23 Thread Steve Christensen
Is this a correct interpretation of what you're trying to do? You have a title string that will be drawn in a handwriting font. You wish to reveal each of the letter strokes over time as if someone were actually writing the title on a piece of paper. On Jun 23, 2011, at 9:45 AM, Gustavo Pizano

Re: How to resolve bulk warning "Creating selector for nonexistent method ..."?

2011-07-05 Thread Steve Christensen
For the nonexistent method warnings, your project- or target-level settings likely have "Undeclared Selector" checked in the GCC warnings section of the build settings. For the multiple selectors warnings, look at the Strict Selector Matching item in the same section. It says this will pop up i

Re: How to resolve bulk warning "Creating selector for nonexistent method ..."?

2011-07-06 Thread Steve Christensen
#x27;s fixed. > > thanks, > arri > > > On Tue, Jul 5, 2011 at 9:17 PM, Steve Christensen wrote: >> For the nonexistent method warnings, your project- or target-level settings >> likely have "Undeclared Selector" checked in the GCC warnings section of the

Re: iOS: AVFoundation, AVAssetWriter and caching

2011-07-06 Thread Steve Christensen
With the caveat that I haven't actually tried it, would it make more sense to be streaming the movie data to a local file, then specifying the URL/path to the file in the initializer method of one of the movie player classes? If the player can handle the case where not all the movie data is pres

Re: IOS graphics

2011-07-11 Thread Steve Christensen
The first thing I notice is that none of the CGContext* calls after UIGraphicsBeginImageContext is referring to that image context so they are having no effect on it. You should move the UIGraphicsGetCurrentContext down after the [drawImage...] call. If you are still not able to get the desired

Re: iPhone: validate a NSString for US zipcode

2010-01-07 Thread Steve Christensen
As others have pointed out, letting the service do the validation takes the onus off of your app to keep itself up-to-date. If you get an error, though, I would let the user know that the zip code is invalid and give them an opportunity to fix it or choose a different one. The user shouldn

Re: CGImageCreate performance

2010-01-07 Thread Steve Christensen
If I'm understanding you correctly, it sounds like you're effectively displaying a window into a larger image. If that's the case, how about tiling the big image and creating sections wrapped in CGImages that intersect the display area? You could then manage a cache where tiles get purged o

Re: NSColorPanel question

2010-01-18 Thread Steve Christensen
A bit of the crash log showing the backtrace and reason for crashing would be much more helpful than just saying that it crashed. Secondly, NSColorPanel is a floating panel so its behavior isn't really oriented towards modally opening it, selecting a color and closing it. You'd normally cli

Re: Keeping closed windows in the Window menu

2010-01-18 Thread Steve Christensen
Just a guess that they're known windows, so items are added to the Window menu in IB. On Jan 18, 2010, at 11:23 AM, Andreas Eriksson wrote: What's the recommended way of keeping a window in the Window menu (like e.g. Address book and iChat does) so that it can be brought back even after it h

Re: Keeping closed windows in the Window menu

2010-01-18 Thread Steve Christensen
- [NSWindow setExcludedFromWindowsMenu:]? On Jan 18, 2010, at 11:58 AM, Andreas Eriksson wrote: That would still require some effort to prevent the window (and the separator) to be listed twice, I assume? On Mon, Jan 18, 2010 at 8:38 PM, Steve Christensen wrote: Just a guess that they&#x

Re: NSView : Background bitmap drawing issue

2010-02-15 Thread Steve Christensen
While there could be a drawing but in the OS, it's probably best to rule out issues with your code first. How do you determine the OS version? I ask because that's the only version-specific test in your drawing code. I would do something like this to initialize the variables: double major

Re: Null value from NSMutableArray

2010-02-15 Thread Steve Christensen
You could expect to see zero/nil values returned from object properties if the object pointer is nil. Adding NSLog(@"%p", fooObj); would tell you if that's the case. Also, I'm not sure how your question relates to NSMutableArray since, at least in your code snippet, you don't do much with i

Re: super call in the middle of a block of code ..

2010-02-19 Thread Steve Christensen
Although it looks like your code is leaking a NSIndexPath each time through because you retain it on "if (editing)" and release it on "if (!editing)". On Feb 18, 2010, at 7:53 AM, Luke the Hiesterman wrote: This seems fine to me. Generally, when subclassing, the contract is that you must

Re: How to detect if mouse on border of view

2010-02-19 Thread Steve Christensen
On Feb 18, 2010, at 8:44 PM, Mazen M. Abdel-Rahman wrote: 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 w

Re: super call in the middle of a block of code ..

2010-02-19 Thread Steve Christensen
ase where setEditing is called with YES twice without an intervening setEditing:NO. On 20-Feb-2010, at 12:07 AM, Steve Christensen wrote: Although it looks like your code is leaking a NSIndexPath each time through because you retain it on "if (editing)" and release it on "i

Re: Deprecated APIs

2010-02-23 Thread Steve Christensen
On Feb 23, 2010, at 2:09 AM, charisse napeÿf1as wrote: I am not sure if this problem has already been submitted but how do I define two APIs, one that is supported from Leopard down and another that is only supported in Snow Leopard if I only have one binary for all OSes? Below is a sni

Re: Deprecated APIs

2010-02-23 Thread Steve Christensen
On Feb 23, 2010, at 3:26 PM, Charles Srstka wrote: On Feb 23, 2010, at 2:25 PM, Steve Christensen wrote: As others have already pointed out, it's your choice of whether or not to support a deprecated API method. When I decide to use OS version-specific API methods, I code as follows

Re: Deprecated APIs

2010-02-24 Thread Steve Christensen
On Feb 24, 2010, at 11:04 AM, Bill Bumgarner wrote: On Feb 23, 2010, at 8:57 PM, Steve Christensen wrote: That code uses blocks, though, which implies that it will be compiled using a later version of Objective-C. Will that code really run on older versions of OS X? The compile-time

Re: Store more complex values into NSDictionary

2010-02-25 Thread Steve Christensen
On Feb 25, 2010, at 2:59 PM, Dave Carrigan wrote: On Feb 25, 2010, at 2:51 PM, Daniel Káčer wrote: i need help with solution about store more complex values into NSDictionary. I have following data which i need store in NSDictionary: value1:@"A1" value2:@"B1" key:1 value1:@"A2" value2:@"B2"

Re: 10.6 Base, 10.5 Target, runs fine on everything except Intel 10.5

2010-03-09 Thread Steve Christensen
The class NSRunningApplication only exists on 10.6 and later. Are you doing a runtime check before using it? Class nsRunningAppClass = NSClassFromString(@"NSRunningApplication"); if (nsRunningAppClass != NULL) { // 10.6 case... NSRunningApplication* currentApplication = [nsRunningAppC

Re: Get Users/Shared full path and its localized dir name

2009-05-29 Thread Steve Christensen
On May 29, 2009, at 4:27 PM, Erg Consultant wrote: How can I get the full path to the Users/Shared dir and the dir's localized name? FSRef usersSharedFSRef; if (FSFindFolder(kOnAppropriateDisk, kSharedUserDataFolderType, kDontCreateFolder, &usersSharedFSRef) == noErr) { NSString* user

crash in -[_NSArrayControllerTreeNode _safeNodeAtIndexPath:]

2009-06-06 Thread Steve Christensen
I'm seeing a crash in -[_NSArrayControllerTreeNode _safeNodeAtIndexPath:] but I'm not really sure why. That would be "why" in the sense of what -[_NSArrayControllerTreeNode _safeNodeAtIndexPath:] might be doing or of something I should or shouldn't have done vs. saying that it crashed becau

Re: crash in -[_NSArrayControllerTreeNode _safeNodeAtIndexPath:]

2009-06-09 Thread Steve Christensen
ex.pl?NSTreeControllerBugOrDeveloperError The post from Frank at the bottom of the above page gives a solution that worked for me. However, you should only use this code on 10.4. The problem was fixed on 10.5. Dave On Jun 6, 2009, at 4:32 PM, Steve Christensen wrote: I'm seeing

processing AppleEvents if a modal window is open?

2009-06-16 Thread Steve Christensen
I am working on a plugin that runs inside a host app. Some of its configuration is handled inside a modal window ([NSApp runModalForWindow:window]) since the host app doesn't directly support more complicated configuration options. As part of the process, the plugin needs to query the host

Re: extending NSSavePanel, how to disable button?

2009-06-24 Thread Steve Christensen
I haven't tried myself, but just checking the headers it looks like the closest thing would be to make your controlling class the delegate and then implement either - (BOOL)panel:(id)sender isValidFilename:(NSString *)filename; or - (NSString *)panel:(id)sender userEnteredFilename:(NSString

Re: Which drawing tool for a simple task

2009-06-25 Thread Steve Christensen
I can think of at least a couple of ways of doing that without creating a custom view: 1. Create a new image that is a composite of the original image and the border image, then set the view's image to the composite. 2. Create two image views that occupy the same space and put the border

Re: Number of images in main bundle folder (iPhone)

2009-06-25 Thread Steve Christensen
You mean that quick perusal of NSBundle.h didn't turn up anything? Maybe my headers are different from yours, but it was really easy to come up with that line myself: NSUInteger jpegCount = [[[NSBundle mainBundle] pathsForResourcesOfType:@"jpg" inDirectory:subDirName] count]; On Jun 25,

Re: Base SDK and deployment target Q

2009-06-27 Thread Steve Christensen
I don't believe such a switch exists since it's not really a compiler issue: using a 10.5+ method is completely legal for your configuration. A quick way to check what 10.5 methods you're using would be to set the SDK to 10.4 temporarily and see what errors you get. You can then make sure y

Re: Base SDK and deployment target Q

2009-06-28 Thread Steve Christensen
one else run the app under 10.4. It's kind of a pain, but if I can just switch the SDK and run it under Leopard, that's fine. Thanks again. On Sat, Jun 27, 2009 at 8:42 PM, Steve Christensen wrote: I don't believe such a switch exists since it's not really a compiler i

Re: 10.4 & 10.5 compatibility

2009-06-28 Thread Steve Christensen
On Jun 28, 2009, at 5:09 PM, Stephen Blinkhorn wrote: I have just noticed that some standard Cocoa objects look very different on 10.4 compared to 10.5. In particular NSPopUpMenu and NSButton objects are being drawn as much larger controls on 10.4 (rounded rect style, mini size). I am cre

Re: Disabling buttons in NSSavePanel

2009-06-29 Thread Steve Christensen
A question about disabling the Save button was just asked on this list a few days ago. The thread is archived here: . Google is your friend... steve On Jun 29, 2009, at 6:45 AM, Michael Domino wrote: I use an NSSavePane

Re: Re[2]: NSApp problem outside of bundle

2009-06-29 Thread Steve Christensen
On Jun 29, 2009, at 3:22 PM, Peter Mulholland wrote: Monday, June 29, 2009, 11:12:20 PM, you wrote: You don't use kCurrentProcess as an argument. You use it like this: ProcessSerialNumber psn = { 0, kCurrentProcess }; TransformProcessType( &psn, ... ); I see. It isn't really explained all t

Re: Determining OS at Runtime

2009-07-02 Thread Steve Christensen
On Jul 1, 2009, at 5:22 PM, Sherm Pendley wrote: On Wed, Jul 1, 2009 at 7:24 PM, iseecolors wrote: I need to support 10.4 in my application, but it uses some Carbon APIs that are deprecated in 10.5 and I am using some new 10.5 APIs that require the 10.5 SDK. I am sure I have seen this bef

Re: Determining OS at Runtime

2009-07-02 Thread Steve Christensen
On Jul 2, 2009, at 4:29 PM, Steve Christensen wrote: On Jul 1, 2009, at 5:22 PM, Sherm Pendley wrote: On Wed, Jul 1, 2009 at 7:24 PM, iseecolors wrote: I need to support 10.4 in my application, but it uses some Carbon APIs that are deprecated in 10.5 and I am using some new 10.5 APIs that

Re: Determining OS at Runtime

2009-07-03 Thread Steve Christensen
On Jul 2, 2009, at 9:56 PM, Andrew Farmer wrote: On 2 Jul 2009, at 16:29, Steve Christensen wrote: If you want to make sure that you don't include any "old" code in your executable when you decide to make 10.5 (for example) your base OS version, you could arrange your code l

Re: Determining OS at Runtime

2009-07-03 Thread Steve Christensen
n (sVersion >= 0x1050); } On Jul 3, 2009, at 9:00 AM, Mark Munz wrote: You might also just use Gestalt: BOOL IsLeopardOrLater(void) { SInt32 vers; Gestalt(gestaltSystemVersion,&vers); return (vers >= 0x1050); } On Fri, Jul 3, 2009 at 6:59 AM, Steve Chri

Re: How to share Cocoa classes?

2009-07-06 Thread Steve Christensen
I build a number of plugins and ended up with a lot of shared code so I ended up creating a project that builds a static library with all those pieces, then make all my plugin targets dependent on it so that it gets [re-]built first. I created a common include file that includes all the hea

Re: TableView displaying a zillion empty rows

2009-07-06 Thread Steve Christensen
On Jul 6, 2009, at 11:50 AM, Greg Guerin wrote: Brian Hughes wrote: -(int) numberOfRowsInTableView: (NSTableView *)aTableView { int returnValue; if (aTableView == gameScoresTableView) //This works as expected { if (currentIndex_>= 0)

Re: How to share Cocoa classes?

2009-07-06 Thread Steve Christensen
where it should be located? Should I create my own directory system or is it better to use some standard (system) directories for that? If I must use my own directories, then where should I add a path to them to avoid the necessarity to add this path to every new XCode project manually? T

Re: TableView displaying a zillion empty rows

2009-07-07 Thread Steve Christensen
On Jul 6, 2009, at 8:20 PM, Brian Hughes wrote: I really appreciate your other points about my error code -- I never thought about what the tableView might do if -1 was returned and now that I think about it I don't really want to find out so I changed it to 0. Others have already given y

Re: NSSavePanel delegate Methods called by NSOpenPanel

2009-07-10 Thread Steve Christensen
On Jul 9, 2009, at 6:40 AM, Daniel Demiss wrote: Hi all, I'm a little confused by the following situation: I have an NSPathControl (PopUp-Style) that should only allow certain paths to be selected. Therefore I have a controller-object that I set as the delegate of the NSPathControl and the NS

Re: NSScrollView

2009-07-11 Thread Steve Christensen
The view hierarchy is: NSScrollView -> NSClipView -> YourDocumentView. I believe all you need to do is set the frame of your document view to be the size needed to represent your diagram and then everything else should "just work," i.e., the scrollbars should correctly reflect the relative

Re: 10.4 vs 10.5 SDK - some problems in compilation

2009-07-15 Thread Steve Christensen
On Jul 15, 2009, at 5:10 AM, Alexander Bokovikov wrote: I'm rather new in XCode and Cocoa, so maybe it's my misunderstanding. Am I correct in my understanding, that I need to select 10.4 SDK in XCode project menu to create an application, compatible with both Tiger and Leo? I've got few err

Re: Ideas required on testing an application install

2009-07-19 Thread Steve Christensen
On Jul 19, 2009, at 12:24 PM, Ian Piper wrote: On 19 Jul 2009, at 6:46pm, Andy Lee wrote: On Jul 19, 2009, at 7:45 AM, Ian Piper wrote: How do you get the SD card to act as a bootable drive? Did you try Google? A search for "boot sd card macbook" turned up this as the first hit:

Re: [iPhone] UITableView cell display bugs ?

2009-07-20 Thread Steve Christensen
From what you've said below, you probably should be creating a custom cell type based on UITableViewCellStyleSubtitle and add the third label to your class. At least in NSTableView (I haven't yet played with the iPhone), a cell class determines what is drawn at a particular row/column locat

Re: Exception-like behavior in save panel used for file choose

2009-07-31 Thread Steve Christensen
You could very well be taking an exception. Given this possibility, why haven't you tried wrapping your code in -pushChooseButton: in a @try/@catch block and either just dumping out the exception (if any) and/or putting a breakpoint in the @catch to see what the state of the world is? If yo

Re: Converting colors to CGFloat

2009-07-31 Thread Steve Christensen
On Jul 31, 2009, at 2:31 AM, Matthias Schmidt wrote: how do I convert color values from longint or UInt16 as they were used with the carbon API to CGFloat used with NSColor? I assume you're talking about something like QuickDraw's RGBColor, where color components range from 0 to 65535? You

Re: Adding string encodings CoCoa

2009-08-16 Thread Steve Christensen
Well, certainly one way would be to preprocess the text buffer, converting the custom characters into a standard encoding like UTF-8, then passing the processed buffer into +[NSString stringWithUTF8String:]. At that point it would "just work" since it's in a known encoding. Depending on w

Re: Coding with VM limitation on the iPhone?

2009-08-18 Thread Steve Christensen
On Aug 18, 2009, at 4:53 PM, Jonathon Kuo wrote: On Aug 18, 2009, at 4:37 PM, Luke the Hiesterman wrote: Your app will not be paged to the disk at all. It must run entirely on in physical memory. To know when you're running out of memory, override -[UIViewController didReceiveMemoryWarning]

Re: Accessing method from another class

2009-08-20 Thread Steve Christensen
If your logging code is displaying a message on entry to resetTextAndBar:, but nothing after that, it sounds like you're taking an exception. In your code snippet below, you're calling [self updateText], but in the last sentence of your problem description, you mention a method called updat

Re: NSTextField too slow to update

2009-08-22 Thread Steve Christensen
On Aug 22, 2009, at 6:41 PM, PCWiz wrote: I have a large list of files that are being copied in my app, and after each file I need it to update the NSTextField so that it reads something like this: Processing file X of X The problem is that the text field is way too slow in updating its

Re: Drawing over a transparent background

2009-08-24 Thread Steve Christensen
On Aug 23, 2009, at 10:00 PM, Ron Fleckner wrote: On 24/08/2009, at 2:29 PM, Rob Keniger wrote: On 24/08/2009, at 9:33 AM, Ron Fleckner wrote: My borderless window has a semi-transparent background. When the drawing in a subview changes, the background retains a ghost of the original draw

Re: Transparent IKImageBrowserView

2010-07-23 Thread Steve Christensen
This worked for me: NSColor* browserBackgroundColor = [NSColor colorWithCalibratedWhite:0.10 alpha:0.60]; [_effectsBrowser setValue:browserBackgroundColor forKey:IKImageBrowserBackgroundColorKey]; Are you sure that it's not working for you? Perhaps a superview has a non-transparent backgroun

Re: draw NSAttributedstring with transparency

2010-07-23 Thread Steve Christensen
On Jul 23, 2010, at 3:53 AM, Bernard Knaepen wrote: > I need to draw an NSAttributedString over an image. The characters of the > string might have different sizes, fonts and colors. > > I am currently using the drawAtPoint method but I would like to specify a > global opacity (transparency) t

Re: Discard all drawing in a UIView

2010-07-24 Thread Steve Christensen
myself the effort and use the exception handling mechanism. Problem is > that after I extract and draw a few strings of valid ranges, I run into the > exception. So, at this point I would like to clear out all drawing and do my > error string handling bit. > > Thanks > Ge

-remoteControlReceivedWithEvent: is not getting called

2010-07-27 Thread Steve Christensen
I am trying to get remote control events to start/stop some audio my app is playing, but -remoteControlReceivedWithEvent: isn't getting called. My app has a tab bar that switches among multiple views, if that makes any difference. The view controller for each view implements the setup per Apple'

Re: Truncating UIActionSheet labels

2010-07-27 Thread Steve Christensen
Although you say that the button labels are generated dynamically, does it really not make sense for you to generate the alert title and/or message strings dynamically and use static button labels (OK/Cancel, Yes/No, etc.)? Both of those fields are set up to resize to fit the strings. Otherwise

Re: IKImageView choppy?

2010-07-31 Thread Steve Christensen
Your browser's -imageBrowser:itemAtIndex: data source method returns objects that conform to the IKImageBrowserItem informal protocol. You can specify -imageRepresentationType to return IKImageBrowserNSImageRepresentationType and have -imageRepresentation return a reasonably-sized thumbnail imag

Re: iOS: UITableViewCell an textlabel?

2010-08-04 Thread Steve Christensen
It's actually cleaner to create your custom views in the designated initializer, as Bill showed below. The only thing missing is that if you correctly set the custom view's autoresizingMask property, the view will resize as the cell resizes, rather than you needing to manually change it in -lay

Re: CGColorSpaceCreateWithName on iOS

2010-08-12 Thread Steve Christensen
Apparently you should use CGColorSpaceCreateDeviceRGB(). In the documentation for that function, it says: "In Mac OS X v10.4 and later, this color space is no longer device-dependent and is replaced by the generic counterpart—kCGColorSpaceGenericRGB—described in “Color Space Names”. If you use

Re: Using Apple icons

2010-08-16 Thread Steve Christensen
On Aug 16, 2010, at 5:52 AM, Sean McBride wrote: > Ryan Joseph (r...@thealchemistguild.org) on 2010-08-16 20:48 said: > >> What is Apples policy on using their icons in commercial application >> icons? I wanted to use some of the common app icons that are standard to >> OS X (like Mail, Safari, S

Controls created at runtime aren't drawn as enabled until a mouse click...

2010-09-09 Thread Steve Christensen
I have a window and controls that are loaded from a nib. One of the controls builds a subview hierarchy to control a set of parameters that aren't known until runtime. What I'm finding is that all of the controls in that hierarchy are drawn as if they're disabled until you click on them, then th

Re: Controls created at runtime aren't drawn as enabled until a mouse click...

2010-09-09 Thread Steve Christensen
7;re using an NSBorderlessWindowMask window? If so, you may need > to override canBecomeKeyWindow. > > Kevin > > > On Sep 9, 2010, at 11:12 AM, Steve Christensen wrote: > >> I have a window and controls that are loaded from a nib. One of the controls >> builds a subview hierar

Re: NSFileManager and Resource Forks

2010-10-26 Thread Steve Christensen
On Oct 26, 2010, at 7:26 PM, k...@highrolls.net wrote: > Is there a way to write a resource fork for a file at a path? I don't believe that NSFileManager knows about resource files, either in the resource or data fork. You can use Resource Manager routines FSCreateResourceFile() or FSCreateRes

Re: rotate UIImage based on rotation of UIView

2010-12-03 Thread Steve Christensen
One thing I noticed is that you're using the transform from wrapperView, which may not exclusively have your modifications applied. Have you tried caching the resultant scale, translation and rotation values from any gestures and then using those values to create a new transform from scratch? S

Re: Working with CGImage and Retina Display

2010-12-15 Thread Steve Christensen
I believe the issue is that CGImage just refers to an image with an effective scale factor of 1.0, no matter the device scale. It sounds like you need to somehow keep track of the image scale you're using so that you're always drawing at the correct size. One way would be to use +[UIImage imageN

Re: [iPhone] can't get views not to slide off by the height of the status bar

2011-01-26 Thread Steve Christensen
On Jan 25, 2011, at 3:24 PM, WT wrote: > On Jan 25, 2011, at 8:45 PM, Dave Carrigan wrote: > >> When the docs say that a UINavigationController can be a tab in a tab bar >> interface, they mean a UITabBarController, not a UIViewController that >> happens to implement a tab bar interface. > > I

Re: How to scale a TabBarItem Image

2011-01-26 Thread Steve Christensen
On Jan 26, 2011, at 3:10 AM, ico wrote: > Everything is fine except that my images for UITabBarItem is not scale to fit > the item size to be displayed properly. As > it should be as described in the UITabBarItem documentation: > *image* > > The item’s image. If nil, an image is not displayed. >

Re: How to scale a TabBarItem Image

2011-01-27 Thread Steve Christensen
aled to fit if I use TabBarController, but what I > am doing is that I try to implement TabBarController feature by myself by > subclassing UIViewController and implement the TabBarDelegate. > > On Wed, Jan 26, 2011 at 11:31 PM, Steve Christensen wrote: >> On Jan

Re: stripped down webview

2012-08-18 Thread Steve Christensen
How about asynchronously downloading the page HTML into a string, doing a text replace of the name of the CSS file to your local one, then passing the modified HTML to the web view? Sent from my iPhone On Aug 18, 2012, at 6:52 AM, Koen van der Drift wrote: > > On Aug 18, 2012, at 7:24 AM, K

Re: Optimal height for WebView

2013-01-04 Thread Steve Christensen
On Jan 4, 2013, at 10:40 AM, Mike Abdullah wrote: > On 4 Jan 2013, at 18:12, Eric Gorr wrote: > >> Good point Mike. >> >> However, after it has completed the layout, is it possible to determine the >> height of the content? If so, i could probably work with that information. >> >> But, I woul

Re: How to tell if iTunes is running.

2008-05-24 Thread Steve Christensen
Would something like this work better? It should deal with localization or if the user renames iTunes for some reason. iTunesIsOpen = NO; NSWorkspace* workspace = [NSWorkspace sharedWorkspace]; NSString* iTunesPath = [workspace absolutePathForAppBundleWithIdentifier:@"com.apple.iTunes"]; NSA

Re: How to tell if iTunes is running.

2008-05-24 Thread Steve Christensen
gelmeier pointed out in a separate message, Apple doesn't currently localize the names of its iApps so you're probably safe. On May 24, 2008, at 12:17 PM, Mr. Gecko wrote: because I do not need the path for what I am doing. On May 24, 2008, at 2:05 PM, Steve Christensen wro

Re: How to tell if iTunes is running.

2008-05-24 Thread Steve Christensen
On May 24, 2008, at 2:11 PM, Jens Alfke wrote: On 24 May '08, at 12:05 PM, Steve Christensen wrote: Would something like this work better? It should deal with localization or if the user renames iTunes for some reason. ... if ([[applicationD objectForKey:@"NSAppli

Re: Faster way to test pixels?

2008-05-25 Thread Steve Christensen
On May 25, 2008, at 4:34 AM, Graham Cox wrote: On 25 May 2008, at 5:13 pm, Jens Alfke wrote: Is there any faster way of doing this than just iterating over the pixels like this? I can't think of anything but someone might have a bright idea. If you do test against pixels, work with the ra

drawer attached to modal window is unresponsive

2008-05-30 Thread Steve Christensen
I'm working on a plugin that needs to do some involved setup, and I'm handling this in a modal window since the setup has to be done in an atomic fashion. The window also has an attached drawer. What I'm finding is that I can open and close the drawer, and a table view in the drawer will sc

Re: drawer attached to modal window is unresponsive

2008-05-30 Thread Steve Christensen
as all but dumped them in their own programs -- Mail.app's sidebar, for instance, is now a source list in the main window, instead of being in a drawer. Cheers, Andrew On May 30, 2008, at 12:55 PM, Steve Christensen wrote: I'm working on a plugin that needs to do some invo

Re: Why does this https post request always return "404 Not Found"

2008-06-22 Thread Steve Christensen
Hmmm... Google not working? - lists the APIs for a variety of programming languages at the bottom of the page. - is an open source Cocoa del.icio.us client, so you should be able to see what they did. On J

Re: [Moderator] List Guidelines - Must Read

2008-06-27 Thread Steve Christensen
On Jun 27, 2008, at 8:25 AM, Devon Ferns wrote: I agree. It's not like what's in the SDK is super secret. Anyone can download it. Yeah, anyone can download it, but in order to download it, you have to go through the process of accepting a license agreement that includes a NDA restrictio

Re: Trying to display a static image on my window. Any tips would be great

2008-07-01 Thread Steve Christensen
On Jul 1, 2008, at 6:41 AM, Papa-Raboon wrote: I have been trying to get a static image to display in a corner of my window and it has to literally just sit there and do nothing however I have searched and searched Apple's dodumentation but no success yet. I have dropped an Image View onto the

Re: Trying to display a static image on my window. Any tips would be great

2008-07-01 Thread Steve Christensen
ing as I wanted now. Someone kindly pointed out that if I created my image with an Alpha chanel that it could also have transparencies too which worked beautifully. I just need to figure out how to hyperlink it so it can open a URL in a browser now. Cheers Paul 2008/7/1 Steve Christensen <[EMAI

Re: How to converting a Carbon nib to Cocoa?

2008-07-02 Thread Steve Christensen
This question was asked recently on the carbon-dev list and the answer was that there is no way to automate the process, nor even a method to get you part-way. Unfortunately this is likely to be one of those painful transitions for you... On Jul 2, 2008, at 8:31 PM, Fosse wrote: It would

Re: Does this caution need fixed? (newb)

2008-07-03 Thread Steve Christensen
On Jul 3, 2008, at 9:40 AM, Chris Paveglio wrote: Also, should my code be "caution free" as a sign of clean coding or can some cautions that don't affect functionality be dismissed? I'm one of those people who turns on just about every warning and then fixes the code that generates the warn

Re: Does this caution need fixed? (newb)

2008-07-03 Thread Steve Christensen
On Jul 3, 2008, at 11:57 AM, Chris Paveglio wrote: My code is like this: NSMutableString *theSettings; theSettings = [[NSMutableString alloc] init]; //myPrefs is an array of strings, each item is like "Library/Safari" int i; for (i = 0; i < 8; i++ { theSettings = [NSHomeDirect

Re: iPhone: Implementing search and index combo, like Contacts?

2008-07-15 Thread Steve Christensen
On Jul 15, 2008, at 7:48 AM, Michael Dupuis wrote: I'm assuming the NDA has been lifted now... Nope, still under NDA, as mentioned a few days ago: From: Cocoa Dev Admins <[EMAIL PROTECTED]> Date: July 10, 2008 7:01:39 PM PDT To: Cocoa-Dev List Subject: [Moderator] iPhone SDK is still under

Re: Detecting platform architecture within Cocoa app?

2008-07-29 Thread Steve Christensen
On Jul 29, 2008, at 12:56 PM, Jack Skellington wrote: Is there a way to determine if an App is running on Intel or PPC from within the App? Depending on what you're trying to do, you can go at least a couple routes at build time. If you only care about endianness: #ifdef __BIG_ENDIAN__ #i

Re: Checking for hackintosh

2008-07-30 Thread Steve Christensen
On Jul 30, 2008, at 8:55 AM, Tim McGaughy wrote: On Jul 29, 2008, at 9:22 PM, John Joyce wrote: Does anybody have a means or a tool for checking for hackintoshes? I really don't approve of such things and would like to leave clever messages on my own software if it is run on a hackintosh.

Re: My own listbox

2008-08-02 Thread Steve Christensen
On Aug 2, 2008, at 3:52 AM, Vitaly Ovchinnikov wrote: Is it possible to get rid of blue "focus" border for NSTableView when I select it? In IB's inspector window, one of NSTableView's attributes is Focus Ring. Just set it to "none." ___ Cocoa-de

Re: Rotate NSString... I give up :(

2008-08-06 Thread Steve Christensen
No, Jean-Daniel's method looks right. The first -translateXBy:yBy: moves (0, 0) to the center of your text rectangle. -rotateByDegrees: rotates the coordinate system by 90 degrees around that center point, then the second call to -translateXBy:yBy: restores the coordinate system's (0, 0) po

Re: Accessing member variables from another thread crashes

2008-08-10 Thread Steve Christensen
On Aug 9, 2008, at 5:24 PM, Dennis Harms wrote: I've created a class with some member variables of type NSString*. In the init function of the class, I write something into those strings. Now I call a function of the initialized class instance as a new thread and try to read from those memb

Re: Monospaced Simulated Braille

2008-08-12 Thread Steve Christensen
For the time being I suppose you could query the Braille font for its maximum character width, then draw each character in a string individually, centering it horizontally within a rectangle that has the maximum width. That would mean manually advancing each character's position on a line a

Re: Preventing windows from being dragged

2008-08-21 Thread Steve Christensen
Kinda hair-trigger on the defensiveness, dontcha think, especially since Andrew didn't actually say you were wrong? The great majority of Mac applications do not run in kiosk mode so for most cases preventing window movement *is* wrong because you take control away from the user. Had you fi

Re: Preventing windows from being dragged

2008-08-22 Thread Steve Christensen
On Aug 21, 2008, at 8:31 PM, Kyle Sluder wrote: On Thu, Aug 21, 2008 at 11:18 PM, Steve Christensen <[EMAIL PROTECTED]> wrote: The great majority of Mac applications do not run in kiosk mode so for most cases preventing window movement *is* wrong because you take control away fr

Re: Read jpeg comments from file?

2008-04-03 Thread Steve Christensen
On Apr 3, 2008, at 2:13 AM, Trygve Inda wrote: If you just need to display the image, use an NSImage (initWithContentsOfFile). If you need a greater control over metadata, use the ImageIO API (search CGImageSource in doc and sample codes). This works and retrieves the user text that was embedde

Re: fileHFSCreatorCode & fileAttributesAtPath:traverseLink on app bundles

2008-04-08 Thread Steve Christensen
On Apr 7, 2008, at 10:03 PM, Jens Alfke wrote: On 7 Apr '08, at 8:11 PM, Mike wrote: I need to get the creator code of my app's bundle without diving into the bundle and reading the plist directly. You're mixing up HFS creator codes with bundle identifiers, I think. HFS creator codes are at

Re: Finding running process on disk

2008-04-09 Thread Steve Christensen
On Apr 9, 2008, at 9:03 PM, Mike wrote: Is there a way to locate the bundle of a running process on disk from within the running process? You mean something like +[NSBundle mainBundle]? ___ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) Please

Re: Tips to deploy applications to multiple Mac OS X versions

2008-04-10 Thread Steve Christensen
On Apr 9, 2008, at 11:08 PM, Ben Lachman wrote: On Apr 9, 2008, at 3:27 PM, David Duncan wrote: On Apr 9, 2008, at 7:43 AM, Lorenzo Bevilacqua wrote: I'm trying to build a Cocoa application so that it can run on Mac OS X from version 10.3.9 to 10.5. I have 10.5 installed so the application ru

<    1   2   3   4   >