• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Photoshop style palettes, layers & UI
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Photoshop style palettes, layers & UI


  • Subject: Re: Photoshop style palettes, layers & UI
  • From: Raphael Sebbe <email@hidden>
  • Date: Fri, 28 Sep 2001 21:16:51 +0200

On Friday, September 28, 2001, at 08:52 PM, Brian Hook wrote:

> I'm starting work on my first document based application, and it's
> fairly large. Hey, gotta learn somehow =)
>
> In short, it's a kind of image editing software, where I'll have two
> views onto a piece of data (a 2D and a 3D view), along with multiple
> tool palettes. This is very similar to Photoshop where you have a
> single window per image, and a set of panels with various functionality:
>
> - Tool selection, which looks like it could be done as an NSMatrix of
> NSButtonCells in radio button mode.
>
> - Info panel, which shows various information like the X,Y of the
> cursor, W/H of the selection, etc.
>
> - Tool options toolbar: This changes depending on the currently active
> tool, and is a dockable toolbar in the application window (I'm looking
> at my Win32 Photoshop 6.0 so I'm not sure how this is handled in
> MacOS/OS X).
>
> - Layers/Channels/Paths panel
>
> I think I have a pretty good idea of the basics of doing a multiple
> document app, but some questions have already popped up:
>
> 1. Should each panel have its own NIB, or should they all just go into
> the Main.Nib?

Yes. You don't want to waste memory with panels that the user won't use
in a session, so, you load them separately as much as possible.

> 2. I'm assuming that the document's NIB will have both of the windows
> in it.

A single document may have multiple document windows. But if it makes no
sense for you to have only one of the two, you may use a single NIB (but
I believe, 2 NSWindowControllers...). Otherwise, go for 2 NIBs.

> 3. What's the right way to change the appearance (drastically) of an
> existing panel? For example, say I have a panel that is context
> sensitive to the currently selected tool. Would I programmatically just
> remove and add controls, or would I just have two separate panels and
> have them hide/unhide appropriately?

I tend to use NSBox and -setContentView: method generally. There is also
NSView's addSubview: method.


> 4. For the layer view, there is a stack of cells that basically show
> the operations that you've done and in what order. You can remove
> cells, or drag and drop cells to re-order them. Is this something that
> should be a subclass of NSMatrix, or will I need to do something even
> more customized? Does NSMatrix require all of its cells to be of the
> same type? Unfortunately, each layer cell that I'm envisioning may have
> a slightly different appearance (or even subcontrols) depending on how
> that layer was created.

If you still mean something like Photoshop history panel, I would go
with NSTableView or NSOutlineView (hierarchical). They both have some
dnd support builtin.


> I'm sure I'll have more questions later, I just don't want to hose
> myself too badly early on =)
>
> Thanks,
>
> Brian


Hope this helps,

Raphael


References: 
 >Photoshop style palettes, layers & UI (From: Brian Hook <email@hidden>)

  • Prev by Date: Re: Photoshop style palettes, layers & UI
  • Next by Date: Re: cocoa-dev digest, Vol 1 #640 - 16 msgs
  • Previous by thread: Re: Photoshop style palettes, layers & UI
  • Next by thread: Re: cocoa-dev digest, Vol 1 #640 - 16 msgs
  • Index(es):
    • Date
    • Thread