Header files reorganized. All the definitions were moved in appropiate files.

Each header file includes only the header files it needs and it uses
@class to forward reference a class.


git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@2189 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
netcrep 1997-02-18 00:29:25 +00:00
parent 8c3afd9724
commit d5fd123408
151 changed files with 2718 additions and 3068 deletions

View file

@ -1,27 +1,48 @@
Wed Feb 12 14:14:47 1997 GNUstep Development <gnustep@net-community.com>
Mon Feb 17 19:30:50 1997 Ovidiu Predescu <ovidiu@bx.logicnet.ro>
* Initial implementation of NSCursor.
* Headers/gnustep/gui/NSCursor.h: Likewise.
* Source/NSCursor.m: Likewise.
* Headers/gnustep/gui/NSWindow.h: Implement cursor rectangles.
* Source/NSView.m: Likewise.
* Source/NSWindow.m: Likewise.
* Source/Makefile.in: Clean up variables
* Source/NSApplication.m: Fixes to event posting. Unhide the
cursor when a mouse event occurs.
* Source/NSEvent.m: NSCursorUpdate events are implemented
as enter/exit events instead of other events.
* Headers/gnustep/gui/NSTextField.h: Add text field cursor.
* Source/NSTextField.m: Likewise.
* Source/NSButton.m: New methods -setAlignment: and -alignment,
setIntValue:, setFloatValue:, setDoubleValue:, setAlignment:,
alignment.
* Source/NSButtonCell.m: setType: changed to setButtonType:. Changed
the way in which the button types are handled (use highlightsBy and
showsStateBy attributes). Fixed some object allocation retain/release
problems. setHighlightsBy: and setShowsStateBy: implemented. New
methods setIntValue:, setFloatValue:, setDoubleValue:, intValue,
floatValue, doubleValue. Fixed coding methods.
* Source/NSCell.m: Fixed some object allocation problems. Changed the
way in which setIntValue:, setFloatValue: and setDoubleValue: work.
Commented out a point conversion that works wrong (why?).
Thu Feb 6 19:31:54 1997 GNUstep Development <gnustep@net-community.com>
Sat Feb 15 23:12:35 1997 Ovidiu Predescu <ovidiu@bx.logicnet.ro>
* Fill out implementation of NSColorWell.
* Headers/gnustep/gui/NSColorWell.h: Add backend instance variable
and backend method.
* Source/NSColorWell.m: Initial implementation.
* NSView.m: Don't use -isKindOfClass: because it isn't working
as we expect with the backend classes doing a +poseAs:
* Major reorganization of header files. Types and constants were moved
in the files they belong (too many to enumerate here). Each header
file includes only the headers it really needs. Use @class to forward
class definitions instead of including the corresponding class file.
* Headers/gnustep/gui/Functions.h: Removed.
* Headers/gnustep/gui/NSBundle.h: Removed.
* Headers/gnustep/gui/NSFontPrivate.h: Removed.
* Headers/gnustep/gui/TypesandConstants.h: Removed.
* Headers/gnustep/gui/stdappkit.h: Removed.
* Headers/gnustep/gui/NSGraphichs.h: New file.
* Headers/gnustep/gui/AppKitExceptions.h: New file. A place to put
exception strings that don't belong elsewhere.
* Headers/gnustep/gui/NSNibLoading.h: Added category to NSBundle that
deals with nib loading.
Mon Feb 10 17:23:06 1997 Ovidiu Predescu <ovidiu@bx.logicnet.ro>
* Source/NSFont.m: Completely reworked. Get the default fonts using
the NSUserDefaults class instead of hard-coding them. Almost all the
methods have to be overwritten in the true backend class.
* Headers/gnustep/gui/NSFont.h: Removed unnecessary instance variables.
Define some particular glyph types.
* Source/NSFontManager.m: Commented out the methods that converts
between different fonts and traits.
* Source/Makefile: Define GNUSTEP_INSTALL_LIBDIR directly as string.
* Source/NSImage.m: GNUSTEP_INSTALL_LIBDIR is passed as string during
compilation so don't use OBJC_STRINGIFY. Use an OpenStep method to
search for a resource instead of the particular gnustep-base method.
Fri Jan 31 05:30:40 1997 Scott Christley <scottc@net-community.com>
@ -101,6 +122,15 @@ Thu Jan 23 15:10:13 1997 Scott Christley <scottc@net-community.com>
defined in NSApplication.
* Source/NSTextFieldCell.m (-initWithFrame:): Bezeled by default.
Tue Jan 14 9:33:04 1997 Ovidiu Predescu <ovidiu@bx.logicnet.ro>
* Source/Functions.m: Exclude from compiling the NSLog functions when
working with libFoundation.
* Source/NSBundle.m: Renamed to NSBundleAdditions.m to make possible
create a shared library under OS 4.1.
* Changed the -encodeWithCoder: and -initWithCoder: methods in all
classes to work with the basic NSCoder methods.
Thu Dec 5 06:58:51 1996 GNUstep Development <gnustep@net-community.com>
* Source/NSColorList.m: Fill out implementation.

View file

@ -29,6 +29,8 @@
#ifndef _GNUstep_H_DPSOperators
#define _GNUstep_H_DPSOperators
#include <gnustep/gui/config.h>
// Use the DPSclient library if we have it
#ifdef HAVE_DPSCLIENT

View file

@ -29,10 +29,12 @@
#ifndef _GNUstep_H_NSDPSContext
#define _GNUstep_H_NSDPSContext
#include <AppKit/stdappkit.h>
#include <DPSClient/TypesandConstants.h>
#include <Foundation/NSData.h>
#include <DPSClient/DPSOperators.h>
#include <Foundation/NSObject.h>
@class NSData;
@class NSMutableData;
//
// NSDPSContextNotification

View file

@ -29,6 +29,10 @@
#ifndef _GNUstep_H_DPSTypes
#define _GNUstep_H_DPSTypes
#include <gnustep/gui/config.h>
@class NSString;
// These are already defined in the DPSclient headers
#ifndef HAVE_DPSCLIENT
typedef void *DPSProgramEncoding;

View file

@ -0,0 +1 @@
config.h

View file

@ -29,8 +29,6 @@
#ifndef _GNUstep_H_AppKit
#define _GNUstep_H_AppKit
#include <AppKit/stdappkit.h>
//
// System dependent information
//
@ -42,15 +40,10 @@ float MB_SCREEN_MAXHEIGHT();
//
#include <DPSClient/DPSOperators.h>
//
// Types and Constants for GNUstep GUI Library
//
#include <AppKit/TypesandConstants.h>
//
// GNUstep GUI Library functions
//
#include <AppKit/Functions.h>
#include <AppKit/NSGraphics.h>
//
// Protocols
@ -148,7 +141,4 @@ float MB_SCREEN_MAXHEIGHT();
#include <AppKit/NSWindow.h>
#include <AppKit/NSWorkspace.h>
#include <Foundation/NSBundle.h>
#include <AppKit/NSBundle.h>
#endif _GNUstep_H_AppKit

View file

@ -0,0 +1,67 @@
/*
AppKitExceptions.h
Copyright (C) 1996 Free Software Foundation, Inc.
Author: Ovidiu Predescu <ovidiu@bx.logicnet.ro>
Date: February 1997
This file is part of the GNUstep GUI Library.
This library is free software; you can redistribute it and/or
modify it under the terms of the GNU Library General Public
License as published by the Free Software Foundation; either
version 2 of the License, or (at your option) any later version.
This library is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
Library General Public License for more details.
You should have received a copy of the GNU Library General Public
License along with this library; if not, write to the Free
Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
*/
#ifndef __AppKit_AppKitExceptions_h__
#define __AppKit_AppKitExceptions_h__
@class NSString;
extern NSString *NSAbortModalException;
extern NSString *NSAbortPrintingException;
extern NSString *NSAppKitIgnoredException;
extern NSString *NSAppKitVirtualMemoryException;
extern NSString *NSBadBitmapParametersException;
extern NSString *NSBadComparisonException;
extern NSString *NSBadRTFColorTableException;
extern NSString *NSBadRTFDirectiveException;
extern NSString *NSBadRTFFontTableException;
extern NSString *NSBadRTFStyleSheetException;
extern NSString *NSBrowserIllegalDelegateException;
extern NSString *NSColorListIOException;
extern NSString *NSColorListNotEditableException;
extern NSString *NSDraggingException;
extern NSString *NSFontUnavailableException;
extern NSString *NSIllegalSelectorException;
extern NSString *NSImageCacheException;
extern NSString *NSNibLoadingException;
extern NSString *NSPPDIncludeNotFoundException;
extern NSString *NSPPDIncludeStackOverflowException;
extern NSString *NSPPDIncludeStackUnderflowException;
extern NSString *NSPPDParseException;
extern NSString *NSPasteboardCommunicationException;
extern NSString *NSPrintOperationExistsException;
extern NSString *NSPrintPackageException;
extern NSString *NSPrintingCommunicationException;
extern NSString *NSRTFPropertyStackOverflowException;
extern NSString *NSTIFFException;
extern NSString *NSTextLineTooLongException;
extern NSString *NSTextNoSelectionException;
extern NSString *NSTextReadException;
extern NSString *NSTextWriteException;
extern NSString *NSTypedStreamVersionException;
extern NSString *NSWindowServerCommunicationException;
extern NSString *NSWordTablesReadException;
extern NSString *NSWordTablesWriteException;
#endif /* __AppKit_AppKitExceptions_h__ */

View file

@ -1,248 +0,0 @@
/*
Functions.h
Generic functions for the GNUstep GUI Library
Copyright (C) 1996 Free Software Foundation, Inc.
Author: Scott Christley <scottc@net-community.com>
Date: 1996
This file is part of the GNUstep GUI Library.
This library is free software; you can redistribute it and/or
modify it under the terms of the GNU Library General Public
License as published by the Free Software Foundation; either
version 2 of the License, or (at your option) any later version.
This library is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
Library General Public License for more details.
You should have received a copy of the GNU Library General Public
License along with this library; see the file COPYING.LIB.
If not, write to the Free Software Foundation,
59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
*/
#ifndef _GNUstep_H_AppKitFunctions
#define _GNUstep_H_AppKitFunctions
#include <AppKit/stdappkit.h>
#include <DPSClient/DPSOperators.h>
@class NSPasteboard, NSColor;
//
// Rectangle Drawing Functions
//
//
// Optimize Drawing
//
void NSEraseRect(NSRect aRect);
void NSHighlightRect(NSRect aRect);
void NSRectClip(NSRect aRect);
void NSRectClipList(const NSRect *rects, int count);
void NSRectFill(NSRect aRect);
void NSRectFillList(const NSRect *rects, int count);
void NSRectFillListWithGrays(const NSRect *rects,
const float *grays, int count);
//
// Draw a Bordered Rectangle
//
void NSDrawButton(NSRect aRect, NSRect clipRect);
void NSDrawGrayBezel(NSRect aRect, NSRect clipRect);
void NSDrawGroove(NSRect aRect, NSRect clipRect);
NSRect NSDrawTiledRects(NSRect boundsRect, NSRect clipRect,
const NSRectEdge *sides, const float *grays,
int count);
void NSDrawWhiteBezel(NSRect aRect, NSRect clipRect);
void NSFrameRect(NSRect aRect);
void NSFrameRectWithWidth(NSRect aRect, float frameWidth);
//
// Color Functions
//
//
// Get Information About Color Space and Window Depth
//
const NSWindowDepth *NSAvailableWindowDepths(void);
NSWindowDepth NSBestDepth(NSString *colorSpace,
int bitsPerSample, int bitsPerPixel,
BOOL planar, BOOL *exactMatch);
int NSBitsPerPixelFromDepth(NSWindowDepth depth);
int NSBitsPerSampleFromDepth(NSWindowDepth depth);
NSString *NSColorSpaceFromDepth(NSWindowDepth depth);
int NSNumberOfColorComponents(NSString *colorSpaceName);
BOOL NSPlanarFromDepth(NSWindowDepth depth);
//
// Read the Color at a Screen Position
//
NSColor *NSReadPixel(NSPoint location);
//
// Text Functions
//
//
// Filter Characters Entered into a Text Object
//
unsigned short NSEditorFilter(unsigned short theChar,
int flags, NSStringEncoding theEncoding);
unsigned short NSFieldFilter(unsigned short theChar,
int flags, NSStringEncoding theEncoding);
//
// Calculate or Draw a Line of Text (in Text Object)
//
int NSDrawALine(id self, NSLayInfo *layInfo);
int NSScanALine(id self, NSLayInfo *layInfo);
//
// Calculate Font Ascender, Descender, and Line Height (in Text Object)
//
void NSTextFontInfo(id fid,
float *ascender, float *descender,
float *lineHeight);
//
// Access Text Object's Word Tables
//
NSData * NSDataWithWordTable(const unsigned char *smartLeft,
const unsigned char *smartRight,
const unsigned char *charClasses,
const NSFSM *wrapBreaks,
int wrapBreaksCount,
const NSFSM *clickBreaks,
int clickBreaksCount,
BOOL charWrap);
void NSReadWordTable(NSZone *zone,
NSData *data,
unsigned char **smartLeft,
unsigned char **smartRight,
unsigned char **charClasses,
NSFSM **wrapBreaks,
int *wrapBreaksCount,
NSFSM **clickBreaks,
int *clickBreaksCount,
BOOL *charWrap);
//
// Array Allocation Functions for Use by the NSText Class
//
NSTextChunk *NSChunkCopy(NSTextChunk *pc, NSTextChunk *dpc);
NSTextChunk *NSChunkGrow(NSTextChunk *pc, int newUsed);
NSTextChunk *NSChunkMalloc(int growBy, int initUsed);
NSTextChunk *NSChunkRealloc(NSTextChunk *pc);
NSTextChunk *NSChunkZoneCopy(NSTextChunk *pc,
NSTextChunk *dpc,
NSZone *zone);
NSTextChunk *NSChunkZoneGrow(NSTextChunk *pc, int newUsed, NSZone *zone);
NSTextChunk *NSChunkZoneMalloc(int growBy, int initUsed, NSZone *zone);
NSTextChunk *NSChunkZoneRealloc(NSTextChunk *pc, NSZone *zone);
//
// Imaging Functions
//
//
// Copy an image
//
void NSCopyBitmapFromGState(int srcGstate, NSRect srcRect, NSRect destRect);
void NSCopyBits(int srcGstate, NSRect srcRect, NSPoint destPoint);
//
// Render Bitmap Images
//
void NSDrawBitmap(NSRect rect,
int pixelsWide,
int pixelsHigh,
int bitsPerSample,
int samplesPerPixel,
int bitsPerPixel,
int bytesPerRow,
BOOL isPlanar,
BOOL hasAlpha,
NSString *colorSpaceName,
const unsigned char *const data[5]);
//
// Attention Panel Functions
//
//
// Create an Attention Panel without Running It Yet
//
id NSGetAlertPanel(NSString *title,
NSString *msg,
NSString *defaultButton,
NSString *alternateButton,
NSString *otherButton, ...);
//
// Create and Run an Attention Panel
//
int NSRunAlertPanel(NSString *title,
NSString *msg,
NSString *defaultButton,
NSString *alternateButton,
NSString *otherButton, ...);
int NSRunLocalizedAlertPanel(NSString *table,
NSString *title,
NSString *msg,
NSString *defaultButton,
NSString *alternateButton,
NSString *otherButton, ...);
//
// Release an Attention Panel
//
void NSReleaseAlertPanel(id panel);
//
// Services Menu Functions
//
//
// Determine Whether an Item Is Included in Services Menus
//
int NSSetShowsServicesMenuItem(NSString *item, BOOL showService);
BOOL NSShowsServicesMenuItem(NSString *item);
//
// Programmatically Invoke a Service
//
BOOL NSPerformService(NSString *item, NSPasteboard *pboard);
//
// Force Services Menu to Update Based on New Services
//
void NSUpdateDynamicServices(void);
//
// Other GNUstep GUI Library Functions
//
//
// Play the System Beep
//
void NSBeep(void);
//
// Return File-related Pasteboard Types
//
NSString *NSCreateFileContentsPboardType(NSString *fileType);
NSString *NSCreateFilenamePboardType(NSString *filename);
NSString *NSGetFileType(NSString *pboardType);
NSArray *NSGetFileTypes(NSArray *pboardTypes);
//
// Draw a Distinctive Outline around Linked Data
//
void NSFrameLinkRect(NSRect aRect, BOOL isDestination);
float NSLinkFrameThickness(void);
//
// Convert an Event Mask Type to a Mask
//
unsigned int NSEventMaskFromType(NSEventType type);
#endif // _GNUstep_H_AppKitFunctions

View file

