I'm trying to implement a simple method to read new lines from a log file each time the method is called.
I've looked at the various suggestions both on stackoverflow (e.g. here) and elsewhere for simulating "tail" functionality; most involve using readline() to read in new lines as they're appended to the file. It should be simple enou...
I'm porting an application to MacOS X - but the original developer's build system uses NMAKE, and ideally they'd like to keep it instead of switching to a new one.
I've managed to get NMAKE running under OSX using wine (built using MacPorts) and added Objective C support to the build files, and created a Unix-linked PE wrapper 'run.exe'...
I need to know which NSString values i can use for key equivalents.
I can't find out what to use for
cursor keys
delete/backspace
function keys
numpad items
...
Hello,
I was wondering if anyone can explain why all of a sudden in Python interactive mode all arrow keys are failing?
When I press up button for example to go through command history I get "^[[A". Same with any other arrow keys.
I have no idea why this happened and it was working before (on OS X Snow Leopard). Does anyone know a way...
I have an OS X 10.6 Mac I'm using as my dev machine. The program I wrote works perfectly on the dev machine. However, when I tried to run it on an OS X 10.5 (not sure if that's relevant) test machine, it crashes on launch.
This is the error I'm getting:
Process: MyApp[25908]
Path: /Applications/MyApp.app/Contents/Mac...
Let's suppose that I enter Xcode, and select File>New Project...>Cocoa Application. I'll call this new project StupidTest. Now, once the project window opens up, I can select Build>Build and Run, and the project will build and run, creating a nice blank window.
Now, lets suppose that I have a library, libStupid.so, or libStupid.dylib,...
I have one or many files and/or folders selected in the Finder. I manually copy them to the clipboard/pasteboard (⌘C).
To keep things simple, let's say I just copied one single normal file. The ideal solution, however, would deal with many files and a mixed selection with folders, aliases.
Now that this file is on the clipboard, I want...
Hi,
I am fluent in C++, Java, and Python and can pretty much pick up any other skill given enough time (no surprise there, I'm sure 99.9% of the people reading this share the same ability).
I have an idea for a small app for Mac OS X and I was wondering what technology I should employ/learn to get it working. I need some minimal OS X ...
window of the desktop is rather crippled. Can't get its index.
Finder windows does not include the desktop window, so I can't check that the it's the first there.
index of the first Finder window is 1 regardless of the desktop having focus. (as long as other Finder windows exist, otherwise it'll fail.)
...
After starting out with Python on Ubuntu Linux, I've now for a good while been doing most of my sustained work on the Mac, currently OS X 10.6. Unfortunately I've neglected to give proper attention to how Python is installed there and ended up with:
Python 2.6.1 (Mac default version?) in /usr/bin (also, 2.5.4, which I'm not sure how it...
Hey there,
I'm currently writing a QuickLook plugin, and I wondering how I can display an image and some information about that image at the same time, similar to http://www.code-line.com/software/sneakpeekphoto/ .
...
The Qt documentation "Mac Differences" page provides the following code for accessing an application's bundle path:
CFURLRef appUrlRef = CFBundleCopyBundleURL(CFBundleGetMainBundle());
CFStringRef macPath = CFURLCopyFileSystemPath(appUrlRef, kCFURLPOSIXPathStyle);
const char *pathPtr = CFStringGetCStringPtr(macPath,CFStringGetSystemEnco...
How do I make ruby 1.9 the default version to use instead of the 1.8.x that is by default installed on os x?
Thanks.
...
Hi,
i've been experiencing a weird bug for days.
In my program i use a sheet attached to the main window and at random it hangs without displaying the sheet itself.
Here's the trace:
#0 0x95af0266 in mach_msg_trap
#1 0x95af7a5c in mach_msg
#2 0x951e6e7e in CFRunLoopRunSpecific
#3 0x951e7aa8 in CFRunLoopRunInMode
#4 0x944e00ce in ...
I am working on a GUI application that will be used to perform "manual assessment" of large datasets produced by an AI algorithm. The nature of the assessment isn't important to this question; only the fact that the program will need to periodically check for new data from a server, download it, and then upload the results that the user ...
Hi, for Emacs you can define your shell-mode aliases in .emacs.d/init_bash.sh, but Aquamacs (2.0 on OS X 10.5) does not seem to use this. Is there another place where these can be defined?
...
Hello,
I have the following issue:
In my openCV program under Mac OS X 10.5.8 when I try to open my USB camera for video it always opens the iSight built-in camera, although I explicitly set the camera number to 1 (iSight is supposed to be 0). Furthermore, choosing camera numbers of 2, 3 etc. also opens the iSight camera, although I onl...
Im trying to download java for my MAC, but I dont know which platform should I choose just before downloading it, there is no MAC OS listed, so what should I choose instead? I used this URL for download
https://cds.sun.com/is-bin/INTERSHOP.enfinity/WFS/CDS-CDS_Developer-Site/en_US/-/USD/ViewProductDetail-Start?ProductRef=jdk-6u21-oth-JP...
I'm working on a Cocoa application that requires several sliders that will control the values for several "channels" of data. I would like to create the the app so that all of the channel data is stored as integers in a single array. Each slider would then be bound to a single element in the array. Is this possible at all? If so do I nee...
What is the equivalent of PostMessage/SendMessage in Windows on Mac OS X?
I have recently started out with Mac development, with most of my experience coming from Windows and nix.
I want to hook a window and simulate mouse clicks or keyboard presses. Also I want to be able to find a function like GetWindowText or any function that can ...