diff options
Diffstat (limited to 'khtml/rendering')
-rw-r--r-- | khtml/rendering/bidi.cpp | 24 | ||||
-rw-r--r-- | khtml/rendering/break_lines.h | 8 | ||||
-rw-r--r-- | khtml/rendering/font.cpp | 2 | ||||
-rw-r--r-- | khtml/rendering/render_block.cpp | 2 | ||||
-rw-r--r-- | khtml/rendering/render_box.cpp | 2 | ||||
-rw-r--r-- | khtml/rendering/render_canvas.cpp | 2 | ||||
-rw-r--r-- | khtml/rendering/render_form.cpp | 18 | ||||
-rw-r--r-- | khtml/rendering/render_generated.cpp | 2 | ||||
-rw-r--r-- | khtml/rendering/render_image.cpp | 2 | ||||
-rw-r--r-- | khtml/rendering/render_layer.cpp | 6 | ||||
-rw-r--r-- | khtml/rendering/render_style.cpp | 2 | ||||
-rw-r--r-- | khtml/rendering/render_style.h | 8 | ||||
-rw-r--r-- | khtml/rendering/render_text.cpp | 6 | ||||
-rw-r--r-- | khtml/rendering/render_text.h | 2 |
14 files changed, 43 insertions, 43 deletions
diff --git a/khtml/rendering/bidi.cpp b/khtml/rendering/bidi.cpp index e866f8838..bd010047a 100644 --- a/khtml/rendering/bidi.cpp +++ b/khtml/rendering/bidi.cpp @@ -242,7 +242,7 @@ static inline RenderObject *Bidinext(RenderObject *par, RenderObject *current, B if (!oldEndOfInline && !current->isFloating() && !current->isReplaced() && !current->isPositioned()) { next = current->firstChild(); if ( next && adjustEmbedding ) { - EUnicodeBidi ub = next->style()->tqunicodeBidi(); + EUnicodeBidi ub = next->style()->unicodeBidi(); if ( ub != UBNormal && !emptyRun ) { EDirection dir = next->style()->direction(); TQChar::Direction d = ( ub == Embed ? ( dir == RTL ? TQChar::DirRLE : TQChar::DirLRE ) @@ -261,7 +261,7 @@ static inline RenderObject *Bidinext(RenderObject *par, RenderObject *current, B while (current && current != par) { next = current->nextSibling(); if (next) break; - if ( adjustEmbedding && current->style()->tqunicodeBidi() != UBNormal && !emptyRun ) { + if ( adjustEmbedding && current->style()->unicodeBidi() != UBNormal && !emptyRun ) { embed( TQChar::DirPDF, bidi ); } current = current->parent(); @@ -454,7 +454,7 @@ static void checkMidpoints(BidiIterator& lBreak, BidiState &bidi) // Don't shave a character off the endpoint if it was from a soft hyphen. RenderText* textObj = static_cast<RenderText*>(endpoint.obj); if (endpoint.pos+1 < textObj->length() && - textObj->text()[endpoint.pos+1].tqunicode() == SOFT_HYPHEN) + textObj->text()[endpoint.pos+1].unicode() == SOFT_HYPHEN) return; } endpoint.pos--; @@ -1241,7 +1241,7 @@ void RenderBlock::bidiReorderLine(const BidiIterator &start, const BidiIterator } // this causes the operator ++ to open and close embedding levels as needed - // for the CSS tqunicode-bidi property + // for the CSS unicode-bidi property adjustEmbedding = true; bidi.current.increment( bidi ); adjustEmbedding = false; @@ -1611,11 +1611,11 @@ BidiIterator RenderBlock::findNextLineBreak(BidiIterator &start, BidiState &bidi // be skipped. while (!start.atEnd() && (start.obj->isInlineFlow() || (!start.obj->style()->preserveWS() && !start.obj->isBR() && #ifndef QT_NO_UNICODETABLES - ( (start.current().tqunicode() == (ushort)0x0020) || // ASCII space - (start.current().tqunicode() == (ushort)0x0009) || // ASCII tab - (start.current().tqunicode() == (ushort)0x000A) || // ASCII line feed - (start.current().tqunicode() == (ushort)0x000C) || // ASCII form feed - (start.current().tqunicode() == (ushort)0x200B) || // Zero-width space + ( (start.current().unicode() == (ushort)0x0020) || // ASCII space + (start.current().unicode() == (ushort)0x0009) || // ASCII tab + (start.current().unicode() == (ushort)0x000A) || // ASCII line feed + (start.current().unicode() == (ushort)0x000C) || // ASCII form feed + (start.current().unicode() == (ushort)0x200B) || // Zero-width space start.obj->isFloatingOrPositioned() ) #else ( start.current() == ' ' || start.current() == '\n' || start.obj->isFloatingOrPositioned() ) @@ -1824,7 +1824,7 @@ BidiIterator RenderBlock::findNextLineBreak(BidiIterator &start, BidiState &bidi isLineEmpty = false; // Check for soft hyphens. Go ahead and ignore them. - if (c.tqunicode() == SOFT_HYPHEN && pos > 0) { + if (c.unicode() == SOFT_HYPHEN && pos > 0) { nextIsSoftBreakable = true; if (!ignoringSpaces) { // Ignore soft hyphens @@ -1911,7 +1911,7 @@ BidiIterator RenderBlock::findNextLineBreak(BidiIterator &start, BidiState &bidi lBreak.endOfInline = false; } goto end; - } else if ( (pos > 1 && str[pos-1].tqunicode() == SOFT_HYPHEN) ) + } else if ( (pos > 1 && str[pos-1].unicode() == SOFT_HYPHEN) ) // Subtract the width of the soft hyphen out since we fit on a line. tmpW -= t->width(pos-1, 1, f); } @@ -2189,7 +2189,7 @@ BidiIterator RenderBlock::findNextLineBreak(BidiIterator &start, BidiState &bidi // For soft hyphens on line breaks, we have to chop out the midpoints that made us // ignore the hyphen so that it will render at the end of the line. TQChar c = static_cast<RenderText*>(lBreak.obj)->text()[lBreak.pos-1]; - if (c.tqunicode() == SOFT_HYPHEN) + if (c.unicode() == SOFT_HYPHEN) chopMidpointsAt(lBreak.obj, lBreak.pos-2); } diff --git a/khtml/rendering/break_lines.h b/khtml/rendering/break_lines.h index ed6df2aab..5176e5fb0 100644 --- a/khtml/rendering/break_lines.h +++ b/khtml/rendering/break_lines.h @@ -6,7 +6,7 @@ namespace khtml { /* - array of tqunicode codes where breaking shouldn't occur. + array of unicode codes where breaking shouldn't occur. (in sorted order because of using with binary search) these are currently for Japanese, though simply adding Korean, Chinese ones should work as well @@ -122,7 +122,7 @@ namespace khtml { inline bool isBreakable( const TQChar *str, const int pos, int len ) { const TQChar *c = str+pos; - unsigned short ch = c->tqunicode(); + unsigned short ch = c->unicode(); if ( ch > 0xff ) { // not latin1, need to do more sophisticated checks for asian fonts unsigned char row = c->row(); @@ -147,8 +147,8 @@ namespace khtml { return false; // do binary search in dontbreak[] - return break_bsearch(dontbreakbefore, c->tqunicode()) && - break_bsearch(dontbreakafter, (str+(pos-1))->tqunicode()); + return break_bsearch(dontbreakbefore, c->unicode()) && + break_bsearch(dontbreakafter, (str+(pos-1))->unicode()); } else // no asian font return c->isSpace(); } else { diff --git a/khtml/rendering/font.cpp b/khtml/rendering/font.cpp index 64ede83e3..a33f0e082 100644 --- a/khtml/rendering/font.cpp +++ b/khtml/rendering/font.cpp @@ -293,7 +293,7 @@ int Font::width( TQChar *chs, int, int pos, int len, int start, int end, int toA const TQString qstr = cstr.string(); if ( scFont ) { const TQString upper = qstr.upper(); - const TQChar *uc = qstr.tqunicode(); + const TQChar *uc = qstr.unicode(); const TQFontMetrics sc_fm( *scFont ); for ( int i = 0; i < len; ++i ) { if ( (uc+i)->category() == TQChar::Letter_Lowercase ) diff --git a/khtml/rendering/render_block.cpp b/khtml/rendering/render_block.cpp index 5b30e2a58..ccbb6fad0 100644 --- a/khtml/rendering/render_block.cpp +++ b/khtml/rendering/render_block.cpp @@ -881,7 +881,7 @@ static inline bool isAnonymousWhitespace( RenderObject* o ) { return false; RenderObject *fc = o->firstChild(); return fc && fc == o->lastChild() && fc->isText() && static_cast<RenderText *>(fc)->stringLength() == 1 && - static_cast<RenderText *>(fc)->text()[0].tqunicode() == ' '; + static_cast<RenderText *>(fc)->text()[0].unicode() == ' '; } RenderObject* RenderBlock::handleCompactChild(RenderObject* child, CompactInfo& compactInfo, const MarginInfo& marginInfo, bool& handled) diff --git a/khtml/rendering/render_box.cpp b/khtml/rendering/render_box.cpp index 1dda168c2..7400752ac 100644 --- a/khtml/rendering/render_box.cpp +++ b/khtml/rendering/render_box.cpp @@ -346,7 +346,7 @@ void RenderBox::paintRootBoxDecorations(PaintInfo& paintInfo, int _tx, int _ty) } if( !bgColor.isValid() && canvas()->view()) - bgColor = canvas()->view()->tqpalette().active().color(TQColorGroup::Base); + bgColor = canvas()->view()->palette().active().color(TQColorGroup::Base); int w = width(); int h = height(); diff --git a/khtml/rendering/render_canvas.cpp b/khtml/rendering/render_canvas.cpp index 6fdf45849..e8540eba6 100644 --- a/khtml/rendering/render_canvas.cpp +++ b/khtml/rendering/render_canvas.cpp @@ -329,7 +329,7 @@ void RenderCanvas::paintBoxDecorations(PaintInfo& paintInfo, int /*_tx*/, int /* if ((firstChild() && firstChild()->style()->visibility() == VISIBLE) || !view()) return; - paintInfo.p->fillRect(paintInfo.r, view()->tqpalette().active().color(TQColorGroup::Base)); + paintInfo.p->fillRect(paintInfo.r, view()->palette().active().color(TQColorGroup::Base)); } void RenderCanvas::repaintRectangle(int x, int y, int w, int h, Priority p, bool f) diff --git a/khtml/rendering/render_form.cpp b/khtml/rendering/render_form.cpp index d55b32fe4..a0ac7b732 100644 --- a/khtml/rendering/render_form.cpp +++ b/khtml/rendering/render_form.cpp @@ -155,8 +155,8 @@ void RenderCheckBox::calcMinMaxWidth() KHTMLAssert( !minMaxKnown() ); TQCheckBox *cb = static_cast<TQCheckBox *>( m_widget ); - TQSize s( cb->tqstyle().pixelMetric( TQStyle::PM_IndicatorWidth ), - cb->tqstyle().pixelMetric( TQStyle::PM_IndicatorHeight ) ); + TQSize s( cb->style().pixelMetric( TQStyle::PM_IndicatorWidth ), + cb->style().pixelMetric( TQStyle::PM_IndicatorHeight ) ); setIntrinsicWidth( s.width() ); setIntrinsicHeight( s.height() ); @@ -207,8 +207,8 @@ void RenderRadioButton::calcMinMaxWidth() KHTMLAssert( !minMaxKnown() ); TQRadioButton *rb = static_cast<TQRadioButton *>( m_widget ); - TQSize s( rb->tqstyle().pixelMetric( TQStyle::PM_ExclusiveIndicatorWidth ), - rb->tqstyle().pixelMetric( TQStyle::PM_ExclusiveIndicatorHeight ) ); + TQSize s( rb->style().pixelMetric( TQStyle::PM_ExclusiveIndicatorWidth ), + rb->style().pixelMetric( TQStyle::PM_ExclusiveIndicatorHeight ) ); setIntrinsicWidth( s.width() ); setIntrinsicHeight( s.height() ); @@ -263,14 +263,14 @@ void RenderSubmitButton::calcMinMaxWidth() raw = TQString::fromLatin1("X"); TQFontMetrics fm = pb->fontMetrics(); TQSize ts = fm.size( ShowPrefix, raw); - TQSize s(pb->tqstyle().tqsizeFromContents( TQStyle::CT_PushButton, pb, ts ) + TQSize s(pb->style().tqsizeFromContents( TQStyle::CT_PushButton, pb, ts ) .expandedTo(TQApplication::globalStrut())); - int margin = pb->tqstyle().pixelMetric( TQStyle::PM_ButtonMargin, pb) + - pb->tqstyle().pixelMetric( TQStyle::PM_DefaultFrameWidth, pb ) * 2; + int margin = pb->style().pixelMetric( TQStyle::PM_ButtonMargin, pb) + + pb->style().pixelMetric( TQStyle::PM_DefaultFrameWidth, pb ) * 2; int w = ts.width() + margin; int h = s.height(); if (pb->isDefault() || pb->autoDefault()) { - int dbw = pb->tqstyle().pixelMetric( TQStyle::PM_ButtonDefaultIndicator, pb ) * 2; + int dbw = pb->style().pixelMetric( TQStyle::PM_ButtonDefaultIndicator, pb ) * 2; w += dbw; } @@ -805,7 +805,7 @@ void RenderFileButton::calcMinMaxWidth() int h = fm.lineSpacing(); int w = fm.width( 'x' ) * (size > 0 ? size+1 : 17); // "some" KLineEdit* edit = static_cast<KURLRequester*>( m_widget )->lineEdit(); - TQSize s = edit->tqstyle().tqsizeFromContents(TQStyle::CT_LineEdit, + TQSize s = edit->style().tqsizeFromContents(TQStyle::CT_LineEdit, edit, TQSize(w + 2 + 2*edit->frameWidth(), kMax(h, 14) + 2 + 2*edit->frameWidth())) .expandedTo(TQApplication::globalStrut()); diff --git a/khtml/rendering/render_generated.cpp b/khtml/rendering/render_generated.cpp index ba80a5aa1..17c65fc9c 100644 --- a/khtml/rendering/render_generated.cpp +++ b/khtml/rendering/render_generated.cpp @@ -53,7 +53,7 @@ void RenderCounterBase::calcMinMaxWidth() generateContent(); if (str) str->deref(); - str = new DOM::DOMStringImpl(m_item.tqunicode(), m_item.length()); + str = new DOM::DOMStringImpl(m_item.unicode(), m_item.length()); str->ref(); RenderText::calcMinMaxWidth(); diff --git a/khtml/rendering/render_image.cpp b/khtml/rendering/render_image.cpp index 8626580d6..46104adb8 100644 --- a/khtml/rendering/render_image.cpp +++ b/khtml/rendering/render_image.cpp @@ -266,7 +266,7 @@ void RenderImage::paint(PaintInfo& paintInfo, int _tx, int _ty) if ( !berrorPic ) { //qDebug("qDrawShadePanel %d/%d/%d/%d", _tx + leftBorder, _ty + topBorder, cWidth, cHeight); qDrawShadePanel( paintInfo.p, _tx + leftBorder + leftPad, _ty + topBorder + topPad, cWidth, cHeight, - KApplication::tqpalette().inactive(), true, 1 ); + KApplication::palette().inactive(), true, 1 ); } TQPixmap const* pix = i ? &i->pixmap() : 0; if(berrorPic && pix && (cWidth >= pix->width()+4) && (cHeight >= pix->height()+4) ) diff --git a/khtml/rendering/render_layer.cpp b/khtml/rendering/render_layer.cpp index 96b0236cb..2b7e93f1f 100644 --- a/khtml/rendering/render_layer.cpp +++ b/khtml/rendering/render_layer.cpp @@ -637,7 +637,7 @@ int RenderLayer::verticalScrollbarWidth() #ifdef APPLE_CHANGES return m_vBar->width(); #else - return m_vBar->tqstyle().pixelMetric(TQStyle::PM_ScrollBarExtent); + return m_vBar->style().pixelMetric(TQStyle::PM_ScrollBarExtent); #endif } @@ -650,7 +650,7 @@ int RenderLayer::horizontalScrollbarHeight() #ifdef APPLE_CHANGES return m_hBar->height(); #else - return m_hBar->tqstyle().pixelMetric(TQStyle::PM_ScrollBarExtent); + return m_hBar->style().pixelMetric(TQStyle::PM_ScrollBarExtent); #endif } @@ -691,7 +691,7 @@ void RenderLayer::positionScrollbars(const TQRect& absBounds) TQScrollBar *b = m_hBar; if (!m_hBar) b = m_vBar; - int sw = b->tqstyle().pixelMetric(TQStyle::PM_ScrollBarExtent); + int sw = b->style().pixelMetric(TQStyle::PM_ScrollBarExtent); if (m_vBar) { TQRect vBarRect = TQRect(tx + w - sw + 1, ty, sw, h - (m_hBar ? sw : 0) + 1); diff --git a/khtml/rendering/render_style.cpp b/khtml/rendering/render_style.cpp index ecbbf6de2..a71dd4116 100644 --- a/khtml/rendering/render_style.cpp +++ b/khtml/rendering/render_style.cpp @@ -786,7 +786,7 @@ RenderStyle::Diff RenderStyle::diff( const RenderStyle *other ) const !(noninherited_flags.f._position == other->noninherited_flags.f._position) || !(noninherited_flags.f._floating == other->noninherited_flags.f._floating) || !(noninherited_flags.f._flowAroundFloats == other->noninherited_flags.f._flowAroundFloats) || - !(noninherited_flags.f._tqunicodeBidi == other->noninherited_flags.f._tqunicodeBidi) ) + !(noninherited_flags.f._unicodeBidi == other->noninherited_flags.f._unicodeBidi) ) return CbLayout; } diff --git a/khtml/rendering/render_style.h b/khtml/rendering/render_style.h index 59e38277d..80d052980 100644 --- a/khtml/rendering/render_style.h +++ b/khtml/rendering/render_style.h @@ -919,7 +919,7 @@ protected: PseudoId _styleType : 4; bool _hasClip : 1; unsigned _pseudoBits : 8; - EUnicodeBidi _tqunicodeBidi : 2; + EUnicodeBidi _unicodeBidi : 2; // non CSS2 non-inherited bool _textOverflow : 1; // Whether or not lines that spill out should be truncated with "..." @@ -991,7 +991,7 @@ protected: noninherited_flags.f._styleType = NOPSEUDO; noninherited_flags.f._hasClip = false; noninherited_flags.f._pseudoBits = 0; - noninherited_flags.f._tqunicodeBidi = initialUnicodeBidi(); + noninherited_flags.f._unicodeBidi = initialUnicodeBidi(); noninherited_flags.f._textOverflow = initialTextOverflow(); noninherited_flags.f.unused = 0; } @@ -1108,7 +1108,7 @@ public: LengthBox clip() const { return visual->clip; } bool hasClip() const { return noninherited_flags.f._hasClip; } - EUnicodeBidi tqunicodeBidi() const { return noninherited_flags.f._tqunicodeBidi; } + EUnicodeBidi unicodeBidi() const { return noninherited_flags.f._unicodeBidi; } EClear clear() const { return noninherited_flags.f._clear; } ETableLayout tableLayout() const { return noninherited_flags.f._table_layout; } @@ -1272,7 +1272,7 @@ public: void setClip( Length top, Length right, Length bottom, Length left ); void setHasClip( bool b ) { noninherited_flags.f._hasClip = b; } - void setUnicodeBidi( EUnicodeBidi b ) { noninherited_flags.f._tqunicodeBidi = b; } + void setUnicodeBidi( EUnicodeBidi b ) { noninherited_flags.f._unicodeBidi = b; } void setClear(EClear v) { noninherited_flags.f._clear = v; } void setTableLayout(ETableLayout v) { noninherited_flags.f._table_layout = v; } diff --git a/khtml/rendering/render_text.cpp b/khtml/rendering/render_text.cpp index 58c9c33df..f5fa2e373 100644 --- a/khtml/rendering/render_text.cpp +++ b/khtml/rendering/render_text.cpp @@ -1036,7 +1036,7 @@ void RenderText::calcMinMaxWidth() bool firstLine = true; for(int i = 0; i < len; i++) { - unsigned short c = str->s[i].tqunicode(); + unsigned short c = str->s[i].unicode(); bool isNewline = false; // If line-breaks survive to here they are preserved @@ -1056,7 +1056,7 @@ void RenderText::calcMinMaxWidth() continue; int wordlen = 0; - while( i+wordlen < len && (i+wordlen == 0 || str->s[i+wordlen].tqunicode() != SOFT_HYPHEN) && + while( i+wordlen < len && (i+wordlen == 0 || str->s[i+wordlen].unicode() != SOFT_HYPHEN) && !(isBreakable( str->s, i+wordlen, str->l )) ) wordlen++; @@ -1470,7 +1470,7 @@ static TQString quoteAndEscapeNonPrintables(const TQString &s) } else if (c == '"') { result += "\\\""; } else { - ushort u = c.tqunicode(); + ushort u = c.unicode(); if (u >= 0x20 && u < 0x7F) { result += c; } else { diff --git a/khtml/rendering/render_text.h b/khtml/rendering/render_text.h index fabf5e051..50132fbc7 100644 --- a/khtml/rendering/render_text.h +++ b/khtml/rendering/render_text.h @@ -36,7 +36,7 @@ class TQPainter; class TQFontMetrics; -// Define a constant for soft hyphen's tqunicode value. +// Define a constant for soft hyphen's unicode value. #define SOFT_HYPHEN 173 const int cNoTruncation = -1; |