First, sorry about my last post with the RE:Contents of ... title.
My bad.
Anyhow, I figured out what was wrong. Seems you need to call
[self.view addSubview:picker] to hook up the picker to the view
controller. I am doing that in my viewDidLoad method.
Regards,
Paul
:
On Jan 12, 2010, at 12:26 PM, Paul Archibald wrote:
Anyhow, I figured out what was wrong. Seems you need to call
[self.view addSubview:picker] to hook up the picker to the view
controller. I am doing that in my viewDidLoad method.
If the picker is already a subview of the view controller's view
I have a couple of pickers in my app, and when they are displayed I
want them to show their current values. I have tried:
-(IBAction) setThePicker:(id) sender {
[picker selectRow:3 inComponent:0 animated:YES];
}
(hooked to a button, as a test) as well as just calling
[picker
On Jan 11, 2010, at 4:19 PM, cocoa-dev-requ...@lists.apple.com wrote:
What does NSLog(@%@, picker); print out?
UIPickerView: 0x138cee0; frame = (0 0; 320 216); layer = CALayer:
0x138cf30
Does that tell you anything? It looks okay to me. At least its not
deadbeef or nil, and the frame
I am using SQLite in my iPhone app. and i want to be able to email the
database file. I see that attaching it to a message is pretty
straightforward, but the addAttachmentData method requires a mime
type, and I don't know what that should be. Any ideas out there?
Cool, thanks, I'll try that.
On Dec 29, 2009, at 11:10 AM, davel...@mac.com wrote:
On Dec 29, 2009, at 11:56 AM, Paul Archibald wrote:
I am using SQLite in my iPhone app. and i want to be able to email
the database file. I see that attaching it to a message is pretty
straightforward
Is there a way to test the emailing code in my app from within the
simulator? I don't have an iPhone. It looks like my code is working,
but I would really like to see whether the message is actually being
constructed and sent correctly. I realize that on an iPhone it would
be handed over
It seems as though the UITextField/View classes do not allow a return
or done key when keyboardType is a UIKeyboardTypeNumberPad. Am I
missing something, or is this a deliberate design?
This seems odd to me and kind of a drag since I have several text and
numeric controls in my view and I
Comrades,
I have a bunch of UITableViewControllers in my app, each of which is
responsible for some aspect of the data in my sqlite database. Now,
maybe I should have done it differently, but I am passing a
backpointer from each parent vc to its child vc, where the child
vc is going to
this is the answer.
Thanks,
Paul
On Nov 20, 2009, at 5:23 PM, Michael Babin wrote:
On Nov 20, 2009, at 5:55 PM, Paul Archibald wrote:
So, why does setParentViewController get called twice, and why is
the parameter type different the second time, and why don't I get
an exception when the wrong
Hey,
I am working on an iPhone app to manage project files which consist of
names, equipment, and tasks. I want to use Core Data with SQLite as
the backing store.
Our prototype has a bunch of tableview pages that allow the user to
create, edit and delete projects and project elements.I
Hey, I just noticed that there is a goviphone list you can subscribe
to. Maybe you could find out something useful there. I was looking to
see if there was a new, dedicated iPhone/iPod/Touch list,
Paul Archibald
Amen.
Codewarrior is dead, long live Xcode. (I still mourn CodeWarrior, but
what's past is past.)
I did some work with MFC a couple of years ago, and thought it was
pretty nice (not elegant, but productive). Now, I am trying to port
my Cocoa app to Windows, and for various reasons
Is there a simple way to detect that the option key was down when a
button was clicked? I have a method in my controller that gets the
button click, of course, and I have been trying this:
-(IBAction) handleButton:(id)sender {
if( [[NSApp currentEvent] modifierFlags]
This is pretty obscure, I think.
My app makes files which can be quite large. It also allows the user
to distribute copies of those files to various locations. So, to test
this I have tried creating and mounting a disk image which I tried
making a copy to.
The problem is that it seems I
Hey folks,
The app I am working on has 2 windows. My project has been to
implement the 2nd window. I added a new nib file and a new class,
MyController:NSWindowController. In the MainController:NSObject
implementation, there is a MyController object, which can be shown or
hidden by the
I have gotten some suggestions on a problem which require access to
standard C calls. In particular, one poster suggested that I use some
calls which require a FILE*, when all I have at this point are
NSTask, NSPipe, and NSFileHandle objects.
Is it possible to get a FILE* from an NSPipe or
On Sep 4, 2008, at 10:18 AM, Jean-Daniel Dupas wrote:
Le 4 sept. 08 à 19:09, Paul Archibald a écrit :
I have gotten some suggestions on a problem which require access
to standard C calls. In particular, one poster suggested that I
use some calls which require a FILE*, when all I have
I do not have the source code to the subprocess, so I think I will
need to find another solution. I can't call setvbuf from my code, can I?
I am using the TaskWrapper class from the Moriarity sample for my
task handling. It is pretty old, maybe it is not compatible with
Leopard or Xcode 3?
Okay, after a bunch of struggles, I got my code to work. What I
wanted was to make a multi-page pdf document from a bunch of text. I
wanted a method that would take an array of strings and make a pdf
page from each string, then join them all together into a single pdf
document.
My
Thanks for the comments Andy.
I see what you mean about reassigning that page pointer. As I recall,
I had trouble fully allocating a page without the pdf document. Just
using [[PDFPage alloc] init] did not seem to create a real pdf
page, and trying to do anything with such an object
scheduled programming
Paul Archibald
Governments need armies to protect them
from their enslaved and oppressed subjects.
-- Leo Tolstoy
___
Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)
Please do not post admin requests or moderator
I really like that rule of thumb. Very clean, very cool. Thanks. (I
am not too worried about overhead in this case.)
Paul
On Sep 2, 2008, at 7:00 PM, [EMAIL PROTECTED] wrote:
And if you do use autorelease, then put it right where you allocate
the object. For example:
NSTextView* view
Help.
I was about to send my client a new version of the app, and the main
thing I just thought I fixed has completely stopped working. Sheesh.
What the app does is launch a memory and cpu intensive command line
program and monitor its progress. It I run the CLP separately, I see
it
Doug is correct. Check out NSText in the APIs. I used this method
just yesterday to size a text view:
-sizeToFit
Resizes the receiver to fit its text.
- (void)sizeToFit
Discussion
The text view will not be sized any smaller than its minimum size,
however.
Availability
•
or to a printer, add annotations, count
characters, define selections, and get the textual content of a page
as an NSString object.
Your application instantiates a PDFPage object by asking for one from
a PDFDocument object.
That sounds like the right thing to use, what am I doing wrong?
Paul
Comrades -
A while back I posted a question about creating a PDF file. I got a
good, simple answer from Chuck which has worked in one test I have
tried, but which I want to generalize. The first test used a custom
view in the nib file, which I inserted text into, and then wrote out
to
Officer of Redundancy)
On Aug 26, 2008, at 1:22 PM, Andy Lee wrote:
On Aug 26, 2008, at 4:03 PM, Paul Archibald wrote:
PDFImageView* pdfview = [[PDFImageView alloc] init];
[...], I see that my pdfbounds rectangle is not properly sized,
but is just {0,0,0,0}.
That's because you used
] ) {
if( [[file pathExtension] isEqualToString:interestingExtension]
) {
// do something with file
}
}
Paul Archibald
An ocean without its unnamed monsters
would be like a completely dreamless sleep.
— John Steinbeck
On Aug 19, 2008
On Aug 21, 2008, at 9:49 AM, Sean McBride wrote:
On 8/21/08 7:46 AM, Paul Archibald said:
NSString *file;
// Get all of the files in the source directory, loop thru them.
NSEnumerator *files = [[myFileMgr
directoryContentsAtPath:srcDirectory] objectEnumerator
Comrades -
It looks like PDFKit is aimed at simply reading and navigating within
an existing PDF file, but what I need to do is create a new PDF and
write some simple text to it. I know that the Preview app does that
for a lot of apps, but I would like to bypass that, too. I simply
want
Dude!
That does look simple. I figured it would be.
Thanks,
Paul
On Aug 6, 2008, at 11:42 AM, Charles Steinman wrote:
--- On Wed, 8/6/08, Paul Archibald [EMAIL PROTECTED] wrote:
It looks like PDFKit is aimed at simply reading and
navigating within
an existing PDF file, but what I need
Comrades:
I have experimented a bit with this, and I think I have something
that works, but I would like to understand it better. I am reading
the Hillegass book, but I don't really see an example of what I am
tryng to do, although it seems like a very basic question.
The Question:
If I
Is there a way to use class objects that wrap multiple IBOutlet objects?
The app I am working on has groups of interface elements that are
repeated on the interface and in the code. Let me see if I can
illustrate what I mean:
The window looks (slightly) like this:
(button_set_src_1) (add)
Well, Erik, you know that sometimes we inherit working code without
knowing much about its history. I don't want to break something that
already works (and ships), and re-factoring the whole codebase is not
part of my charter. I am trying to add my stuff without disturbing
the working app.
tasks, but share the
controller. I want separate controllers for each window/task.
Thanks, Ken.
On Jun 13, 2008, at 6:22 PM, Ken Thomases wrote:
On jun 13, 2008, at 4:21 PM, Paul Archibald wrote:
This puzzles me. I am tracing through some code in which I am
looking at the value of some
Wow, Ken, thank you for such a thoughtful and detailed response. I
need to read it a few more times to understand it better, but it has
been very useful already. I recognize a couple of points were I might
have gone astray in my first try.
Oh, and thanks for your second response, too. For
Comrades:
Geez, I am feeling totally wrapped around the axle here.
I have posted questions on this project a couple of times, and have
gotten useful answers that allow me to continue. Sometimes I think I
am heading deeper into the weeds, though. So, let me try rephrasing
my situation and
Comrades:
This puzzles me. I am tracing through some code in which I am looking
at the value of some selected popup menu items. I am seeing the
correct values for them, but I have to confess I don't know how the
code is connected to the popup, or just why the code even works! I
see the
my head is hurting
I am trying to understand the NIB/code connection. I have a couple of
windows in this project, one of which I am working on, the other I
have been leaving alone. For MyWindow, I have been adding methods in
my category.h file, and dragging that header to the nib, and
Comrades:
I am working on a file-handling Cocoa app that (at this point) has a
single window. We are adding a second window (really sort of a non-
modal dialog) to do some extra processing of the target files. The
interface for the new window is already built (with IB), but is not
hooked
Ooops, saw that go by and spaced out fixing it. I am just beginning
with Cocoa, and the framework names are not that familiar yet.
Thanks for the advice, Brian, especially the part about instantiating
my controller in code. I figured it couldn't be too hard, but a
little nudge in the right
a menu item that is not in the NIB? Where
else does Xcode/IB store resources that I am not seeing?
Thanks for any help. I am sure to lots more questions while I work
through tutorials and wok on this project.
Paul Archibald
--
The competent
on, though. Maybe as I gain experience with Cocoa/IB I will figure it
out.
On May 29, 2008, at 2:32 PM, Jean-Daniel Dupas wrote:
Le 29 mai 08 à 20:25, Paul Archibald a écrit :
Comrades,
-- Newbie Alert --
This is my first posting to this list, and has to do with my first
foray
I am really a total newbie (3 or 4 days) with IB, so I have NO
confidence that I can tell what is a bug yet. I barely understand
what I am doing as yet.
However, I should have done the IB run mode thing. I did not think
of that. I just looked at it and it looks correct (no extra item). Go
(color default = 4, size default = 3).
I guess I could have a dictionary for each popup, but that seems
clunky. I see there is something called Bindings for menu/popup
items, is that a way to go? (I am trying not to put the info in the
NIB, I would prefer code, where I can see it.)
Paul
46 matches
Mail list logo