xCode 3.0 Bug Subclassing NSPanel (HUD)?

Discussion in 'Mac Programming' started by Darkroom, Jun 28, 2008.

  1. Guest


    Dec 15, 2006
    Montréal, Canada
    i was able to subclass an NSPanel (with HUD) only after writing files for it in xCode and than launching IB. originally, i had dragged a HUD out but whenever i would try to subclass it, i would loose the HUD visuals - it would turn into a basic looking panel... is that a bug in xCode? or was i doing something wrong?
  2. macrumors newbie

    Jul 15, 2008
    xCode 3.0 Bug Subclassing NSPanel (HUD)

    You can subclass NSPanel and keep the HUD display. The problem is that the style masks can only be used in certain combinations. Here is an example of a panel subclass that has some proper combination of style masks:
    [[MyPanel alloc] initWithContentRect:windowRect									 
    styleMask:NSHUDWindowMask | NSTitledWindowMask | NSUtilityWindowMask						
    screen:[[NSApp mainWindow] screen]];
    I can't remember where I found the combinations. I think they were buried somewhere in the release notes for app kit. Hope that helps. Good luck.

Share This Page