bug-gnustep
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

NSTitleView class


From: Serg Stoyan
Subject: NSTitleView class
Date: Mon, 31 Mar 2003 23:56:18 +0300

Hi everybody,

As a result of my fixing/enhancement around NSMenu* system I've decided to
create a replacement for NSMenuWindowTitle but enhanced. I've attached all
necessary files to test NSTitleView class. Here is some explain:

- Source-GNUmakefile.diff - patch for Source/GNUmakefile, adds
  NSTitleView.m and NSTitleView.h to compile and install;

- NSTitleView.tar.bz2 - NSTitleView.m (gui/Source) and
  NSTitleView.h (gui/Headers/AppKit);

- NSMenuView.diff - patch for using NSTitleView for menus instead
  NSMenuWindowTitleView;

- *.tiff - images for close and miniaturize button (title buttons now
  bordered and images support this, so it isn't WindowMaker style but 
  OPENSTEP style);

- NSMenuTest.tar.bz2 - test program. Choosing Document->New menu item
  produces window with NSTitleView inside window. You can see WindowMaker
  title bar also and can play around with windowStyleMask to see how
  NSTitleView reacts on window style changes compared to WindowMaker's.
  You can drag NSTiteView to move window, close miniaturized button to
  miniaturize window, and close button to close.
  Also notice the following:
  1. Create 2 windows selecting Document->New;
  2. Try to change focus between them. Focused window has black NSTitleView
     and inactive dark gray one. If change focus to another application,
     active window NSTitleView (black) turns into light gray but
     WindowMaker's becomes dark gray;

Why I create this class:
1. It can be used by NSMenuView, NSWindow and so on.
2. It can be used by Login-style applications (that is, before any window
   manager's loaded) to create own panels/windows which can be moved
   around.
3. It can be used by GNUstep ObjectiveC window managers (e.g. Interface).
4. It helps keeping consistent look and feel across the environments.
5. It helps dealing with focus issues.

But this is the simplest part of implementation, I guess. Next important
thing is to make NSWindow using NSTitleView.

But anyway, what do you think about adding this non-standard (Cocoa
and OpenStep doesn't have this) class? Should I commit it to CVS? Is there
any problems or difficulties I missed?

-- 
Serg Stoyan

Attachment: NSMenuTest.tar.bz2
Description: Binary data

Attachment: NSMenuView.diff
Description: Text document

Attachment: Source-GNUmakefile.diff
Description: Text document

Attachment: common_Close.tiff
Description: TIFF image

Attachment: common_CloseH.tiff
Description: TIFF image

Attachment: common_Miniaturize.tiff
Description: TIFF image

Attachment: common_MiniaturizeH.tiff
Description: TIFF image

Attachment: NSTitleView.tar.bz2
Description: Binary data


reply via email to

[Prev in Thread] Current Thread [Next in Thread]