Commit 99550d9e authored by Eric Heintzmann's avatar Eric Heintzmann

Import Upstream version 1.2.8

parent 9ebba0d7
1 ANNOUNCE
**********
This is version 1.2.3 of Gorm.
This is version 1.2.8 of Gorm.
1.1 What is Gorm?
=================
......@@ -12,22 +12,20 @@ GNUstep Object Relationship Modeler).
Gorm is a clone of the NeXTstep `Interface Builder' application for
GNUstep.
1.2 Noteworthy changes in version `1.2.4'
1.2 Noteworthy changes in version `1.2.8'
=========================================
Requires: gnustep-gui-0.13.2. Reason: Due to changes in popupbutton
controller logic.
Requires: gnustep-gui-0.16.0. It will not compile without this version
of the library. Reason: Nib and Gorm loading were moved to a more
sensible file structure. Additionally, Nib loading was refactored.
* Corrected bug#'s 19640, 21845, 19792, 15637, 17892, 18171.
* Correction for bug#25001.
* Added error panel to show the detected inconsistencies in a file.
* Correction for bug#25111.
* Added preference setting to turn on or off the gorm file repair
logic.
* Fixes for nib encoding to use the proper template class instances.
* Added capability to repair logic to fix window level issue.
* Added ruler switch to scroll view inspector.
* Changes to use new headers.
1.3 How can I get support for this software?
============================================
......
This diff is collapsed.
This diff is collapsed.
PACKAGE_NAME = gorm
include $(GNUSTEP_MAKEFILES)/common.make
include ../Version
......
......@@ -4,6 +4,33 @@
@include version.texi
@end ifset
@section Noteworthy changes in version @samp{1.2.8}
Requires: gnustep-gui-0.16.0. It will not compile without this version of the library.
Reason: Nib and Gorm loading were moved to a more sensible file structure. Additionally, Nib loading was refactored.
@itemize @bullet
@item Correction for bug#25001.
@item Correction for bug#25111.
@item Fixes for nib encoding to use the proper template class instances.
@item Changes to use new headers.
@end itemize
@ifclear ANNOUNCE-ONLY
@c ====================================================================
@c Keep the next line just below the list of changes in most recent version.
@section Noteworthy changes in version @samp{1.2.6}
@itemize @bullet
@item Corrections to allow Gorm to build and run properly on the Darwin operating system.
@item Corrected sizing of Controls Palette.
@item Added preliminary support for IBPlugin API.
@item Added preferences panel to add plugins dynamically.
@item Moved load/save logic for gorm, gmodel, and nib to plugins. This change should allow plugins for virtually any format to be read/written by Gorm.
@item Correction for bug#24146, bug#23889.
@end itemize
@section Noteworthy changes in version @samp{1.2.4}
Requires: gnustep-gui-0.13.2.
......@@ -17,10 +44,6 @@ Reason: Due to changes in popupbutton controller logic.
@item Added ruler switch to scroll view inspector.
@end itemize
@ifclear ANNOUNCE-ONLY
@c ====================================================================
@c Keep the next line just below the list of changes in most recent version.
@section Noteworthy changes in version @samp{1.2.2}
Requires: gnustep-gui-0.13.0.
......
......@@ -2,9 +2,10 @@
"## Comment" = "Do NOT change this file, Gorm maintains it";
FirstResponder = {
Actions = (
"alignSelectedObjects:",
"arrangeSelectedObjects:",
"exportStrings:",
"alignSelectedObjects:",
"newAction:",
"orderFrontFontPanel:",
"translate:"
);
......@@ -42,7 +43,8 @@
"createClassFiles:",
"loadClass:",
"preferencesPanel:",
"guideline:"
"guideline:",
"print:"
);
Outlets = (
gormMenu,
......
......@@ -34,6 +34,13 @@
);
Super = NSDocument;
};
GormDocumentWindow = {
Actions = (
);
Outlets = (
);
Super = NSWindow;
};
GormFilePrefsManager = {
Actions = (
"showIncompatibilities:",
......
{
"## Comment" = "Do NOT change this file, Gorm maintains it";
GormPaletteMatrix = {
Actions = (
);
Outlets = (
);
Super = NSMatrix;
};
GormPalettePanel = {
Actions = (
);
Outlets = (
);
Super = NSPanel;
};
GormPaletteView = {
Actions = (
);
Outlets = (
);
Super = NSView;
};
GormPalettesManager = {
Actions = (
);
Outlets = (
panel,
dragView,
selectionView
);
Super = NSObject;
};
}
\ No newline at end of file
{
"## Comment" = "Do NOT change this file, Gorm maintains it";
FirstResponder = {
Actions = (
"orderFrontFontPanel:",
"removeAction:",
"addAction:"
);
Super = NSObject;
};
GormPluginsPref = {
Actions = (
"removeAction:",
"addAction:"
);
Outlets = (
_view,
window,
removeButton,
addButton,
table
);
Super = NSObject;
};
PluginDataSource = {
Actions = (
);
Outlets = (
);
Super = NSObject;
};
}
\ No newline at end of file
......@@ -24,9 +24,8 @@
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
#
# Put in the system directory...
GNUSTEP_INSTALLATION_DOMAIN=SYSTEM
PACKAGE_NAME = gorm
export PACKAGE_NAME
include $(GNUSTEP_MAKEFILES)/common.make
CVS_MODULE_NAME = gorm
......@@ -34,7 +33,6 @@ SVN_MODULE_NAME = gorm
SVN_BASE_URL = svn+ssh://svn.gna.org/svn/gnustep/apps
PACKAGE_NAME=gorm
include ./Version
#
......@@ -64,6 +62,9 @@ Gorm_RESOURCE_FILES = \
Palettes/2Controls/2Controls.palette \
Palettes/3Containers/3Containers.palette \
Palettes/4Data/4Data.palette \
Plugins/Gorm/Gorm.plugin \
Plugins/Nib/Nib.plugin \
Plugins/GModel/GModel.plugin \
Images/GormClass.tiff \
Images/GormFilesOwner.tiff \
Images/GormFirstResponder.tiff \
......@@ -149,12 +150,14 @@ Gorm_LOCALIZED_RESOURCE_FILES = \
GormInspectorPanel.gorm \
GormObjectInspector.gorm \
GormNSSplitViewInspector.gorm \
GormPalettePanel.gorm \
GormPrefColors.gorm \
GormPreferences.gorm \
GormPrefGeneral.gorm \
GormPrefGuideline.gorm \
GormPrefHeaders.gorm \
GormPrefPalettes.gorm \
GormPrefPlugins.gorm \
GormScrollViewAttributesInspector.gorm \
GormSetName.gorm \
GormShelfPref.gorm \
......
......@@ -30,6 +30,7 @@
#include <GormCore/GormFontViewController.h>
#include <GormCore/GormSetNameController.h>
#include <GormCore/GormFunctions.h>
#include <GormCore/GormPluginManager.h>
#include <GNUstepBase/GSObjCRuntime.h>
#include <GormPrefs/GormPrefController.h>
......@@ -39,6 +40,7 @@
GormClassManager *classManager;
GormInspectorsManager *inspectorsManager;
GormPalettesManager *palettesManager;
GormPluginManager *pluginManager;
id<IBSelectionOwners> selectionOwner;
NSMutableArray *documents;
BOOL isConnecting;
......@@ -56,11 +58,7 @@
NSImage *gormImage;
NSImage *testingImage;
id connectSource;
NSWindow *connectSWindow;
NSRect connectSRect;
id connectDestination;
NSWindow *connectDWindow;
NSRect connectDRect;
NSPoint cascadePoint;
NSMutableArray *testingWindows;
NSSet *topObjects;
......@@ -137,10 +135,12 @@
}
/*
* Make sure the palettes manager exists, so that the editors and
* inspectors provided in the standard palettes are available.
* Make sure the palettes/plugins managers exist, so that the
* editors and inspectors provided in the standard palettes
* are available.
*/
[self palettesManager];
[self pluginManager];
/*
* set the delegate.
......@@ -959,6 +959,15 @@
return palettesManager;
}
- (GormPluginManager*) pluginManager
{
if (pluginManager == nil)
{
pluginManager = [[GormPluginManager alloc] init];
}
return pluginManager;
}
- (id<IBSelectionOwners>) selectionOwner
{
return (id<IBSelectionOwners>)selectionOwner;
......@@ -1243,20 +1252,6 @@
return classMenu;
}
- (void) unhide: (id)sender
{
[super unhide: sender];
if(!isTesting)
{
id document = [self activeDocument];
id window = [document window];
[(GormDocument *)document setDocumentActive: NO];
[(GormDocument *)document setDocumentActive: YES];
[window orderFront: sender];
[[self mainMenu] display];
}
}
- (BOOL) documentNameIsUnique: (NSString *)filename
{
NSEnumerator *en = [documents objectEnumerator];
......@@ -1275,4 +1270,9 @@
return unique;
}
- (void) print: (id) sender
{
[[self keyWindow] print: sender];
}
@end
......@@ -24,8 +24,10 @@
# Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA
#
PACKAGE_NAME = gorm
include $(GNUSTEP_MAKEFILES)/common.make
PACKAGE_NAME=GormCore
LIBRARY_VAR=GORMCORE
LIBRARY_NAME=GormCore
......@@ -68,6 +70,8 @@ GormCore_HEADER_FILES = \
GormOutlineView.h \
GormPalettesManager.h \
GormPlacementInfo.h \
GormPlugin.h \
GormPluginManager.h \
GormPrivate.h \
GormProtocol.h \
GormResource.h \
......@@ -113,23 +117,20 @@ GormCore_OBJC_FILES = \
GormFunctions.m \
GormGenericEditor.m \
GormHelpInspector.m \
GormGormWrapperBuilder.m \
GormGormWrapperLoader.m \
GormGModelWrapperLoader.m \
GormImage.m \
GormImageEditor.m \
GormImageInspector.m \
GormInspectorsManager.m \
GormInternalViewEditor.m \
GormMatrixEditor.m \
GormNibWrapperBuilder.m \
GormNibWrapperLoader.m \
GormNSSplitViewInspector.m \
GormObjectEditor.m \
GormObjectInspector.m \
GormOpenGLView.m \
GormOutlineView.m \
GormPalettesManager.m \
GormPlugin.m \
GormPluginManager.m \
GormResource.m \
GormResourceEditor.m \
GormResourceManager.m \
......
......@@ -35,4 +35,6 @@ else
ADDITIONAL_LIB_DIRS += \
-L../GormLib/$(GNUSTEP_OBJ_DIR) \
-L../GormObjCHeaderParser/$(GNUSTEP_OBJ_DIR)
endif
\ No newline at end of file
endif
GormCore_LIBRARIES_DEPEND_UPON += -lGormObjCHeaderParser
......@@ -31,8 +31,8 @@
#include <AppKit/NSFont.h>
#include <AppKit/NSNibLoading.h>
#include <GNUstepGUI/GSNibTemplates.h>
#include <GNUstepGUI/GSNibCompatibility.h>
#include <GNUstepGUI/GSGormLoading.h>
#include <GNUstepGUI/GSNibLoading.h>
@class GSCustomView;
......@@ -105,46 +105,83 @@
return cls;
}
- (BOOL) classNameIsSet
{
if([className isEqualToString: @"CustomView"] ||
[className isEqualToString: @""] || className == nil)
{
return NO;
}
return YES;
}
/*
- (Class) classForCoder
{
if([self _classNameIsSet])
{
return [NSView class];
}
return [self class];
}
*/
/*
* This needs to be coded like a GSNibItem. How do we make sure this
* tracks changes in GSNibItem coding?
*/
- (void) encodeWithCoder: (NSCoder*)aCoder
{
if([aCoder allowsKeyedCoding])
/*
if([self _classNameIsSet])
{
GormClassManager *classManager = [(id<Gorm>)NSApp classManager];
NSString *extension = nil;
ASSIGNCOPY(extension,[classManager nonCustomSuperClassOf: className]);
[aCoder encodeObject: className forKey: @"NSClassName"];
[aCoder encodeRect: [self frame] forKey: @"NSFrame"];
if(extension != nil)
{
[aCoder encodeObject: extension forKey: @"NSExtension"];
}
if([self nextResponder] != nil)
*/
if([aCoder allowsKeyedCoding])
{
[aCoder encodeObject: [self nextResponder] forKey: @"NSNextResponder"];
GormClassManager *classManager = [(id<Gorm>)NSApp classManager];
NSString *extension = nil;
ASSIGNCOPY(extension,[classManager nonCustomSuperClassOf: className]);
[aCoder encodeObject: className forKey: @"NSClassName"];
[aCoder encodeRect: [self frame] forKey: @"NSFrame"];
if(extension != nil)
{
[aCoder encodeObject: extension forKey: @"NSExtension"];
}
if([self nextResponder] != nil)
{
[aCoder encodeObject: [self nextResponder] forKey: @"NSNextResponder"];
}
if([self superview] != nil)
{
[aCoder encodeObject: [self superview] forKey: @"NSSuperview"];
}
RELEASE(extension);
}
if([self superview] != nil)
else
{
[aCoder encodeObject: [self superview] forKey: @"NSSuperview"];
[aCoder encodeObject: [self stringValue]];
[aCoder encodeRect: _frame];
[aCoder encodeValueOfObjCType: @encode(unsigned int)
at: &_autoresizingMask];
}
RELEASE(extension);
/*
}
else
{
[aCoder encodeObject: [self stringValue]];
[aCoder encodeRect: _frame];
[aCoder encodeValueOfObjCType: @encode(unsigned int)
at: &_autoresizingMask];
if([aCoder allowsKeyedCoding] == NO)
{
NSView *temp = [[NSView alloc] initWithFrame: [self frame]];
[temp setNextResponder: [self nextResponder]];
[(NSArchiver *)aCoder replaceObject: self withObject: temp];
}
}
*/
}
- (id) initWithCoder: (NSCoder*)aCoder
......
......@@ -41,7 +41,7 @@
#include <AppKit/NSSound.h>
#include <AppKit/NSNibConnector.h>
#include <AppKit/NSNibLoading.h>
#include <GNUstepGUI/GSNibTemplates.h>
#include <GNUstepGUI/GSGormLoading.h>
#include "NSView+GormExtensions.h"
#include "GormSound.h"
#include "GormImage.h"
......@@ -341,6 +341,7 @@ static NSImage *fileImage = nil;
// set up the toolbar...
toolbar = [(NSToolbar *)[NSToolbar alloc] initWithIdentifier: @"GormToolbar"];
[toolbar setAllowsUserCustomization: NO];
// [toolbar setSizeMode: NSToolbarSizeModeSmall];
[toolbar setDelegate: self];
[window setToolbar: toolbar];
RELEASE(toolbar);
......@@ -779,6 +780,20 @@ static NSImage *fileImage = nil;
id v = [ti view];
[self attachObject: v toParent: ti];
}
/*
* If it's a matrix, add the elements of the matrix.
*/
else if ([anObject isKindOfClass: [NSMatrix class]])
{
NSCell *cell = nil;
NSEnumerator *en = [[anObject cells] objectEnumerator];
// add all of the cells....
while((cell = [en nextObject]) != nil)
{
[self attachObject: cell toParent: anObject];
}
}
/*
* If it's a simple NSView, add it and all of it's subviews.
*/
......@@ -1160,6 +1175,18 @@ static NSImage *fileImage = nil;
NSDebugLog(@"Owner changed for %@", sender);
}
- (void) release
{
[super release];
}
- (id) retain
{
[super retain];
NSDebugLog(@"Retaining document, retain count %d",[self retainCount]);
return self;
}
/**
* Dealloc all things owned by a GormDocument object.
*/
......@@ -1167,15 +1194,14 @@ static NSImage *fileImage = nil;
{
[[NSNotificationCenter defaultCenter] removeObserver: self];
ASSIGN(lastEditor, nil);
// [filePrefsWindow close];
// Get rid of the selection box.
[selectionBox removeFromSuperviewWithoutNeedingDisplay];
// [selectionBox removeFromSuperviewWithoutNeedingDisplay];
RELEASE(classManager);
RELEASE(filePrefsManager);
RELEASE(filePrefsView);
RELEASE(savedEditors);
RELEASE(openEditors);
RELEASE(hidden);
if (objToName != 0)
......@@ -1196,6 +1222,8 @@ static NSImage *fileImage = nil;
RELEASE(topLevelObjects);
RELEASE(visibleWindows);
RELEASE(deferredWindows);
DESTROY(savedEditors);
DESTROY(openEditors);
TEST_RELEASE(scmWrapper);
[super dealloc];
......@@ -2806,10 +2834,10 @@ static void _real_close(GormDocument *self,
*/
- (NSString *) description
{
return [NSString stringWithFormat: @"<%s: %lx> = %@",
return [NSString stringWithFormat: @"<%s: %lx> = <<name table: %@, connections: %@>>",
GSClassNameFromObject(self),
(unsigned long)self,
nameTable];
nameTable, connections];
}
/**
......
......@@ -31,7 +31,7 @@
/* All Rights reserved */
#include <AppKit/AppKit.h>
#include <GNUstepGUI/GSNibTemplates.h>
#include <GNUstepGUI/GSGormLoading.h>
#include "GormFilePrefsManager.h"
#include "GormFunctions.h"
#include "GormDocument.h"
......@@ -85,7 +85,7 @@ NSString *formatVersion(int version)
+ (int) currentVersion
{
return appVersion(1,2,4);
return appVersion(1,2,8);
}
- (void) awakeFromNib
......
......@@ -81,6 +81,7 @@
// private methods...
@interface GormGenericEditor (PrivateMethods)
- (void) willCloseDocument: (NSNotification *) aNotification;
- (void) groupSelectionInScrollView;
- (void) groupSelectionInSplitView;
- (void) groupSelectionInBox;
......
......@@ -122,6 +122,11 @@
return YES;
}
- (void) willCloseDocument: (NSNotification *)aNotification
{
document = nil;
}
- (void) close
{
if(closed == NO)
......@@ -147,11 +152,18 @@
{
if((self = [super init]) != nil)
{
// don't retain the document...
/* don't retain the document... */
document = aDocument;
closed = NO;
activated = NO;
resourceManager = nil;
/* since we don't retain the document handle its close notifications */
[[NSNotificationCenter defaultCenter]
addObserver: self
selector: @selector(willCloseDocument:)
name: IBWillCloseDocumentNotification
object: document];
}
return self;
}
......
......@@ -2,7 +2,7 @@
#include <AppKit/AppKit.h>
#include "GormHelpInspector.h"
#include <GNUstepGUI/GSNibCompatibility.h>
#include <GNUstepGUI/GSNibLoading.h>
@implementation GormHelpInspector
- (id) init
......
......@@ -38,7 +38,7 @@ static NSMapTable *docMap = 0;
if (self == [GormImageEditor class])
{
docMap = NSCreateMapTable(NSNonRetainedObjectMapKeyCallBacks,
NSObjectMapValueCallBacks, 2);
NSNonRetainedObjectMapValueCallBacks, 2);
}
}
......@@ -126,8 +126,16 @@ static NSMapTable *docMap = 0;
// Once loaded, they are in the cache permanently and
// are release on app termination.
RELEASE(objects);
NSDebugLog(@"Released...");
// RELEASE(objects);
NSDebugLog(@"Released image editor...");
// GSNOSUPERDEALLOC;
[super dealloc];
}
- (void) willCloseDocument: (NSNotification *)aNotification
{
NSMapRemove(docMap,document);
[super willCloseDocument: aNotification];
}
- (void) close
......
......@@ -28,6 +28,7 @@
#include <InterfaceBuilder/IBInspectorMode.h>
#include <InterfaceBuilder/IBObjectAdditions.h>
#include <InterfaceBuilder/IBInspectorManager.h>
#include <InterfaceBuilder/IBDocuments.h>
#include "GormPrivate.h"