-
Notifications
You must be signed in to change notification settings - Fork 20
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
21 changed files
with
221 additions
and
16 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Binary file not shown.
Binary file not shown.
Binary file not shown.
16 changes: 16 additions & 0 deletions
16
Applications/Gorm/Palettes/5Boxes/BoxesPalette.gorm/data.classes
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
{ | ||
"## Comment" = "Do NOT change this file, Gorm maintains it"; | ||
BoxesPalette = { | ||
Actions = ( | ||
); | ||
Outlets = ( | ||
vview, | ||
hview, | ||
tview, | ||
vimage, | ||
himage, | ||
timage | ||
); | ||
Super = IBPalette; | ||
}; | ||
} |
Binary file not shown.
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
/* All Rights reserved */ | ||
|
||
#include <AppKit/AppKit.h> | ||
#include <InterfaceBuilder/InterfaceBuilder.h> | ||
|
||
@interface BoxesPalette : IBPalette | ||
{ | ||
id vview; | ||
id hview; | ||
id tview; | ||
id vimage; | ||
id himage; | ||
id timage; | ||
} | ||
@end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,50 @@ | ||
/* All Rights reserved */ | ||
|
||
#include <AppKit/AppKit.h> | ||
#include <GNUstepGUI/GSTable.h> | ||
#include "BoxesPalette.h" | ||
|
||
@interface GSTable (GormDrawingExtension) | ||
- (void) drawRect: (NSRect)rect; | ||
@end | ||
|
||
@implementation GSTable (GormDrawingExtension) | ||
- (void) drawRect: (NSRect)aRect | ||
{ | ||
// draw whatever the parent view contains. | ||
[super drawRect: aRect]; | ||
|
||
if([(id<IB>)NSApp isTestingInterface] == NO) | ||
{ | ||
CGFloat dot_dash[] = {1.0, 1.0}; | ||
NSGraphicsContext *ctxt = GSCurrentContext(); | ||
|
||
// Draw a green box; | ||
[[NSColor blueColor] set]; | ||
DPSsetlinewidth(ctxt, 1.0); | ||
DPSsetdash(ctxt, dot_dash, 4, 0.0); | ||
DPSrectstroke(ctxt, NSMinX(aRect) + 0.5, NSMinY(aRect) + 0.5, | ||
NSWidth(aRect) - 1.0, NSHeight(aRect) - 1.0); | ||
} | ||
} | ||
@end | ||
|
||
@implementation BoxesPalette | ||
|
||
- (void)finishInstantiate | ||
{ | ||
// make the associations... | ||
[self associateObject: tview | ||
type: IBViewPboardType | ||
with: timage]; | ||
|
||
[self associateObject: hview | ||
type: IBViewPboardType | ||
with: himage]; | ||
|
||
[self associateObject: vview | ||
type: IBViewPboardType | ||
with: vimage]; | ||
} | ||
|
||
@end |
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,49 @@ | ||
# GNUmakefile | ||
# | ||
# Copyright (C) 1999 Free Software Foundation, Inc. | ||
# | ||
# Author: Richard Frith-Macdonald <richard@brainstorm.co.uk> | ||
# Date: 1999 | ||
# | ||
# 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 2 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., 675 Mass Ave, Cambridge, MA 02139, USA. | ||
|
||
include $(GNUSTEP_MAKEFILES)/common.make | ||
|
||
PALETTE_NAME = 5Boxes | ||
5Boxes_PALETTE_ICON = BoxesPalette | ||
5Boxes_OBJC_FILES = \ | ||
BoxesPalette.m \ | ||
GSTableInspector.m | ||
|
||
5Boxes_PRINCIPAL_CLASS = BoxesPalette | ||
|
||
5Boxes_RESOURCE_FILES = \ | ||
BoxesPalette.tiff \ | ||
BoxesPalette.gorm \ | ||
GSTableInspector.gorm \ | ||
palette.table | ||
|
||
5Boxes_STANDARD_INSTALL = no | ||
|
||
-include GNUmakefile.preamble | ||
|
||
-include GNUmakefile.local | ||
|
||
include $(GNUSTEP_MAKEFILES)/palette.make | ||
|
||
-include GNUmakefile.postamble | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
# Additional include directories the compiler should search | ||
ADDITIONAL_INCLUDE_DIRS += -I../../ |
11 changes: 11 additions & 0 deletions
11
Applications/Gorm/Palettes/5Boxes/GSTableInspector.gorm/data.classes
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
{ | ||
"## Comment" = "Do NOT change this file, Gorm maintains it"; | ||
GSTableInspector = { | ||
Actions = ( | ||
); | ||
Outlets = ( | ||
matrix | ||
); | ||
Super = IBInspector; | ||
}; | ||
} |
Binary file not shown.
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
/* All Rights reserved */ | ||
|
||
#include <AppKit/AppKit.h> | ||
#include <InterfaceBuilder/InterfaceBuilder.h> | ||
|
||
@interface GSTableInspector : IBInspector | ||
{ | ||
id matrix; | ||
} | ||
@end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,49 @@ | ||
/* All Rights reserved */ | ||
|
||
#include <AppKit/AppKit.h> | ||
#include "GSTableInspector.h" | ||
#include <GNUstepGUI/GSTable.h> | ||
|
||
@implementation GSTable (IBObjectAdditions) | ||
- (NSString *)inspectorClassName | ||
{ | ||
return @"GSTableInspector"; | ||
} | ||
@end | ||
|
||
@implementation GSTableInspector | ||
|
||
- (id) init | ||
{ | ||
if ([super init] == nil) | ||
return nil; | ||
|
||
if ([NSBundle loadNibNamed: @"GSTableInspector" owner: self] == NO) | ||
{ | ||
NSLog(@"Could not load GSTableInspector"); | ||
return nil; | ||
} | ||
return self; | ||
} | ||
|
||
- (void) ok: (id)sender | ||
{ | ||
[super ok: sender]; | ||
NSLog(@"Testing..."); | ||
|
||
if(sender == matrix) | ||
{ | ||
[object setXBorder: [[sender cellAtIndex: 0] intValue]]; | ||
[object setYBorder: [[sender cellAtIndex: 1] intValue]]; | ||
[object setMinXBorder: [[sender cellAtIndex: 2] intValue]]; | ||
[object setMaxXBorder: [[sender cellAtIndex: 3] intValue]]; | ||
[object setMinYBorder: [[sender cellAtIndex: 4] intValue]]; | ||
[object setMaxYBorder: [[sender cellAtIndex: 5] intValue]]; | ||
} | ||
} | ||
|
||
- (void) setObject: (id)anobject | ||
{ | ||
[super setObject: anobject]; | ||
} | ||
@end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
{ | ||
NibFile = "BoxesPalette"; | ||
Class = "BoxesPalette"; | ||
Icon = "BoxesPalette"; | ||
ExportClasses = ("GSTable","GSVbox","GSHbox"); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters