diff --git a/Tools/AGSHtml.h b/Tools/AGSHtml.h
index e3c7f66c9b..b89e276e0e 100644
--- a/Tools/AGSHtml.h
+++ b/Tools/AGSHtml.h
@@ -43,12 +43,15 @@
NSString *nextFile; // Not retained
NSString *prevFile; // Not retained
NSString *upFile; // Not retained
+ NSString *fileName;
unsigned chap;
unsigned sect;
unsigned ssect;
unsigned sssect;
BOOL isContentsDoc;
BOOL ivarsAtEnd;
+ BOOL verbose;
+ BOOL warn;
}
- (void) decIndent;
- (void) incIndent;
@@ -68,7 +71,7 @@
style: (NSString*)style
target: (NSString*)target
to: (NSMutableString*)buf;
-- (NSString*) outputDocument: (GSXMLNode*)node;
+- (NSString*) outputDocument: (GSXMLNode*)node name: (NSString*)file;
- (void) outputNode: (GSXMLNode*)node to: (NSMutableString*)buf;
- (void) outputNodeList: (GSXMLNode*)node to: (NSMutableString*)buf;
- (GSXMLNode*) outputBlock: (GSXMLNode*)node
diff --git a/Tools/AGSHtml.m b/Tools/AGSHtml.m
index 1c78d54230..dbb6a7e8d9 100644
--- a/Tools/AGSHtml.m
+++ b/Tools/AGSHtml.m
@@ -22,11 +22,7 @@
#import "common.h"
-#import "Foundation/NSAutoreleasePool.h"
-#import "Foundation/NSArray.h"
-#import "Foundation/NSDictionary.h"
-#import "Foundation/NSSet.h"
-#import "Foundation/NSUserDefaults.h"
+#import "Foundation/Foundation.h"
#import "AGSHtml.h"
#import "GNUstepBase/NSString+GNUstepBase.h"
#import "GNUstepBase/NSMutableString+GNUstepBase.h"
@@ -108,6 +104,7 @@ - (void) dealloc
RELEASE(localRefs);
RELEASE(projectRefs);
RELEASE(indent);
+ RELEASE(fileName);
DEALLOC
}
@@ -128,9 +125,15 @@ - (void) incIndent
- (id) init
{
- indent = [[NSMutableString alloc] initWithCapacity: 64];
- project = RETAIN([[NSUserDefaults standardUserDefaults]
- stringForKey: @"Project"]);
+ if (nil != (self = [super init]))
+ {
+ NSUserDefaults *defs = [NSUserDefaults standardUserDefaults];
+
+ indent = [[NSMutableString alloc] initWithCapacity: 64];
+ project = RETAIN([defs stringForKey: @"Project"]);
+ verbose = [defs boolForKey: @"Verbose"];
+ warn = [defs boolForKey: @"Warn"];
+ }
return self;
}
@@ -281,10 +284,11 @@ - (NSString*) makeLink: (NSString*)r
return [s stringByReplacingString: @":" withString: @"$"];
}
-- (NSString*) outputDocument: (GSXMLNode*)node
+- (NSString*) outputDocument: (GSXMLNode*)node name: (NSString*)file
{
NSMutableString *buf;
+ ASSIGN(fileName, file);
if (localRefs == nil)
{
localRefs = [AGSIndex new];
@@ -305,6 +309,7 @@ - (NSString*) outputDocument: (GSXMLNode*)node
[self decIndent];
[buf appendString: @"