You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+34-4Lines changed: 34 additions & 4 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -384,6 +384,8 @@ Each of the get\* functions above takes an additional "useIndex" function, which
384
384
AdvancedHTMLFormatter and formatHTML
385
385
------------------------------------
386
386
387
+
**AdvancedHTMLFormatter**
388
+
387
389
The AdvancedHTMLFormatter formats HTML into a pretty layout. It can handle elements like pre, core, script, style, etc to keep their contents preserved, but does not understand CSS rules.
388
390
389
391
The methods are:
@@ -397,18 +399,46 @@ The methods are:
397
399
getRoot - Gets the "root" node (on a valid document this should be <html>). For arbitrary HTML, you should use getRootNodes, as there may be several nodes at the same outermost level
398
400
399
401
402
+
You can access this same formatting off an AdvancedHTMLParser.AdvancedHTMLParser (or IndexedAdvancedHTMLParser) by calling .getFormattedHTML()
403
+
404
+
405
+
**AdvancedHTMLMiniFormatter**
406
+
407
+
The AdvancedHTMLMiniFormatter will strip all non-functional whitespace (meaning any whitespace which wouldn't normally add a space to the document or is required for xhtml) and provide no indentation.
408
+
409
+
Use this when pretty-printing doesn't matter and you'd like to save space.
410
+
411
+
412
+
You can access this same formatting off an AdvancedHTMLParser.AdvancedHTMLParser (or IndexedAdvancedHTMLParser) by calling .getMiniHTML()
413
+
414
+
415
+
**formatHTML script**
416
+
400
417
401
418
A script, formatHTML comes with this package and will perform formatting on an input file, and output to a file or stdout:
Copy file name to clipboardExpand all lines: README.rst
+41-4Lines changed: 41 additions & 4 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -400,6 +400,8 @@ Each of the get\* functions above takes an additional "useIndex" function, which
400
400
AdvancedHTMLFormatter and formatHTML
401
401
------------------------------------
402
402
403
+
**AdvancedHTMLFormatter**
404
+
403
405
The AdvancedHTMLFormatter formats HTML into a pretty layout. It can handle elements like pre, core, script, style, etc to keep their contents preserved, but does not understand CSS rules.
404
406
405
407
The methods are:
@@ -415,18 +417,53 @@ The methods are:
415
417
getRoot \- Gets the "root" node (on a valid document this should be <html>). For arbitrary HTML, you should use getRootNodes, as there may be several nodes at the same outermost level
416
418
417
419
420
+
You can access this same formatting off an AdvancedHTMLParser.AdvancedHTMLParser (or IndexedAdvancedHTMLParser) by calling .getFormattedHTML()
421
+
422
+
423
+
**AdvancedHTMLMiniFormatter**
424
+
425
+
The AdvancedHTMLMiniFormatter will strip all non-functional whitespace (meaning any whitespace which wouldn't normally add a space to the document or is required for xhtml) and provide no indentation.
426
+
427
+
Use this when pretty-printing doesn't matter and you'd like to save space.
428
+
429
+
430
+
You can access this same formatting off an AdvancedHTMLParser.AdvancedHTMLParser (or IndexedAdvancedHTMLParser) by calling .getMiniHTML()
431
+
432
+
433
+
**formatHTML script**
434
+
418
435
419
436
A script, formatHTML comes with this package and will perform formatting on an input file, and output to a file or stdout:
0 commit comments