The other night I spent about three hours trying to figure out why
some code I had was behaving so strangely. It got to the point where I
was convinced I found a bug in gcc - but as always, it was the pilot
at fault. It turns out I forgot to terminate several of my
variable-argument lists with a
Le 16 juil. 09 à 04:55, Graham Cox a écrit :
On 16/07/2009, at 6:45 AM, Development wrote:
Anyone has some comments or ideas about this? Possibly someone
with some inner understanding of how localized strings are read?
Optimise later. You are fretting about the speed of loading
On 13.07.2009, at 15:59, I. Savant wrote:
My guess: I think because you're removing (with or without
animation) the bottom field / label, you're changing the autosizing
behavior of the content view's contents while it's being moved around.
On 14.07.2009, at 04:37, Peter N Lewis wrote:
Hi,
The Java application uses RC4 Encryption. Could some one help me to encrypt
a String with CommonCrypto. I think we can use CCCrypt function to do this.
Can anyone point some way.
I have worked on below code to encrypt a string. But it did not seem to be
working.
- (NSString*)
I would like to play a m4v from my bundle and I am using
MPMoviePlayerController to do this. Works great. However in my view the
designer would like the video to playback overlaid on top of a graphic of a
television set. I don't seem to be able to do this with
MPMoviePlayerController.
How can I
On 15 Jul 2009, at 6:14 PM, tmow...@talktalk.net wrote:
(gdb) po err
Program received signal EXC_BAD_ACCESS, Could not access memory.
Reason: KERN_PROTECTION_FAILURE at address: 0x
0x922e668c in objc_msgSend ()
(Earlier:)
NSError *err;
BOOL result = [moc save: err];
Are you sure
Add a QTMovieView as a subview of another view containing the TV set
graphics.
--Graham
On 16/07/2009, at 10:15 PM, Eric E. Dolecki wrote:
I would like to play a m4v from my bundle and I am using
MPMoviePlayerController to do this. Works great. However in my view
the
designer would
Hello everyone!
So I have a little problem that I don't know how to fix so if somebody
would be kind to help and explain the solution.
Problem is that splitView displays subviews that are rendered outside from the
visible area
of the window so therefore are clipped (not visible). They are
In fairness he did ask about MPMoviePlayerController which as far as
I'm aware doesn't exist on the Mac.
On 16 Jul 2009, at 15:19, Graham Cox wrote:
Of course, because you didn't mention it, I didn't realise you were
talking about the iPhone, which might not have QTMovieView like the
Mac
On 17/07/2009, at 12:55 AM, Mario Kušnjer wrote:
Here is the code that I'm using for displaying splitView.
I suggest removing it. You don't normally need to write any code to
make a split view work unless you have some unusual constraint
requirements. Mostly it can be set in IB.
On 17/07/2009, at 1:02 AM, Mike Abdullah wrote:
In fairness he did ask about MPMoviePlayerController which as far as
I'm aware doesn't exist on the Mac.
True, but I had to Google for it to find out it was an iPhone class -
it could equally have been something third party as far as this
You might have better luck posting to the CDSA list (it's for crypto
and security issues).
Dave
On Jul 16, 2009, at 3:13 AM, Tharindu Madushanka wrote:
Hi,
The Java application uses RC4 Encryption. Could some one help me to
encrypt
a String with CommonCrypto. I think we can use CCCrypt
I am trying to show an image from my Resources directory on a UIWebView
along with toms text.
I create the UIWebView using loadHTMLString:baseURL:.
The string I pass has all of my content in html - the img tag and
text. The text gets displayed but the image is shown as a broken link
(in the
On Wed, 15 Jul 2009 21:23:29 -0700, K. Darcy Otto do...@csusb.edu said:
For those who are working on a similar problem, I created new view
controller object from -printOperationWithSettings:, and that view
object in turn creates the view that I want to print. That view
implements various other
So, what is the convention? I assume I should prefix my class names
so that I minimize potential for name space conflict, but what should
I use as a prefix? The options readily available to me are:
1) Developer or company name
2) Application or framework name
Given that I have a Protocol
Forgot to add:
I am accessing the image file like this
NSString *imageName = [[NSBundle mainBundle] pathForResource:@myImage
ofType:@png];
I have confirmed (using NSLog) the path printed in the img tag is correct
img align=center src=/Users/hrishi/Library/Application
Support/iPhone
Hi Mario,
Just want to add a short note to what Graham Cox said about using
Interface Builder. Be sure to read the section Setting a View's
Autosizing Behavior in Interface Builder User Guide and take some
time to experiment with setting springs and struts for various views
and
Post some code. What does your HTML look like? Does it use a relative
or absolute URL for the image? What format is your image? What are you
passing in for baseURL?
On 16 Jul 2009, at 16:27, M.S. Hrishikesh wrote:
I am trying to show an image from my Resources directory on a
UIWebView
On Jul 16, 2009, at 8:08 AM, Graham Cox wrote:
In the absence of any other info, suggesting QTMovieView seems
reasonable - doesn't the iPhone have an equivalent?
No. The iPhone SDK does not support playing a movie in a window.
Enhancement Request would be the best way to go here.
--
On 16 Jul 2009, at 17:28, M.S. Hrishikesh wrote:
Forgot to add:
I am accessing the image file like this
NSString *imageName = [[NSBundle mainBundle]
pathForResource:@myImage ofType:@png];
I have confirmed (using NSLog) the path printed in the img tag is
correct
img align=center
Adding file:// to the src tag fixed it.
I also replaces all spaces with %20 (example Application Support
with Application%20Support) but I dont think that matters.
img align=center src=/file://Users/hrishi/Library/Application
Support/iPhone
On Thu, Jul 16, 2009 at 9:14 AM, Michael A.
Crawfordmichaelacrawf...@mac.com wrote:
So, what is the convention? I assume I should prefix my class names so that
I minimize potential for name space conflict, but what should I use as a
prefix? The options readily available to me are:
Choose
Hello,
During my recent encounter with custom NSControl and NSCell subclasses
I found this amazing nugget on cocoadev.com.
..If you write an NSControl subclass without using cells, and you
want to use target/actions, you have to link your Control with a
NSActionCell? by adding in your
On Jul 16, 2009, at 1:42 PM, Stephen Blinkhorn wrote:
During my recent encounter with custom NSControl and NSCell
subclasses I found this amazing nugget on cocoadev.com.
...
This works perfectly for me but why the question marks? Is there
some uncertainty about whether this is the correct
Is there any way to get a UIImage of the system images on the iPhone? i.e.
how would I get a UIImage of the Play, Pause, Rewind, Fast Forward etc
images used on UIBarButtonItems. I seem to recall seeing this in the
earlier betas, but can't find it now...
Thanks.
Rick
On 16 Jul 2009, at 11:44, I. Savant wrote:
No uncertainty. It's a wiki. The camel notation MakesThatALink but
there's NoPageByThatName? (because nobody ever filled in what it
thinks is a stub) so there's a question mark beside it.
Oh yeah, so that's why it is a different colour and
I have searched the list archives and Google to no avail in trying to
determine how the Kind value shown in the Finder is set.
My initial thought was that the UTTypeDescription entry under
UTExportedTypesDeclarations in the info.plist for a QuickLook
Generator was the answer as the docs
If I attach sample code from my app, is it out there for all to see?
-Michael
--
We know as much about software quality problems as they knew about the
Black Plague in the 1600s. We've seen the victims' agonies and helped
burn the corpses. We don't know what causes it;
Hello,
I hope it's OK to discuss an undocumented class on the list.
You can set the background color of the IKImageFlowView in ImageKit
with either -(void)setBackgroundColor: or
-(void)_setBackgroundColorRed:green:blue:alpha:. This works fine on
most machines, but will inevitably cause a crash
On Thu, Jul 16, 2009 at 11:19 AM, Michael A.
Crawfordmichaelacrawf...@mac.com wrote:
If I attach sample code from my app, is it out there for all to see?
Best to ask ADC folks directly for questions like these... but no
radar's are currently only visible to those that submit them and those
On 17 Jul 2009, at 00:13 AM, Fritz Anderson fri...@manoverboard.org wrote:
On 15 Jul 2009, at 6:14 PM, tmow...@talktalk.net wrote:
(gdb) po err
Program received signal EXC_BAD_ACCESS, Could not access memory.
Reason: KERN_PROTECTION_FAILURE at address: 0x
0x922e668c
NSError *err;
BOOL result = [moc save: err];
Make sure you initialize err:
NSError *err = nil;
Otherwise, you may be dealing with a bogus error object, since method-scope
variables are not automatically initialized to 0. (Instance variables are
initialized, btw.) I don't think that
On Thu, Jul 16, 2009 at 11:47 AM,
slasktrattena...@gmail.comslasktrattena...@gmail.com wrote:
I hope it's OK to discuss an undocumented class on the list.
It's not. File a bug at http://bugreport.apple.com asking for this
API. In the meantime, heed the Apple developers' humorous warning
found
NSError *err;
BOOL result = [moc save: err];
Make sure you initialize err:
NSError *err = nil;
Otherwise, you may be dealing with a bogus error object, since
method-scope
variables are not automatically initialized to 0. (Instance
variables are
initialized, btw.) I don't think
On Jul 15, 2009, at 6:25 PM, K. Darcy Otto wrote:
(1) Contrary to my first message, it appears to me now that
PDFDocument inherits from NSObject. So, i shouldn't have to do any
special memory management, right?
You shouldn't. It is a bug in the PDFKit framework. Please file a
bug via
On Thu, Jul 16, 2009 at 1:26 PM, Bill Bumgarnerb...@mac.com wrote:
You should *never* assume *anything* about the value of err across a call to
-save: or any other similar method *unless* the result indicates an error.
This makes many people's lives difficult. It's kinda bogus that if I
pass
On Thu, Jul 16, 2009 at 10:27 PM, Kyle Sluderkyle.slu...@gmail.com wrote:
On Thu, Jul 16, 2009 at 11:47 AM,
slasktrattena...@gmail.comslasktrattena...@gmail.com wrote:
I hope it's OK to discuss an undocumented class on the list.
It's not.
Oh, too bad... Well, thanks anyway.
File a bug at
On Jul 16, 2009, at 1:37 PM, Kyle Sluder wrote:
This makes many people's lives difficult. It's kinda bogus that if I
pass in the address of a pointer-to-NULL and receive back a YES that I
have to turn around and re-NULL that pointer before reusing it. Many
AppKit methods have a tendency to
I'm using code something like this to build a list of file types that
my application can read:
NSArray *movieTypes = [[QTMovie movieFileTypes:QTIncludeCommonTypes]
retain];
NSArray *imageTypes = [[NSImage imageFileTypes] retain];
allTypes = [[imageTypes
So, is there an SDK for accessing iTunes on the Mac?
-Michael
-Michael
--
The united stand. The divided get played.
-- Bernie MAC
smime.p7s
Description: S/MIME cryptographic signature
___
Cocoa-dev mailing list
I am trying to use genstrings:
genstrings AppDelegate.m Appdel.strings
from the terminal window and I get no errors and no output.
Likewise when I do
ibtoo -generate-strings-file MainWindow.nib MainWindow.xib
I get no error and no output.
I am in the terminal in the correct directory so I have
On Jul 16, 2009, at 12:51 PM, tmow...@talktalk.net wrote:
I have removed it completely and just called the longer winded
[[NSApp delegate] managedObjectContext] when I need it. I suppose I
could have set the ivar in the awakeFromNib when all NIB objects are
guaranteed to have been
On Jul 16, 2009, at 3:42 PM, Michael A. Crawford wrote:
So, is there an SDK for accessing iTunes on the Mac?
AppleScript?
Nick Zitzmann
http://www.chronosnet.com/
___
Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)
Please do not post admin
On 16 Jul 2009, at 22:12, Andrew Salamon wrote:
I'm using code something like this to build a list of file types
that my application can read:
NSArray *movieTypes = [[QTMovie movieFileTypes:QTIncludeCommonTypes]
retain];
NSArray *imageTypes = [[NSImage imageFileTypes] retain];
allTypes =
Or, if you want something more code-y, try the Scripting Bridge:
http://developer.apple.com/documentation/Cocoa/Conceptual/ScriptingBridgeConcepts/UsingScriptingBridge/UsingScriptingBridge.html#//apple_ref/doc/uid/TP40006104-CH4-DontLinkElementID_11
-BJ
On Thu, Jul 16, 2009 at 3:55 PM, Nick
On Jul 16, 2009, at 1:58 PM, Bill Bumgarner wrote:
Then your macros are buggy.
According to the rules now, quite possibly. But the rules are
kinda busted.
One place that looking at *outError and being able to assume it
would be nil on the *entry* to a NSError-returning method is
genstrings does not produce output. It does, however, produce
Appdel.strings.
-BJ
On Thu, Jul 16, 2009 at 3:51 PM, Development developm...@fornextsoft.comwrote:
I am trying to use genstrings:
genstrings AppDelegate.m Appdel.strings
from the terminal window and I get no errors and no output.
On Jul 16, 2009, at 15:19, Timothy Wood wrote:
then at xxx you'd like to build a new NSError that has *outError
(if outError != NULL) as the underlying error. This is perfectly OK
since we are on the failure side. Unless the developer of -bar:
forgot to actually set *outError (clang
On Thu, Jul 16, 2009 at 3:54 PM, Quincey
Morrisquinceymor...@earthlink.net wrote:
If I've misunderstood your point, it would be helpful to see an example of
how your code might look with the NSError-wrapping code in place.
The point is that convenience is increased if NSError-returning
methods
On Jul 16, 2009, at 15:54, Quincey Morris wrote:
On Jul 16, 2009, at 15:19, Timothy Wood wrote:
then at xxx you'd like to build a new NSError that has *outError
(if outError != NULL) as the underlying error
It seems to be you have this precisely upside-down. outError is an
output
On Jul 16, 2009, at 3:54 PM, Quincey Morris wrote:
Aside: If the developer of bar forgot to set *outError, then the
developer of bar forgot to set an output parameter, and that's not
just a bug on the developer's part, but a *horrible* bug.
Sure. And clang-sa should check for this and
It's been a while since I dealt with this, but if I recall correctly,
AppleScript gets you almost everything you can with the COM interface
on Windows. The only exception was that you can't register to listen
for player updates, though I believe there are undocumented
distributed
ibtool -generate-strings-file MainWindow.nib MainWindow.xib
Will invoke ibtool, and tell it to open MainWindow.xib and then read
all the localizable strings out of that XIB, and then write them into
the argument of the -generate-strings-file argument. So after
running that command, ibtool
On Jul 16, 2009, at 4:49 PM, Timothy Wood wrote:
Sure, I should remember to ignore it or initialize it to nil myself
or have a OBBaseError macro, but one day I'll forget. The current
rules make me write more and more fragile code than I'd need to if
we could just all depend on setting
On Jul 16, 2009, at 16:49, Timothy Wood wrote:
So, as an example, I might want do do something like:
- (BOOL)saveSomething:(NSError **)outError;
{
NSData *data = build some data;
if ([data writeToFile:path options:someOptions error:outError])
return YES;
On Jul 16, 2009, at 5:39 PM, Greg Parker wrote:
The alternative would be to require the caller to set `err=nil`
before calling `whateverWithError:err`.
Yes, and this would a code savings. Only at the top level
invocations would you need to worry about this. There are far more
methods
On Jul 16, 2009, at 5:44 PM, Quincey Morris wrote:
In the second case, you're not screwed because of these NSError
rules but because you're using an output parameter of the method as
an input parameter to the macro. It's a plain bug, unless you assert
it not to be a bug (which is basically
Ok, I have tried:
about.text = @About text;
and
[about setText:@About Text]
but when I bring up the text view it is empty until I touch inside it
and the KB appears. which ruins the whole point since it is suppose to
be non editable.
What am I doing wrong with this view that it will not
Have you verified that the about pointer is actually set to point to
a text field? If it was nil, it would explain the behavior your
describing.
Jon Hess
On Jul 16, 2009, at 6:52 PM, Development wrote:
Ok, I have tried:
about.text = @About text;
and
[about setText:@About Text]
but when
Actually its a UITextView, it is linked in IB and when I
NSLog(@%@,about.text) it shows me that it has the string stored in
the object, however it is not updating the onscreen view.
On Jul 16, 2009, at 6:58 PM, Jonathan Hess wrote:
Have you verified that the about pointer is actually set
On Jul 16, 2009, at 18:33, Timothy Wood wrote:
and if there's something to do that doesn't return a NSError:
if (![... do something ...]) {
OBError (nil, ...);
return NO;
}
Um, no. This doesn't fill *outError if you pass nil. Either way,
On Jul 16, 2009, at 4:49 PM, Timothy Wood wrote:
Sure, I should remember to ignore it or initialize it to nil myself
or have a OBBaseError macro, but one day I'll forget. The current
rules make me write more and more fragile code than I'd need to if
we could just all depend on setting NSError
On Jul 16, 2009, at 9:09 PM, Development wrote:
Actually its a UITextView, it is linked in IB and when I NSLog
(@%@,about.text) it shows me that it has the string stored in the
object, however it is not updating the onscreen view.
Make sure that your text view is large enough to show the
ApleScript/Scripting-Bridge it is. Thanks, guys.
-Michael
--
There are two ways of constructing a software design. One way is to
make it so simple that there are obviously no deficiencies.
And the other way is to make it so complicated that there are no
obvious
On 16 Jul 2009, at 09:55, M.S. Hrishikesh wrote:
img align=center src=/file://Users/hrishi/Library/Application
Support/iPhone Simulator/User/Applications/87888BAB-2F9D-44F6-BEB8-
FB7D65D2F1CC/Epicures.app/myImage.png /
Although it may display correctly, that's still not correct. The URI
On 16 Jul 2009, at 05:15, Eric E. Dolecki wrote:
I would like to play a m4v from my bundle and I am using
MPMoviePlayerController to do this. Works great. However in my view
the
designer would like the video to playback overlaid on top of a
graphic of a
television set. I don't seem to be
I don't want to use the Settings app as I need a clean way for the user to
get to the settings from within my app and then return to my app. So I need
to build a grouped table view, with each cell containing a single control
(and a label) like the settings app does.
For example, I need a table
Hi All,
I need following functionality to be implemented in
NSTableView.
Selecting Multiple cells of single column in
NSTableView.
I subclassed NSTableView and created class TestTableView.
I have done following 3 things.
1)I have overriden
Hi all,
I have 2 tabs, with an IKImageBrowserView in each tab.
I have implemented imageBrowser:writeItemsAtIndexes:toPasteboard: so I
can drag images from one IKImageBrowserView to another, and have also
implemented imageBrowser:removeItemsAtIndexes: so images can be
removed.
However,
Hi All,
I need following functionality to be implemented in
NSTableView.
Selecting Multiple cells of single column in
NSTableView.
I subclassed NSTableView and created class TestTableView.
I have done following 3 things.
1)I have overriden
Hi,
I am currently investigating a crash we experienced in our application. We
have a daemon process running in the background, and it crashed, writing the
attached report as it did so. This only happened once, which suggest that
this is a sporadic problem. In case it is useful, we use
Hi all,
I'm new to the Cocoa framework, and puzzled why the following code would
work:
CGLayerRef layer = ...assume we have a layer created.
printf(Retain count after creation: %i\n, CFGetRetainCount(layer));
[(NSObject*)layer retain];
printf(Retain count after sending a retain message: %i\n,
Hello,
Imagine the following example:
Entity Attributes Relationships
-----
WeeklyMenu date menuItems (To-many Destination:
MenuItems)
MenuItemsdish week (Destination:
Cocoa-devListMembers,
In my AppController I have a NSMutableArray which stores all user
request/response objects made by the application. The requests are a
subclass of NSObject with two NSDictionaries. The first NSDictionary
has three key value pairs which comprise the request portion of
Hi,
We have a TeamCity build server setup to produce automatic builds for our
cocoa application. We also code sign our apps but this part has to be done
on a dev box as the build agent (OS X 10.5) doesn¹t recognize the
certificate in the system keychain (there is no login keychain when the
build
Hello all,
For various reasons I'd like to implement a method similar in function
to NSString's -sizeWithFont: (UIKit addition). The difference is it
takes a CGFontRef. Here's a rough idea of the code (a slight
adaptation of Timothy Ritchey's TTFontCell code, and I apologize
because I
Hello Everyone,
For some time I wanted my cocoa application not to appear in the dock, nor
to show the main menu bar. After some searching and screaming,
I managed to achieve this by adding
keyNSBGOnly/key
string1/string
to the Info.plist, now my question is: is this the usual way of doing it?
I haven't played with sliders, but here is an example for a switch:
UITableViewCell *yourCell = [tableView
dequeueReusableCellWithIdentifier:YourCellIdentifier];
if (yourCell == nil)
{
yourCell = [[[UITableViewCell alloc]
initWithStyle:UITableViewCellStyleDefault
1) Forget -retainCount exists. Never call it.
2) Look up toll-free bridging.
--Kyle Sluder
___
Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at
http://www.cocoadev.com/index.pl?LSBackgroundOnly
On 17/07/2009, at 10:43 AM, Piotr Grzybowski wrote:
Hello Everyone,
For some time I wanted my cocoa application not to appear in the
dock, nor
to show the main menu bar. After some searching and screaming,
I managed to achieve this by
This question seems to come up every week. If you search the list
archives you'll see that you want to create an LSUIElement.
--Kyle Sluder
___
Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)
Please do not post admin requests or moderator
Look at the table view programming guide for how to build custom table
cells. Just think of each cell as a custom view. They can even be
built in IB easily enough. Drag UITableViewCell objects into your nib
and lay them out however you like.
Luke
Sent from my iPhone.
On Jul 16, 2009, at
Also - on iPhone OS 3.0 this is even simpler. You don't need custom
table cells.
UITableViewCell *cell = [tableView
dequeueReusableCellWithIdentifier:CellDetailIdentifier];
if (cell == nil) {
cell = [[[UITableViewCell alloc]
initWithStyle:UITableViewCellStyleValue1
Ok google showed me a couple articles on how textviews within
scrollviews dont work right.
so I tried to implement a bit of code but it still didnt work and I
had to move the text view so that it was on the view screen from the
start. That really cramped the style of the interface but for
On Jul 16, 2009, at 5:24 AM, Wilson Chen wrote:
Since a CGLayer is not a subclass of NSObject, its instances shouldn't
respond to retain/release messages. Yet the code works.
The toll-free bridging documentation isn't very clear on this, unless
it's changed recently. At least for
Yeah, the NSURLConnection docs aren't too heavy on details when it
comes to threads, and what it does say about its threading behavior
seems purely consequential to the fact that NSURLConnection relies on
NS/CFRunLoop facilities, rather than NSUC implementing its own
thread-safe logic. So from the
On Jul 16, 2009, at 07:28, Sean Kline wrote:
Imagine the following example:
Entity Attributes Relationships
WeeklyMenu date menuItems (To-many
Destination: MenuItems)
MenuItemsdish week (Destination: WeeklyMenu)
Greetings!
I was looking at core animation in interface builder, and I really
like what one can do there.
I need a quick tip... when i define a shadow, or an animation, i would
like to be able to control in code or bindings
when the shadow appears or when the animation will start in response
On Jul 16, 2009, at 7:24 AM, Wilson Chen wrote:
Hi all,
I'm new to the Cocoa framework, and puzzled why the following code
would
work:
CGLayerRef layer = ...assume we have a layer created.
printf(Retain count after creation: %i\n, CFGetRetainCount(layer));
[(NSObject*)layer retain];
89 matches
Mail list logo