Skip to content

Commit

Permalink
Merge d83e99a into 0fdbaaa
Browse files Browse the repository at this point in the history
  • Loading branch information
rgregg committed Sep 8, 2015
2 parents 0fdbaaa + d83e99a commit c1c0463
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 1 deletion.
6 changes: 6 additions & 0 deletions Core/Source/DTHTMLWriter.h
Expand Up @@ -57,4 +57,10 @@
*/
@property (nonatomic, readonly) NSAttributedString *attributedString;


/**
The HTML element tag name to use for paragraphs. Defaults to @"p".
*/
@property (nonatomic, strong) NSString *paragraphTagName;

@end
4 changes: 3 additions & 1 deletion Core/Source/DTHTMLWriter.m
Expand Up @@ -42,6 +42,8 @@ - (id)initWithAttributedString:(NSAttributedString *)attributedString

// default is to leave px sizes as is
_textScale = 1.0f;

_paragraphTagName = @"p";
}

return self;
Expand Down Expand Up @@ -430,7 +432,7 @@ - (void)_buildOutputAsHTMLFragment:(BOOL)fragment
}
else
{
blockElement = @"p";
blockElement = _paragraphTagName;
}

NSNumber *headerLevel = [paraAttributes objectForKey:DTHeaderLevelAttribute];
Expand Down

0 comments on commit c1c0463

Please sign in to comment.