diff options
Diffstat (limited to 'Source')
-rw-r--r-- | Source/SPPrintController.m | 14 |
1 files changed, 12 insertions, 2 deletions
diff --git a/Source/SPPrintController.m b/Source/SPPrintController.m index 3a2f4148..1119fc15 100644 --- a/Source/SPPrintController.m +++ b/Source/SPPrintController.m @@ -178,7 +178,6 @@ // Cancel the print thread [printThread cancel]; - } /** @@ -217,7 +216,16 @@ NSDictionary *tableSource = [tableSourceInstance tableSourceForPrinting]; - heading = NSLocalizedString(@"Table Structure", @"table structure print heading"); + SPExportMode tableType = [tablesListInstance tableType]; + + switch (tableType) { + case SPTableTypeTable: + heading = NSLocalizedString(@"Table Structure", @"table structure print heading"); + break; + case SPTableTypeView: + heading = NSLocalizedString(@"View Structure", @"view structure print heading"); + break; + } rows = [[NSArray alloc] initWithArray: [[tableSource objectForKey:@"structure"] objectsAtIndexes: @@ -235,6 +243,8 @@ [printData setObject:indexes forKey:@"indexes"]; [printData setObject:indexColumns forKey:@"indexColumns"]; + if ([indexes count]) [printData setObject:[NSNumber numberWithInteger:1] forKey:@"hasIndexes"]; + [rows release]; [indexes release]; } |