trying to use cached image as background in NSView

2017-04-03 Thread Patrick J. Collins
Hi everyone,

I have a NSView in which I am drawing a waveform from a buffer. This
NSView has a child playhead element, that I want to move across the
waveform as it plays. The problem is, drawRect: is expensive and anytime
the playhead moves, the waveform has to draw itself all over again,
causing terrible performance problems.

My thought was to draw the waveform once, save it as an NSImage, and
then have drawRect: draw itself from the saved image, and when a new
buffer is loaded, discard the image and let drawRect: draw the new
waveform and save it as an NSImage, etc.

However, when drawRect: is called subsequent times (after new buffers
are set), the image appears to be garbage and therefore this strategy is
not quite working as planned... What am I doing wrong?

  @property (nonatomic, strong) NSImage *image;

  ...

  -(void)drawRect:(NSRect)dirtyRect {
  if (self.image) {
  [self.image drawInRect:dirtyRect];
  return;
  }

  [[NSColor blackColor] setFill];
  NSRectFill(dirtyRect);
  [super drawRect:dirtyRect];

  float zero = self.bounds.size.height / 2;
  [[NSColor blueColor] set];

  NSPoint pointA = NSMakePoint(0, zero);
  NSPoint pointB = NSMakePoint(self.bounds.size.width, zero);
  [self drawLineFromPointA:pointA toPointB:pointB];

  if (self.buffer) {
  float spacing = self.bounds.size.width / self.buffer.size;
  for (int i = 0; i < self.buffer.size - 1; i++) {
  NSPoint pointA = NSMakePoint(i * spacing, zero - 
(self.buffer.samples[i] * zero));
  NSPoint pointB = NSMakePoint((i + 1) * spacing, zero - 
(self.buffer.samples[i + 1] * zero));
  [self drawLineFromPointA:pointA toPointB:pointB];
  }
  }

  [self lockFocus];
  NSBitmapImageRep *rep = [[NSBitmapImageRep alloc] 
initWithFocusedViewRect:[self bounds]];
  self.image = [[NSImage alloc] initWithData:[rep TIFFRepresentation]];
  [self unlockFocus];
  }

  -(void)setBuffer:(Buffer *)buffer {
  _buffer = buffer;
  self.image = nil;
  [self setNeedsDisplay:YES];
  }

I tried asking this question on Stack Overflow, but it's gotten no love..
http://stackoverflow.com/questions/43177850/trying-to-use-cached-image-as-background-in-nsview

Patrick J. Collins
http://collinatorstudios.com

___

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
https://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com


best way to implement a clickable grid?

2015-09-14 Thread Patrick J. Collins
Hi everyone,

I am looking to implement something that would look somewhat like a
graphic equalizer.  Meaning, a grid of blocks...  Clicking on a single
grid block would change the appearance of all cells directly under it..
So in other words, clicking on 1,1 would turn on 1,1. but clicking 1,5
woudl turn on 1,5, 1,4, 1,3, 1,2, 1,1...

I am curious if anyone here has a suggestion of what the best design
approach would be for something like this?  Should I just
programatically generate a bunch of NSViews?  Should I overal an
invisible button over each view?  Or is there a better way to handle
click events on a simple NSView?

Any push in the right direction would be greatly appreciated.  Thanks!


Patrick J. Collins
http://collinatorstudios.com

___

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
https://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com

another question about view based NSTableViews

2015-03-15 Thread Patrick J. Collins
So, I have my NSTableView which is made up of NSTextFields as cells...
How do I handle knowing when the value of one of these text fields
change?

The docs say that with a view based table, the subviews (i.e. columns)
should handle their own behavior, but-- how does a NSTextField (my cell
view) know what row it's in, what column it is, etc... ?

Patrick J. Collins
http://collinatorstudios.com

___

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
https://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com

Re: Trying to hide a NSProgressIndicator upon finishing of table rendering

