mac

PHP mail() using Sendmail on Mac OS X Leopard (10.5.8)

I've been struggling to get a really basic PHP function working on my iMac, the PHP mail() function. I've used it countless times, albeit on a Windows platform and now I'm trying to get it running on Mac. I've installed XAMPP v1.01 maybe because I didn't know any better at the time and I thought it would all just work fine, because tha...

Why can't I input the integers from a file?

I'm trying to get this C++ code to input a series of numbers from a text file: int x = 0; cin >> x; ifstream iffer; int numbers[12]; iffer.open("input.txt"); for (int i = 0; i < 12; i++){ iffer >> numbers[i]; } This doesn't seem to work on the Mac. Every cell will equal to 0 regardless of the value...

How to prevent Firefox from copying numbers or #'s when copy and pasting on a Mac?

When I copy and paste from a website that formats their text using <*li>, I get numbers or #'s when I paste into any text editor on my Mac (running Snow Leopard). Is there anything I can get that is equivalent to Windows Notepad, that will NOT copy the formatting, and just give me the text? Example of a site that I copy/paste from that g...

Turn off the warnings due to boost library

Hello All, I am building an application in C++, Mac OS X, Qt and using boost libraries. Every time i build a project I get a huge list of warnings only from boost libraries itself. I want to turn off them so that I can see only my project specific warnings and errors. Can anybody help me? Thanks, Rahul ...

Application menu is enabled even if a modal dialog box is open.

I have an application where I can launch a modal dialog box over a main window. The main window has some network activity going on in background which updates my background UI. Due to this the application menu becomes accessible even if the modal dialog is open. How can I avoid this? Any help is appreciated. I am using Mac, Qt, Carbon....

Get application icon from ProcessSerialNumber

I would like to get the application icon for all foreground applications running on my Mac. I'm already iterating over all applications using the Process Manager API. I have determined that any process that does not have the modeBackgroundOnly flag set in the processMode (as retrieved from GetProcessInformation()) is a "foreground" appli...

Is it possible to detect that whether any modal dialog box is open over main window?

Hello All, Is it possible to detect that whether any modal dialog box is open over main window? If yes then how? I am using Qt, Mac, Carbon. Thanks Rahul ...

Problem upgrading eclipse rcp app from 3.3 to 3.5 on Mac OS

I previously had an eclipse rcp app based on eclipse 3.3 pugins deployed on both windows and mac OS X 10.4. i'm now trying to port the app to java 1.6 and eclipse 3.5 (Build id: 20100218-1602) plugins on Mac OS X 10.5.8 (Leopard). I can launch the product from eclipse 3.5 on windows but not on Mac OS X. I have the 64bit cocoa eclipse ID...

Usability: Do mac users understand "right-click"?

I have a feature of my application which depends on alternate-click. Windows users don't understand "alternate-click" though, and I was wondering if most mac users understood "right-click", and if so if they were offended or annoyed when they see such text. Does anyone have experience developing usable (consumer) applications for mac us...

Launchd agent not starting

I'm attempting to write a launchd agent that runs a simple application for every user that logs in to the Mac OS X system. I have created a file named com.mycompany.myapp.plist and placed it in /Library/LaunchAgents. The contents of that file are: { LimitLoadToSessionType = "Aqua"; StartInterval = 10; OnDemand = NO; Kee...

How do you dynamically allocate memory in Mac OS X assembly?

I would like to dynamically allocate memory from an assembly program that does not link against the standard C library. Since brk(2) and sbrk(2) are unavailable on Mac OS X (10.6.2), what are the alternatives? (I'm guessing that it involves a Mach call, but there seems to be little documentation around that) ...

Is there a syntax highlighting editor component for Mac OS X

I am looking for a syntax highlighting component that I can include in a Mac OS X XCode project to allow editing of Ruby, C++, Lua, etc. I need a component that is open source or has the source included. My Google searches didn't turn up much in the way of Mac OS X frameworks or components at all, let alone the type I am looking for. ...

Programmatically Installing Fonts

How could I programmatically install a font on the Mac platform (Snow Leopard)? What steps would I need to follow? I would like for the user to input a font file, then my software installs it. ...

Bind Java program to Cocoa interface

Hi, would it be possible to bind a Java application to a Cocoa graphical interface? I'm working in Eclipse right now, on my mac, and am wondering if Interface Builder could be used to construct a new interface so that I don't have to look at Swing all day. Any ideas/suggestions? Thanks! ...

OSX: How to get a volume name (or bsd name) from a IOUSBDeviceInterface or location id

Hi, I'm trying to write an app that associates a particular USB string descriptor (of a USB mass storage device) with its volume or bsd name. So the code goes through all the connected USB devices, gets the string descriptors and extracts information from one of them. I would like to get the volume name of those USB devices. I can't ...

Qt4: QMenuBar/QMenu doesn't show up on Mac OS X

Hello, I'm having difficulties to make a QMenuBar display a QMenu with a QAction under Mac OS X (Snow Leopard). Here is the code I'm using for creating the menu: void ClientWindow::setUpMenu () { QMenu * file = menuBar()->addMenu("&File"); QAction * quit = new QAction("&Quit", this); file->addAction(quit); connect(quit, S...

Saving CFPropertyLists To Users Folder

I'm trying to save a CFPropertyList to a location in the user's home folder. Using the code below I'm getting errorCode = -10 (unknown error). CFURLRef fileURL = CFURLCreateWithFileSystemPath(kCFAllocatorDefault, CFSTR("~/testfile.txt"), kCFURLPOSIXPathStyle, false ); SInt32 errorCode; Boolean status = CFURLWriteDataAndPropertiesTo...

Adding methods to an Objective C class interface is optional?

Coming from a C++ background, one thing that confuses me about Objective C is the fact that you can add a method to a class without actually specifying it in the class interface. So I had a barrage of questions: Why would someone choose to not add the method in the class interface? Is it simply because of visibility? Methods without ...

QuickTime movie disappearing from Javascript when scrolled offscreen in non-Safari Mac browsers?

I have a web page I'm creating that uses Javascript to control an embedded QuickTime player. I add the QuickTime movie to the page using the AC_QuickTime.js file from Apple (as described here - http://developer.apple.com/mac/library/documentation/QuickTime/Conceptual/QTScripting_HTML/QTScripting_HTML_Document/ScriptingHTML.html#//apple_r...

progressIndicator does not update till about 10 seconds after awakeFromNib occures

I have been trying to get this one section of my UI to immediatly up date when the document loads into view. The awakeFromNib fires the pasted code and then starts a timer to repeat every 10 seconds... I load a default storage location: ~/Movies... which shows up immediately.. yet the network location that is saved in the document tha...