@ -29,12 +29,9 @@
#ifndef _GNUstep_H_NSActionCell
#define _GNUstep_H_NSActionCell
#include <AppKit/stdappkit.h>
#include <AppKit/NSCell.h>
#include <Foundation/NSCoder.h>
@interface NSActionCell : NSCell <NSCoding>
{
// Attributes
int tag;
@ -51,25 +48,17 @@
- (void)setEnabled:(BOOL)flag;
- (void)setFloatingPointFormat:(BOOL)autoRange
left:(unsigned int)leftDigits
right:(unsigned int)rightDigits;
right:(unsigned int)rightDigits;
- (void)setFont:(NSFont *)fontObject;
- (void)setImage:(NSImage *)image;
//
// Manipulating NSActionCell Values
//
- (double)doubleValue;
- (float)floatValue;
- (int)intValue;
- (void)setIntValue:(int)anInt;
- (void)setFloatValue:(float)aFloat;
- (void)setDoubleValue:(double)aDouble;
- (void)setStringValue:(NSString *)aString;
- (NSString *)stringValue;
//
// Displaying
//
- (void)drawWithFrame:(NSRect)cellFrame
inView:(NSView *)controlView;
- (NSView *)controlView;
//
// Target and Action

View file

@ -29,28 +29,41 @@
#ifndef _GNUstep_H_NSApplication
#define _GNUstep_H_NSApplication
#include <AppKit/stdappkit.h>
#include <Foundation/NSArray.h>
#include <Foundation/NSException.h>
#include <AppKit/NSEvent.h>
#include <AppKit/NSResponder.h>
#include <AppKit/NSWindow.h>
#include <AppKit/NSMenu.h>
#include <AppKit/NSImage.h>
#include <Foundation/NSDate.h>
#include <gnustep/base/Queue.h>
#include <Foundation/NSCoder.h>
#include <DPSClient/NSDPSContext.h>
#include <Foundation/NSNotification.h>
@class NSArray;
@class NSMutableArray;
@class NSString;
@class NSException;
@class NSNotification;
@class NSDate;
@class NSEvent;
@class NSPasteboard;
@class NSMenu;
@class NSMenuCell;
@class NSImage;
@class NSWindow;
@class NSDPSContext;
extern id NSApp;
typedef struct _NSModalSession *NSModalSession;
enum {
NSRunStoppedResponse,
NSRunAbortedResponse,
NSRunContinuesResponse
};
extern NSString *NSModalPanelRunLoopMode;
extern NSString *NSEventTrackingRunLoopMode;
@interface NSApplication : NSResponder <NSCoding>
{
// Attributes
NSMutableArray *window_list;
Queue *event_queue;
NSMutableArray *event_queue;
NSEvent *current_event;
id key_window;
id main_window;
@ -268,4 +281,36 @@
@end
//
// Notifications
//
extern NSString *NSApplicationDidBecomeActiveNotification;
extern NSString *NSApplicationDidFinishLaunchingNotification;
extern NSString *NSApplicationDidHideNotification;
extern NSString *NSApplicationDidResignActiveNotification;
extern NSString *NSApplicationDidUnhideNotification;
extern NSString *NSApplicationDidUpdateNotification;
extern NSString *NSApplicationWillBecomeActiveNotification;
extern NSString *NSApplicationWillFinishLaunchingNotification;
extern NSString *NSApplicationWillHideNotification;
extern NSString *NSApplicationWillResignActiveNotification;
extern NSString *NSApplicationWillUnhideNotification;
extern NSString *NSApplicationWillUpdateNotification;
//
// Determine Whether an Item Is Included in Services Menus
//
int NSSetShowsServicesMenuItem(NSString *item, BOOL showService);
BOOL NSShowsServicesMenuItem(NSString *item);
//
// Programmatically Invoke a Service
//
BOOL NSPerformService(NSString *item, NSPasteboard *pboard);
//
// Force Services Menu to Update Based on New Services
//
void NSUpdateDynamicServices(void);
#endif // _GNUstep_H_NSApplication

View file

@ -29,13 +29,25 @@
#ifndef _GNUstep_H_NSBitmapImageRep
#define _GNUstep_H_NSBitmapImageRep
#include <AppKit/stdappkit.h>
#include <AppKit/NSImageRep.h>
#include <Foundation/NSCoder.h>
#include <AppKit/nsimage-tiff.h>
@class NSArray;
@class NSString;
@class NSData;
@class NSMutableData;
typedef enum _NSTIFFCompression {
NSTIFFCompressionNone = 1,
NSTIFFCompressionCCITTFAX3 = 3,
NSTIFFCompressionCCITTFAX4 = 4,
NSTIFFCompressionLZW = 5,
NSTIFFCompressionJPEG = 6,
NSTIFFCompressionNEXT = 32766,
NSTIFFCompressionPackBits = 32773,
NSTIFFCompressionOldJPEG = 32865
} NSTIFFCompression;
@interface NSBitmapImageRep : NSImageRep <NSCoding>
{
// Attributes
unsigned int bytesPerRow;

View file

@ -29,15 +29,23 @@
#ifndef _GNUstep_H_NSBox
#define _GNUstep_H_NSBox
#include <AppKit/stdappkit.h>
#include <AppKit/NSView.h>
#include <AppKit/NSFont.h>
#include <Foundation/NSCoder.h>
@class NSString;
@class NSFont;
typedef enum _NSTitlePosition {
NSNoTitle,
NSAboveTop,
NSAtTop,
NSBelowTop,
NSAboveBottom,
NSAtBottom,
NSBelowBottom
} NSTitlePosition;
@interface NSBox : NSView <NSCoding>
{
@protected
// Attributes
id cell;
id content_view;

View file

@ -29,14 +29,16 @@
#ifndef _GNUstep_H_NSBrowser
#define _GNUstep_H_NSBrowser
#include <AppKit/stdappkit.h>
#include <AppKit/NSControl.h>
#include <AppKit/NSMatrix.h>
#include <AppKit/NSScroller.h>
#include <Foundation/NSCoder.h>
@class NSString;
@class NSArray;
@class NSCell;
@class NSMatrix;
@class NSScroller;
@interface NSBrowser : NSControl <NSCoding>
{
// Attributes
}
@ -130,7 +132,7 @@
//
- (void)drawTitle:(NSString *)title
inRect:(NSRect)aRect
ofColumn:(int)column;
ofColumn:(int)column;
- (BOOL)isTitled;
- (void)setTitled:(BOOL)flag;
- (void)setTitle:(NSString *)aString
@ -184,28 +186,6 @@ ofColumn:(int)column;
//
- (void)tile;
//
// Methods Implemented by the Delegate
//
- (void)browser:(NSBrowser *)sender
createRowsForColumn:(int)column
inMatrix:(NSMatrix *)matrix;
- (BOOL)browser:(NSBrowser *)sender
isColumnValid:(int)column;
- (int)browser:(NSBrowser *)sender
numberOfRowsInColumn:(int)column;
- (BOOL)browser:(NSBrowser *)sender
selectCell:(NSString *)title
inColumn:(int)column;
- (NSString *)browser:(NSBrowser *)sender
titleOfColumn:(int)column;
- (void)browser:(NSBrowser *)sender
willDisplayCell:(id)cell
atRow:(int)row
column:(int)column;
- (void)browserDidScroll:(NSBrowser *)sender;
- (void)browserWillScroll:(NSBrowser *)sender;
//
// NSCoding protocol
//
@ -214,4 +194,32 @@ column:(int)column;
@end
//
// Methods Implemented by the Delegate
//
@interface NSObject (NSBrowserDelegate)
- (void)browser:(NSBrowser *)sender
createRowsForColumn:(int)column
inMatrix:(NSMatrix *)matrix;
- (BOOL)browser:(NSBrowser *)sender
isColumnValid:(int)column;
- (int)browser:(NSBrowser *)sender
numberOfRowsInColumn:(int)column;
- (BOOL)browser:(NSBrowser *)sender
selectCell:(NSString *)title
inColumn:(int)column;
- (NSString *)browser:(NSBrowser *)sender
titleOfColumn:(int)column;
- (void)browser:(NSBrowser *)sender
willDisplayCell:(id)cell
atRow:(int)row
column:(int)column;
- (void)browserDidScroll:(NSBrowser *)sender;
- (void)browserWillScroll:(NSBrowser *)sender;
@end
#endif // _GNUstep_H_NSBrowser

View file

@ -29,12 +29,11 @@
#ifndef _GNUstep_H_NSBrowserCell
#define _GNUstep_H_NSBrowserCell
#include <AppKit/stdappkit.h>
#include <AppKit/NSCell.h>
#include <Foundation/NSCoder.h>
@class NSImage;
@interface NSBrowserCell : NSCell <NSCoding>
{
// Attributes
}

View file

@ -1,51 +0,0 @@
/*
NSBundle.h
Category of additional methods used by GUI Library.
Copyright (C) 1996 Free Software Foundation, Inc.
Author: Scott Christley <scottc@net-community.com>
Date: 1996
This file is part of the GNUstep GUI Library.
This library is free software; you can redistribute it and/or
modify it under the terms of the GNU Library General Public
License as published by the Free Software Foundation; either
version 2 of the License, or (at your option) any later version.
This library is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
Library General Public License for more details.
You should have received a copy of the GNU Library General Public
License along with this library; see the file COPYING.LIB.
If not, write to the Free Software Foundation,
59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
*/
#ifndef _GNUstep_H_NSBundleAdditions
#define _GNUstep_H_NSBundleAdditions
#include <AppKit/stdappkit.h>
#include <Foundation/NSBundle.h>
@interface NSBundle (NSBundleAdditions)
- (NSString *)pathForImageResource:(NSString *)name;
+ (BOOL)loadNibFile:(NSString *)fileName
externalNameTable:(NSDictionary *)context
withZone:(NSZone *)zone;
+ (BOOL)loadNibNamed:(NSString *)aNibName
owner:(id)owner;
@end
#endif // _GNUstep_H_NSBundleAdditions

View file

@ -29,13 +29,13 @@
#ifndef _GNUstep_H_NSButton
#define _GNUstep_H_NSButton
#include <AppKit/stdappkit.h>
#include <AppKit/NSControl.h>
#include <DPSClient/DPSOperators.h>
#include <Foundation/NSCoder.h>
#include <AppKit/NSButtonCell.h>
@class NSString;
@class NSEvent;
@interface NSButton : NSControl <NSCoding>
{
// Attributes
}
@ -49,7 +49,7 @@
//
// Setting the Button Type
//
- (void)setType:(NSButtonType)aType;
- (void)setButtonType:(NSButtonType)aType;
//
// Setting the State

View file

@ -29,20 +29,32 @@
#ifndef _GNUstep_H_NSButtonCell
#define _GNUstep_H_NSButtonCell
#include <AppKit/stdappkit.h>
#include <AppKit/NSActionCell.h>
#include <Foundation/NSString.h>
#include <DPSClient/DPSOperators.h>
#include <AppKit/NSControl.h>
#include <Foundation/NSCoder.h>
@class NSFont;
typedef enum _NSButtonType {
NSMomentaryPushButton,
NSPushOnPushOffButton,
NSToggleButton,
NSSwitchButton,
NSRadioButton,
NSMomentaryChangeButton,
NSOnOffButton,
NSMomentaryLight
} NSButtonType;
@interface NSButtonCell : NSActionCell <NSCoding>
{
// Attributes
NSString *alt_contents;
NSImage *alt_image;
NSString *altContents;
NSImage *altImage;
NSString* keyEquivalent;
NSFont* keyEquivalentFont;
unsigned int keyEquivalentModifierMask;
BOOL transparent;
unsigned int highlightsByMask;
unsigned int showAltStateMask;
// Reserved for back-end use
void *be_bc_reserved;
@ -88,7 +100,6 @@
//
// Modifying Graphic Attributes
//
- (BOOL)isOpaque;
- (BOOL)isTransparent;
- (void)setTransparent:(BOOL)flag;
@ -98,7 +109,7 @@
- (int)highlightsBy;
- (void)setHighlightsBy:(int)aType;
- (void)setShowsStateBy:(int)aType;
- (void)setType:(NSButtonType)aType;
- (void)setButtonType:(NSButtonType)aType;
- (int)showsStateBy;
//

View file

@ -28,13 +28,275 @@
#ifndef _GNUstep_H_NSCStringText
#define _GNUstep_H_NSCStringText
#include <AppKit/stdappkit.h>
#include <AppKit/NSText.h>
#include <Foundation/NSCoder.h>
#include <AppKit/NSFontManager.h>
@class NSCell;
@class NSPasteBoard;
typedef short NSLineDesc;
typedef struct _NSTextChunk {
short growby;
int allocated;
int used;
} NSTextChunk;
typedef struct _NSBreakArray {
NSTextChunk chunk;
NSLineDesc breaks[1];
} NSBreakArray;
typedef struct _NSCharArray {
NSTextChunk chunk;
unsigned char text[1];
} NSCharArray;
typedef unsigned short (*NSCharFilterFunc) (unsigned short charCode,
int flags,
NSStringEncoding theEncoding);
typedef struct _NSFSM {
const struct _NSFSM *next;
short delta;
short token;
} NSFSM;
typedef struct _NSHeightInfo {
float newHeight;
float oldHeight;
NSLineDesc lineDesc;
} NSHeightInfo;
typedef struct _NSHeightChange {
NSLineDesc lineDesc;
NSHeightInfo heightInfo;
} NSHeightChange;
typedef struct {
unsigned int underline:1;
unsigned int dummy:1;
unsigned int subclassWantsRTF:1;
unsigned int graphic:1;
unsigned int forcedSymbol:1;
unsigned int RESERVED:11;
} NSRunFlags;
typedef struct _NSRun {
id font;
int chars;
void *paraStyle;
int textRGBColor;
unsigned char superscript;
unsigned char subscript;
id info;
NSRunFlags rFlags;
} NSRun;
typedef struct {
unsigned int mustMove:1;
unsigned int isMoveChar:1;
unsigned int RESERVED:14;
} NSLayFlags;
typedef struct _NSLay {
float x;
float y;
short offset;
short chars;
id font;
void *paraStyle;
NSRun *run;
NSLayFlags lFlags;
} NSLay;
typedef struct _NSLayArray {
NSTextChunk chunk;
NSLay lays[1];
} NSLayArray;
typedef struct _NSWidthArray {
NSTextChunk chunk;
float widths[1];
} NSWidthArray;
typedef struct _NSTextBlock {
struct _NSTextBlock *next;
struct _NSTextBlock *prior;
struct _tbFlags {
unsigned int malloced:1;
unsigned int PAD:15;
} tbFlags;
short chars;
unsigned char *text;
} NSTextBlock;
typedef struct _NSTextCache {
int curPos;
NSRun *curRun;
int runFirstPos;
NSTextBlock *curBlock;
int blockFirstPos;
} NSTextCache;
typedef struct _NSLayInfo {
NSRect rect;
float descent;
float width;
float left;
float right;
float rightIndent;
NSLayArray *lays;
NSWidthArray *widths;
NSCharArray *chars;
NSTextCache cache;
NSRect *textClipRect;
struct _lFlags {
unsigned int horizCanGrow:1;
unsigned int vertCanGrow:1;
unsigned int erase:1;
unsigned int ping:1;
unsigned int endsParagraph:1;
unsigned int resetCache:1;
unsigned int RESERVED:10;
} lFlags;
} NSLayInfo;
typedef enum _NSParagraphProperty {
NSLeftAlignedParagraph,
NSRightAlignedParagraph,
NSCenterAlignedParagraph,
NSJustificationAlignedParagraph,
NSFirstIndentParagraph,
NSIndentParagraph,
NSAddTabParagraph,
NSRemoveTabParagraph,
NSLeftMarginParagraph,
NSRightMarginParagraph
} NSParagraphProperty;
typedef struct _NSRunArray {
NSTextChunk chunk;
NSRun runs[1];
} NSRunArray;
typedef struct _NSSelPt {
int cp;
int line;
float x;
float y;
int c1st;
float ht;
} NSSelPt;
typedef struct _NSTabStop {
short kind;
float x;
} NSTabStop;
typedef char *(*NSTextFilterFunc) (id self,
unsigned char * insertText,
int *insertLength,
int position);
typedef int (*NSTextFunc) (id self,
NSLayInfo *layInfo);
typedef struct _NSTextStyle {
float indent1st;
float indent2nd;
float lineHt;
float descentLine;
NSTextAlignment alignment;
short numTabs;
NSTabStop *tabs;
} NSTextStyle;
enum {
NSLeftTab
};
enum {
NSBackspaceKey = 8,
NSCarriageReturnKey = 13,
NSDeleteKey= 0x7f,
NSBacktabKey = 25
};
enum {
NSTextBlockSize = 512
};
//
// NSCStringText Internal State Structure
//
typedef struct _NSCStringTextInternalState {
const NSFSM *breakTable;
const NSFSM *clickTable;
const unsigned char *preSelSmartTable;
const unsigned char *postSelSmartTable;
const unsigned char *charCategoryTable;
char delegateMethods;
NSCharFilterFunc charFilterFunc;
NSTextFilterFunc textFilterFunc;
NSString *_string;
NSTextFunc scanFunc;
NSTextFunc drawFunc;
id delegate;
int tag;
void *cursorTE;
NSTextBlock *firstTextBlock;
NSTextBlock *lastTextBlock;
NSRunArray *theRuns;
NSRun typingRun;
NSBreakArray *theBreaks;
int growLine;
int textLength;
float maxY;
float maxX;
NSRect bodyRect;
float borderWidth;
char clickCount;
NSSelPt sp0;
NSSelPt spN;
NSSelPt anchorL;
NSSelPt anchorR;
NSSize maxSize;
NSSize minSize;
struct _tFlags {
#ifdef __BIG_ENDIAN__
unsigned int _editMode:2;
unsigned int _selectMode:2;
unsigned int _caretState:2;
unsigned int changeState:1;
unsigned int charWrap:1;
unsigned int haveDown:1;
unsigned int anchorIs0:1;
unsigned int horizResizable:1;
unsigned int vertResizable:1;
unsigned int overstrikeDiacriticals:1;
unsigned int monoFont:1;
unsigned int disableFontPanel:1;
unsigned int inClipView:1;
#else
unsigned int inClipView:1;
unsigned int disableFontPanel:1;
unsigned int monoFont:1;
unsigned int overstrikeDiacriticals:1;
unsigned int vertResizable:1;
unsigned int horizResizable:1;
unsigned int anchorIs0:1;
unsigned int haveDown:1;
unsigned int charWrap:1;
unsigned int changeState:1;
unsigned int _caretState:2;
unsigned int _selectMode:2;
unsigned int _editMode:2;
#endif
} tFlags;
void *_info;
void *_textStr;
} NSCStringTextInternalState;
@interface NSCStringText : NSText
@ -294,4 +556,93 @@
@end
//
// Break Tables
//
extern const NSFSM *NSCBreakTable;
extern int NSCBreakTableSize;
extern const NSFSM *NSEnglishBreakTable;
extern int NSEnglishBreakTableSize;
extern const NSFSM *NSEnglishNoBreakTable;
extern int NSEnglishNoBreakTableSize;
//
// Character Category Tables
//
extern const unsigned char *NSCCharCatTable;
extern const unsigned char *NSEnglishCharCatTable;
//
// Click Tables
//
extern const NSFSM *NSCClickTable;
extern int NSCClickTableSize;
extern const NSFSM *NSEnglishClickTable;
extern int NSEnglishClickTableSize;
//
// Smart Cut and Paste Tables
//
extern const unsigned char *NSCSmartLeftChars;
extern const unsigned char *NSCSmartRightChars;
extern const unsigned char *NSEnglishSmartLeftChars;
extern const unsigned char *NSEnglishSmartRightChars;
//
// Calculate or Draw a Line of Text (in Text Object)
//
int NSDrawALine(id self, NSLayInfo *layInfo);
int NSScanALine(id self, NSLayInfo *layInfo);
//
// Calculate Font Ascender, Descender, and Line Height (in Text Object)
//
void NSTextFontInfo(id fid,
float *ascender, float *descender,
float *lineHeight);
//
// Access Text Object's Word Tables
//
NSData * NSDataWithWordTable(const unsigned char *smartLeft,
const unsigned char *smartRight,
const unsigned char *charClasses,
const NSFSM *wrapBreaks,
int wrapBreaksCount,
const NSFSM *clickBreaks,
int clickBreaksCount,
BOOL charWrap);
void NSReadWordTable(NSZone *zone,
NSData *data,
unsigned char **smartLeft,
unsigned char **smartRight,
unsigned char **charClasses,
NSFSM **wrapBreaks,
int *wrapBreaksCount,
NSFSM **clickBreaks,
int *clickBreaksCount,
BOOL *charWrap);
//
// Array Allocation Functions for Use by the NSText Class
//
NSTextChunk *NSChunkCopy(NSTextChunk *pc, NSTextChunk *dpc);
NSTextChunk *NSChunkGrow(NSTextChunk *pc, int newUsed);
NSTextChunk *NSChunkMalloc(int growBy, int initUsed);
NSTextChunk *NSChunkRealloc(NSTextChunk *pc);
NSTextChunk *NSChunkZoneCopy(NSTextChunk *pc,
NSTextChunk *dpc,
NSZone *zone);
NSTextChunk *NSChunkZoneGrow(NSTextChunk *pc, int newUsed, NSZone *zone);
NSTextChunk *NSChunkZoneMalloc(int growBy, int initUsed, NSZone *zone);
NSTextChunk *NSChunkZoneRealloc(NSTextChunk *pc, NSZone *zone);
//
// Filter Characters Entered into a Text Object
//
unsigned short NSEditorFilter(unsigned short theChar,
int flags, NSStringEncoding theEncoding);
unsigned short NSFieldFilter(unsigned short theChar,
int flags, NSStringEncoding theEncoding);
#endif // _GNUstep_H_NSCStringText

View file

@ -29,13 +29,12 @@
#ifndef _GNUstep_H_NSCachedImageRep
#define _GNUstep_H_NSCachedImageRep
#include <AppKit/stdappkit.h>
#include <AppKit/NSImageRep.h>
#include <AppKit/NSWindow.h>
#include <Foundation/NSCoder.h>
#include <AppKit/NSGraphics.h>
@class NSWindow;
@interface NSCachedImageRep : NSImageRep <NSCoding>
{
// Attributes
NSRect _rect;

View file

@ -29,16 +29,71 @@
#ifndef _GNUstep_H_NSCell
#define _GNUstep_H_NSCell
#include <AppKit/stdappkit.h>
#include <AppKit/NSImage.h>
#include <Foundation/NSString.h>
#include <AppKit/NSView.h>
#include <AppKit/NSFont.h>
#include <AppKit/NSText.h>
#include <Foundation/NSCoder.h>
#include <Foundation/NSGeometry.h>
#include <AppKit/NSText.h>
@class NSString;
@class NSView;
@class NSFont;
@class NSText;
typedef enum _NSCellType {
NSNullCellType,
NSTextCellType,
NSImageCellType
} NSCellType;
enum {
NSAnyType,
NSIntType,
NSPositiveIntType,
NSFloatType,
NSPositiveFloatType,
NSDateType,
NSDoubleType,
NSPositiveDoubleType
};
typedef enum {
NSNoImage = 0,
NSImageOnly,
NSImageLeft,
NSImageRight,
NSImageBelow,
NSImageAbove,
NSImageOverlaps
} NSCellImagePosition;
typedef enum _NSCellAttribute {
NSCellDisabled,
NSCellState,
NSPushInCell,
NSCellEditable,
NSChangeGrayCell,
NSCellHighlighted,
NSCellLightsByContents,
NSCellLightsByGray,
NSChangeBackgroundCell,
NSCellLightsByBackground,
NSCellIsBordered,
NSCellHasOverlappingImage,
NSCellHasImageHorizontal,
NSCellHasImageOnLeftOrBottom,
NSCellChangesContents,
NSCellIsInsetButton
} NSCellAttribute;
enum {
NSNoCellMask = 0,
NSContentsCellMask = 1,
NSPushInCellMask = 2,
NSChangeGrayCellMask = 4,
NSChangeBackgroundCellMask = 8
};
@interface NSCell : NSObject <NSCoding>
{
// Attributes
NSString *contents;
@ -56,7 +111,7 @@
BOOL cell_float_autorange;
unsigned int cell_float_left;
unsigned int cell_float_right;
unsigned int image_position;
NSCellImagePosition image_position;
int cell_type;
NSTextAlignment text_align;
int entry_type;

View file

@ -29,15 +29,15 @@
#ifndef _GNUstep_H_NSClipView
#define _GNUstep_H_NSClipView
#include <AppKit/stdappkit.h>
#include <AppKit/NSView.h>
#include <AppKit/NSCursor.h>
#include <AppKit/NSColor.h>
#include <Foundation/NSCoder.h>
#include <Foundation/NSNotification.h>
@class NSNotification;
@class NSCursor;
@class NSEvent;
@class NSColor;
@interface NSClipView : NSView <NSCoding>
{
// Attributes
}

View file

@ -29,9 +29,11 @@
#ifndef _GNUstep_H_NSColor
#define _GNUstep_H_NSColor
#include <AppKit/stdappkit.h>
#include <Foundation/NSCoder.h>
@class NSString;
@class NSDictionary;
@class NSPasteboard;
// What component should we take values from
@ -40,8 +42,28 @@
#define GNUSTEP_GUI_HSB_ACTIVE 3
#define GNUSTEP_GUI_WHITE_ACTIVE 4
@interface NSColor : NSObject <NSCoding>
enum {
NSGrayModeColorPanel,
NSRGBModeColorPanel,
NSCMYKModeColorPanel,
NSHSBModeColorPanel,
NSCustomPaletteModeColorPanel,
NSColorListModeColorPanel,
NSWheelModeColorPanel
};
enum {
NSColorPanelGrayModeMask,
NSColorPanelRGBModeMask,
NSColorPanelCMYKModeMask,
NSColorPanelHSBModeMask,
NSColorPanelCustomPaletteModeMask,
NSColorPanelColorListModeMask,
NSColorPanelWheelModeMask,
NSColorPanelAllModesMask
};
@interface NSColor : NSObject <NSCoding>
{
// Attributes
NSString *colorspace_name;

View file

@ -29,12 +29,15 @@
#ifndef _GNUstep_H_NSColorList
#define _GNUstep_H_NSColorList
#include <AppKit/stdappkit.h>
#include <AppKit/NSColor.h>
#include <Foundation/NSCoder.h>
#include <Foundation/NSDictionary.h>
#include <Foundation/NSArray.h>
#include <Foundation/NSString.h>
@class NSString;
@class NSArray;
@class NSMutableArray;
@class NSDictionary;
@class NSMutableDictionary;
@class NSColor;
@interface NSColorList : NSObject <NSCoding>
@ -96,4 +99,7 @@
@end
/* Notifications */
extern NSString *NSColorListChangedNotification;
#endif // _GNUstep_H_NSColorList

View file

@ -29,14 +29,13 @@
#ifndef _GNUstep_H_NSColorPanel
#define _GNUstep_H_NSColorPanel
#include <AppKit/stdappkit.h>
#include <AppKit/NSPanel.h>
#include <AppKit/NSColorList.h>
#include <Foundation/NSCoder.h>
#include <AppKit/NSApplication.h>
@class NSView;
@class NSColorList;
@class NSEvent;
@interface NSColorPanel : NSPanel <NSCoding>
{
// Attributes
}
@ -74,7 +73,7 @@
//
+ (BOOL)dragColor:(NSColor **)aColor
withEvent:(NSEvent *)anEvent
fromView:(NSView *)sourceView;
fromView:(NSView *)sourceView;
- (float)alpha;
- (NSColor *)color;
- (void)setColor:(NSColor *)aColor;
@ -87,4 +86,7 @@ fromView:(NSView *)sourceView;
@end
/* Notifications */
extern NSString *NSColorPanelColorChangedNotification;
#endif // _GNUstep_H_NSColorPanel

View file

@ -29,15 +29,15 @@
#ifndef _GNUstep_H_NSColorPicker
#define _GNUstep_H_NSColorPicker
#include <AppKit/stdappkit.h>
#include <AppKit/NSColorPanel.h>
#include <AppKit/NSImage.h>
#include <AppKit/NSColorList.h>
#include <AppKit/NSButtonCell.h>
#include <Foundation/NSObject.h>
#include <AppKit/NSColorPicking.h>
@interface NSColorPicker : NSObject <NSColorPickingDefault>
@class NSColorPanel;
@class NSColorList;
@class NSImage;
@class NSButtonCell;
@interface NSColorPicker : NSObject <NSColorPickingDefault>
{
// Attributes
}

View file

@ -28,10 +28,11 @@
#ifndef _GNUstep_H_NSColorPicking
#define _GNUstep_H_NSColorPicking
#include <AppKit/NSPasteboard.h>
#include <objc/Protocol.h>
@class NSColor;
@class NSColorPanel;
@class NSView;
@class NSImage;
@class NSButtonCell;
@class NSColorList;

View file

@ -29,7 +29,7 @@
#ifndef _GNUstep_H_NSColorPrivate
#define _GNUstep_H_NSColorPrivate
#include <gnustep/gui/NSColor.h>
#include <AppKit/NSColor.h>
@interface NSColor (GNUstepPrivate)

View file

@ -29,10 +29,9 @@
#ifndef _GNUstep_H_NSColorWell
#define _GNUstep_H_NSColorWell
#include <AppKit/stdappkit.h>
#include <AppKit/NSControl.h>
#include <Foundation/NSCoder.h>
#include <AppKit/NSColor.h>
@class NSColor;
@interface NSColorWell : NSControl <NSCoding>
@ -41,9 +40,6 @@
NSColor *the_color;
BOOL is_active;
BOOL is_bordered;
// Reserved for back-end use
void *be_cwell_reserved;
}
//
@ -79,13 +75,4 @@
@end
//
// GNUstep backend methods
//
@interface NSColorWell (GNUstepBackend)
- (void)drawBorderRect:(NSRect)aRect;
@end
#endif // _GNUstep_H_NSColorWell

View file

@ -29,14 +29,16 @@
#ifndef _GNUstep_H_NSControl
#define _GNUstep_H_NSControl
#include <AppKit/stdappkit.h>
#include <AppKit/NSView.h>
#include <AppKit/NSCell.h>
#include <Foundation/NSCoder.h>
#include <Foundation/NSNotification.h>
#include <AppKit/NSText.h>
@class NSString;
@class NSNotification;
@class NSCell;
@class NSFont;
@class NSEvent;
@interface NSControl : NSView <NSCoding>
{
// Attributes
int tag;
@ -98,7 +100,7 @@
- (void)setFont:(NSFont *)fontObject;
- (void)setFloatingPointFormat:(BOOL)autoRange
left:(unsigned)leftDigits
right:(unsigned)rightDigits;
right:(unsigned)rightDigits;
//
// Managing the Field Editor
@ -152,9 +154,9 @@ right:(unsigned)rightDigits;
// Methods Implemented by the Delegate
//
- (BOOL)control:(NSControl *)control
textShouldBeginEditing:(NSText *)fieldEditor;
textShouldBeginEditing:(NSText *)fieldEditor;
- (BOOL)control:(NSControl *)control
textShouldEndEditing:(NSText *)fieldEditor;
textShouldEndEditing:(NSText *)fieldEditor;
- (void)controlTextDidBeginEditing:(NSNotification *)aNotification;
- (void)controlTextDidEndEditing:(NSNotification *)aNotification;
- (void)controlTextDidChange:(NSNotification *)aNotification;
@ -167,4 +169,8 @@ textShouldEndEditing:(NSText *)fieldEditor;
@end
extern NSString *NSControlTextDidBeginEditingNotification;
extern NSString *NSControlTextDidEndEditingNotification;
extern NSString *NSControlTextDidChangeNotification;
#endif // _GNUstep_H_NSControl

View file

@ -29,11 +29,11 @@
#ifndef _GNUstep_H_NSCursor
#define _GNUstep_H_NSCursor
#include <AppKit/stdappkit.h>
#include <AppKit/NSImage.h>
#include <AppKit/NSEvent.h>
#include <Foundation/NSCoder.h>
@class NSImage;
@class NSEvent;
@interface NSCursor : NSObject <NSCoding>
{

View file

@ -29,12 +29,9 @@
#ifndef _GNUstep_H_NSCustomImageRep
#define _GNUstep_H_NSCustomImageRep
#include <AppKit/stdappkit.h>
#include <AppKit/NSImageRep.h>
#include <Foundation/NSCoder.h>
@interface NSCustomImageRep : NSImageRep <NSCoding>
{
// Attributes
id delegate;

View file

@ -29,16 +29,34 @@
#ifndef _GNUstep_H_NSDataLink
#define _GNUstep_H_NSDataLink
#include <AppKit/stdappkit.h>
#include <AppKit/NSSelection.h>
#include <AppKit/NSPasteboard.h>
#include <Foundation/NSDate.h>
#include <Foundation/NSCoder.h>
@class NSString;
@class NSArray;
@class NSDate;
@class NSDataLinkManager;
@class NSSelection;
@class NSPasteboard;
typedef int NSDataLinkNumber;
typedef enum _NSDataLinkDisposition {
NSLinkInDestination,
NSLinkInSource,
NSLinkBroken
} NSDataLinkDisposition;
typedef enum _NSDataLinkUpdateMode {
NSUpdateContinuously,
NSUpdateWhenSourceSaved,
NSUpdateManually,
NSUpdateNever
} NSDataLinkUpdateMode;
extern NSString *NSDataLinkFileNameExtension;
@interface NSDataLink : NSObject <NSCoding>
{
// Attributes
}
@ -49,7 +67,7 @@
- (id)initLinkedToFile:(NSString *)filename;
- (id)initLinkedToSourceSelection:(NSSelection *)selection
managedBy:(NSDataLinkManager *)linkManager
supportingTypes:(NSArray *)newTypes;
supportingTypes:(NSArray *)newTypes;
- (id)initWithContentsOfFile:(NSString *)filename;
- (id)initWithPasteboard:(NSPasteboard *)pasteboard;

View file

@ -29,14 +29,17 @@
#ifndef _GNUstep_H_NSDataLinkManager
#define _GNUstep_H_NSDataLinkManager
#include <AppKit/stdappkit.h>
#include <AppKit/NSWindow.h>
#include <AppKit/NSDataLink.h>
#include <AppKit/NSSelection.h>
#include <Foundation/NSCoder.h>
@interface NSDataLinkManager : NSObject <NSCoding>
@class NSString;
@class NSEnumerator;
@class NSDataLink;
@class NSSelection;
@class NSPasteboard;
@class NSWindow;
@interface NSDataLinkManager : NSObject <NSCoding>
{
// Attributes
}
@ -57,7 +60,7 @@
at:(NSSelection *)selection;
- (NSDataLink *)addLinkPreviouslyAt:(NSSelection *)oldSelection
fromPasteboard:(NSPasteboard *)pasteboard
at:(NSSelection *)selection;
at:(NSSelection *)selection;
- (void)breakAllLinks;
- (void)writeLinksToPasteboard:(NSPasteboard *)pasteboard;
@ -96,7 +99,7 @@ at:(NSSelection *)selection;
//
- (BOOL)copyToPasteboard:(NSPasteboard *)pasteboard
at:(NSSelection *)selection
cheapCopyAllowed:(BOOL)flag;
cheapCopyAllowed:(BOOL)flag;
- (void)dataLinkManager:(NSDataLinkManager *)sender
didBreakLink:(NSDataLink *)link;
- (BOOL)dataLinkManager:(NSDataLinkManager *)sender
@ -124,4 +127,10 @@ cheapCopyAllowed:(BOOL)flag;
@end
//
// Draw a Distinctive Outline around Linked Data
//
void NSFrameLinkRect(NSRect aRect, BOOL isDestination);
float NSLinkFrameThickness(void);
#endif // _GNUstep_H_NSDataLinkManager

View file

@ -29,15 +29,13 @@
#ifndef _GNUstep_H_NSDataLinkPanel
#define _GNUstep_H_NSDataLinkPanel
#include <AppKit/stdappkit.h>
#include <AppKit/NSPanel.h>
#include <AppKit/NSDataLink.h>
#include <Foundation/NSCoder.h>
#include <AppKit/NSApplication.h>
@class NSDataLink;
@class NSDataLinkManager;
@class NSView;
@interface NSDataLinkPanel : NSPanel <NSCoding>
{
// Attributes
}
@ -52,16 +50,16 @@
//
+ (void)getLink:(NSDataLink **)link
manager:(NSDataLinkManager **)linkManager
isMultiple:(BOOL *)flag;
isMultiple:(BOOL *)flag;
+ (void)setLink:(NSDataLink *)link
manager:(NSDataLinkManager *)linkManager
isMultiple:(BOOL)flag;
isMultiple:(BOOL)flag;
- (void)getLink:(NSDataLink **)link
manager:(NSDataLinkManager **)linkManager
isMultiple:(BOOL *)flag;
isMultiple:(BOOL *)flag;
- (void)setLink:(NSDataLink *)link
manager:(NSDataLinkManager *)linkManager
isMultiple:(BOOL)flag;
isMultiple:(BOOL)flag;
//
// Customizing the Panel

View file

@ -28,12 +28,22 @@
#ifndef _GNUstep_H_NSDragging
#define _GNUstep_H_NSDragging
#include <AppKit/stdappkit.h>
#include <objc/Protocol.h>
#include <Foundation/NSGeometry.h>
@class NSWindow;
@class NSPasteBoard;
@class NSPasteboard;
@class NSImage;
typedef enum _NSDragOperation {
NSDragOperationNone,
NSDragOperationCopy,
NSDragOperationLink,
NSDragOperationGeneric,
NSDragOperationPrivate,
NSDragOperationAll
} NSDragOperation;
@protocol NSDraggingInfo
//

View file

@ -29,12 +29,11 @@
#ifndef _GNUstep_H_NSEPSImageRep
#define _GNUstep_H_NSEPSImageRep
#include <AppKit/stdappkit.h>
#include <AppKit/NSImageRep.h>
#include <Foundation/NSCoder.h>
@class NSData;
@interface NSEPSImageRep : NSImageRep <NSCoding>
{
// Attributes
}

View file

@ -29,17 +29,62 @@
#ifndef _GNUstep_H_NSEvent
#define _GNUstep_H_NSEvent
#include <AppKit/stdappkit.h>
#include <DPSClient/DPSOperators.h>
#include <Foundation/NSRange.h>
#include <Foundation/NSDate.h>
#include <Foundation/NSCoder.h>
#include <DPSClient/NSDPSContext.h>
#include <Foundation/NSGeometry.h>
@class NSString;
@class NSWindow;
@class NSDPSContext;
typedef enum _NSEventType {
NSLeftMouseDown,
NSLeftMouseUp,
NSRightMouseDown,
NSRightMouseUp,
NSMouseMoved,
NSLeftMouseDragged,
NSRightMouseDragged,
NSMouseEntered,
NSMouseExited,
NSKeyDown,
NSKeyUp,
NSFlagsChanged,
NSPeriodic,
NSCursorUpdate
} NSEventType;
enum {
NSLeftMouseDownMask = 1,
NSLeftMouseUpMask = 2,
NSRightMouseDownMask = 4,
NSRightMouseUpMask = 8,
NSMouseMovedMask = 16,
NSLeftMouseDraggedMask = 32,
NSRightMouseDraggedMask = 64,
NSMouseEnteredMask = 128,
NSMouseExitedMask = 256,
NSKeyDownMask = 512,
NSKeyUpMask = 1024,
NSFlagsChangedMask = 2048,
NSPeriodicMask = 4096,
NSCursorUpdateMask = 8192,
// Note that NSAnyEventMask is an OR-combination of all other event masks
NSAnyEventMask = 16383
};
enum {
NSAlphaShiftKeyMask = 1,
NSShiftKeyMask = 2,
NSControlKeyMask = 4,
NSAlternateKeyMask = 8,
NSCommandKeyMask = 16,
NSNumericPadKeyMask = 32,
NSHelpKeyMask = 64,
NSFunctionKeyMask = 128
};
@interface NSEvent : NSObject <NSCoding>
{
// Attributes
NSEventType event_type;
@ -177,4 +222,85 @@
@end
enum {
NSUpArrowFunctionKey = 0xF700,
NSDownArrowFunctionKey = 0xF701,
NSLeftArrowFunctionKey = 0xF702,
NSRightArrowFunctionKey = 0xF703,
NSF1FunctionKey = 0xF704,
NSF2FunctionKey = 0xF705,
NSF3FunctionKey = 0xF706,
NSF4FunctionKey = 0xF707,
NSF5FunctionKey = 0xF708,
NSF6FunctionKey = 0xF709,
NSF7FunctionKey = 0xF70A,
NSF8FunctionKey = 0xF70B,
NSF9FunctionKey = 0xF70C,
NSF10FunctionKey = 0xF70D,
NSF11FunctionKey = 0xF70E,
NSF12FunctionKey = 0xF70F,
NSF13FunctionKey = 0xF710,
NSF14FunctionKey = 0xF711,
NSF15FunctionKey = 0xF712,
NSF16FunctionKey = 0xF713,
NSF17FunctionKey = 0xF714,
NSF18FunctionKey = 0xF715,
NSF19FunctionKey = 0xF716,
NSF20FunctionKey = 0xF717,
NSF21FunctionKey = 0xF718,
NSF22FunctionKey = 0xF719,
NSF23FunctionKey = 0xF71A,
NSF24FunctionKey = 0xF71B,
NSF25FunctionKey = 0xF71C,
NSF26FunctionKey = 0xF71D,
NSF27FunctionKey = 0xF71E,
NSF28FunctionKey = 0xF71F,
NSF29FunctionKey = 0xF720,
NSF30FunctionKey = 0xF721,
NSF31FunctionKey = 0xF722,
NSF32FunctionKey = 0xF723,
NSF33FunctionKey = 0xF724,
NSF34FunctionKey = 0xF725,
NSF35FunctionKey = 0xF726,
NSInsertFunctionKey = 0xF727,
NSDeleteFunctionKey = 0xF728,
NSHomeFunctionKey = 0xF729,
NSBeginFunctionKey = 0xF72A,
NSEndFunctionKey = 0xF72B,
NSPageUpFunctionKey = 0xF72C,
NSPageDownFunctionKey = 0xF72D,
NSPrintScreenFunctionKey = 0xF72E,
NSScrollLockFunctionKey = 0xF72F,
NSPauseFunctionKey = 0xF730,
NSSysReqFunctionKey = 0xF731,
NSBreakFunctionKey = 0xF732,
NSResetFunctionKey = 0xF733,
NSStopFunctionKey = 0xF734,
NSMenuFunctionKey = 0xF735,
NSUserFunctionKey = 0xF736,
NSSystemFunctionKey = 0xF737,
NSPrintFunctionKey = 0xF738,
NSClearLineFunctionKey = 0xF739,
NSClearDisplayFunctionKey = 0xF73A,
NSInsertLineFunctionKey = 0xF73B,
NSDeleteLineFunctionKey = 0xF73C,
NSInsertCharFunctionKey = 0xF73D,
NSDeleteCharFunctionKey = 0xF73E,
NSPrevFunctionKey = 0xF73F,
NSNextFunctionKey = 0xF740,
NSSelectFunctionKey = 0xF741,
NSExecuteFunctionKey = 0xF742,
NSUndoFunctionKey = 0xF743,
NSRedoFunctionKey = 0xF744,
NSFindFunctionKey = 0xF745,
NSHelpFunctionKey = 0xF746,
NSModeSwitchFunctionKey = 0xF747
};
//
// Convert an Event Mask Type to a Mask
//
unsigned int NSEventMaskFromType(NSEventType type);
#endif // _GNUstep_H_NSEvent

View file

@ -6,7 +6,8 @@
Copyright (C) 1996 Free Software Foundation, Inc.
Author: Scott Christley <scottc@net-community.com>
Date: 1996
Author: Ovidiu Predescu <ovidiu@bx.logicnet.ro>
Date: 1996, 1997
This file is part of the GNUstep GUI Library.
@ -29,19 +30,26 @@
#ifndef _GNUstep_H_NSFont
#define _GNUstep_H_NSFont
#include <AppKit/stdappkit.h>
#include <Foundation/NSCoder.h>
#include <Foundation/NSGeometry.h>
@class NSString;
@class NSDictionary;
typedef unsigned int NSGlyph;
enum {
NSControlGlyph = 0x00ffffff,
NSNullGlyph = 0x0
};
extern const float *NSFontIdentityMatrix;
@interface NSFont : NSObject <NSCoding>
{
// Attributes
NSString *family_name;
NSString *font_name;
NSString *type_face;
float point_size;
NSFontTraitMask font_traits;
int font_weight;
// Font attributes
NSString *fontName;
float matrix[6];
// Reserved for back-end use
void *be_font_reserved;
@ -76,11 +84,21 @@
- (NSString *)displayName;
- (NSString *)familyName;
- (NSString *)fontName;
- (NSString *)encodingScheme;
- (BOOL)isFixedPitch;
- (BOOL)isBaseFont;
- (const float *)matrix;
- (float)pointSize;
- (NSFont *)printerFont;
- (NSFont *)screenFont;
- (float)ascender;
- (float)descender;
- (float)capHeight;
- (float)italicAngle;
- (NSSize)maximumAdvancement;
- (float)underlinePosition;
- (float)underlineThickness;
- (float)xHeight;
- (float)widthOfString:(NSString *)string;
- (float *)widths;
@ -90,6 +108,7 @@
- (NSSize)advancementForGlyph:(NSGlyph)aGlyph;
- (NSRect)boundingRectForGlyph:(NSGlyph)aGlyph;
- (BOOL)glyphIsEncoded:(NSGlyph)aGlyph;
- (NSGlyph)glyphWithName:(NSString*)glyphName;
- (NSPoint)positionOfGlyph:(NSGlyph)curGlyph
precededByGlyph:(NSGlyph)prevGlyph
isNominal:(BOOL *)nominal;
@ -102,4 +121,22 @@
@end
extern NSString *NSAFMAscender;
extern NSString *NSAFMCapHeight;
extern NSString *NSAFMCharacterSet;
extern NSString *NSAFMDescender;
extern NSString *NSAFMEncodingScheme;
extern NSString *NSAFMFamilyName;
extern NSString *NSAFMFontName;
extern NSString *NSAFMFormatVersion;
extern NSString *NSAFMFullName;
extern NSString *NSAFMItalicAngle;
extern NSString *NSAFMMappingScheme;
extern NSString *NSAFMNotice;
extern NSString *NSAFMUnderlinePosition;
extern NSString *NSAFMUnderlineThickness;
extern NSString *NSAFMVersion;
extern NSString *NSAFMWeight;
extern NSString *NSAFMXHeight;
#endif // _GNUstep_H_NSFont

View file

@ -29,21 +29,38 @@
#ifndef _GNUstep_H_NSFontManager
#define _GNUstep_H_NSFontManager
#include <AppKit/stdappkit.h>
#include <AppKit/NSFont.h>
#include <AppKit/NSFontPanel.h>
#include <AppKit/NSMenu.h>
#include <Foundation/NSObject.h>
@class NSString;
@class NSArray;
@class NSFont;
@class NSMenu;
@class NSFontPanel;
typedef unsigned int NSFontTraitMask;
enum {
NSItalicFontMask = 1,
NSBoldFontMask = 2,
NSUnboldFontMask = 4,
NSNonStandardCharacterSetFontMask = 8,
NSNarrowFontMask = 16,
NSExpandedFontMask = 32,
NSCondensedFontMask = 64,
NSSmallCapsFontMask = 128,
NSPosterFontMask = 256,
NSCompressedFontMask = 512,
NSUnitalicFontMask = 1024
};
@interface NSFontManager : NSObject
{
// Attributes
id delegate;
SEL action;
NSMutableArray *family_list;
NSMutableArray *family_metrics;
NSFont *selected_font;
NSMutableArray *font_list;
NSArray *fontsList;
NSMenu *font_menu;
}
@ -80,7 +97,6 @@
//
- (SEL)action;
- (NSArray *)availableFonts;
- (NSArray *)familyMetrics;
- (NSMenu *)fontMenu:(BOOL)create;
- (NSFontPanel *)fontPanel:(BOOL)create;
- (BOOL)isEnabled;

View file

@ -29,12 +29,23 @@
#ifndef _GNUstep_H_NSFontPanel
#define _GNUstep_H_NSFontPanel
#include <AppKit/stdappkit.h>
#include <DPSClient/TypesandConstants.h>
#include <AppKit/NSPanel.h>
#include <Foundation/NSCoder.h>
@class NSFont;
@class NSView;
enum {
NSFPPreviewButton,
NSFPRevertButton,
NSFPSetButton,
NSFPPreviewField,
NSFPSizeField,
NSFPSizeTitle,
NSFPCurrentField
};
@interface NSFontPanel : NSPanel <NSCoding>
{
// Attributes
NSFont *panel_font;

View file

@ -1,48 +0,0 @@
/*
NSFontPrivate.h
Private methods for the font class.
Copyright (C) 1996 Free Software Foundation, Inc.
Author: Scott Christley <scottc@net-community.com>
Date: September 1996
This file is part of the GNUstep GUI Library.
This library is free software; you can redistribute it and/or
modify it under the terms of the GNU Library General Public
License as published by the Free Software Foundation; either
version 2 of the License, or (at your option) any later version.
This library is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
Library General Public License for more details.
You should have received a copy of the GNU Library General Public
License along with this library; see the file COPYING.LIB.
If not, write to the Free Software Foundation,
59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
*/
#ifndef _GNUstep_H_NSFontPrivate
#define _GNUstep_H_NSFontPrivate
#include <gnustep/gui/NSFont.h>
@interface NSFont (GNUstepPrivate)
- (void)setFamilyName:(NSString *)familyName;
- (void)setFontName:(NSString *)fontName;
- (void)setPointSize:(float)value;
- (NSFontTraitMask)traits;
- (void)setTraits:(NSFontTraitMask)traits;
- (int)weight;
- (void)setWeight:(int)value;
- (NSString *)typeface;
- (void)setTypeface:(NSString *)str;
@end
#endif /* _GNUstep_H_NSFontPrivate */

View file

@ -29,14 +29,12 @@
#ifndef _GNUstep_H_NSForm
#define _GNUstep_H_NSForm
#include <AppKit/stdappkit.h>
#include <AppKit/NSMatrix.h>
#include <AppKit/NSFormCell.h>
#include <AppKit/NSFont.h>
#include <Foundation/NSCoder.h>
@class NSFormCell;
@class NSFont;
@interface NSForm : NSMatrix <NSCoding>
{
// Attributes
}

View file

@ -29,12 +29,9 @@
#ifndef _GNUstep_H_NSFormCell
#define _GNUstep_H_NSFormCell
#include <AppKit/stdappkit.h>
#include <AppKit/NSActionCell.h>
#include <Foundation/NSCoder.h>
@interface NSFormCell : NSActionCell <NSCoding>
{
// Attributes
}

View file

@ -0,0 +1,137 @@
/*
NSGraphics.h
Copyright (C) 1996 Free Software Foundation, Inc.
Author: Ovidiu Predescu <ovidiu@bx.logicnet.ro>
Date: February 1997
This file is part of the GNUstep GUI Library.
This library is free software; you can redistribute it and/or
modify it under the terms of the GNU Library General Public
License as published by the Free Software Foundation; either
version 2 of the License, or (at your option) any later version.
This library is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
Library General Public License for more details.
You should have received a copy of the GNU Library General Public
License along with this library; if not, write to the Free
Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
*/
#ifndef __NSGraphics_h__
#define __NSGraphics_h__
#include <Foundation/NSObject.h>
#include <Foundation/NSGeometry.h>
@class NSString;
@class NSColor;
//
// Colorspace Names
//
extern NSString *NSCalibratedWhiteColorSpace;
extern NSString *NSCalibratedBlackColorSpace;
extern NSString *NSCalibratedRGBColorSpace;
extern NSString *NSDeviceWhiteColorSpace;
extern NSString *NSDeviceBlackColorSpace;
extern NSString *NSDeviceRGBColorSpace;
extern NSString *NSDeviceCMYKColorSpace;
extern NSString *NSNamedColorSpace;
extern NSString *NSCustomColorSpace;
typedef int NSWindowDepth;
//
// Gray Values
//
extern const float NSBlack;
extern const float NSDarkGray;
extern const float NSWhite;
extern const float NSLightGray;
//
// Device Dictionary Keys
//
extern NSString *NSDeviceResolution;
extern NSString *NSDeviceColorSpaceName;
extern NSString *NSDeviceBitsPerSample;
extern NSString *NSDeviceIsScreen;
extern NSString *NSDeviceIsPrinter;
extern NSString *NSDeviceSize;
//
// Rectangle Drawing Functions
//
void NSEraseRect(NSRect aRect);
void NSHighlightRect(NSRect aRect);
void NSRectClip(NSRect aRect);
void NSRectClipList(const NSRect *rects, int count);
void NSRectFill(NSRect aRect);
void NSRectFillList(const NSRect *rects, int count);
void NSRectFillListWithGrays(const NSRect *rects,
const float *grays, int count);
//
// Draw a Bordered Rectangle
//
void NSDrawButton(NSRect aRect, NSRect clipRect);
void NSDrawGrayBezel(NSRect aRect, NSRect clipRect);
void NSDrawGroove(NSRect aRect, NSRect clipRect);
NSRect NSDrawTiledRects(NSRect boundsRect, NSRect clipRect,
const NSRectEdge *sides, const float *grays,
int count);
void NSDrawWhiteBezel(NSRect aRect, NSRect clipRect);
void NSFrameRect(NSRect aRect);
void NSFrameRectWithWidth(NSRect aRect, float frameWidth);
//
// Get Information About Color Space and Window Depth
//
const NSWindowDepth *NSAvailableWindowDepths(void);
NSWindowDepth NSBestDepth(NSString *colorSpace,
int bitsPerSample, int bitsPerPixel,
BOOL planar, BOOL *exactMatch);
int NSBitsPerPixelFromDepth(NSWindowDepth depth);
int NSBitsPerSampleFromDepth(NSWindowDepth depth);
NSString *NSColorSpaceFromDepth(NSWindowDepth depth);
int NSNumberOfColorComponents(NSString *colorSpaceName);
BOOL NSPlanarFromDepth(NSWindowDepth depth);
//
// Read the Color at a Screen Position
//
NSColor *NSReadPixel(NSPoint location);
//
// Copy an image
//
void NSCopyBitmapFromGState(int srcGstate, NSRect srcRect, NSRect destRect);
void NSCopyBits(int srcGstate, NSRect srcRect, NSPoint destPoint);
//
// Render Bitmap Images
//
void NSDrawBitmap(NSRect rect,
int pixelsWide,
int pixelsHigh,
int bitsPerSample,
int samplesPerPixel,
int bitsPerPixel,
int bytesPerRow,
BOOL isPlanar,
BOOL hasAlpha,
NSString *colorSpaceName,
const unsigned char *const data[5]);
//
// Play the System Beep
//
void NSBeep(void);
#endif /* __NSGraphics_h__ */

View file

@ -29,13 +29,11 @@
#ifndef _GNUstep_H_NSHelpPanel
#define _GNUstep_H_NSHelpPanel
#include <AppKit/stdappkit.h>
#include <AppKit/NSPanel.h>
#include <Foundation/NSCoder.h>
#include <AppKit/NSApplication.h>
@class NSString;
@interface NSHelpPanel : NSPanel <NSCoding>
{
// Attributes
}
@ -60,7 +58,7 @@
//
+ (void)attachHelpFile:(NSString *)filename
markerName:(NSString *)markerName
to:(id)anObject;
to:(id)anObject;
+ (void)detachHelpFrom:(id)anObject;
//

View file

@ -29,12 +29,16 @@
#ifndef _GNUstep_H_NSImage
#define _GNUstep_H_NSImage
#include <AppKit/stdappkit.h>
#include <DPSClient/TypesandConstants.h>
#include <AppKit/NSBundle.h>
#include <Foundation/NSBundle.h>
#include <Foundation/NSCoder.h>
#include <AppKit/NSBitmapImageRep.h>
@class NSString;
@class NSMutableArray;
@class NSData;
@class NSPasteboard;
@class NSMutableArray;
@class NSImageRep;
@class NSColor;
@class NSView;
@ -195,4 +199,11 @@
@end
@interface NSBundle (NSImageAdditions)
- (NSString *)pathForImageResource:(NSString *)name;
@end
#endif // _GNUstep_H_NSImage

View file

@ -29,12 +29,20 @@
#ifndef _GNUstep_H_NSImageRep
#define _GNUstep_H_NSImageRep
#include <AppKit/stdappkit.h>
#include <AppKit/NSPasteboard.h>
#include <Foundation/NSCoder.h>
#include <Foundation/NSGeometry.h>
@class NSString;
@class NSArray;
@class NSData;
@class NSPasteboard;
enum {
NSImageRepMatchesDevice
};
@interface NSImageRep : NSObject <NSCoding>
{
// Attributes
NSString* _colorSpace;
@ -111,4 +119,6 @@
@end
extern NSString *NSImageRepRegistryChangedNotification;
#endif // _GNUstep_H_NSImageRep

View file

@ -31,13 +31,25 @@
#ifndef _GNUstep_H_NSMatrix
#define _GNUstep_H_NSMatrix
#include <AppKit/stdappkit.h>
#include <AppKit/NSControl.h>
#include <Foundation/NSCoder.h>
#include <Foundation/NSNotification.h>
@class NSArray;
@class NSMutableArray;
@class NSNotification;
@class NSCell;
@class NSColor;
@class NSText;
@class NSEvent;
typedef enum _NSMatrixMode {
NSRadioModeMatrix,
NSHighlightModeMatrix,
NSListModeMatrix,
NSTrackModeMatrix
} NSMatrixMode;
@interface NSMatrix : NSControl <NSCoding>
{
// Attributes
NSMutableArray *rows;
@ -241,7 +253,7 @@
column:(int)column;
- (void)highlightCell:(BOOL)flag
atRow:(int)row
column:(int)column;
column:(int)column;
//
//Target and Action

View file

@ -30,15 +30,17 @@
#ifndef _GNUstep_H_NSMenu
#define _GNUstep_H_NSMenu
#include <AppKit/stdappkit.h>
#include <AppKit/NSWindow.h>
#include <AppKit/NSMenuCell.h>
#include <AppKit/NSMatrix.h>
#include <Foundation/NSCoder.h>
#include <Foundation/NSZone.h>
#include <Foundation/NSGeometry.h>
@class NSString;
@class NSArray;
@class NSMutableArray;
@class NSMatrix;
@class NSMenuCell;
@interface NSMenu : NSObject <NSCoding>
{
// Attributes
NSString *window_title;

View file

@ -29,14 +29,12 @@
#ifndef _GNUstep_H_NSMenuCell
#define _GNUstep_H_NSMenuCell
#include <AppKit/stdappkit.h>
#include <AppKit/NSButtonCell.h>
#include <Foundation/NSCoder.h>
@class NSString;
@class NSMenu;
@interface NSMenuCell : NSButtonCell <NSCoding>
{
// Attributes
NSString *key_equivalent;

View file

@ -29,7 +29,7 @@
#ifndef _GNUstep_H_NSMenuPrivate
#define _GNUstep_H_NSMenuPrivate
#include <gnustep/gui/NSMenu.h>
#include <AppKit/NSMenu.h>
@interface NSMenu (GNUstepPrivate)

View file

@ -28,8 +28,7 @@
#ifndef _GNUstep_H_NSNibLoading
#define _GNUstep_H_NSNibLoading
#include <AppKit/stdappkit.h>
#include <AppKit/NSBundle.h>
#include <Foundation/NSBundle.h>
@interface NSObject (NSNibAwaking)
@ -40,4 +39,16 @@
@end
@interface NSBundle (NSNibLoading)
+ (BOOL)loadNibFile:(NSString *)fileName
externalNameTable:(NSDictionary *)context
withZone:(NSZone *)zone;
+ (BOOL)loadNibNamed:(NSString *)aNibName
owner:(id)owner;
@end
#endif // _GNUstep_H_NSNibLoading

View file

@ -29,12 +29,13 @@
#ifndef _GNUstep_H_NSOpenPanel
#define _GNUstep_H_NSOpenPanel
#include <AppKit/stdappkit.h>
#include <AppKit/NSSavePanel.h>
#include <Foundation/NSCoder.h>
@class NSString;
@class NSArray;
@class NSMutableArray;
@interface NSOpenPanel : NSSavePanel <NSCoding>
{
// Attributes
NSMutableArray *the_filenames;
@ -69,7 +70,7 @@
- (int)runModalForTypes:(NSArray *)fileTypes;
- (int)runModalForDirectory:(NSString *)path
file:(NSString *)filename
types:(NSArray *)fileTypes;
types:(NSArray *)fileTypes;
//
// NSCoding protocol

View file

@ -29,14 +29,24 @@
#ifndef _GNUstep_H_NSPageLayout
#define _GNUstep_H_NSPageLayout
#include <AppKit/stdappkit.h>
#include <AppKit/NSPanel.h>
#include <AppKit/NSPrintInfo.h>
#include <Foundation/NSCoder.h>
#include <AppKit/NSApplication.h>
@class NSPrintInfo;
@class NSView;
enum {
NSPLImageButton,
NSPLTitleField,
NSPLPaperNameButton,
NSPLUnitsButton,
NSPLWidthForm,
NSPLHeightForm,
NSPLOrientationMatrix,
NSPLCancelButton,
NSPLOKButton
};
@interface NSPageLayout : NSPanel <NSCoding>
{
// Attributes
}

View file

@ -29,12 +29,23 @@
#ifndef _GNUstep_H_NSPanel
#define _GNUstep_H_NSPanel
#include <AppKit/stdappkit.h>
#include <AppKit/NSWindow.h>
#include <Foundation/NSCoder.h>
@class NSString;
enum {
NSOKButton = 1,
NSCancelButton = 0
};
enum {
NSAlertDefaultReturn = 1,
NSAlertAlternateReturn = 0,
NSAlertOtherReturn = -1,
NSAlertErrorReturn = -2
};
@interface NSPanel : NSWindow <NSCoding>
{
// Attributes
}
@ -57,4 +68,33 @@
@end
//
// Create an Attention Panel without Running It Yet
//
id NSGetAlertPanel(NSString *title,
NSString *msg,
NSString *defaultButton,
NSString *alternateButton,
NSString *otherButton, ...);
//
// Create and Run an Attention Panel
//
int NSRunAlertPanel(NSString *title,
NSString *msg,
NSString *defaultButton,
NSString *alternateButton,
NSString *otherButton, ...);
int NSRunLocalizedAlertPanel(NSString *table,
NSString *title,
NSString *msg,
NSString *defaultButton,
NSString *alternateButton,
NSString *otherButton, ...);
//
// Release an Attention Panel
//
void NSReleaseAlertPanel(id panel);
#endif // _GNUstep_H_NSPanel

View file

@ -29,10 +29,38 @@
#ifndef _GNUstep_H_NSPasteboard
#define _GNUstep_H_NSPasteboard
#include <AppKit/stdappkit.h>
#include <Foundation/NSObject.h>
@class NSString;
@class NSArray;
@class NSData;
//
// Pasteboard Type Globals
//
extern NSString *NSStringPboardType;
extern NSString *NSColorPboardType;
extern NSString *NSFileContentsPboardType;
extern NSString *NSFilenamesPboardType;
extern NSString *NSFontPboardType;
extern NSString *NSRulerPboardType;
extern NSString *NSPostScriptPboardType;
extern NSString *NSTabularTextPboardType;
extern NSString *NSRTFPboardType;
extern NSString *NSTIFFPboardType;
extern NSString *NSDataLinkPboardType;
extern NSString *NSGeneralPboardType;
//
// Pasteboard Name Globals
//
extern NSString *NSDragPboard;
extern NSString *NSFindPboard;
extern NSString *NSFontPboard;
extern NSString *NSGeneralPboard;
extern NSString *NSRulerPboard;
@interface NSPasteboard : NSObject
{
// Attributes
}
@ -94,9 +122,18 @@
// Methods Implemented by the Owner
//
- (void)pasteboard:(NSPasteboard *)sender
provideDataForType:(NSString *)type;
provideDataForType:(NSString *)type;
- (void)pasteboardChangedOwner:(NSPasteboard *)sender;
@end
//
// Return File-related Pasteboard Types
//
NSString *NSCreateFileContentsPboardType(NSString *fileType);
NSString *NSCreateFilenamePboardType(NSString *filename);
NSString *NSGetFileType(NSString *pboardType);
NSArray *NSGetFileTypes(NSArray *pboardTypes);
#endif // _GNUstep_H_NSPasteboard

View file

@ -29,15 +29,17 @@
#ifndef _GNUstep_H_NSPopUpButton
#define _GNUstep_H_NSPopUpButton
#include <AppKit/stdappkit.h>
#include <AppKit/NSButton.h>
#include <AppKit/NSMenuCell.h>
#include <AppKit/NSMatrix.h>
#include <AppKit/NSFont.h>
#include <Foundation/NSCoder.h>
@class NSString;
@class NSArray;
@class NSMutableArray;
@class NSMenuCell;
@class NSFont;
@class NSMatrix;
@interface NSPopUpButton : NSButton <NSCoding>
{
// Attributes
NSMutableArray *list_items;

View file

@ -29,13 +29,27 @@
#ifndef _GNUstep_H_NSPrintInfo
#define _GNUstep_H_NSPrintInfo
#include <AppKit/stdappkit.h>
#include <AppKit/NSPrinter.h>
#include <Foundation/NSDictionary.h>
#include <Foundation/NSCoder.h>
#include <Foundation/NSGeometry.h>
@class NSString;
@class NSDictionary;
@class NSMutableDictionary;
@class NSPrinter;
typedef enum _NSPrintingOrientation {
NSPortraitOrientation,
NSLandscapeOrientation
} NSPrintingOrientation;
typedef enum _NSPrintingPaginationMode {
NSAutoPagination,
NSFitPagination,
NSClipPagination
} NSPrintingPaginationMode;
@interface NSPrintInfo : NSObject <NSCoding>
{
// Attributes
}
@ -114,4 +128,51 @@
@end
//
// Printing Information Dictionary Keys
//
extern NSString *NSPrintAllPages;
extern NSString *NSPrintBottomMargin;
extern NSString *NSPrintCopies;
extern NSString *NSPrintFaxCoverSheetName;
extern NSString *NSPrintFaxHighResolution;
extern NSString *NSPrintFaxModem;
extern NSString *NSPrintFaxReceiverNames;
extern NSString *NSPrintFaxReceiverNumbers;
extern NSString *NSPrintFaxReturnReceipt;
extern NSString *NSPrintFaxSendTime;
extern NSString *NSPrintFaxTrimPageEnds;
extern NSString *NSPrintFaxUseCoverSheet;
extern NSString *NSPrintFirstPage;
extern NSString *NSPrintHorizonalPagination;
extern NSString *NSPrintHorizontallyCentered;
extern NSString *NSPrintJobDisposition;
extern NSString *NSPrintJobFeatures;
extern NSString *NSPrintLastPage;
extern NSString *NSPrintLeftMargin;
extern NSString *NSPrintManualFeed;
extern NSString *NSPrintOrientation;
extern NSString *NSPrintPackageException;
extern NSString *NSPrintPagesPerSheet;
extern NSString *NSPrintPaperFeed;
extern NSString *NSPrintPaperName;
extern NSString *NSPrintPaperSize;
extern NSString *NSPrintPrinter;
extern NSString *NSPrintReversePageOrder;
extern NSString *NSPrintRightMargin;
extern NSString *NSPrintSavePath;
extern NSString *NSPrintScalingFactor;
extern NSString *NSPrintTopMargin;
extern NSString *NSPrintVerticalPagination;
extern NSString *NSPrintVerticallyCentered;
//
// Print Job Disposition Values
//
extern NSString *NSPrintCancelJob;
extern NSString *NSPrintFaxJob;
extern NSString *NSPrintPreviewJob;
extern NSString *NSPrintSaveJob;
extern NSString *NSPrintSpoolJob;
#endif // _GNUstep_H_NSPrintInfo

View file

@ -29,14 +29,26 @@
#ifndef _GNUstep_H_NSPrintOperation
#define _GNUstep_H_NSPrintOperation
#include <AppKit/stdappkit.h>
#include <AppKit/NSView.h>
#include <AppKit/NSPrintInfo.h>
#include <AppKit/NSPrintPanel.h>
#include <Foundation/NSData.h>
#include <Foundation/NSObject.h>
#include <Foundation/NSGeometry.h>
@class NSString;
@class NSData;
@class NSMutableData;
@class NSView;
@class NSPrintInfo;
@class NSPrintPanel;
@class NSDPSContext;
typedef enum _NSPrintingPageOrder {
NSDescendingPageOrder,
NSSpecialPageOrder,
NSAscendingPageOrder,
NSUnknownPageOrder
} NSPrintingPageOrder;
@interface NSPrintOperation : NSObject
{
// Attributes
}
@ -46,21 +58,21 @@
//
+ (NSPrintOperation *)EPSOperationWithView:(NSView *)aView
insideRect:(NSRect)rect
toData:(NSMutableData *)data;
toData:(NSMutableData *)data;
+ (NSPrintOperation *)EPSOperationWithView:(NSView *)aView
insideRect:(NSRect)rect
toData:(NSMutableData *)data
printInfo:(NSPrintInfo *)aPrintInfo;
toData:(NSMutableData *)data
printInfo:(NSPrintInfo *)aPrintInfo;
+ (NSPrintOperation *)EPSOperationWithView:(NSView *)aView
insideRect:(NSRect)rect
toPath:(NSString *)path
toPath:(NSString *)path
printInfo:(NSPrintInfo *)aPrintInfo;
+ (NSPrintOperation *)printOperationWithView:(NSView *)aView;
+ (NSPrintOperation *)printOperationWithView:(NSView *)aView
printInfo:(NSPrintInfo *)aPrintInfo;
- (id)initEPSOperationWithView:(NSView *)aView
insideRect:(NSRect)rect
toData:(NSMutableData *)data
toData:(NSMutableData *)data
printInfo:(NSPrintInfo *)aPrintInfo;
- (id)initWithView:(NSView *)aView
printInfo:(NSPrintInfo *)aPrintInfo;

View file

@ -29,12 +29,33 @@
#ifndef _GNUstep_H_NSPrintPanel
#define _GNUstep_H_NSPrintPanel
#include <AppKit/stdappkit.h>
#include <AppKit/NSPanel.h>
#include <Foundation/NSCoder.h>
@class NSView;
enum {
NSPPSaveButton,
NSPPPreviewButton,
NSFaxButton,
NSPPTitleField,
NSPPImageButton,
NSPPNameTitle,
NSPPNameField,
NSPPNoteTitle,
NSPPNoteField,
NSPPStatusTitle,
NSPPStatusField,
NSPPCopiesField,
NSPPPageChoiceMatrix,
NSPPPageRangeFrom,
NSPPPageRangeTo,
NSPPScaleField,
NSPPOptionsButton,
NSPPPaperFeedButton,
NSPPLayoutButton
};
@interface NSPrintPanel : NSPanel <NSCoding>
{
// Attributes
}

View file

@ -29,11 +29,19 @@
#ifndef _GNUstep_H_NSPrinter
#define _GNUstep_H_NSPrinter
#include <AppKit/stdappkit.h>
#include <Foundation/NSCoder.h>
@interface NSPrinter : NSObject <NSCoding>
@class NSString;
@class NSArray;
@class NSDictionary;
typedef enum _NSPrinterTableStatus {
NSPrinterTableOK,
NSPrinterTableNotFound,
NSPrinterTableError
} NSPrinterTableStatus;
@interface NSPrinter : NSObject <NSCoding>
{
// Attributes
}

View file

@ -29,15 +29,12 @@
#ifndef _GNUstep_H_NSResponder
#define _GNUstep_H_NSResponder
#include <AppKit/stdappkit.h>
#include <AppKit/NSEvent.h>
#include <Foundation/NSObject.h>
#include <Foundation/NSString.h>
#include <Foundation/NSArray.h>
#include <Foundation/NSCoder.h>
@interface NSResponder : NSObject <NSCoding>
@class NSString;
@class NSEvent;
@interface NSResponder : NSObject <NSCoding>
{
// Attributes
id next_responder;

View file

@ -29,16 +29,26 @@
#ifndef _GNUstep_H_NSSavePanel
#define _GNUstep_H_NSSavePanel
#include <AppKit/stdappkit.h>
#include <AppKit/NSPanel.h>
#include <AppKit/NSView.h>
#include <Foundation/NSCoder.h>
@class NSString;
@class NSView;
enum {
NSFileHandlingPanelImageButton,
NSFileHandlingPanelTitleField,
NSFileHandlingPanelBrowser,
NSFileHandlingPanelCancelButton,
NSFileHandlingPanelOKButton,
NSFileHandlingPanelForm,
NSFileHandlingPanelHomeButton,
NSFileHandlingPanelDiskButton,
NSFileHandlingPanelDiskEjectButton
};
// Should be subclassed from NSPanel but
// we are using the WIN32 common dialog
@interface NSSavePanel : NSObject <NSCoding>
{
// Attributes
NSView *accessory_view;
@ -113,12 +123,12 @@
//
- (NSComparisonResult)panel:(id)sender
compareFilename:(NSString *)filename1
with:(NSString *)filename2
caseSensitive:(BOOL)caseSensitive;
with:(NSString *)filename2
caseSensitive:(BOOL)caseSensitive;
- (BOOL)panel:(id)sender
shouldShowFilename:(NSString *)filename;
shouldShowFilename:(NSString *)filename;
- (BOOL)panel:(id)sender
isValidFilename:(NSString*)filename;
isValidFilename:(NSString*)filename;
//
// NSCoding protocol

View file

@ -29,12 +29,13 @@
#ifndef _GNUstep_H_NSScreen
#define _GNUstep_H_NSScreen
#include <AppKit/stdappkit.h>
#include <AppKit/TypesandConstants.h>
#include <Foundation/NSDictionary.h>
#include <Foundation/NSObject.h>
#include <AppKit/NSGraphics.h>
@class NSDictionary;
@class NSMutableDictionary;
@interface NSScreen : NSObject
{
// Attributes
NSMutableDictionary *device_desc;

View file

@ -29,13 +29,14 @@
#ifndef _GNUstep_H_NSScrollView
#define _GNUstep_H_NSScrollView
#include <AppKit/stdappkit.h>
#include <AppKit/NSView.h>
#include <AppKit/NSScroller.h>
#include <Foundation/NSCoder.h>
@class NSScroller;
@class NSClipView;
@class NSColor;
@class NSCursor;
@interface NSScrollView : NSView <NSCoding>
{
// Attributes
}
@ -51,11 +52,11 @@
//
+ (NSSize)contentSizeForFrameSize:(NSSize)size
hasHorizontalScroller:(BOOL)horizFlag
hasVerticalScroller:(BOOL)vertFlag
borderType:(NSBorderType)aType;
hasVerticalScroller:(BOOL)vertFlag
borderType:(NSBorderType)aType;
+ (NSSize)frameSizeForContentSize:(NSSize)size
hasHorizontalScroller:(BOOL)horizFlag
hasVerticalScroller:(BOOL)vertFlag
hasVerticalScroller:(BOOL)vertFlag
borderType:(NSBorderType)aType;
- (void)setHasHorizontalScroller:(BOOL)flag;
- (BOOL)hasHorizontalScroller;

View file

@ -29,12 +29,40 @@
#ifndef _GNUstep_H_NSScroller
#define _GNUstep_H_NSScroller
#include <AppKit/stdappkit.h>
#include <AppKit/NSControl.h>
#include <Foundation/NSCoder.h>
@class NSEvent;
typedef enum _NSScrollArrowPosition {
NSScrollerArrowsMaxEnd,
NSScrollerArrowsMinEnd,
NSScrollerArrowsNone
} NSScrollArrowPosition;
typedef enum _NSScrollerPart {
NSScrollerNoPart,
NSScrollerDecrementPage,
NSScrollerKnob,
NSScrollerIncrementPage,
NSScrollerDecrementLine,
NSScrollerIncrementLine,
NSScrollerKnobSlot
} NSScrollerPart;
typedef enum _NSScrollerUsablePart {
NSNoScrollerParts,
NSOnlyScrollerArrows,
NSAllScrollerParts
} NSUsableScrollerParts;
typedef enum _NSScrollerArrow {
NSScrollerIncrementArrow,
NSScrollerDecrementArrow
} NSScrollerArrow;
extern const float NSScrollerWidth;
@interface NSScroller : NSControl <NSCoding>
{
// Attributes
BOOL is_horizontal;

View file

@ -29,12 +29,12 @@
#ifndef _GNUstep_H_NSSelection
#define _GNUstep_H_NSSelection
#include <AppKit/stdappkit.h>
#include <AppKit/NSPasteboard.h>
#include <Foundation/NSCoder.h>
@interface NSSelection : NSObject <NSCoding>
@class NSData;
@class NSPasteboard;
@interface NSSelection : NSObject <NSCoding>
{
// Attributes
}

View file

@ -29,12 +29,16 @@
#ifndef _GNUstep_H_NSSlider
#define _GNUstep_H_NSSlider
#include <AppKit/stdappkit.h>
#include <AppKit/NSControl.h>
#include <Foundation/NSCoder.h>
@class NSString;
@class NSImage;
@class NSCell;
@class NSFont;
@class NSColor;
@class NSEvent;
@interface NSSlider : NSControl <NSCoding>
{
// Attributes
}

View file

@ -29,12 +29,13 @@
#ifndef _GNUstep_H_NSSliderCell
#define _GNUstep_H_NSSliderCell
#include <AppKit/stdappkit.h>
#include <AppKit/NSActionCell.h>
#include <Foundation/NSCoder.h>
@class NSString;
@class NSColor;
@class NSFont;
@interface NSSliderCell : NSActionCell <NSCoding>
{
// Attributes
double max_value;

View file

@ -29,13 +29,15 @@
#ifndef _GNUstep_H_NSSpellChecker
#define _GNUstep_H_NSSpellChecker
#include <AppKit/stdappkit.h>
#include <AppKit/NSView.h>
#include <AppKit/NSPanel.h>
#include <Foundation/NSObject.h>
#include <Foundation/NSRange.h>
@interface NSSpellChecker : NSObject
@class NSString;
@class NSArray;
@class NSView;
@class NSPanel;
@interface NSSpellChecker : NSObject
{
// Attributes
}
@ -62,10 +64,10 @@
startingAt:(int)startingOffset;
- (NSRange)checkSpellingOfString:(NSString *)stringToCheck
startingAt:(int)startingOffset
language:(NSString *)language
wrap:(BOOL)wrapFlag
inSpellDocumentWithTag:(int)tag
wordCount:(int *)wordCount;
language:(NSString *)language
wrap:(BOOL)wrapFlag
inSpellDocumentWithTag:(int)tag
wordCount:(int *)wordCount;
//
// Setting the Language
@ -79,10 +81,10 @@ inSpellDocumentWithTag:(int)tag
+ (int)uniqueSpellDocumentTag;
- (void)closeSpellDocumentWithTag:(int)tag;
- (void)ignoreWord:(NSString *)wordToIgnore
inSpellDocumentWithTag:(int)tag;
inSpellDocumentWithTag:(int)tag;
- (NSArray *)ignoredWordsInSpellDocumentWithTag:(int)tag;
- (void)setIgnoredWords:(NSArray *)someWords
inSpellDocumentWithTag:(int)tag;
inSpellDocumentWithTag:(int)tag;
- (void)setWordFieldStringValue:(NSString *)aString;
- (void)updateSpellingPanelWithMisspelledWord:(NSString *)word;

View file

@ -29,8 +29,7 @@
#ifndef _GNUstep_H_NSSpellServer
#define _GNUstep_H_NSSpellServer
#include <AppKit/stdappkit.h>
#include <Foundation/NSRange.h>
#include <Foundation/NSObject.h>
@interface NSSpellServer : NSObject

View file

@ -29,13 +29,12 @@
#ifndef _GNUstep_H_NSSplitView
#define _GNUstep_H_NSSplitView
#include <AppKit/stdappkit.h>
#include <AppKit/NSView.h>
#include <Foundation/NSCoder.h>
#include <Foundation/NSNotification.h>
@class NSString;
@class NSNotification;
@interface NSSplitView : NSView <NSCoding>
{
// Attributes
}
@ -57,11 +56,11 @@
// Implemented by the Delegate
//
- (void)splitView:(NSSplitView *)splitView
constrainMinCoordinate:(float *)min
maxCoordinate:(float *)max
ofSubviewAt:(int)offset;
constrainMinCoordinate:(float *)min
maxCoordinate:(float *)max
ofSubviewAt:(int)offset;
- (void)splitView:(NSSplitView *)sender
resizeSubviewsWithOldSize:(NSSize)oldSize;
resizeSubviewsWithOldSize:(NSSize)oldSize;
- (void)splitViewDidResizeSubviews:(NSNotification *)notification;
- (void)splitViewWillResizeSubviews:(NSNotification *)notification;
@ -73,4 +72,7 @@ resizeSubviewsWithOldSize:(NSSize)oldSize;
@end
extern NSString *NSSplitViewDidResizeSubviewsNotification;
extern NSString *NSSplitViewWillResizeSubviewsNotification;
#endif // _GNUstep_H_NSSplitView

View file

@ -29,15 +29,35 @@
#ifndef _GNUstep_H_NSText
#define _GNUstep_H_NSText
#include <AppKit/stdappkit.h>
#include <AppKit/NSView.h>
#include <AppKit/NSFont.h>
#include <AppKit/NSSpellProtocol.h>
#include <Foundation/NSCoder.h>
#include <Foundation/NSNotification.h>
@class NSString;
@class NSData;
@class NSNotification;
@class NSColor;
@class NSFont;
typedef enum _NSTextAlignment {
NSLeftTextAlignment,
NSRightTextAlignment,
NSCenterTextAlignment,
NSJustifiedTextAlignment,
NSNaturalTextAlignment
} NSTextAlignment;
enum {
NSIllegalTextMovement = 0,
NSReturnTextMovement = 0x10,
NSTabTextMovement = 0x11,
NSBacktabTextMovement = 0x12,
NSLeftTextMovement = 0x13,
NSRightTextMovement = 0x14,
NSUpTextMovement = 0x15,
NSDownTextMovement = 0x16
};
@interface NSText : NSView <NSChangeSpelling,NSIgnoreMisspelledWords,NSCoding>
{
// Attributes
id delegate;
@ -209,4 +229,9 @@
@end
/* Notifications */
extern NSString *NSTextDidBeginEditingNotification;
extern NSString *NSTextDidEndEditingNotification;
extern NSString *NSTextDidChangeNotification;
#endif // _GNUstep_H_NSText

View file

@ -29,22 +29,19 @@
#ifndef _GNUstep_H_NSTextField
#define _GNUstep_H_NSTextField
#include <AppKit/stdappkit.h>
#include <AppKit/NSControl.h>
#include <AppKit/NSColor.h>
#include <Foundation/NSCoder.h>
#include <Foundation/NSNotification.h>
#include <AppKit/NSCursor.h>
@class NSNotification;
@class NSColor;
@class NSText;
@interface NSTextField : NSControl <NSCoding>
{
// Attributes
id next_text;
id previous_text;
id text_delegate;
SEL error_action;
NSCursor *text_cursor;
}
//

View file

@ -29,14 +29,11 @@
#ifndef _GNUstep_H_NSTextFieldCell
#define _GNUstep_H_NSTextFieldCell
#include <AppKit/stdappkit.h>
#include <AppKit/NSActionCell.h>
#include <DPSClient/DPSOperators.h>
#include <AppKit/NSColor.h>
#include <Foundation/NSCoder.h>
@class NSColor;
@interface NSTextFieldCell : NSActionCell <NSCoding>
{
// Attributes
NSColor *background_color;

View file

@ -29,19 +29,41 @@
#ifndef _GNUstep_H_NSView
#define _GNUstep_H_NSView
#include <AppKit/stdappkit.h>
#include <DPSClient/TypesandConstants.h>
#include <AppKit/NSResponder.h>
#include <AppKit/NSImage.h>
#include <Foundation/NSArray.h>
#include <AppKit/TrackingRectangle.h>
#include <AppKit/NSCursor.h>
#include <Foundation/NSCoder.h>
@class NSString;
@class NSArray;
@class NSMutableArray;
@class NSData;
@class NSWindow;
@class NSPasteboard;
@class NSView;
@class NSClipView;
@class NSImage;
@class NSCursor;
typedef int NSTrackingRectTag;
typedef enum _NSBorderType {
NSNoBorder,
NSLineBorder,
NSBezelBorder,
NSGrooveBorder
} NSBorderType;
enum {
NSViewNotSizable,
NSViewMinXMargin,
NSViewWidthSizable,
NSViewMaxXMargin,
NSViewMinYMargin,
NSViewHeightSizable,
NSViewMaxYMargin
};
@interface NSView : NSResponder <NSCoding>
{
// Attributes
NSRect frame;
@ -52,7 +74,6 @@
NSMutableArray *sub_views;
id window;
NSMutableArray *tracking_rects;
NSMutableArray *cursor_rects;
BOOL is_flipped;
BOOL is_rotated_from_base;
@ -208,7 +229,6 @@
- (void)removeCursorRect:(NSRect)aRect
cursor:(NSCursor *)anObject;
- (void)resetCursorRects;
- (NSArray *)cursorRectangles;
//
// Assigning a Tag
@ -229,7 +249,7 @@
- (NSTrackingRectTag)addTrackingRect:(NSRect)aRect
owner:(id)anObject
userData:(void *)data
assumeInside:(BOOL)flag;
assumeInside:(BOOL)flag;
- (NSArray *)trackingRectangles;
//
@ -312,4 +332,8 @@
@end
/* Notifications */
extern NSString *NSViewFrameChangedNotification;
extern NSString *NSViewFocusChangedNotification;
#endif // _GNUstep_H_NSView

View file

@ -29,21 +29,47 @@
#ifndef _GNUstep_H_NSWindow
#define _GNUstep_H_NSWindow
#include <AppKit/stdappkit.h>
#include <DPSClient/TypesandConstants.h>
#include <AppKit/NSGraphics.h>
#include <AppKit/NSResponder.h>
#include <AppKit/NSView.h>
#include <AppKit/NSEvent.h>
#include <Foundation/NSDate.h>
#include <Foundation/NSString.h>
#include <AppKit/NSImage.h>
#include <AppKit/NSColor.h>
#include <AppKit/NSText.h>
#include <Foundation/NSCoder.h>
#include <AppKit/NSScreen.h>
#include <Foundation/NSNotification.h>
#include <AppKit/LogFile.h>
@class NSString;
@class NSArray;
@class NSData;
@class NSDictionary;
@class NSNotification;
@class NSDate;
@class NSColor;
@class NSImage;
@class NSScreen;
@class NSEvent;
@class NSPasteboard;
@class NSView;
@class NSText;
enum {
NSNormalWindowLevel = 0,
NSFloatingWindowLevel = 3,
NSDockWindowLevel = 5,
NSSubmenuWindowLevel = 10,
NSMainMenuWindowLevel = 20
};
enum {
NSBorderlessWindowMask = 1,
NSTitledWindowMask = 2,
NSClosableWindowMask = 4,
NSMiniaturizableWindowMask = 8,
NSResizableWindowMask = 16
};
extern NSSize NSIconSize;
extern NSSize NSTokenSize;
@interface NSWindow : NSResponder <NSCoding>
{
// Attributes
NSRect frame;
@ -73,7 +99,6 @@
BOOL dynamic_depth_limit;
BOOL cursor_rects_enabled;
BOOL cursor_rects_valid;
BOOL visible;
BOOL is_key;
@ -389,4 +414,20 @@
@end
/* Notifications */
extern NSString *NSWindowDidBecomeKeyNotification;
extern NSString *NSWindowDidBecomeMainNotification;
extern NSString *NSWindowDidChangeScreenNotification;
extern NSString *NSWindowDidDeminiaturizeNotification;
extern NSString *NSWindowDidExposeNotification;
extern NSString *NSWindowDidMiniaturizeNotification;
extern NSString *NSWindowDidMoveNotification;
extern NSString *NSWindowDidResignKeyNotification;
extern NSString *NSWindowDidResignMainNotification;
extern NSString *NSWindowDidResizeNotification;
extern NSString *NSWindowDidUpdateNotification;
extern NSString *NSWindowWillCloseNotification;
extern NSString *NSWindowWillMiniaturizeNotification;
extern NSString *NSWindowWillMoveNotification;
#endif // _GNUstep_H_NSWindow

View file

@ -29,13 +29,16 @@
#ifndef _GNUstep_H_NSWorkspace
#define _GNUstep_H_NSWorkspace
#include <AppKit/stdappkit.h>
#include <AppKit/NSImage.h>
#include <AppKit/NSView.h>
#include <Foundation/NSNotification.h>
#include <Foundation/NSObject.h>
#include <Foundation/NSGeometry.h>
@class NSString;
@class NSArray;
@class NSNotificationCenter;
@class NSImage;
@class NSView;
@interface NSWorkspace : NSObject
{
// Attributes
}
@ -51,13 +54,13 @@
- (BOOL)openFile:(NSString *)fullPath;
- (BOOL)openFile:(NSString *)fullPath
fromImage:(NSImage *)anImage
at:(NSPoint)point
inView:(NSView *)aView;
at:(NSPoint)point
inView:(NSView *)aView;
- (BOOL)openFile:(NSString *)fullPath
withApplication:(NSString *)appName;
withApplication:(NSString *)appName;
- (BOOL)openFile:(NSString *)fullPath
withApplication:(NSString *)appName
andDeactivate:(BOOL)flag;
withApplication:(NSString *)appName
andDeactivate:(BOOL)flag;
- (BOOL)openTempFile:(NSString *)fullPath;
//
@ -65,11 +68,11 @@ andDeactivate:(BOOL)flag;
//
- (BOOL)performFileOperation:(NSString *)operation
source:(NSString *)source
destination:(NSString *)destination
files:(NSArray *)files
tag:(int *)tag;
destination:(NSString *)destination
files:(NSArray *)files
tag:(int *)tag;
- (BOOL)selectFile:(NSString *)fullPath
inFileViewerRootedAtPath:(NSString *)rootFullpath;
inFileViewerRootedAtPath:(NSString *)rootFullpath;
//
// Requesting Information about Files
@ -77,13 +80,13 @@ inFileViewerRootedAtPath:(NSString *)rootFullpath;
- (NSString *)fullPathForApplication:(NSString *)appName;
- (BOOL)getFileSystemInfoForPath:(NSString *)fullPath
isRemovable:(BOOL *)removableFlag
isWritable:(BOOL *)writableFlag
isUnmountable:(BOOL *)unmountableFlag
description:(NSString **)description
type:(NSString **)fileSystemType;
isWritable:(BOOL *)writableFlag
isUnmountable:(BOOL *)unmountableFlag
description:(NSString **)description
type:(NSString **)fileSystemType;
- (BOOL)getInfoForFile:(NSString *)fullPath
application:(NSString **)appName
type:(NSString **)type;
type:(NSString **)type;
- (NSImage *)iconForFile:(NSString *)fullPath;
- (NSImage *)iconForFiles:(NSArray *)pathArray;
- (NSImage *)iconForFileType:(NSString *)fileType;
@ -106,7 +109,7 @@ type:(NSString **)type;
- (BOOL)launchApplication:(NSString *)appName;
- (BOOL)launchApplication:(NSString *)appName
showIcon:(BOOL)showIcon
autolaunch:(BOOL)autolaunch;
autolaunch:(BOOL)autolaunch;
//
// Unmounting a Device
@ -136,7 +139,7 @@ autolaunch:(BOOL)autolaunch;
//
- (void)slideImage:(NSImage *)image
from:(NSPoint)fromPoint
to:(NSPoint)toPoint;
to:(NSPoint)toPoint;
//
// Requesting Additional Time before Power Off or Logout
@ -145,4 +148,38 @@ to:(NSPoint)toPoint;
@end
/* Notifications */
extern NSString *NSWorkspaceDidLaunchApplicationNotification;
extern NSString *NSWorkspaceDidMountNotification;
extern NSString *NSWorkspaceDidPerformFileOperationNotification;
extern NSString *NSWorkspaceDidTerminateApplicationNotification;
extern NSString *NSWorkspaceDidUnmountNotification;
extern NSString *NSWorkspaceWillLaunchApplicationNotification;
extern NSString *NSWorkspaceWillPowerOffNotification;
extern NSString *NSWorkspaceWillUnmountNotification;
//
// Workspace File Type Globals
//
extern NSString *NSPlainFileType;
extern NSString *NSDirectoryFileType;
extern NSString *NSApplicationFileType;
extern NSString *NSFilesystemFileType;
extern NSString *NSShellCommandFileType;
//
// Workspace File Operation Globals
//
extern NSString *NSWorkspaceCompressOperation;
extern NSString *NSWorkspaceCopyOperation;
extern NSString *NSWorkspaceDecompressOperation;
extern NSString *NSWorkspaceDecryptOperation;
extern NSString *NSWorkspaceDestroyOperation;
extern NSString *NSWorkspaceDuplicateOperation;
extern NSString *NSWorkspaceEncryptOperation;
extern NSString *NSWorkspaceLinkOperation;
extern NSString *NSWorkspaceMoveOperation;
extern NSString *NSWorkspaceRecycleOperation;
#endif // _GNUstep_H_NSWorkspace

View file

@ -29,11 +29,9 @@
#ifndef _GNUstep_H_TrackingRectangle
#define _GNUstep_H_TrackingRectangle
#include <AppKit/stdappkit.h>
#include <Foundation/NSCoder.h>
#include <AppKit/NSView.h>
@interface TrackingRectangle : NSObject <NSCoding>
{
// Attributes
NSRect rectangle;
@ -45,10 +43,10 @@
// Instance methods
- initWithRect:(NSRect)aRect
tag:(NSTrackingRectTag)aTag
owner:anObject
userData:(void *)theData
inside:(BOOL)flag;
tag:(NSTrackingRectTag)aTag
owner:anObject
userData:(void *)theData
inside:(BOOL)flag;
- (NSRect)rectangle;
- (NSTrackingRectTag)tag;

File diff suppressed because it is too large Load diff

View file

@ -1,37 +0,0 @@
/* stdappkit.h
Global includes for the GNUstep GUI Library.
Copyright (C) 1996 Free Software Foundation, Inc.
Author: Scott Christley <scottc@net-community.com>
Date: 1996
This file is part of the GNUstep GUI Library.
This library is free software; you can redistribute it and/or
modify it under the terms of the GNU Library General Public
License as published by the Free Software Foundation; either
version 2 of the License, or (at your option) any later version.
This library is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
Library General Public License for more details.
You should have received a copy of the GNU Library General Public
License along with this library; see the file COPYING.LIB.
If not, write to the Free Software Foundation,
59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
*/
#ifndef _GNUstep_H_AppKitStandard
#define _GNUstep_H_AppKitStandard
#include <AppKit/config.h>
#include <AppKit/LogFile.h>
#include <AppKit/TypesandConstants.h>
#include <AppKit/Functions.h>
#endif // _GNUstep_H_AppKitStandard

1
Images/.cvsignore Normal file
View file

@ -0,0 +1 @@
Makefile

1
Source/.cvsignore Normal file
View file

@ -0,0 +1 @@
Makefile

View file

@ -26,11 +26,16 @@
59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
*/
#include <gnustep/gui/Functions.h>
#include <gnustep/gui/LogFile.h>
#include <stdio.h>
#include <stdarg.h>
#include <AppKit/NSGraphics.h>
#ifndef LIB_FOUNDATION_LIBRARY
#include <Foundation/NSString.h>
#include <gnustep/gui/LogFile.h>
// Should be in Foundation Kit
// Does not handle %@
// yuck, yuck, yuck
@ -51,7 +56,18 @@ void NSLog(NSString *format, ...)
NSLogV(format, ap);
va_end(ap);
}
#endif /* LIB_FOUNDATION_LIBRARY */
void NSNullLog(NSString *format, ...)
{
}
//
// Play the System Beep
//
void NSBeep(void)
{
#ifdef WIN32
MessageBeep(MB_OK);
#endif
}

View file

@ -26,7 +26,7 @@
59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
*/
#include <gnustep/gui/LogFile.h>
#include <AppKit/LogFile.h>
@implementation LogFile
@ -101,6 +101,7 @@
fprintf(the_log, "%s", logEntry);
fflush(the_log);
}
return self;
}
- closeLog
@ -108,6 +109,7 @@
[self writeLog:"Log closed.\n"];
if (the_log) fclose(the_log);
the_log = NULL;
return self;
}
- (BOOL)isDateLogging
@ -118,6 +120,7 @@
- setDateLogging:(BOOL)flag
{
l_flags.is_date_logging = flag;
return self;
}
- (BOOL)isLocking

View file

@ -45,12 +45,10 @@ bindir = @bindir@
MAKEDEFINES =
CC = @CC@
CC = @CC@ -g
CPPFLAGS = @CPPFLAGS@
CFLAGS = -g -O -Wall $(GCCFLAGS)
ALL_CPPFLAGS = $(CPPFLAGS) -I../Headers
ALL_CFLAGS = $(ALL_CPPFLAGS) $(CFLAGS)
DEFS = -DGNUSTEP_INSTALL_LIBDIR=$(gnustep_libdir) @DEFS@
CFLAGS = -c $(GCCFLAGS) -I../Headers $(CPPFLAGS)
DEFS = -DGNUSTEP_INSTALL_LIBDIR=\"$(gnustep_libdir)\" @DEFS@
GCC_LIB =
OBJC_LIB = -lobjc
@ -175,7 +173,7 @@ NSBitmapImageRep$(oext) \
NSBox$(oext) \
NSBrowser$(oext) \
NSBrowserCell$(oext) \
NSBundle$(oext) \
NSBundleAdditions$(oext) \
NSButton$(oext) \
NSButtonCell$(oext) \
NSCStringText$(oext) \
@ -242,9 +240,9 @@ OBJS = $(OBJS_WITHOUT_INIT)
.SUFFIXES: .m
.m$(oext):
$(CC) -c $(ALL_CFLAGS) $(DEFS) $<
$(CC) $(CFLAGS) $(DEFS) $<
.c$(oext):
$(CC) -c $(ALL_CFLAGS) $(DEFS) $<
$(CC) $(CFLAGS) $(DEFS) $<
#
# libraries
@ -276,7 +274,7 @@ $(MAIN_FILE)$(libext): $(OBJS)
$(INIT_FILE_OBJ): $(OBJS_WITHOUT_INIT)
nm $(OBJS_WITHOUT_INIT) | grep " __GLOBAL_" > tmpinit.c
collect tmpinit.c $(INIT_FILE)
$(CC) $(ALL_CFLAGS) $(INIT_FILE).c
$(CC) $(CFLAGS) $(INIT_FILE).c
rm tmpinit.c
install: installdirs install-lib install-headers
@ -321,9 +319,6 @@ uninstall:
rm -rf $(includedir)/DPSClient
rm -rf $(libdir)/$(MAIN_FILE)$(libext)
Makefile: $(srcdir)/Makefile.in ../config.status
cd ..; $(SHELL) config.status
#
# Cleaning
#

View file

@ -26,9 +26,10 @@
59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
*/
#include <gnustep/gui/NSActionCell.h>
#include <gnustep/base/NSCoder.h>
#include <gnustep/gui/NSControl.h>
#include <Foundation/NSCoder.h>
#include <AppKit/NSActionCell.h>
#include <AppKit/NSControl.h>
#include <AppKit/LogFile.h>
@implementation NSActionCell
@ -151,21 +152,6 @@
//
// Manipulating NSActionCell Values
//
- (double)doubleValue
{
return [super doubleValue];
}
- (float)floatValue
{
return [super floatValue];
}
- (int)intValue
{
return [super intValue];
}
- (void)setStringValue:(NSString *)aString
{
[super setStringValue:aString];
@ -174,23 +160,28 @@
[(NSControl *)control_view updateCell: self];
}
- (NSString *)stringValue
- (void)setDoubleValue:(double)aDouble
{
return [super stringValue];
[super setDoubleValue:aDouble];
if (control_view)
if ([control_view isKindOfClass: [NSControl class]])
[(NSControl *)control_view updateCell: self];
}
//
// Displaying
//
- (void)drawWithFrame:(NSRect)cellFrame
inView:(NSView *)controlView
- (void)setFloatValue:(float)aFloat
{
[super drawWithFrame:cellFrame inView:controlView];
[super setFloatValue:aFloat];
if (control_view)
if ([control_view isKindOfClass: [NSControl class]])
[(NSControl *)control_view updateCell: self];
}
- (NSView *)controlView
- (void)setIntValue:(int)anInt
{
return [super controlView];
[super setIntValue:anInt];
if (control_view)
if ([control_view isKindOfClass: [NSControl class]])
[(NSControl *)control_view updateCell: self];
}
//
@ -237,8 +228,13 @@
[super encodeWithCoder:aCoder];
[aCoder encodeValueOfObjCType: "i" at: &tag];
#if 0
[aCoder encodeObjectReference: target withName: @"Target"];
[aCoder encodeValueOfObjCType: @encode(SEL) at: &action];
#else
[aCoder encodeConditionalObject:target];
#endif
[aCoder encodeValueOfObjCType:@encode(SEL) at: &action];
}
- initWithCoder:aDecoder
@ -246,7 +242,11 @@
[super initWithCoder:aDecoder];
[aDecoder decodeValueOfObjCType: "i" at: &tag];
#if 0
[aDecoder decodeObjectAt: &target withName: NULL];
#else
target = [aDecoder decodeObject];
#endif
[aDecoder decodeValueOfObjCType: @encode(SEL) at: &action];
return self;

View file

@ -26,18 +26,27 @@
59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
*/
#include <gnustep/gui/NSApplication.h>
#include <gnustep/gui/NSPopUpButton.h>
#include <gnustep/gui/NSPanel.h>
#include <stdio.h>
#include <Foundation/NSArray.h>
#include <Foundation/NSNotification.h>
#include <DPSClient/NSDPSContext.h>
#include <AppKit/NSApplication.h>
#include <AppKit/NSPopUpButton.h>
#include <AppKit/NSPanel.h>
#include <AppKit/NSEvent.h>
#include <AppKit/NSImage.h>
#include <AppKit/NSMenu.h>
#include <AppKit/NSMenuCell.h>
#include <AppKit/LogFile.h>
//
// Class variables
//
// The global application instance
extern id NSApp;
NSEvent *NullEvent;
BOOL gnustep_gui_app_is_in_dealloc;
NSEvent *NullEvent = NULL;
static BOOL gnustep_gui_app_is_in_dealloc;
// Global strings
NSString *NSModalPanelRunLoopMode = @"ModalPanelMode";
@ -152,7 +161,7 @@ NSString *NSApplicationWillUpdateNotification = @"ApplicationWillUpdate";
// Event handling setup
//
// allocate the event queue
event_queue = [[Queue alloc] init];
event_queue = [[NSMutableArray alloc] init];
// No current event
current_event = nil;
// The NULL event
@ -183,8 +192,6 @@ NSString *NSApplicationWillUpdateNotification = @"ApplicationWillUpdate";
- (void)dealloc
{
int i, j;
NSDebugLog(@"Freeing NSApplication\n");
// Let ourselves know we are within dealloc
@ -263,7 +270,7 @@ NSString *NSApplicationWillUpdateNotification = @"ApplicationWillUpdate";
e = [self nextEventMatchingMask:NSAnyEventMask untilDate:nil
inMode:nil dequeue:YES];
if (e)
[self sendEvent: e];
[self postEvent:e atStart:YES];
else
{
// Null event
@ -437,10 +444,10 @@ NSString *NSApplicationWillUpdateNotification = @"ApplicationWillUpdate";
int i, j;
// If the queue isn't empty then check those messages
if (![event_queue isEmpty])
if ([event_queue count])
{
j = [event_queue count];
for (i = j-1;i >= 0; --i)
for (i = j-1;i > 0; --i)
{
e = [event_queue objectAtIndex: i];
if ([self event: e matchMask: mask])
@ -469,32 +476,13 @@ NSString *NSApplicationWillUpdateNotification = @"ApplicationWillUpdate";
}
}
// Unhide the cursor if necessary
{
NSEventType type;
// Only if we should unhide when mouse moves
if ([NSCursor isHiddenUntilMouseMoves])
{
// Make sure the event is a mouse event before unhiding
type = [e type];
if ((type == NSLeftMouseDown) || (type == NSLeftMouseUp)
|| (type == NSRightMouseDown) || (type == NSRightMouseUp)
|| (type == NSMouseMoved))
[NSCursor unhide];
}
}
[self setCurrentEvent: e];
return e;
}
- (void)postEvent:(NSEvent *)event atStart:(BOOL)flag
{
if (flag)
[event_queue appendObject: event];
else
[event_queue enqueueObject: event];
[self sendEvent:event];
}
//
@ -713,7 +701,6 @@ NSString *NSApplicationWillUpdateNotification = @"ApplicationWillUpdate";
int i, j;
NSMenuCell *mc;
NSArray *mi;
id w;
// Release old and retain new
[main_menu release];
@ -779,9 +766,6 @@ NSString *NSApplicationWillUpdateNotification = @"ApplicationWillUpdate";
- (void)removeWindowsItem:aWindow
{
int i, j;
id w;
// +++ This should be different
if (aWindow == key_window)
key_window = nil;
@ -875,7 +859,7 @@ NSString *NSApplicationWillUpdateNotification = @"ApplicationWillUpdate";
{
BOOL result = NO;
if ([delegate respondsTo:@selector(application:openFileWithoutUI:)])
if ([delegate respondsToSelector:@selector(application:openFileWithoutUI:)])
result = [delegate application:sender openFileWithoutUI:filename];
return result;
@ -885,7 +869,7 @@ NSString *NSApplicationWillUpdateNotification = @"ApplicationWillUpdate";
{
BOOL result = NO;
if ([delegate respondsTo:@selector(application:openFile:)])
if ([delegate respondsToSelector:@selector(application:openFile:)])
result = [delegate application:app openFile:filename];
return result;
@ -895,7 +879,7 @@ NSString *NSApplicationWillUpdateNotification = @"ApplicationWillUpdate";
{
BOOL result = NO;
if ([delegate respondsTo:@selector(application:openTempFile:)])
if ([delegate respondsToSelector:@selector(application:openTempFile:)])
result = [delegate application:app openTempFile:filename];
return result;
@ -903,37 +887,37 @@ NSString *NSApplicationWillUpdateNotification = @"ApplicationWillUpdate";
- (void)applicationDidBecomeActive:(NSNotification *)aNotification
{
if ([delegate respondsTo:@selector(applicationDidBecomeActive:)])
if ([delegate respondsToSelector:@selector(applicationDidBecomeActive:)])
[delegate applicationDidBecomeActive:aNotification];
}
- (void)applicationDidFinishLaunching:(NSNotification *)aNotification
{
if ([delegate respondsTo:@selector(applicationDidFinishLaunching:)])
if ([delegate respondsToSelector:@selector(applicationDidFinishLaunching:)])
[delegate applicationDidFinishLaunching:aNotification];
}
- (void)applicationDidHide:(NSNotification *)aNotification
{
if ([delegate respondsTo:@selector(applicationDidHide:)])
if ([delegate respondsToSelector:@selector(applicationDidHide:)])
[delegate applicationDidHide:aNotification];
}
- (void)applicationDidResignActive:(NSNotification *)aNotification
{
if ([delegate respondsTo:@selector(applicationDidResignActive:)])
if ([delegate respondsToSelector:@selector(applicationDidResignActive:)])
[delegate applicationDidResignActive:aNotification];
}
- (void)applicationDidUnhide:(NSNotification *)aNotification
{
if ([delegate respondsTo:@selector(applicationDidUnhide:)])
if ([delegate respondsToSelector:@selector(applicationDidUnhide:)])
[delegate applicationDidUnhide:aNotification];
}
- (void)applicationDidUpdate:(NSNotification *)aNotification
{
if ([delegate respondsTo:@selector(applicationDidUpdate:)])
if ([delegate respondsToSelector:@selector(applicationDidUpdate:)])
[delegate applicationDidUpdate:aNotification];
}
@ -941,7 +925,7 @@ NSString *NSApplicationWillUpdateNotification = @"ApplicationWillUpdate";
{
BOOL result = NO;
if ([delegate respondsTo:@selector(applicationOpenUntitledFile:)])
if ([delegate respondsToSelector:@selector(applicationOpenUntitledFile:)])
result = [delegate applicationOpenUntitledFile:app];
return result;
@ -951,7 +935,7 @@ NSString *NSApplicationWillUpdateNotification = @"ApplicationWillUpdate";
{
BOOL result = YES;
if ([delegate respondsTo:@selector(applicationShouldTerminate:)])
if ([delegate respondsToSelector:@selector(applicationShouldTerminate:)])
result = [delegate applicationShouldTerminate:sender];
return result;
@ -959,37 +943,37 @@ NSString *NSApplicationWillUpdateNotification = @"ApplicationWillUpdate";
- (void)applicationWillBecomeActive:(NSNotification *)aNotification
{
if ([delegate respondsTo:@selector(applicationWillBecomeActive:)])
if ([delegate respondsToSelector:@selector(applicationWillBecomeActive:)])
[delegate applicationWillBecomeActive:aNotification];
}
- (void)applicationWillFinishLaunching:(NSNotification *)aNotification
{
if ([delegate respondsTo:@selector(applicationWillFinishLaunching:)])
if ([delegate respondsToSelector:@selector(applicationWillFinishLaunching:)])
[delegate applicationWillFinishLaunching:aNotification];
}
- (void)applicationWillHide:(NSNotification *)aNotification
{
if ([delegate respondsTo:@selector(applicationWillHide:)])
if ([delegate respondsToSelector:@selector(applicationWillHide:)])
[delegate applicationWillHide:aNotification];
}
- (void)applicationWillResignActive:(NSNotification *)aNotification
{
if ([delegate respondsTo:@selector(applicationWillResignActive:)])
if ([delegate respondsToSelector:@selector(applicationWillResignActive:)])
[delegate applicationWillResignActive:aNotification];
}
- (void)applicationWillUnhide:(NSNotification *)aNotification
{
if ([delegate respondsTo:@selector(applicationWillUnhide:)])
if ([delegate respondsToSelector:@selector(applicationWillUnhide:)])
[delegate applicationWillUnhide:aNotification];
}
- (void)applicationWillUpdate:(NSNotification *)aNotification
{
if ([delegate respondsTo:@selector(applicationWillUpdate:)])
if ([delegate respondsToSelector:@selector(applicationWillUpdate:)])
[delegate applicationWillUpdate:aNotification];
}
@ -1004,11 +988,19 @@ NSString *NSApplicationWillUpdateNotification = @"ApplicationWillUpdate";
// We don't want to code the event queue do we?
//[aCoder encodeObject: event_queue];
//[aCoder encodeObject: current_event];
#if 0
[aCoder encodeObjectReference: key_window withName: @"Key window"];
[aCoder encodeObjectReference: main_window withName: @"Main window"];
[aCoder encodeObjectReference: delegate withName: @"Delegate"];
[aCoder encodeObject: main_menu];
[aCoder encodeObjectReference: windows_menu withName: @"Windows menu"];
#else
[aCoder encodeConditionalObject:key_window];
[aCoder encodeConditionalObject:main_window];
[aCoder encodeConditionalObject:delegate];
[aCoder encodeObject:main_menu];
[aCoder encodeConditionalObject:windows_menu];
#endif
}
- initWithCoder:aDecoder
@ -1016,11 +1008,19 @@ NSString *NSApplicationWillUpdateNotification = @"ApplicationWillUpdate";
[super initWithCoder:aDecoder];
window_list = [aDecoder decodeObject];
#if 0
[aDecoder decodeObjectAt: &key_window withName: NULL];
[aDecoder decodeObjectAt: &main_window withName: NULL];
[aDecoder decodeObjectAt: &delegate withName: NULL];
main_menu = [aDecoder decodeObject];
[aDecoder decodeObjectAt: &windows_menu withName: NULL];
#else
key_window = [aDecoder decodeObject];
main_window = [aDecoder decodeObject];
delegate = [aDecoder decodeObject];
main_menu = [aDecoder decodeObject];
windows_menu = [aDecoder decodeObject];
#endif
return self;
}
@ -1036,7 +1036,7 @@ NSString *NSApplicationWillUpdateNotification = @"ApplicationWillUpdate";
// Get next event
- (NSEvent *)getNextEvent
{
[event_queue enqueueObject: NullEvent];
[event_queue addObject: NullEvent];
return NullEvent;
}

View file

@ -28,10 +28,16 @@
#include <stdlib.h>
#include <math.h>
#include <tiff.h>
#include <Foundation/NSException.h>
#include <Foundation/NSArray.h>
#include <Foundation/NSData.h>
#include <AppKit/NSGraphics.h>
#include <AppKit/NSPasteboard.h>
#include <AppKit/NSBitmapImageRep.h>
#include <AppKit/AppKitExceptions.h>
#include <gnustep/gui/nsimage-tiff.h>
/* Maximum number of planes */
#define MAX_PLANES 5

View file

@ -26,8 +26,9 @@
59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
*/
#include <gnustep/gui/NSBox.h>
#include <gnustep/gui/NSTextFieldCell.h>
#include <Foundation/NSArray.h>
#include <AppKit/NSBox.h>
#include <AppKit/NSTextFieldCell.h>
@implementation NSBox

View file

@ -26,7 +26,7 @@
59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
*/
#include <gnustep/gui/NSBrowser.h>
#include <AppKit/NSBrowser.h>
@implementation NSBrowser

View file

@ -26,7 +26,7 @@
59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
*/
#include <gnustep/gui/NSBrowserCell.h>
#include <AppKit/NSBrowserCell.h>
@implementation NSBrowserCell

View file

@ -26,7 +26,7 @@
*/
#include <Foundation/NSBundle.h>
#include <AppKit/NSBundle.h>
#include <AppKit/NSNibLoading.h>
@implementation NSBundle (NSBundleAdditions)
@ -37,7 +37,7 @@
+ (BOOL)loadNibFile:(NSString *)fileName
externalNameTable:(NSDictionary *)context
withZone:(NSZone *)zone
withZone:(NSZone *)zone
{
return NO;
}
@ -49,3 +49,10 @@ withZone:(NSZone *)zone
}
@end
@interface __dummy_class_in_NSBundle
@end
@implementation __dummy_class_in_NSBundle
@end

View file

@ -26,15 +26,16 @@
59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
*/
#include <gnustep/gui/NSButton.h>
#include <gnustep/gui/NSWindow.h>
#include <gnustep/gui/NSButtonCell.h>
#include <gnustep/gui/NSApplication.h>
#include <AppKit/NSButton.h>
#include <AppKit/NSWindow.h>
#include <AppKit/NSButtonCell.h>
#include <AppKit/NSApplication.h>
#include <gnustep/gui/LogFile.h>
//
// class variables
//
id MB_NSBUTTON_CLASS;
static id MB_NSBUTTON_CLASS = nil;
//
// NSButton implementation
@ -94,9 +95,9 @@ id MB_NSBUTTON_CLASS;
//
// Setting the Button Type
//
- (void)setType:(NSButtonType)aType
- (void)setButtonType:(NSButtonType)aType
{
[cell setType:aType];
[cell setButtonType:aType];
[self display];
}
@ -111,6 +112,21 @@ id MB_NSBUTTON_CLASS;
//
// Setting the State
//
- (void)setIntValue:(int)anInt
{
[self setState:(anInt != 0)];
}
- (void)setFloatValue:(float)aFloat
{
[self setState:(aFloat != 0)];
}
- (void)setDoubleValue:(double)aDouble
{
[self setState:(aDouble != 0)];
}
- (void)setState:(int)value
{
[cell setState:value];
@ -194,6 +210,16 @@ id MB_NSBUTTON_CLASS;
[self display];
}
- (void)setAlignment:(NSTextAlignment)mode
{
[cell setAlignment:mode];
}
- (NSTextAlignment)alignment
{
return [cell alignment];
}
//
// Modifying Graphic Attributes
//
@ -270,6 +296,7 @@ id MB_NSBUTTON_CLASS;
// capture mouse
[[self window] captureMouse: self];
[self lockFocus];
done = NO;
e = theEvent;
@ -300,6 +327,7 @@ id MB_NSBUTTON_CLASS;
[cell highlight: NO withFrame: bounds
inView: self];
#if 0
//
// Perform different state changes based upon our type
//
@ -326,11 +354,18 @@ id MB_NSBUTTON_CLASS;
[cell setState:1];
NSDebugLog(@"toggle state on\n");
}
default:
break;
}
#endif
[cell setState:![self state]];
// Have the target perform the action
[self sendAction:[self action] to:[self target]];
[cell drawWithFrame:bounds inView:self];
}
[self unlockFocus];
}
- (void)performClick:(id)sender

View file

@ -26,13 +26,15 @@
59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
*/
#include <gnustep/gui/NSButtonCell.h>
#include <gnustep/gui/NSButton.h>
#include <gnustep/gui/NSWindow.h>
#include <Foundation/NSLock.h>
#include <Foundation/NSArray.h>
#include <gnustep/gui/NSEvent.h>
#include <gnustep/gui/NSApplication.h>
#include <AppKit/NSButtonCell.h>
#include <AppKit/NSButton.h>
#include <AppKit/NSWindow.h>
#include <AppKit/NSEvent.h>
#include <AppKit/NSApplication.h>
#include <AppKit/NSFont.h>
#include <AppKit/NSImage.h>
//
// NSButtonCell implementation
@ -56,17 +58,17 @@
//
- init
{
[self initTextCell:[NSString stringWithCString:"Button"]];
[self initTextCell:@"Button"];
return self;
}
- initImageCell:(NSImage *)anImage
{
[super initImageCell:anImage];
contents = @"Button";
cell_type = NSMomentaryPushButton;
[self setStringValue:@"Button"];
[self setButtonType:NSMomentaryPushButton];
[self setEnabled:YES];
transparent = NO;
[self setTransparent:NO];
[self setBordered:YES];
return self;
}
@ -74,16 +76,20 @@
- initTextCell:(NSString *)aString
{
[super initTextCell:aString];
alt_contents = @"Button";
cell_type = NSMomentaryPushButton;
altContents = @"Button";
[self setButtonType:NSMomentaryPushButton];
[self setEnabled:YES];
transparent = NO;
[self setTransparent:NO];
[self setBordered:YES];
return self;
}
- (void)dealloc
{
[altContents release];
[altImage release];
[keyEquivalent release];
[keyEquivalentFont release];
[super dealloc];
}
@ -92,12 +98,12 @@
//
- (NSString *)alternateTitle
{
return alt_contents;
return altContents;
}
- (void)setAlternateTitle:(NSString *)aString
{
alt_contents = aString;
altContents = [aString copy];
// update our state
[self setState:[self state]];
}
@ -124,7 +130,7 @@
//
- (NSImage *)alternateImage
{
return alt_image;
return altImage;
}
- (NSCellImagePosition)imagePosition
@ -134,7 +140,7 @@
- (void)setAlternateImage:(NSImage *)anImage
{
alt_image = anImage;
altImage = [anImage retain];
}
- (void)setImagePosition:(NSCellImagePosition)aPosition
@ -158,40 +164,43 @@
//
- (NSString *)keyEquivalent
{
return nil;
return keyEquivalent;
}
- (NSFont *)keyEquivalentFont
{
return nil;
return keyEquivalentFont;
}
- (unsigned int)keyEquivalentModifierMask
{
return 0;
return keyEquivalentModifierMask;
}
- (void)setKeyEquivalent:(NSString *)aKeyEquivalent
{}
- (void)setKeyEquivalent:(NSString *)key
{
keyEquivalent = [key copy];
}
- (void)setKeyEquivalentModifierMask:(unsigned int)mask
{}
{
keyEquivalentModifierMask = mask;
}
- (void)setKeyEquivalentFont:(NSFont *)fontObj
{}
{
keyEquivalentFont = [fontObj retain];
}
- (void)setKeyEquivalentFont:(NSString *)fontName
size:(float)fontSize
{}
{
keyEquivalentFont = [[NSFont fontWithName:fontName size:fontSize] retain];
}
//
// Modifying Graphic Attributes
//
- (BOOL)isOpaque
{
return NO;
}
- (BOOL)isTransparent
{
return transparent;
@ -202,23 +211,64 @@
transparent = flag;
}
- (BOOL)isOpaque
{
return !transparent && [self isBordered];
}
//
// Modifying Graphic Attributes
//
- (int)highlightsBy
{
return 0;
return highlightsByMask;
}
- (void)setHighlightsBy:(int)aType
{}
- (void)setShowsStateBy:(int)aType
{}
- (void)setType:(NSButtonType)aType
- (void)setHighlightsBy:(int)mask
{
cell_type = aType;
highlightsByMask = mask;
}
- (void)setShowsStateBy:(int)mask
{
showAltStateMask = mask;
}
- (void)setButtonType:(NSButtonType)buttonType
{
[super setType:buttonType];
switch (buttonType) {
case NSMomentaryLight:
[self setHighlightsBy:NSChangeBackgroundCellMask];
[self setShowsStateBy:NSNoCellMask];
break;
case NSMomentaryPushButton:
[self setHighlightsBy:NSPushInCellMask | NSChangeGrayCellMask];
[self setShowsStateBy:NSNoCellMask];
break;
case NSMomentaryChangeButton:
[self setHighlightsBy:NSContentsCellMask];
[self setShowsStateBy:NSNoCellMask];
break;
case NSPushOnPushOffButton:
[self setHighlightsBy:NSPushInCellMask | NSChangeGrayCellMask];
[self setShowsStateBy:NSChangeBackgroundCellMask];
break;
case NSOnOffButton:
[self setHighlightsBy:NSChangeBackgroundCellMask];
[self setShowsStateBy:NSChangeBackgroundCellMask];
break;
case NSToggleButton:
[self setHighlightsBy:NSPushInCellMask | NSContentsCellMask];
[self setShowsStateBy:NSContentsCellMask];
break;
case NSSwitchButton:
case NSRadioButton:
[self setHighlightsBy:NSContentsCellMask];
[self setShowsStateBy:NSContentsCellMask];
break;
}
// update our state
[self setState:[self state]];
@ -226,14 +276,28 @@
- (int)showsStateBy
{
return 0;
return showAltStateMask;
}
- (void)setState:(int)value
- (void)setIntValue:(int)anInt
{
[super setState:value];
[self setState:(anInt != 0)];
}
- (void)setFloatValue:(float)aFloat
{
[self setState:(aFloat != 0)];
}
- (void)setDoubleValue:(double)aDouble
{
[self setState:(aDouble != 0)];
}
- (int)intValue { return [self state]; }
- (float)floatValue { return [self state]; }
- (double)doubleValue { return [self state]; }
//
// Displaying
//
@ -259,8 +323,8 @@
[super encodeWithCoder:aCoder];
NSDebugLog(@"NSButtonCell: start encoding\n");
[aCoder encodeObject: alt_contents];
[aCoder encodeObject: alt_image];
[aCoder encodeObject: altContents];
[aCoder encodeObject: altImage];
[aCoder encodeValueOfObjCType: @encode(BOOL) at: &transparent];
NSDebugLog(@"NSButtonCell: finish encoding\n");
}
@ -270,8 +334,8 @@
[super initWithCoder:aDecoder];
NSDebugLog(@"NSButtonCell: start decoding\n");
alt_contents = [aDecoder decodeObject];
alt_image = [aDecoder decodeObject];
altContents = [aDecoder decodeObject];
altImage = [aDecoder decodeObject];
[aDecoder decodeValueOfObjCType: @encode(BOOL) at: &transparent];
NSDebugLog(@"NSButtonCell: finish decoding\n");
return self;

View file

@ -25,9 +25,9 @@
Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
*/
#include <gnustep/gui/NSCStringText.h>
#include <gnustep/gui/NSText.h>
#include <Foundation/NSCoder.h>
#include <AppKit/NSCStringText.h>
#include <AppKit/NSText.h>
//
// NSCStringText implementation

View file

@ -26,9 +26,14 @@
59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
*/
#include <gnustep/gui/NSCell.h>
#include <gnustep/gui/NSApplication.h>
#include <gnustep/gui/NSButton.h>
#include <Foundation/NSValue.h>
#include <AppKit/NSApplication.h>
#include <AppKit/NSImage.h>
#include <AppKit/NSFont.h>
#include <AppKit/NSView.h>
#include <AppKit/NSCell.h>
#include <AppKit/NSEvent.h>
#include <AppKit/LogFile.h>
@implementation NSCell
@ -92,7 +97,7 @@
cell_type = NSImageCellType;
cell_image = anImage;
image_position = NSImageOnly;
cell_font = [NSFont userFontOfSize:12];
cell_font = [[NSFont userFontOfSize:12] retain];
cell_state = NO;
cell_highlighted = NO;
cell_enabled = YES;
@ -116,7 +121,7 @@
//if (![aString isKindOfClass:[NSString class]])
// return nil;
cell_font = [NSFont userFontOfSize:12];
cell_font = [[NSFont userFontOfSize:12] retain];
contents = aString;
cell_type = NSTextCellType;
text_align = NSLeftTextAlignment;
@ -137,6 +142,14 @@
return self;
}
- (void)dealloc
{
[contents release];
[cell_image release];
[cell_font release];
[super dealloc];
}
//
// Determining Component Sizes
//
@ -222,7 +235,7 @@
return;
// Only set the image if we are an image cell
cell_image = anImage;
cell_image = [anImage retain];
}
//
@ -245,48 +258,28 @@
- (NSString *)stringValue
{
return [NSString stringWithCString: [contents cString]];
return contents;
}
- (void)setDoubleValue:(double)aDouble
{
char c[256];
unsigned int w = cell_float_left + cell_float_right;
NSNumber* number = [NSNumber numberWithDouble:aDouble];
// Default printf formatting
if (cell_float_left == 0)
sprintf(c, "%f", aDouble);
else
if (cell_float_autorange)
sprintf(c, "%*f", w, aDouble);
else
sprintf(c, "%*.*f", w, cell_float_right, aDouble);
contents = [NSString stringWithCString:c];
contents = [[number stringValue] retain];
}
- (void)setFloatValue:(float)aFloat
{
char c[256];
unsigned int w = cell_float_left + cell_float_right;
NSNumber* number = [NSNumber numberWithFloat:aFloat];
// Default printf formatting
if (cell_float_left == 0)
sprintf(c, "%f", aFloat);
else
if (cell_float_autorange)
sprintf(c, "%*f", w, aFloat);
else
sprintf(c, "%*.*f", w, cell_float_right, aFloat);
contents = [NSString stringWithCString:c];
contents = [[number stringValue] retain];
}
- (void)setIntValue:(int)anInt
{
char c[256];
sprintf(c, "%d", anInt);
contents = [NSString stringWithCString:c];
NSNumber* number = [NSNumber numberWithInt:anInt];
contents = [[number stringValue] retain];
}
- (void)setStringValue:(NSString *)aString
@ -294,7 +287,7 @@
if (!aString)
contents = @"";
else
contents = [NSString stringWithCString: [aString cString]];
contents = [aString copy];
}
//
@ -367,7 +360,7 @@
if (![fontObject isKindOfClass:[NSFont class]])
return;
cell_font = fontObject;
cell_font = [fontObject retain];
}
- (void)setSelectable:(BOOL)flag
@ -618,8 +611,7 @@
NSPoint point = [controlView convertPoint: location fromView: nil];
NSPoint last_point;
BOOL done;
NSRect r;
BOOL untilMU, mouseWentUp;
BOOL mouseWentUp;
NSDebugLog(@"NSCell start tracking\n");
NSDebugLog(@"NSCell tracking in rect %f %f %f %f\n",
@ -645,8 +637,11 @@
last_point = point;
e = [theApp nextEventMatchingMask:event_mask untilDate:nil
inMode:nil dequeue:YES];
// What is going on here? After the following statement location
// should be in the window coordinates, but is in the receiving
// view's coordinate.
location = [e locationInWindow];
point = [controlView convertPoint: location fromView: nil];
// point = [controlView convertPoint: location fromView: nil];
NSDebugLog(@"NSCell location %f %f\n", location.x, location.y);
NSDebugLog(@"NSCell point %f %f\n", point.x, point.y);
@ -733,8 +728,6 @@
//
- (void)encodeWithCoder:aCoder
{
[super encodeWithCoder:aCoder];
[aCoder encodeObject: contents];
[aCoder encodeObject: cell_image];
[aCoder encodeObject: cell_font];
@ -754,13 +747,15 @@
[aCoder encodeValueOfObjCType: "i" at: &cell_type];
[aCoder encodeValueOfObjCType: @encode(NSTextAlignment) at: &text_align];
[aCoder encodeValueOfObjCType: "i" at: &entry_type];
#if 0
[aCoder encodeObjectReference: control_view withName: @"Control view"];
#else
[aCoder encodeConditionalObject:control_view];
#endif
}
- initWithCoder:aDecoder
{
[super initWithCoder:aDecoder];
contents = [aDecoder decodeObject];
cell_image = [aDecoder decodeObject];
cell_font = [aDecoder decodeObject];
@ -780,8 +775,11 @@
[aDecoder decodeValueOfObjCType: "i" at: &cell_type];
[aDecoder decodeValueOfObjCType: @encode(NSTextAlignment) at: &text_align];
[aDecoder decodeValueOfObjCType: "i" at: &entry_type];
#if 0
[aDecoder decodeObjectAt: &control_view withName: NULL];
#else
control_view = [aDecoder decodeObject];
#endif
return self;
}

View file

@ -26,7 +26,7 @@
59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
*/
#include <gnustep/gui/NSClipView.h>
#include <AppKit/NSClipView.h>
@implementation NSClipView

View file

@ -26,9 +26,9 @@
59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
*/
#include <gnustep/gui/NSColor.h>
#include <gnustep/gui/NSColorPrivate.h>
#include <gnustep/gui/NSView.h>
#include <AppKit/NSColor.h>
#include <AppKit/NSColorPrivate.h>
#include <AppKit/NSView.h>
// Class variables
static BOOL gnustep_gui_ignores_alpha = YES;
@ -582,8 +582,6 @@ const float NSWhite = 1;
//
- (void)encodeWithCoder:aCoder
{
[super encodeWithCoder:aCoder];
// Version 1
[aCoder encodeValueOfObjCType: "f" at: &RGB_component.red];
[aCoder encodeValueOfObjCType: "f" at: &RGB_component.green];
@ -609,7 +607,6 @@ const float NSWhite = 1;
- initWithCoder:aDecoder
{
NSString *s;
[super initWithCoder:aDecoder];
// Version 1
[aDecoder decodeValueOfObjCType: "f" at: &RGB_component.red];
@ -619,7 +616,7 @@ const float NSWhite = 1;
[aDecoder decodeValueOfObjCType: @encode(BOOL) at: &is_clear];
// Get our class name
s = [NSString stringWithCString: object_get_class_name(self)];
s = NSStringFromClass(isa);
// Version 2
// +++ Coding cannot return class version yet

View file

@ -26,11 +26,13 @@
59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
*/
#include <gnustep/gui/NSColorList.h>
#include <Foundation/NSNotification.h>
#include <Foundation/NSLock.h>
#include <Foundation/NSDictionary.h>
#include <Foundation/NSArchiver.h>
#include <Foundation/NSException.h>
#include <AppKit/NSColorList.h>
#include <AppKit/AppKitExceptions.h>
// NSColorList notifications
NSString *NSColorListChangedNotification = @"NSColorListChange";
@ -86,7 +88,8 @@ static NSLock *gnustep_color_list_lock;
//
+ (NSColorList *)colorListNamed:(NSString *)name
{
id o, e;
id e;
NSColorList* o;
BOOL found = NO;
// Serialize access to color list
@ -288,7 +291,6 @@ static NSLock *gnustep_color_list_lock;
//
- (void)encodeWithCoder:aCoder
{
[super encodeWithCoder:aCoder];
[aCoder encodeObject: list_name];
[aCoder encodeObject: color_list];
[aCoder encodeObject: color_list_keys];
@ -297,7 +299,6 @@ static NSLock *gnustep_color_list_lock;
- initWithCoder:aDecoder
{
[super initWithCoder:aDecoder];
list_name = [aDecoder decodeObject];
color_list = [aDecoder decodeObject];
color_list_keys = [aDecoder decodeObject];

Some files were not shown because too many files have changed in this diff Show more