gecko/parser/html/nsIParserUtils.idl
Henri Sivonen b0b6cb7764 Bug 650784 part 1.5 - Move nsScriptableUnescapeHTML from Toolkit to Core. r=smaug.
--HG--
rename : toolkit/components/feeds/nsIScriptableUnescapeHTML.idl => parser/html/nsIScriptableUnescapeHTML.idl
rename : toolkit/components/feeds/nsScriptableUnescapeHTML.cpp => parser/html/nsParserUtils.cpp
rename : toolkit/components/feeds/nsScriptableUnescapeHTML.h => parser/html/nsParserUtils.h
2012-02-27 13:57:48 +02:00

33 lines
1.2 KiB
Plaintext

/* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this file,
* You can obtain one at http://mozilla.org/MPL/2.0/. */
#include "nsISupports.idl"
/**
* Non-Web HTML parser functionality to Firefox extensions and XULRunner apps.
* Don't use this from within Gecko--use nsContentUtils directly instead.
*/
[scriptable, uuid(290f49bb-0619-4bda-8006-ab31bec7231a)]
interface nsIParserUtils : nsISupports
{
/**
* Convert HTML to plain text.
*
* @param src the HTML source to parse (C++ callers are allowed but not
* required to use the same string for the return value.)
* @param flags conversion option flags defined in nsIDocumentEncoder
* @param wrapCol number of characters per line; 0 for no auto-wrapping
*/
AString convertToPlainText(in AString src,
in unsigned long flags,
in unsigned long wrapCol);
};
%{ C++
#define NS_PARSERUTILS_CONTRACTID \
"@mozilla.org/parserutils;1"
#define NS_PARSERUTILS_CID \
{ 0xaf7b24cb, 0x893f, 0x41bb, { 0x96, 0x1f, 0x5a, 0x69, 0x38, 0x8e, 0x27, 0xc3 } }
%}