2015-03-15 Thread Patrick J. Collins
> You probably want to rethink what you mean by "processing of data".
> The table ALWAYS lazy loads, and only asks your data source for the
> row it needs when it needs them. The user scrolls, more rows needed,
> your data source supplies them.  This is all VIEW stuff, nothing to do
> with data processing. Your data model knows what it means by
> "finished", so it could arrange to let its controller know (e.g. using
> a notification of some sort) and the controller can hide the progress
> spinner. You probably want to keep the table out of it altogether.

Ok so, the way this is structured is, a UI button is clicked, and that
does two things:

1)  Tells the progress spinner to show itself and animate
2)  sends a 'parameterChanged' notification

Another part of the app listening for that event then begins processing
the audio, when it is complete, it sends a 'finished' notification along
with a pointer to the processed data.

The controller owning that NSTableView is then listening for that
event and it simply calls the reloadData tableview method.

The tableView is then populated, and the spinner is turned off...

The problem is, there is quite an obnoxious lag between spinner being
hidden and table view contents actually updating.  I am assuming because
this is a 13 column x several hundred rows, all consisting of
NSTextFields as their views...  And also strangely- which is most likely
the reason for this delay, when I followed the apple docs for setting up
a view based table (using their sample code as a starting point), I came
up with:


NSTextField *result = [tableView 
makeViewWithIdentifier:kFrameDataTableViewIdentifier owner:self];
if (!result) {
result = [[NSTextField alloc] initWithFrame:NSZeroRect];
result.font = [NSFont systemFontOfSize:8];
result.bezeled = NO;
result.backgroundColor = [NSColor clearColor];
result.identifier  = kFrameDataTableViewIdentifier;
}
...

And guess what?  result is always false...  Which makes me wonder why in their
documentation do they suggest that result == nil check?  But, I am confused why
it's recreating views from scratch anytime the table content changes?  That's
certainly going to most likely be the performance lag I am seeing.

But that's what my original question was regarding, if say that lag was not
nothing that could be removed, how could I make my progress bar hide not when
the table content updates, but when the table has completed it's updating
(hence the delay is over), because right now I get the spinner, it disappears,
but there is roughly a 0.75 second pause before the table data changes

Patrick J. Collins
http://collinatorstudios.com
___

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
https://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com

Re: highlight a nsview on click-drag?

2015-03-15 Thread Patrick J. Collins
> Why bother with a timer loop to animate the wiper when that functionality is 
> built-in through CoreAnimation?
> Especially since you are using an image as the wave background.

I guess because I like the playhead being tied to the actual
current sample position, not a separate animation that is faking being
connected to what's happening.  With an animation, that's not really
happening.  If I change the sample rate / playback speed, then core
animation has to be "faking" that.  Where as if its position is just
mapped to an X coordinate based on the math of the number of samples and
current sample index, then you get all of that for free and it seems
better to me.

Patrick J. Collins
http://collinatorstudios.com
___

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
https://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com

Re: highlight a nsview on click-drag?

2015-03-15 Thread Patrick J. Collins
> A fairly simple way to implement a selection rectangle is to use
> CALayer, but that only gives you the visual aspect. What does it
> select? Answer that question first and that will tend to lead you to
> the appropriate way to implement it.

This NSView is of an audio waveform.  I currently have my drawRect:
method draw the lines of my waveform, but as soon as I added a timer
loop to move my playhead over the waveform as it plays, I found that
this was not the right approach, as everytime the playhead moved, the
parent (waveform view) would have to redraw itself, and this result in
the playhead moving in an extremely choppy fashion.

My next approach was to save my drawn waveform to an NSImage and use
that as a background for my view...  If you have a better suggestion for
how I could handle this, I'd love to hear it.

And to answer your question, the selection would be selecting frames of
audio, so that when it is played, the playhead starts there and ends at
the end of the rectangle.

Patrick J. Collins
http://collinatorstudios.com
___

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
https://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com

highlight a nsview on click-drag?

