Help with Macintosh programming

macintosh programming, mac programming, mac os programming, mac os x programming, mac programming language, mac programing

Archive for May, 2011

relationship between CFString and wstring?

What is the relationship between CFString and C++’s std::wstring? Is it
easy to convert between them?

cialis .
posted by admin in Uncategorized and have Comment (1)

check for every open document apple event in the system

Hi,

my last question for the next weeks …

is it possible to "listen" for every "open document" apple event
in the system (only MacOS X?)

Thanks in advance
Thomas

posted by admin in Uncategorized and have No Comments

gamma and Lookup table

Hi all,

To learn how to set gamma table or color lookup table, I am studying a
couple of source codes from Apple ftp site. But these are just sample
programs that are not exhaustive in revealing capability of the machine
(Power PC G3). (1) How many levels of each R, G, B value can we set in a
given moment? In Pentium PC, there are 65536 levels, I can set only 256
values for a given moment for each RGB phosphor. But in next frame I can
choose a different set of 256x256x256 in different range. How does it work
on Mac? (2) As an alternative, I am trying to use functions like
DSpContext_SetCLUTEntries(), where one of the four arguments is "ColorSpec".
Is the size or type of this parameter is the pointer of "unsigned char" or
that of "UInt"? (3) I wish that I can be able to combine gamma setting
routine with Opengl Fullscreen mode and change gamma setting per frame. Can
anyone give me any source code that can do system gamma setting or
DSpContext_SetCLUTEntries() or DSpContext_GetCLUTEntries() ?

Thanks,

B-G,

posted by admin in Uncategorized and have No Comments

Perl in OS X versus MacPerl

Can someone please recommend a good source on Perl in Mac OS X versus
MacPerl?

I’ve done a little programming in the latter.
Now that I have a new G4 OSX system I’d like to convert my scripts to
run on it.  Is there an easy way to make a "droplet" in X?

Tom

posted by admin in Uncategorized and have Comments (2)

[Q] When I debugging in ProjectBuilder, How can I global value ?

Hi!

I wrote my code using carbon, not cocoa.

I debug my code in ProjectBuilder.
In ProjectBuilder, I didn’t saw global value.
I saw only local value.

How can I see global value in ProjectBuilder ?

And, ProjctBuilder was not display structure’s member value.
How can I see these, also ?

Let me know please…

posted by admin in Uncategorized and have Comment (1)

Merge Carbon Lib into non-carbon application

Hi,
I wrote a carbon based library on OS 9 , and I would like to know how (and
if) I can merge it in a non-carbon application.
I’m using Codewarrior 6.

Thanks,
Noa

posted by admin in Uncategorized and have Comment (1)

Unicode in Mac OS X

I’m writing an applet that uses some mathematical symbols that are in the
unicode character set (mostly logic and set theory symbols).  The applet
works fine in Internet Explorer under Mac OS 8 or 9, but in OS
X, the symbols don’t show up–I just get rectangles for most of the symbols.
On the Mac, the applet uses the font Font("Serif", Font.PLAIN, 12).  Anyone
know what I’m doing wrong?  Please respond by email to:
djvelle…@amherst.edu.  Thanks.
  -Dan Velleman
P.S.  If you want to try out the applet, you can find it at:
http://www.cs.amherst.edu/~djv/pd/pd.html

posted by admin in Uncategorized and have Comment (1)

When does my window get uncovered?

I am writing a classic (non-carbon) app that will most often be run in
the background.

It contains a window that receives periodic updates (in either
forgraound or background).

If the app is the active one, all is fine. The window gets its
periodic updates and displays them properly.

In the background, I’m having trouble getting the app to display
"intelligently". The problem boils down to not being able to determine
when my window has been revealed (either in whole or in part) after
being obscured.

I’ve spent considerable time looking at the following pieces of the
window/grafport record:
contRgn
visRgn
updateRgn

because they appear to contain the info I need to update my window in
a reasonable fashion when it is in the background.

But all my testing with region manipulation has produced no useful
results.

So, I ask you:
How do I determine when my previously obscured window has been
revealed again (not necessarily by making the app the active one
again)?

Gary

posted by admin in Uncategorized and have Comments (12)

libsndfile framework for OS X: please test

I have created a Project Builder project for the libsndfile library.
It is configured to build libsndfile as an OS X framework, and to build
all of its associated test programs.  It works fine on my machine, but
I would be most grateful if one or two of you would be willing to test
it out on your own boxen.

Libsndfile is at

  http://www.zip.com.au/~erikd/libsndfile/libsndfile-0.0.27.tar.gz

and my OS X files are at

  http://MrFeinberg.com/MacOSX.tgz

To test, simply

  curl -O \
    http://www.zip.com.au/~erikd/libsndfile/libsndfile-0.0.27.tar.gz

  tar zxf libsndfile-0.0.27.tar.gz

  cd libsndfile-0.0.27

  curl -O http://MrFeinberg.com/MacOSX.tgz

  tar zxf MacOSX.tgz

Now either

  cd MacOSX && pbxbuild

or open the project file and select "Build".

Email me with the gory details.  Thank you.


Jonathan Feinberg  j…@pobox.com  Inwood, NY, NY
http://MrFeinberg.com/

posted by admin in Uncategorized and have No Comments

displaying htmlpage directly from internet

hu

I want to display an HTML Page in my application. I thought the
HTMLRenderingLib woud solve my problems, but it is not capable of displaying
pages directly from the internet (or am I wrong ?).
If I pass a file:// link to HR everything works fine, but when I tried it
with http:// my Standard Browser is opened. Is there a possibility except
downloading all needed files (includeing images etc.) to the harddisk and
interpretating them with HR. The problem is that I am absolutly in the need
to display them in my application, so just opening the standard browser is
no solution. HR is able to display all files I need ( no jscripts, XML
etc.).

thanks in advance
L.  

posted by admin in Uncategorized and have Comments (4)