Skip to content

Word wrap squashed #518

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 9 commits into from
Closed
1,430 changes: 905 additions & 525 deletions console/tidy.c

Large diffs are not rendered by default.

16 changes: 16 additions & 0 deletions include/tidy.h
Original file line number Diff line number Diff line change
Expand Up @@ -1404,6 +1404,22 @@ TIDY_EXPORT Bool TIDY_CALL tidySetPrettyPrinterCallback(TidyDoc tdoc,
TidyPPProgress callback
);

/** @} */
/** @name Output Utilities
** Utility functions can make implementing LibTidy applications somewhat
** simpler.
** @{
*/

/** Performs word wrapping on `string` limiting output to `column`, returning
** an allocated string.
** @param tdoc A Tidy document, so that we can use its allocator.
** @param string The text to wrap.
** @param columns The maximum column count to output.
** @result An allocated, word-wrapped string.
*/
TIDY_EXPORT tmbstr TIDY_CALL tidyWrappedText(TidyDoc tdoc, ctmbstr string, uint columns);

/** @} */
/** @} end IO group */
/* MARK: - Document Parse */
Expand Down
1 change: 1 addition & 0 deletions include/tidyenum.h
Original file line number Diff line number Diff line change
Expand Up @@ -542,6 +542,7 @@ typedef enum
TidyBreakBeforeBR, /**< Output newline before <br> or not? */
TidyCharEncoding, /**< In/out character encoding */
TidyCoerceEndTags, /**< Coerce end tags from start tags where probably intended */
TidyConsoleWidth, /**< Specify the width for console message output. */
TidyCSSPrefix, /**< CSS class naming for clean option */
#ifndef DOXYGEN_SHOULD_SKIP_THIS
TidyCustomTags, /**< Internal use ONLY */
Expand Down
Loading