2015-03-14 Thread Patrick J. Collins
I have a NSView with a background image, and am wondering, what is the
best / easiest way to create the behavior so that if I click on a point
within this NSView and drag a direction, the click point to the current
mouse position would then be highlighted (inverse the colors of the
image for that rect)?  Is there anything built-in that does this for me?


Patrick J. Collins
http://collinatorstudios.com

___

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
https://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com

Trying to hide a NSProgressIndicator upon finishing of table rendering

2015-03-13 Thread Patrick J. Collins
I am trying to have a progress spinner show upon processing of data, and
hide upon completeion of rendering all the columns/rows of my table...

The problem is, if I do something like:

  if (row == lastRow) [self hideSpinner]

This does not get called until I physically scroll to the end of my
view, as I guess NSTableView is doing some lazy loading.

Is there a way to determine when the table has actually finished drawing
itself so I can hook into that?

Thanks!

Patrick J. Collins
http://collinatorstudios.com

___

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
https://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com

Re: setting table view rows and columns?

2015-03-13 Thread Patrick J. Collins
> Also make sure that that "headers" is checked in the table view attributes 
> inspector, or the headers won't be exposed to set in the first place.

aargh! Totally missed that checkbox, and yeah that was my problem!!!

thanks!

Patrick J. Collins
http://collinatorstudios.com
___

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
https://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com

Re: setting table view rows and columns?

2015-03-13 Thread Patrick J. Collins
Yeah I did that..

> Just double-click the column header title and type in the title you want. Or 
> select the table column in the hierarchical view and enter text in the Title 
> field of the editor panel.

The inspector shows the text set under 'Title', yet when I build, there
is no text.. it's all blank..  Quite frustrating.

I am thinking labels is the way to go anyway because I want the header
to stay locked when I scroll..

Patrick J. Collins
http://collinatorstudios.com
___

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
https://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com

Re: setting table view rows and columns?

2015-03-12 Thread Patrick J. Collins
> Normally you just set up the column titles in IB. The titles are actually the 
> tableColumn.headerCell.stringValue property, displayed in a 
> NSTableHeaderView. If you are setting these programmatically, you should 
> probably do tat as part of the table controller's setup, not every time the 
> dataSource method is called (which is at least once per row).

I cannot figure out how to do this in IB..  I went into the View
Controller Scene, and found my table view, selected nested table cell
view for a column..  Double clicked on the cell, and typed the header
text...  but when I build my app, it's blank.

I am able to populate my table with data, I just can't seem to get a
header to show up.  Maybe I should just use labels above the table??


Patrick J. Collins
http://collinatorstudios.com
___

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
https://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com

setting table view rows and columns?

2015-03-12 Thread Patrick J. Collins
Hi everyone,

I am a little confused with the documentation for NSTableViews...  I assume 
this is the method that one uses to set the "headers" of the table?

- (void)tableView:(NSTableView *)tableView setObjectValue:(id)object 
forTableColumn:(NSTableColumn *)tableColumn row:(NSInteger)row;

That's what I am looking to do, but I don't get how I specify how many columns 
there are in the table?

I have everything else in my table setup properly, I am just trying to figure 
out how to set the header/column names.

Thanks!


Patrick J. Collins
http://collinatorstudios.com

___

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
https://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com

What is the best way to get events fired on keypress for an NSTextField?

2015-03-12 Thread Patrick J. Collins
I hooked up an action from IB to my view controller, but I don't see an
option for where to define what kind of action it is...  So my problem
is events are only being fired when a textfield stops being edited.  I
would like it to fire anytime a key is pressed,  What is the best way to
do this currently?

Patrick J. Collins
http://collinatorstudios.com

___

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
https://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com

Document based architecture

2015-03-09 Thread Patrick J. Collins
Hi everyone,

It was recently suggested to me that my app should be a document based
architecture design since I want File -> Open ->  to bring up a new
"document" window.  Googling this topic has been a bit frustrating...  I
see lots of references in apple's documentation saying things like "The
Xcode development application provides project templates for
document-based applications."  Which I cannot find anywhere in XCode...

