Re: "Open Quickly" help!
Re: "Open Quickly" help!
- Subject: Re: "Open Quickly" help!
- From: Peter Lau <email@hidden>
- Date: Tue, 14 Mar 2006 20:15:04 -0500
Hi David,
On 14-Mar-06, at 4:09 PM, David Ewing wrote:
On Mar 13, 2006, at 3:11 PM, Peter Lau wrote:
Hi Dave,
On Mar 13, 2006, at 5:50 PM, David Ewing wrote:
On Mar 12, 2006, at 10:48 AM, Peter Lau wrote:
I have a folder structure of the following:
MyProject/
MyProject.xcodeproj
src/
main.c
headers/
SomeHeaders.h
in main.c, I have a line that says:
#include "SomeHeaders.h"
I can compile without problem since I included "$(SRCROOT)/
headers/**" to the User Header Search Path.
However "Open Quickly" couldn't find SomeHeaders.h when I
hilited "SomeHeaders.h" in the main.c window (that's the XCode
text editor window).
What else do I need to set up to make "Open Quickly" to find
SomeHeaders.h?
I really don't want to add the .h files to the project window,
if possible to make this to work.
Are you using the latest version of Xcode? I believe this issue
was fixed some time ago. (The problem had to do with the "**"
recursive include paths.) If you are using the latest stuff, it
would be good to file a bug so we can see what's happening in
your specific circumstance.
The About Box says Version 2.2.1 (IDE: 656.0, Core: 660, TS 651),
I believe this is the latest GM (not including beta if there's
any, I didn't check).
I am not familiar with the problem you mentioned, is there a
workaround or steps that I can try?
Yup, 2.2.1 is the latest. The problem had to do with the build
system not doing the correct lookup for Open Quickly when recursive
header paths were used. (Builds worked correctly, just not Open
Quickly.) But this brings up another possibility: Are you using the
"native" build system? If you're using Jam-based builds or an
external build system (like makefiles), then Xcode doesn't know
enough about your code to make this work. If that's the case, the
best thing to do is to add the files to your project. (We recommend
you add headers to your project anyway. For one thing, it gives you
SCM support for the files. For another, Open Quickly can find them.)
I think I am using the "native" build system 'cos I have no idea what
a Jam-based builds is and definitely is going through the IDE (no
makefile anywhere)... in fact, I can reproduce this with the built-in
Carbon app sample:
I can reproduce this with the following steps:
0. launch XCode, make sure there is no window from XCode
1. Select "Preferences..." and make sure the IDE is using the
"Condensed" Layout (click Apply to make sure it's so).
2. create a sample carbon application project
3. In Finder, create a folder called "headers" next to
the .xcodeproj project file
4. navigate into the folder "headers" and create a header file call
"SomeHeaders.h" with the following contents:
#ifndef SOMEHEADERS_H
#define SOMEHEADERS_H
#define SOME_SOME 1
#endif /* SOMEHEADERS_H */
5. go to main.c from the project and add the following line
somewhere at the beginning of the file:
#include "SomeHeaders.h"
6. at the end of the main() function, change "return err" to the
following:
#if SOME_SOME
return err;
#else
return 0;
#endif
7. Go to Target pane on the project window, select the target, and
do a Get Info
8. search for "User Header Search Paths" and add the following to
the search paths:
$(SRCROOT)/headers
note that it's not recursive.
9. compile (should compile successfully).
10. open main.c in XCode's text editor window
11. hilite the text "SomeHeaders.h" without the quotes
12. do "Open Quickly..."
13. RESULT: the "Open Quickly" opened instead of a text editor
window with SomeHeaders.h contents.
Here's some addition info hopefully I can get my XCode golf shirt (or
help you narrow it down):
1. I closed all windows and set the Layout to "All-In-One".
2. I then open the same project file
3. I clicked on main.c and make sure the editor portion is visible
4. hilite the text "SomeHeaders.h" without the quotes
5. do "Open Quickly..." no go
4. I go to Finder and double click on "SomeHeaders.h", the contents
of the header file shows up in the editor portion of the "All-In-One"
window.
5. Close all windows
6. Go to Preferences and set the layout to "Condensed".
7. Open that very same project file
8. Open main.c
9. hilite the text "SomeHeaders.h" without the quotes
10. do "Open Quickly..."
11. RESULT: SomeHeaders.h is now opened in XCode (did I hear cheering?)
Open Quickly reminds working until the project window is closed.
So, with my developer's hat on, sounds like there's some work being
done in the "All-In-One" mode, and actually get utilized by the
"Condensed" mode but "Condensed" mode does not know how to create,
nor maintain it for persistency?
HTH.
pete
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Xcode-users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden