22 #define MAX(a,b) (((a) > (b))?(a):(b))
25 #define MIN(a,b) (((a) < (b))?(a):(b))
34 #define flg_BadForm 0x00000001
35 #define flg_BadMain 0x00000002
97 #if PRESERVE_FILE_TIMES
98 struct utimbuf filetimes;
140 #define tidyDocToImpl( tdoc ) ((TidyDocImpl*)(tdoc))
141 #define tidyImplToDoc( doc ) ((TidyDoc)(doc))
143 #define tidyMessageToImpl( tmessage ) ((TidyMessageImpl*)(tmessage))
144 #define tidyImplToMessage( message ) ((TidyMessage)(message))
146 #define tidyNodeToImpl( tnod ) ((Node*)(tnod))
147 #define tidyImplToNode( node ) ((TidyNode)(node))
149 #define tidyAttrToImpl( tattr ) ((AttVal*)(tattr))
150 #define tidyImplToAttr( attval ) ((TidyAttr)(attval))
152 #define tidyOptionToImpl( topt ) ((const TidyOptionImpl*)(topt))
153 #define tidyImplToOption( option ) ((TidyOption)(option))
157 #define TidyDocAlloc(doc, size) TidyAlloc((doc)->allocator, size)
158 #define TidyDocRealloc(doc, block, size) TidyRealloc((doc)->allocator, block, size)
159 #define TidyDocFree(doc, block) TidyFree((doc)->allocator, block)
160 #define TidyDocPanic(doc, msg) TidyPanic((doc)->allocator, msg)
Read configuration files and manage configuration properties.
#define TY_PRIVATE
Definition: forward.h:29
#define TY_(str)
Definition: forward.h:23
Bool(TIDY_CALL * TidyOptCallback)(ctmbstr option, ctmbstr value)
This typedef represents the required signature for your provided callback function should you wish to...
Definition: tidy.h:573
void(TIDY_CALL * TidyConfigChangeCallback)(TidyDoc tdoc, TidyOption option)
This typedef represents the required signature for your provided callback function should you wish to...
Definition: tidy.h:616
Bool(TIDY_CALL * TidyConfigCallback)(TidyDoc tdoc, ctmbstr option, ctmbstr value)
This typedef represents the required signature for your provided callback function should you wish to...
Definition: tidy.h:597
void(TIDY_CALL * TidyPPProgress)(TidyDoc tdoc, uint line, uint col, uint destLine)
This typedef represents the required signature for your provided callback function should you wish to...
Definition: tidy.h:1532
Bool(TIDY_CALL * TidyMessageCallback)(TidyMessage tmessage)
This typedef represents the required signature for your provided callback function should you wish to...
Definition: tidy.h:1286
Bool(TIDY_CALL * TidyReportCallback)(TidyDoc tdoc, TidyReportLevel lvl, uint line, uint col, ctmbstr code, va_list args)
This typedef represents the required signature for your provided callback function should you wish to...
Definition: tidy.h:1260
Bool(TIDY_CALL * TidyReportFilter)(TidyDoc tdoc, TidyReportLevel lvl, uint line, uint col, ctmbstr mssg)
This typedef represents the required signature for your provided callback function should you wish to...
Definition: tidy.h:1221
This type is used to define a structure for keeping track of the values for each option.
Definition: config.h:122
Maintains a list of messages not to display.
Definition: message.h:194
This typedef represents a stack of parserState.
Definition: parser.h:68
The pretty-printing buffer.
Definition: pprint.h:85
TidyReportLevel
Message severity level, used throughout LibTidy to indicate the severity or status of a message.
Definition: tidyenum.h:1402
Lexer for HTML and XML Parsers.
Pretty Print the parse tree.
TidyPPProgress progressCallback
Definition: tidy-int.h:65
TidyConfigImpl config
Definition: tidy-int.h:45
void * appData
Definition: tidy-int.h:93
ctmbstr messageKey
Definition: tidy-int.h:121
uint badLayout
Definition: tidy-int.h:79
uint code
Definition: tidy-int.h:111
ctmbstr messagePrefixDefault
Definition: tidy-int.h:132
tmbstr messagePos
Definition: tidy-int.h:130
uint badChars
Definition: tidy-int.h:80
ctmbstr messageFormat
Definition: tidy-int.h:124
int line
Definition: tidy-int.h:112
tmbstr messagePosDefault
Definition: tidy-int.h:129
TidyPrintImpl pprint
Definition: tidy-int.h:52
struct printfArg * arguments
Definition: tidy-int.h:119
NodeTraversalSignal
Definition: tidy-int.h:173
@ ContinueTraversal
Definition: tidy-int.h:174
@ SkipChildren
Definition: tidy-int.h:175
@ ExitTraversal
Definition: tidy-int.h:179
@ SkipSiblings
Definition: tidy-int.h:176
@ VisitParent
Definition: tidy-int.h:178
@ SkipChildrenAndSiblings
Definition: tidy-int.h:177
tmbstr message
Definition: tidy-int.h:127
uint badForm
Definition: tidy-int.h:81
uint footnotes
Definition: tidy-int.h:82
uint indent_char
Definition: tidy-int.h:87
Node root
Definition: tidy-int.h:40
int column
Definition: tidy-int.h:113
TidyParserStack stack
Definition: tidy-int.h:67
TidyTagImpl tags
Definition: tidy-int.h:46
TidyAccessImpl access
Definition: tidy-int.h:48
tmbstr messageOutput
Definition: tidy-int.h:136
ctmbstr messagePrefix
Definition: tidy-int.h:133
uint badAccess
Definition: tidy-int.h:78
StreamOut * docOut
Definition: tidy-int.h:56
TidyConfigChangeCallback pConfigChangeCallback
Definition: tidy-int.h:64
tmbstr messageOutputDefault
Definition: tidy-int.h:135
TidyAttribImpl attribs
Definition: tidy-int.h:47
StreamIn * docIn
Definition: tidy-int.h:55
TidyMutedMessages muted
Definition: tidy-int.h:49
StreamOut * errout
Definition: tidy-int.h:57
tmbstr givenDoctype
Definition: tidy-int.h:100
uint docErrors
Definition: tidy-int.h:75
ctmbstr messageFormatDefault
Definition: tidy-int.h:123
TidyDocImpl * tidyDoc
Definition: tidy-int.h:109
TidyAllocator * allocator
Definition: tidy-int.h:90
Bool HTML5Mode
Definition: tidy-int.h:84
uint warnings
Definition: tidy-int.h:72
Bool muted
Definition: tidy-int.h:116
int argcount
Definition: tidy-int.h:118
TidyOptCallback pOptCallback
Definition: tidy-int.h:62
uint nClassId
Definition: tidy-int.h:94
TidyReportLevel level
Definition: tidy-int.h:114
uint accessErrors
Definition: tidy-int.h:73
tmbstr messageDefault
Definition: tidy-int.h:126
NodeTraversalSignal NodeTraversalCallBack(TidyDocImpl *doc, Node *node, void *propagate)
Definition: tidy-int.h:182
TidyReportCallback reportCallback
Definition: tidy-int.h:60
Bool inputHadBOM
Definition: tidy-int.h:95
int parseStatus
Definition: tidy-int.h:76
uint infoMessages
Definition: tidy-int.h:74
TidyMessageCallback messageCallback
Definition: tidy-int.h:61
Bool allowMessage
Definition: tidy-int.h:115
uint errors
Definition: tidy-int.h:71
uint optionErrors
Definition: tidy-int.h:70
Bool xmlDetected
Definition: tidy-int.h:85
Node * tidyNode
Definition: tidy-int.h:110
Lexer * lexer
Definition: tidy-int.h:42
TidyConfigCallback pConfigCallback
Definition: tidy-int.h:63
TidyReportFilter reportFilter
Definition: tidy-int.h:59
Definition: tidy-int.h:38
The basic struct for communicating a message within LibTidy.
Definition: tidy-int.h:108
Defines HTML Tidy public API implemented by LibTidy.