Can anyone please shed some light on where I can get real-world instructions
on how to setup this sort of design?

Thanks.

Patrick J. Collins
http://collinatorstudios.com

___

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
https://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com

Re: Trying to create a 1px width NSBox

2015-03-08 Thread Patrick J. Collins
> Not sure why you'd waste time trying to bend unsuitable UI components to your 
> will instead of building a custom view.
> It's super easy and it always does exactly what you design it to do.

Well I guess I can ask the reverse question of, why does Apple waste
their time creating and offering a "vertical line", if it's not useful?
I mean, all I want is a vertical line.  I don't understand why something
like that exists if it's not customizable.

Patrick J. Collins
http://collinatorstudios.com
___

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
https://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com

Drawing inside an NSImage?

2015-03-08 Thread Patrick J. Collins
I have an NSView which has in its "drawRect:" method:

NSColor *backgroundColor = [NSColor colorWithPatternImage:self.image];
[backgroundColor setFill];

...

the image method does:

  -(NSImage *)image {
  if (!_image) {
  _image = [[NSImage alloc] initWithSize:self.bounds.size];

  [_image lockFocus];
  [[NSColor blueColor] set];
  NSBezierPath *line = [NSBezierPath bezierPath];

  NSPoint pointA = NSMakePoint(0, 0);
  NSPoint pointB = NSMakePoint(self.bounds.size.width, 0);

  [line moveToPoint:pointA];
  [line lineToPoint:pointB];
  [line stroke];
  }
return _image;
  }

The resulting line is drawn off center (somewhere around -10px) from the middle
of the NSView...  I would like to have my 0,0 origin be the bottom left corner
of the NSView as I would get if I were to put this line directly in the
drawRect (not using an NSImage): method..

What am I doing wrong here?

Patrick J. Collins
http://collinatorstudios.com

___

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
https://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com

Trying to create a 1px width NSBox

2015-03-08 Thread Patrick J. Collins
I am trying to create a "playhead" that will move across a waveform, and
IB shows a "Vertical line" component which looks exactly what I want..
Except it seems to have a default unchangable width of 5px... ???
I tried setting the borderType property to NSNoBorder but that
made no difference.

How can I get a simple 1px solid colored object that I can use for
this purpose?

Patrick J. Collins
http://collinatorstudios.com

___

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
https://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com

using coregraphics with vector art from illustrator

2010-04-19 Thread Patrick J. Collins
Hi everyone,

I have an app that I am using CoreGraphics to draw music notation symbols, and
I want to keep things perfectly scalable (for zooming), and am just wondering
what the best way to go about this is...

Is there perhaps a way to create vector art paths in illustrator, and import
the data into xcode and use those paths in CG and stroke/fill them there?

Is that possible?

Patrick J. Collins
http://collinatorstudios.com


___

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com


dynamically create/remove IB elements and instance vars?

2009-12-10 Thread Patrick J. Collins
Hi,

I just wrote a basic little cocoa app to test my knowledge after going through
Apple's Currency Converter tutorial...

I made two text fields, and when you click a button, it combines the two words
together and displays them in a label.

I would like to expand on this and make it a little more interesting and
challenging, but I don't know how to do what I am thinking-- which is:

Create a button which will insert a new label/text field.  This action also
needs to dynamically generate an instance variable in my model file for the
text of the new textfield, as well as generate an IBOutlet in my controller.

...  I know how to do this immediately with javascript-- but.. objective-c and
xcode...  no clue!

Any suggestions?

Patrick J. Collins
http://collinatorstudios.com

___

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com


breakout game - openGL or quartz?

2009-12-06 Thread Patrick J. Collins
Hi everyone,

I wrote a "breakout" style game for actionscript3:
http://collinatorstudios.com/dev/super_collins_breakout

