1 /* This Source Code Form is subject to the terms of the Mozilla Public
2 * License, v. 2.0. If a copy of the MPL was not distributed with this
3 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
5 inline nsHtml5HtmlAttributes
* GetAttributes() { return attributes
; }
8 * Makes sure the buffers are large enough to be able to tokenize aLength
9 * UTF-16 code units before having to make the buffers larger.
11 * @param aLength the number of UTF-16 code units to be tokenized before the
12 * next call to this method.
13 * @return true if successful; false if out of memory
15 bool EnsureBufferSpace(int32_t aLength
);
17 nsAutoPtr
<nsHtml5Highlighter
> mViewSource
;
20 * Starts handling text/plain. This is a one-way initialization. There is
21 * no corresponding EndPlainText() call.
23 void StartPlainText();
25 void EnableViewSource(nsHtml5Highlighter
* aHighlighter
);
27 bool FlushViewSource();
29 void StartViewSource(const nsAutoString
& aTitle
);
33 void errGarbageAfterLtSlash();
37 void errWarnLtSlashInRcdata();
39 void errCharRefLacksSemicolon();
41 void errNoDigitsInNCR();
43 void errGtInSystemId();
45 void errGtInPublicId();
47 void errNamelessDoctype();
49 void errConsecutiveHyphens();
51 void errPrematureEndOfComment();
53 void errBogusComment();
55 void errUnquotedAttributeValOrNull(char16_t c
);
57 void errSlashNotFollowedByGt();
59 void errNoSpaceBetweenAttributes();
61 void errLtOrEqualsOrGraveInUnquotedAttributeOrNull(char16_t c
);
63 void errAttributeValueMissing();
65 void errBadCharBeforeAttributeNameOrNull(char16_t c
);
67 void errEqualsSignBeforeAttributeName();
69 void errBadCharAfterLt(char16_t c
);
73 void errProcessingInstruction();
75 void errUnescapedAmpersandInterpretedAsCharacterReference();
77 void errNotSemicolonTerminated();
79 void errNoNamedCharacterMatch();
81 void errQuoteBeforeAttributeName(char16_t c
);
83 void errQuoteOrLtInAttributeNameOrNull(char16_t c
);
85 void errExpectedPublicId();
87 void errBogusDoctype();
89 void maybeErrAttributesOnEndTag(nsHtml5HtmlAttributes
* attrs
);
91 void maybeErrSlashInEndTag(bool selfClosing
);
93 char16_t
errNcrNonCharacter(char16_t ch
);
95 void errAstralNonCharacter(int32_t ch
);
97 void errNcrSurrogate();
99 char16_t
errNcrControlChar(char16_t ch
);
103 void errNcrInC1Range();
105 void errEofInPublicId();
107 void errEofInComment();
109 void errEofInDoctype();
111 void errEofInAttributeValue();
113 void errEofInAttributeName();
115 void errEofWithoutGt();
117 void errEofInTagName();
119 void errEofInEndTag();
121 void errEofAfterLt();
123 void errNcrOutOfRange();
125 void errNcrUnassigned();
127 void errDuplicateAttribute();
129 void errEofInSystemId();
131 void errExpectedSystemId();
133 void errMissingSpaceBeforeDoctypeName();
135 void errHyphenHyphenBang();
137 void errNcrControlChar();
141 void errNoSpaceBetweenDoctypeSystemKeywordAndQuote();
143 void errNoSpaceBetweenPublicAndSystemIds();
145 void errNoSpaceBetweenDoctypePublicKeywordAndQuote();