Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
{
"## Comment" = "Do NOT change this file, Gorm maintains it";
GormLayeredInspectorController = {
Actions = (
);
Outlets = (
"_tableView"
);
Super = NSViewController;
};
}
Binary file not shown.
Binary file not shown.
4 changes: 3 additions & 1 deletion Applications/Gorm/GNUmakefile
Original file line number Diff line number Diff line change
Expand Up @@ -155,11 +155,13 @@ Gorm_LANGUAGES = \

Gorm_HEADERS = \
GormAppDelegate.h \
GormLanguageViewController.h
GormLanguageViewController.h \
GormLayeredInspectorController.h

Gorm_OBJC_FILES = \
GormAppDelegate.m \
GormLanguageViewController.m \
GormLayeredInspectorController.m \
main.m

-include GNUmakefile.preamble
Expand Down
36 changes: 36 additions & 0 deletions Applications/Gorm/GormLayeredInspectorController.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
/* GormLayeredInspectorController.h
*
* Copyright (C) 2025 Free Software Foundation, Inc.
*
* Author: Gregory John Casamento <[email protected]>
* Date: 2025
*
* This file is part of GNUstep.
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 3 of the License, or
* (at your option) any later version.
*
* This program 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 General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111 USA.
*/

#ifndef GormLayeredInspectorController_H_INCLUDE
#define GormLayeredInspectorController_H_INCLUDE

#import <AppKit/NSViewController.h>

@interface GormLayeredInspectorController : NSViewController
{
IBOutlet id _tableView;
}
@end

#endif // GormLayeredInspectorController_H_INCLUDE
46 changes: 46 additions & 0 deletions Applications/Gorm/GormLayeredInspectorController.m
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
/* GormLayeredInspectorController.h
*
* Copyright (C) 2025 Free Software Foundation, Inc.
*
* Author: Gregory John Casamento <[email protected]>
* Date: 2025
*
* This file is part of GNUstep.
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 3 of the License, or
* (at your option) any later version.
*
* This program 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 General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111 USA.
*/

#import <AppKit/NSTableView.h>
#import "GormLayeredInspectorController.h"

@implementation GormLayeredInspectorController

// Data source

- (NSInteger) numberOfRowsInTableView: (NSTableView *)tableView
{
return 0; // get all inspectors for the selection...
}

// Delegate

- (NSView *) tableView: (NSTableView *)tableView
viewForTableColumn: (NSTableColumn *)tableColumn
row: (NSInteger)row
{
return nil; // given the class and all subclasses, find all inspectors...
}

@end
11 changes: 10 additions & 1 deletion Applications/Gorm/Palettes/0Menus/inspectors.m
Original file line number Diff line number Diff line change
Expand Up @@ -30,17 +30,23 @@

@implementation NSMenu (IBObjectAdditions)

/**
* Inspector for menu attributes
*/
- (NSString*) inspectorClassName
{
return @"GormMenuAttributesInspector";
}

/**
* Menu editor class
*/
- (NSString*) editorClassName
{
return @"GormMenuEditor";
}

/*
/**
* Method to return the image that should be used to display menus within
* the matrix containing the objects in a document.
*/
Expand All @@ -61,6 +67,9 @@ - (NSImage*) imageForViewer

@implementation NSMenuItem (IBObjectAdditions)

/**
* Inspector class for NSMenuItem instances.
*/
- (NSString*) inspectorClassName
{
return @"GormMenuItemAttributesInspector";
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,8 @@
columnSelectionSwitch,
drawgridSwitch,
resizingSwitch,
reorderingSwitch
reorderingSwitch,
viewBased
);
Super = IBInspector;
};
Expand Down
Binary file not shown.
Binary file not shown.
Binary file modified GormCore/English.lproj/GormSoundInspector.gorm/data.info
Binary file not shown.
Binary file modified GormCore/English.lproj/GormSoundInspector.gorm/objects.gorm
Binary file not shown.
10 changes: 7 additions & 3 deletions GormCore/GormInspectorsManager.h
Original file line number Diff line number Diff line change
Expand Up @@ -40,21 +40,25 @@
@interface GormInspectorsManager : IBInspectorManager
{
IBOutlet NSPanel *panel;
NSMutableDictionary *cache;
IBOutlet NSPopUpButton *popup;
IBOutlet NSBox *selectionView;
IBOutlet NSBox *inspectorView;
IBOutlet IBInspector *inspector;

NSMutableDictionary *cache;
NSView *buttonView;
NSString *oldInspector;
IBOutlet IBInspector *inspector;
int current;
BOOL hiddenDuringTest;
NSRect origFrame;
}
- (NSPanel*) panel;

- (NSPanel *) panel;
- (void) setClassInspector;
- (void) setCurrentInspector: (id)anObject;
- (void) updateSelection;
- (NSArray *) inspectorsForObject: (id)anObject mode: (NSString *)mode;

@end

#endif
6 changes: 6 additions & 0 deletions GormCore/GormInspectorsManager.m
Original file line number Diff line number Diff line change
Expand Up @@ -493,4 +493,10 @@ - (void) setCurrentInspector: (id)anObj
// inspect the object.
[inspector setObject: [currentMode object]];
}

- (NSArray *) inspectorsForObject: (id)anObject mode: (NSString *)mode
{

}

@end
26 changes: 26 additions & 0 deletions GormCore/GormObjectEditor.m
Original file line number Diff line number Diff line change
Expand Up @@ -84,6 +84,32 @@ - (NSString*) editorClassName
return @"GormObjectEditor";
}

// Class level inspector methods...
+ (NSString*) inspectorClassName
{
return @"GormObjectInspector";
}

+ (NSString*) connectInspectorClassName
{
return @"GormConnectionInspector";
}

+ (NSString*) sizeInspectorClassName
{
return @"GormNotApplicableInspector";
}

+ (NSString*) helpInspectorClassName
{
return @"GormNotApplicableInspector";
}

+ (NSString*) classInspectorClassName
{
return @"GormCustomClassInspector";
}

@end

@implementation NSView (GormObjectAdditions)
Expand Down
18 changes: 15 additions & 3 deletions GormCore/GormSoundView.h
Original file line number Diff line number Diff line change
Expand Up @@ -26,12 +26,24 @@

/* All Rights reserved */

#include <AppKit/AppKit.h>
#include <Cocoa/Cocoa.h>

@interface GormSoundView : NSView
{
short *_samples;
NSUInteger _sampleCount;
float _sampleRate;
NSSound *_sound;
}
- (void)setSound: (NSSound *)sound;
- (NSSound *)sound;

- (void)setSamples:(short *)newSamples
sampleCount:(NSUInteger)count
sampleRate:(float)rate;

- (BOOL)loadFromSound:(NSSound *)sound;

- (void) setSound: (NSSound *)sound;

- (NSSound *) sound;

@end
Loading
Loading