and it's been on my mind to make a version for the iPhone..  But before I do
that, I thought it would be good to just make a version for plain old OS X...
So before I do this, I wanted to ask the opinions of every one here--  Should I
use OpenGL or quartz/core animation for my graphics drawing?  I am thinking
that I want to use OpenGL-- even though the game is 2D, I still would like to
be able to do gradients and shading and glowing, etc..  Which I am assuming
isn't going to be as easy to accomplish with quartz/core animation.

Also if anyone recommends any particular books or online tutorials for learning
how to draw simple rectangles and spheres, and make them glow, etc, that would
be great.

Thanks!

Patrick J. Collins
http://collinatorstudios.com


___

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com


question about mutable vs. non-mutable

2009-04-30 Thread Patrick J. Collins
Hi everyone,

I am pretty new to objective-c, and I've been going over some stuff in a book I
bought, and there is just something that is really bothering me.  I can't
really ask the author a question about his paragraph, so I thought I'd write
here instead.

So---  This has to do with arrays, dictionaries and strings.

What I don't get is...  why is there NSMutableString and NSString?

#1.  It seems weird to me that a string object can't be modified once it's
created.  Why is this?

#2.  It seems weird that there is an alternative "mutable" object that can be
modified.  If this is the more convenient way to go, why would anyone use a
regular NSString?  Why not always just use mutable?  In that case, why does the
language even have a plain old NSString?  Isn't it kind of redundant to have
the same sort of thing but less-functional?

#3.  For mutable objects, there is "WithCapacity"..  this is where the author
completely lost me.  So he's saying that these mutable things like
NSMutableArray for example can be set to have a capacity by using
[NSMutableArray arrayWithCapacity: x]

...  Ok.. so, if the whole point of having a mutable object is that it has the
ability to be changed--  Why would you want to specify a capacity?  If you know
the capacity why would you be using NSMutableArray?  Why wouldn't you just use
NSArray?

Ontop of all this, the author says that the capacity isn't a "limit", it's ok
if you go over it--- That really made me lose it.  So--- Why in the world would
you bother setting a capacity for a container object that MIGHT have more
objects than the number you specify???

It just seems like this stuff is so weird and unnecessary and illogical...  So,
I would love it if someone can please explain this to me.  I come from
scripting languages where it's very easy to just define stuff and use it, add
to it, remove from it, etc..  So it's really a struggle for me to see something
that seems so fundamental to be so challenging to accomplish.

Thank you!

Patrick J. Collins
http://collinatorstudios.com

___

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com


image opacity?

2008-05-11 Thread Patrick J. Collins
Hi again,

Does anyone happen to know how one could set the opacity of an
NSImageView object?  I am looking for a way to simply fade in an image
on within my app's window-- but neither of the NSImageView nor
IKImageView list anything about opacity...

Thank you.

Patrick J. Collins
http://collinatorstudios.com


___

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to [EMAIL PROTECTED]


UI tool kit gone in IB 3?

2008-05-10 Thread Patrick J. Collins
Hi,

I am just curious, using Interface Builder 3 for the first time...  Am
I missing something or is the tool kit for all of the window items
(text field, text view, button, slider, etc) gone???  Can anyone walk
me through how I can manually add these items to a window if the UI toolkit
is no longer available?  Or advise a good book on the subject?

Thank you.

Patrick J. Collins
http://collinatorstudios.com


___

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to [EMAIL PROTECTED]


scriptability of button in interface?

2008-05-03 Thread Patrick J. Collins
Hi everyone,

I was just curious--  Does anyone know off the top of their head how one makes
a button's action in an xcode project accessible via applescript?

In otherwords, say your main window has a button named "start".

How do you make it so that an end user could write their own applescript and do
something like:

"Tell application 'patrick's app' to start"

?

I am assuming there is something in interface builder that you need to do to
accomplish this, but I just don't know what it is.

Thank you!

Patrick J. Collins
http://collinatorstudios.com

___

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to [EMAIL PROTECTED]