summaryrefslogtreecommitdiffstats
path: root/khtml/html
diff options
context:
space:
mode:
Diffstat (limited to 'khtml/html')
-rw-r--r--khtml/html/html_documentimpl.cpp12
-rw-r--r--khtml/html/html_elementimpl.cpp34
-rw-r--r--khtml/html/html_elementimpl.h2
-rw-r--r--khtml/html/html_formimpl.cpp20
-rw-r--r--khtml/html/html_imageimpl.cpp22
-rw-r--r--khtml/html/html_imageimpl.h4
-rw-r--r--khtml/html/html_miscimpl.cpp10
-rw-r--r--khtml/html/htmltokenizer.cpp30
-rw-r--r--khtml/html/htmltokenizer.h4
9 files changed, 69 insertions, 69 deletions
diff --git a/khtml/html/html_documentimpl.cpp b/khtml/html/html_documentimpl.cpp
index a5c78657c..e2ee3ba57 100644
--- a/khtml/html/html_documentimpl.cpp
+++ b/khtml/html/html_documentimpl.cpp
@@ -110,8 +110,8 @@ DOMString HTMLDocumentImpl::cookie() const
long windowId = 0;
KHTMLView *v = view ();
- if ( v && v->tqtopLevelWidget() )
- windowId = v->tqtopLevelWidget()->winId();
+ if ( v && v->topLevelWidget() )
+ windowId = v->topLevelWidget()->winId();
TQCString replyType;
TQByteArray params, reply;
@@ -142,8 +142,8 @@ void HTMLDocumentImpl::setCookie( const DOMString & value )
long windowId = 0;
KHTMLView *v = view ();
- if ( v && v->tqtopLevelWidget() )
- windowId = v->tqtopLevelWidget()->winId();
+ if ( v && v->topLevelWidget() )
+ windowId = v->topLevelWidget()->winId();
TQByteArray params;
TQDataStream stream(params, IO_WriteOnly);
@@ -226,7 +226,7 @@ void HTMLDocumentImpl::slotHistoryChanged()
return;
recalcStyle( Force );
- m_render->tqrepaint();
+ m_render->repaint();
}
HTMLMapElementImpl* HTMLDocumentImpl::getMap(const DOMString& _url)
@@ -235,7 +235,7 @@ HTMLMapElementImpl* HTMLDocumentImpl::getMap(const DOMString& _url)
TQString s;
int pos = url.find('#');
//kdDebug(0) << "map pos of #:" << pos << endl;
- s = TQString(_url.tqunicode() + pos + 1, _url.length() - pos - 1);
+ s = TQString(_url.unicode() + pos + 1, _url.length() - pos - 1);
TQMapConstIterator<TQString,HTMLMapElementImpl*> it = mapMap.find(s);
diff --git a/khtml/html/html_elementimpl.cpp b/khtml/html/html_elementimpl.cpp
index 736b5a3b9..f635fcc3d 100644
--- a/khtml/html/html_elementimpl.cpp
+++ b/khtml/html/html_elementimpl.cpp
@@ -176,7 +176,7 @@ void HTMLElementImpl::parseAttribute(AttributeImpl *attr)
case ATTR_CLASS:
if (attr->val()) {
DOMString v = attr->value();
- const TQChar* s = v.tqunicode();
+ const TQChar* s = v.unicode();
int l = v.length();
while( l && !s->isSpace() )
l--,s++;
@@ -354,11 +354,11 @@ static inline bool isHexDigit( const TQChar &c ) {
static inline int toHex( const TQChar &c ) {
return ( (c >= TQChar('0') && c <= TQChar('9'))
- ? (c.tqunicode() - '0')
+ ? (c.unicode() - '0')
: ( ( c >= TQChar('a') && c <= TQChar('f') )
- ? (c.tqunicode() - 'a' + 10)
+ ? (c.unicode() - 'a' + 10)
: ( ( c >= TQChar('A') && c <= TQChar('F') )
- ? (c.tqunicode() - 'A' + 10)
+ ? (c.unicode() - 'A' + 10)
: -1 ) ) );
}
@@ -457,7 +457,7 @@ DOMString HTMLElementImpl::innerHTML() const
TQString result; //Use TQString to accumulate since DOMString is poor for appends
for (NodeImpl *child = firstChild(); child != NULL; child = child->nextSibling()) {
DOMString kid = child->toString();
- result += TQConstString(kid.tqunicode(), kid.length()).string();
+ result += TQConstString(kid.unicode(), kid.length()).string();
}
return result;
}
@@ -620,32 +620,32 @@ void HTMLElementImpl::setInnerText( const DOMString &text, int& exceptioncode )
appendChild( t, exceptioncode );
}
-void HTMLElementImpl::addHTMLAlignment( DOMString tqalignment )
+void HTMLElementImpl::addHTMLAlignment( DOMString alignment )
{
- //qDebug("tqalignment is %s", tqalignment.string().latin1() );
- // vertical tqalignment with respect to the current baseline of the text
+ //qDebug("alignment is %s", alignment.string().latin1() );
+ // vertical alignment with respect to the current baseline of the text
// right or left means floating images
int propfloat = -1;
int propvalign = -1;
- if ( strcasecmp( tqalignment, "absmiddle" ) == 0 ) {
+ if ( strcasecmp( alignment, "absmiddle" ) == 0 ) {
propvalign = CSS_VAL_MIDDLE;
- } else if ( strcasecmp( tqalignment, "absbottom" ) == 0 ) {
+ } else if ( strcasecmp( alignment, "absbottom" ) == 0 ) {
propvalign = CSS_VAL_BOTTOM;
- } else if ( strcasecmp( tqalignment, "left" ) == 0 ) {
+ } else if ( strcasecmp( alignment, "left" ) == 0 ) {
propfloat = CSS_VAL_LEFT;
propvalign = CSS_VAL_TOP;
- } else if ( strcasecmp( tqalignment, "right" ) == 0 ) {
+ } else if ( strcasecmp( alignment, "right" ) == 0 ) {
propfloat = CSS_VAL_RIGHT;
propvalign = CSS_VAL_TOP;
- } else if ( strcasecmp( tqalignment, "top" ) == 0 ) {
+ } else if ( strcasecmp( alignment, "top" ) == 0 ) {
propvalign = CSS_VAL_TOP;
- } else if ( strcasecmp( tqalignment, "middle" ) == 0 ) {
+ } else if ( strcasecmp( alignment, "middle" ) == 0 ) {
propvalign = CSS_VAL__KHTML_BASELINE_MIDDLE;
- } else if ( strcasecmp( tqalignment, "center" ) == 0 ) {
+ } else if ( strcasecmp( alignment, "center" ) == 0 ) {
propvalign = CSS_VAL_MIDDLE;
- } else if ( strcasecmp( tqalignment, "bottom" ) == 0 ) {
+ } else if ( strcasecmp( alignment, "bottom" ) == 0 ) {
propvalign = CSS_VAL_BASELINE;
- } else if ( strcasecmp ( tqalignment, "texttop") == 0 ) {
+ } else if ( strcasecmp ( alignment, "texttop") == 0 ) {
propvalign = CSS_VAL_TEXT_TOP;
}
diff --git a/khtml/html/html_elementimpl.h b/khtml/html/html_elementimpl.h
index 83836f15d..f71ae9b23 100644
--- a/khtml/html/html_elementimpl.h
+++ b/khtml/html/html_elementimpl.h
@@ -68,7 +68,7 @@ public:
protected:
// for IMG, OBJECT and APPLET
- void addHTMLAlignment( DOMString tqalignment );
+ void addHTMLAlignment( DOMString alignment );
};
class HTMLGenericElementImpl : public HTMLElementImpl
diff --git a/khtml/html/html_formimpl.cpp b/khtml/html/html_formimpl.cpp
index 1512395e2..b456d5202 100644
--- a/khtml/html/html_formimpl.cpp
+++ b/khtml/html/html_formimpl.cpp
@@ -60,7 +60,7 @@
#include <kfileitem.h>
#include <tqfile.h>
#include <tqdir.h>
-#include <tqtextcodec.h>
+#include <textcodec.h>
// for keygen
#include <tqstring.h>
@@ -193,7 +193,7 @@ inline static TQString escapeUnencodeable(const TQTextCodec* codec, const TQStri
enc_string.append(c);
else {
TQString ampersandEscape;
- ampersandEscape.sprintf("&#%u;", c.tqunicode());
+ ampersandEscape.sprintf("&#%u;", c.unicode());
enc_string.append(ampersandEscape);
}
}
@@ -1322,10 +1322,10 @@ TQString HTMLInputElementImpl::state( )
{
switch (m_type) {
case PASSWORD:
- return TQString::tqfromLatin1("."); // empty string, avoid restoring
+ return TQString::fromLatin1("."); // empty string, avoid restoring
case CHECKBOX:
case RADIO:
- return TQString::tqfromLatin1(checked() ? "on" : "off");
+ return TQString::fromLatin1(checked() ? "on" : "off");
case TEXT:
if (autoComplete() && value() != getAttribute(ATTR_VALUE) && getDocument()->view())
getDocument()->view()->addFormCompletionItem(name().string(), value().string());
@@ -1340,7 +1340,7 @@ void HTMLInputElementImpl::restoreState(const TQString &state)
switch (m_type) {
case CHECKBOX:
case RADIO:
- setChecked((state == TQString::tqfromLatin1("on")));
+ setChecked((state == TQString::fromLatin1("on")));
break;
case FILE:
m_value = DOMString(state.left(state.length()-1));
@@ -1566,12 +1566,12 @@ bool HTMLInputElementImpl::encoding(const TQTextCodec* codec, khtml::encodingLis
if(m_clicked)
{
m_clicked = false;
- TQString astr(nme.isEmpty() ? TQString::tqfromLatin1("x") : nme + ".x");
+ TQString astr(nme.isEmpty() ? TQString::fromLatin1("x") : nme + ".x");
encoding += fixUpfromUnicode(codec, astr);
astr.setNum(KMAX( clickX(), 0 ));
encoding += fixUpfromUnicode(codec, astr);
- astr = nme.isEmpty() ? TQString::tqfromLatin1("y") : nme + ".y";
+ astr = nme.isEmpty() ? TQString::fromLatin1("y") : nme + ".y";
encoding += fixUpfromUnicode(codec, astr);
astr.setNum(KMAX( clickY(), 0 ) );
encoding += fixUpfromUnicode(codec, astr);
@@ -1618,7 +1618,7 @@ bool HTMLInputElementImpl::encoding(const TQTextCodec* codec, khtml::encodingLis
KIO::UDSEntry filestat;
// can't submit file in www-url-form encoded
- TQWidget* const toplevel = static_cast<RenderSubmitButton*>(m_render)->widget()->tqtopLevelWidget();
+ TQWidget* const toplevel = static_cast<RenderSubmitButton*>(m_render)->widget()->topLevelWidget();
if (multipart) {
TQCString filearray( "" );
if ( KIO::NetAccess::stat(fileurl, filestat, toplevel)) {
@@ -2761,8 +2761,8 @@ static TQString expandLF(const TQString& s)
unsigned pos2 = 0;
for(unsigned pos = 0; pos < len; pos++)
{
- TQChar c = s.tqat(pos);
- switch(c.tqunicode())
+ TQChar c = s.at(pos);
+ switch(c.unicode())
{
case '\n':
r[pos2++] = '\r';
diff --git a/khtml/html/html_imageimpl.cpp b/khtml/html/html_imageimpl.cpp
index 9ced3bf1b..be13e93c2 100644
--- a/khtml/html/html_imageimpl.cpp
+++ b/khtml/html/html_imageimpl.cpp
@@ -418,8 +418,8 @@ void HTMLMapElementImpl::parseAttribute(AttributeImpl *attr)
case ATTR_NAME:
{
DOMString s = attr->value();
- if(*s.tqunicode() == '#')
- name = TQString(s.tqunicode()+1, s.length()-1).lower();
+ if(*s.unicode() == '#')
+ name = TQString(s.unicode()+1, s.length()-1).lower();
else
name = s.string().lower();
// ### make this work for XML documents, e.g. in case of <html:map...>
@@ -441,7 +441,7 @@ HTMLAreaElementImpl::HTMLAreaElementImpl(DocumentImpl *doc)
m_coords=0;
m_coordsLen = 0;
nohref = false;
- tqshape = Unknown;
+ shape = Unknown;
lasth = lastw = -1;
}
@@ -461,13 +461,13 @@ void HTMLAreaElementImpl::parseAttribute(AttributeImpl *attr)
{
case ATTR_SHAPE:
if ( strcasecmp( attr->value(), "default" ) == 0 )
- tqshape = Default;
+ shape = Default;
else if ( strcasecmp( attr->value(), "circle" ) == 0 )
- tqshape = Circle;
+ shape = Circle;
else if ( strcasecmp( attr->value(), "poly" ) == 0 || strcasecmp( attr->value(), "polygon" ) == 0 )
- tqshape = Poly;
+ shape = Poly;
else if ( strcasecmp( attr->value(), "rect" ) == 0 )
- tqshape = Rect;
+ shape = Rect;
break;
case ATTR_COORDS:
delete [] m_coords;
@@ -530,7 +530,7 @@ TQRegion HTMLAreaElementImpl::getRegion(int width_, int height_) const
// what the HTML author tried to tell us.
// a Poly needs at least 3 points (6 coords), so this is correct
- if ((tqshape==Poly || tqshape==Unknown) && m_coordsLen > 5) {
+ if ((shape==Poly || shape==Unknown) && m_coordsLen > 5) {
// make sure its even
int len = m_coordsLen >> 1;
TQPointArray points(len);
@@ -539,19 +539,19 @@ TQRegion HTMLAreaElementImpl::getRegion(int width_, int height_) const
m_coords[(i<<1)+1].minWidth(height_));
region = TQRegion(points);
}
- else if (tqshape==Circle && m_coordsLen>=3 || tqshape==Unknown && m_coordsLen == 3) {
+ else if (shape==Circle && m_coordsLen>=3 || shape==Unknown && m_coordsLen == 3) {
int r = kMin(m_coords[2].minWidth(width_), m_coords[2].minWidth(height_));
region = TQRegion(m_coords[0].minWidth(width_)-r,
m_coords[1].minWidth(height_)-r, 2*r, 2*r,TQRegion::Ellipse);
}
- else if (tqshape==Rect && m_coordsLen>=4 || tqshape==Unknown && m_coordsLen == 4) {
+ else if (shape==Rect && m_coordsLen>=4 || shape==Unknown && m_coordsLen == 4) {
int x0 = m_coords[0].minWidth(width_);
int y0 = m_coords[1].minWidth(height_);
int x1 = m_coords[2].minWidth(width_);
int y1 = m_coords[3].minWidth(height_);
region = TQRegion(x0,y0,x1-x0,y1-y0);
}
- else if (tqshape==Default)
+ else if (shape==Default)
region = TQRegion(0,0,width_,height_);
// else
// return null region
diff --git a/khtml/html/html_imageimpl.h b/khtml/html/html_imageimpl.h
index 1a389e895..6f26cd2df 100644
--- a/khtml/html/html_imageimpl.h
+++ b/khtml/html/html_imageimpl.h
@@ -102,7 +102,7 @@ public:
virtual void parseAttribute(AttributeImpl *attr);
- bool isDefault() const { return tqshape==Default; }
+ bool isDefault() const { return shape==Default; }
bool mapMouseEvent(int x_, int y_, int width_, int height_,
khtml::RenderObject::NodeInfo& info);
@@ -117,7 +117,7 @@ protected:
khtml::Length* m_coords;
int m_coordsLen;
int lastw, lasth;
- Shape tqshape : 3;
+ Shape shape : 3;
bool nohref : 1;
};
diff --git a/khtml/html/html_miscimpl.cpp b/khtml/html/html_miscimpl.cpp
index d5e812029..58804bff5 100644
--- a/khtml/html/html_miscimpl.cpp
+++ b/khtml/html/html_miscimpl.cpp
@@ -328,14 +328,14 @@ NodeImpl *HTMLFormCollectionImpl::item( unsigned long index ) const
TQPtrList<HTMLGenericFormElementImpl>& l = static_cast<HTMLFormElementImpl*>( m_refNode )->formElements;
for (unsigned i = strt; i < l.count(); i++)
{
- if (l.tqat( i )->isEnumeratable())
+ if (l.at( i )->isEnumeratable())
{
if (dist == 0)
{
//Found it!
m_cache->position = index;
m_cache->current.index = i;
- return l.tqat( i );
+ return l.at( i );
}
else
--dist;
@@ -349,7 +349,7 @@ unsigned long HTMLFormCollectionImpl::calcLength(NodeImpl *start) const
unsigned length = 0;
TQPtrList<HTMLGenericFormElementImpl> l = static_cast<HTMLFormElementImpl*>( start )->formElements;
for ( unsigned i = 0; i < l.count(); i++ )
- if ( l.tqat( i )->isEnumeratable() )
+ if ( l.at( i )->isEnumeratable() )
++length;
return length;
}
@@ -369,7 +369,7 @@ NodeImpl *HTMLFormCollectionImpl::nextNamedItem( const DOMString &name ) const
//Go through the list, trying to find the appropriate named form element.
for ( ; currentNamePos < l.count(); ++currentNamePos )
{
- HTMLGenericFormElementImpl* el = l.tqat(currentNamePos);
+ HTMLGenericFormElementImpl* el = l.at(currentNamePos);
if (el->isEnumeratable() &&
((el->getAttribute(ATTR_ID) == name) ||
(el->getAttribute(ATTR_NAME) == name)))
@@ -387,7 +387,7 @@ NodeImpl *HTMLFormCollectionImpl::nextNamedItem( const DOMString &name ) const
TQPtrList<HTMLImageElementImpl>& il = static_cast<HTMLFormElementImpl*>( m_refNode )->imgElements;
for ( ; currentNameImgPos < il.count(); ++currentNameImgPos )
{
- HTMLImageElementImpl* el = il.tqat(currentNameImgPos);
+ HTMLImageElementImpl* el = il.at(currentNameImgPos);
if ((el->getAttribute(ATTR_ID) == name) ||
(el->getAttribute(ATTR_NAME) == name))
{
diff --git a/khtml/html/htmltokenizer.cpp b/khtml/html/htmltokenizer.cpp
index 0b9b5f34d..5da6edd14 100644
--- a/khtml/html/htmltokenizer.cpp
+++ b/khtml/html/htmltokenizer.cpp
@@ -89,7 +89,7 @@ static const char titleEnd [] = "</title";
#define fixUpChar(x)
#else
#define fixUpChar(x) \
- switch ((x).tqunicode()) \
+ switch ((x).unicode()) \
{ \
case 0x80: (x) = 0x20ac; break; \
case 0x82: (x) = 0x201a; break; \
@@ -471,7 +471,7 @@ void HTMLTokenizer::parseComment(TokenizerString &src)
if (strict)
{
- if (src->tqunicode() == '-') {
+ if (src->unicode() == '-') {
delimiterCount++;
if (delimiterCount == 2) {
delimiterCount = 0;
@@ -482,7 +482,7 @@ void HTMLTokenizer::parseComment(TokenizerString &src)
delimiterCount = 0;
}
- if ((!strict || canClose) && src->tqunicode() == '>')
+ if ((!strict || canClose) && src->unicode() == '>')
{
bool handleBrokenComments = brokenComments && !( script || style );
bool scriptEnd=false;
@@ -521,7 +521,7 @@ void HTMLTokenizer::parseServer(TokenizerString &src)
checkScriptBuffer(src.length());
while ( !src.isEmpty() ) {
scriptCode[ scriptCodeSize++ ] = *src;
- if (src->tqunicode() == '>' &&
+ if (src->unicode() == '>' &&
scriptCodeSize > 1 && scriptCode[scriptCodeSize-2] == '%') {
++src;
server = false;
@@ -607,7 +607,7 @@ void HTMLTokenizer::parseEntity(TokenizerString &src, TQChar *&dest, bool start)
while( !src.isEmpty() )
{
- ushort cc = src->tqunicode();
+ ushort cc = src->unicode();
switch(Entity) {
case NoEntity:
return;
@@ -639,7 +639,7 @@ void HTMLTokenizer::parseEntity(TokenizerString &src, TQChar *&dest, bool start)
case Hexadecimal:
{
- int uc = EntityChar.tqunicode();
+ int uc = EntityChar.unicode();
int ll = kMin<uint>(src.length(), 8);
while(ll--) {
TQChar csrc(src->lower());
@@ -658,7 +658,7 @@ void HTMLTokenizer::parseEntity(TokenizerString &src, TQChar *&dest, bool start)
}
case Decimal:
{
- int uc = EntityChar.tqunicode();
+ int uc = EntityChar.unicode();
int ll = kMin(src.length(), 9-cBufferPos);
while(ll--) {
cc = src->cell();
@@ -718,7 +718,7 @@ void HTMLTokenizer::parseEntity(TokenizerString &src, TQChar *&dest, bool start)
}
case SearchSemicolon:
#ifdef TOKEN_DEBUG
- kdDebug( 6036 ) << "ENTITY " << EntityChar.tqunicode() << endl;
+ kdDebug( 6036 ) << "ENTITY " << EntityChar.unicode() << endl;
#endif
fixUpChar(EntityChar);
@@ -919,7 +919,7 @@ void HTMLTokenizer::parseTag(TokenizerString &src)
a = khtml::getAttrID(cBuffer, cBufferPos-1);
}
if (!a)
- attrName = TQString::tqfromLatin1(TQCString(cBuffer, cBufferPos+1).data());
+ attrName = TQString::fromLatin1(TQCString(cBuffer, cBufferPos+1).data());
}
dest = buffer;
@@ -941,7 +941,7 @@ void HTMLTokenizer::parseTag(TokenizerString &src)
}
if ( cBufferPos == CBUFLEN ) {
cBuffer[cBufferPos] = '\0';
- attrName = TQString::tqfromLatin1(TQCString(cBuffer, cBufferPos+1).data());
+ attrName = TQString::fromLatin1(TQCString(cBuffer, cBufferPos+1).data());
dest = buffer;
*dest++ = 0;
tag = SearchEqual;
@@ -956,7 +956,7 @@ void HTMLTokenizer::parseTag(TokenizerString &src)
ushort curchar;
bool atespace = false;
while(!src.isEmpty()) {
- curchar = src->tqunicode();
+ curchar = src->unicode();
if(curchar > ' ') {
if(curchar == '=') {
#ifdef TOKEN_DEBUG
@@ -988,7 +988,7 @@ void HTMLTokenizer::parseTag(TokenizerString &src)
{
ushort curchar;
while(!src.isEmpty()) {
- curchar = src->tqunicode();
+ curchar = src->unicode();
if(curchar > ' ') {
if(( curchar == '\'' || curchar == '\"' )) {
tquote = curchar == '\"' ? DoubleQuote : SingleQuote;
@@ -1012,7 +1012,7 @@ void HTMLTokenizer::parseTag(TokenizerString &src)
while(!src.isEmpty()) {
checkBuffer();
- curchar = src->tqunicode();
+ curchar = src->unicode();
if(curchar <= '\'' && !src.escaped()) {
// ### attributes like '&{blaa....};' are supposed to be treated as jscript.
if ( curchar == '&' )
@@ -1050,7 +1050,7 @@ void HTMLTokenizer::parseTag(TokenizerString &src)
ushort curchar;
while(!src.isEmpty()) {
checkBuffer();
- curchar = src->tqunicode();
+ curchar = src->unicode();
if(curchar <= '>' && !src.escaped()) {
// parse Entities
if ( curchar == '&' )
@@ -1351,7 +1351,7 @@ void HTMLTokenizer::write( const TokenizerString &str, bool appendData )
// do we need to enlarge the buffer?
checkBuffer();
- ushort cc = src->tqunicode();
+ ushort cc = src->unicode();
if (skipLF && (cc != '\n'))
skipLF = false;
diff --git a/khtml/html/htmltokenizer.h b/khtml/html/htmltokenizer.h
index 2197a5083..8e36353b0 100644
--- a/khtml/html/htmltokenizer.h
+++ b/khtml/html/htmltokenizer.h
@@ -76,8 +76,8 @@ namespace khtml {
{
DOMStringImpl *value = 0;
NodeImpl::Id tid = 0;
- if(buffer->tqunicode()) {
- tid = buffer->tqunicode();
+ if(buffer->unicode()) {
+ tid = buffer->unicode();
value = v.implementation();
}
else if ( !attrName.isEmpty() && attrName != "/" ) {