diff options
Diffstat (limited to 'src/kernel/tqwidget.cpp')
| -rw-r--r-- | src/kernel/tqwidget.cpp | 228 |
1 files changed, 114 insertions, 114 deletions
diff --git a/src/kernel/tqwidget.cpp b/src/kernel/tqwidget.cpp index ac56e302a..a4b4ca218 100644 --- a/src/kernel/tqwidget.cpp +++ b/src/kernel/tqwidget.cpp @@ -377,7 +377,7 @@ \i mouseMoveEvent() - called whenever the mouse moves while a button is held down. This is useful for, for example, dragging. If - you call setMouseTracking(TRUE), you get mouse move events even + you call setMouseTracking(true), you get mouse move events even when no buttons are held down. (Note that applications which make use of mouse tracking are often not very useful on low-bandwidth X connections.) (See also the \link dnd.html drag and drop\endlink @@ -894,7 +894,7 @@ TQWidget::TQWidget( TQWidget *parent, const char *name, WFlags f, NFlags n ) fstrut_dirty = 1; - isWidget = TRUE; // is a widget + isWidget = true; // is a widget winid = 0; // default attributes widget_state = 0; widget_flags = f; @@ -904,7 +904,7 @@ TQWidget::TQWidget( TQWidget *parent, const char *name, WFlags f, NFlags n ) own_palette = 0; sizehint_forced = 0; is_closing = 0; - im_enabled = FALSE; + im_enabled = false; #ifndef TQT_NO_LAYOUT lay_out = 0; #endif @@ -931,7 +931,7 @@ TQWidget::TQWidget( TQWidget *parent, const char *name, WFlags f, NFlags n ) crect.size()) ); if ( isTopLevel() ) { setWState( WState_ForceHide | WState_CreatedHidden ); - TQFocusData *fd = focusData( TRUE ); + TQFocusData *fd = focusData( true ); if ( fd->focusWidgets.findRef(this) < 0 ) fd->focusWidgets.append( this ); } else { @@ -961,7 +961,7 @@ TQWidget::~TQWidget() #endif // Remove myself and all children from the can-take-focus list - TQFocusData *f = focusData( FALSE ); + TQFocusData *f = focusData( false ); if ( f ) { TQPtrListIterator<TQWidget> it(f->focusWidgets); TQWidget *w; @@ -1045,7 +1045,7 @@ void TQWidget::destroyMapper() while ( (w=it.current()) ) { // remove parents widgets ++it; if ( !w->parentObj ) // widget is a parent - w->destroy( TRUE, TRUE ); + w->destroy( true, true ); } delete myMapper; } @@ -1075,7 +1075,7 @@ static TQWidgetList *wListInternal( TQWidgetMapper *mapper, bool onlyTopLevel ) TQWidgetList *TQWidget::wList() { - return wListInternal( mapper, FALSE ); + return wListInternal( mapper, false ); } /*! @@ -1086,7 +1086,7 @@ TQWidgetList *TQWidget::wList() TQWidgetList *TQWidget::tlwList() { - return wListInternal( mapper, TRUE ); + return wListInternal( mapper, true ); } @@ -1545,7 +1545,7 @@ uint TQWidget::windowState() const combination of TQt::WindowState: \c WindowMinimized, \c WindowMaximized, \c WindowFullScreen and \c WindowActive. - If the window is not visible (i.e. isVisible() returns FALSE), the + If the window is not visible (i.e. isVisible() returns false), the window state will take effect when show() is called. For visible windows, the change is immediate. For example, to toggle between full-screen and mormal mode, use the following code: @@ -1659,8 +1659,8 @@ void TQWidget::showNormal() } /*! - Returns TRUE if this widget would become enabled if \a ancestor is - enabled; otherwise returns FALSE. + Returns true if this widget would become enabled if \a ancestor is + enabled; otherwise returns false. This is the case if neither the widget itself nor every parent up to but excluding \a ancestor has been explicitly disabled. @@ -1731,7 +1731,7 @@ void TQWidget::setEnabled( bool enable ) ++it; if ( w->isWidgetType() && !w->testWState( WState_ForceDisabled ) ) - w->setEnabled( TRUE ); + w->setEnabled( true ); } } } @@ -1739,7 +1739,7 @@ void TQWidget::setEnabled( bool enable ) if ( !testWState(WState_Disabled) ) { if (focusWidget() == this) { bool parentIsEnabled = (!parentWidget() || parentWidget()->isEnabled()); - if (!parentIsEnabled || !focusNextPrevChild(TRUE)) + if (!parentIsEnabled || !focusNextPrevChild(true)) clearFocus(); } setWState( WState_Disabled ); @@ -1751,7 +1751,7 @@ void TQWidget::setEnabled( bool enable ) while( (w = (TQWidget *)it.current()) != 0 ) { ++it; if ( w->isWidgetType() && w->isEnabled() ) { - w->setEnabled( FALSE ); + w->setEnabled( false ); w->clearWState( WState_ForceDisabled ); } } @@ -1773,7 +1773,7 @@ void TQWidget::setEnabled( bool enable ) } /*! - Disables widget input events if \a disable is TRUE; otherwise + Disables widget input events if \a disable is true; otherwise enables input events. See the \l enabled documentation for more information. @@ -2906,7 +2906,7 @@ const TQColorGroup &TQWidget::colorGroup() const #ifndef TQT_NO_PALETTE void TQWidget::setPalette( const TQPalette &palette ) { - own_palette = TRUE; + own_palette = true; if ( pal == palette ) return; TQPalette old = pal; @@ -2932,7 +2932,7 @@ void TQWidget::unsetPalette() { // reset the palette setPalette( qt_naturalWidgetPalette( this ) ); - own_palette = FALSE; + own_palette = false; } /*! @@ -2985,7 +2985,7 @@ void TQWidget::paletteChange( const TQPalette & ) */ void TQWidget::setFont( const TQFont &font ) { - own_font = TRUE; + own_font = true; if ( fnt == font && fnt.d->mask == font.d->mask ) return; TQFont old = fnt; @@ -3013,7 +3013,7 @@ void TQWidget::unsetFont() { // reset the font setFont( qt_naturalWidgetFont( this ) ); - own_font = FALSE; + own_font = false; } /*! @@ -3286,7 +3286,7 @@ void TQWidget::setFocus() return; } - TQFocusData * f = focusData( TRUE ); + TQFocusData * f = focusData( true ); if ( f->it.current() == this && tqApp->focusWidget() == this #if defined(TQ_WS_WIN) && GetFocus() == winId() @@ -3409,11 +3409,11 @@ void TQWidget::clearFocus() /*! Finds a new widget to give the keyboard focus to, as appropriate - for Tab and Shift+Tab, and returns TRUE if is can find a new - widget and FALSE if it can't, + for Tab and Shift+Tab, and returns true if is can find a new + widget and false if it can't, - If \a next is TRUE, this function searches "forwards", if \a next - is FALSE, it searches "backwards". + If \a next is true, this function searches "forwards", if \a next + is false, it searches "backwards". Sometimes, you will want to reimplement this function. For example, a web browser might reimplement it to move its "current @@ -3441,7 +3441,7 @@ bool TQWidget::focusNextPrevChild( bool next ) if ( !isTopLevel() && p ) return p->focusNextPrevChild(next); - TQFocusData *f = focusData( TRUE ); + TQFocusData *f = focusData( true ); TQWidget *startingPoint = f->it.current(); TQWidget *candidate = 0; @@ -3457,10 +3457,10 @@ bool TQWidget::focusNextPrevChild( bool next ) } while( w && !(candidate && w==startingPoint) ); if ( !candidate ) - return FALSE; + return false; candidate->setFocus(); - return TRUE; + return true; } /*! @@ -3472,7 +3472,7 @@ bool TQWidget::focusNextPrevChild( bool next ) TQWidget *TQWidget::focusWidget() const { TQWidget *that = (TQWidget *)this; // mutable - TQFocusData *f = that->focusData( FALSE ); + TQFocusData *f = that->focusData( false ); if ( f && f->focusWidgets.count() && f->it.current() == 0 ) f->it.toFirst(); return ( f && f->it.current() ) ? f->it.current() : 0; @@ -3492,14 +3492,14 @@ TQWidget *TQWidget::focusWidget() const */ TQFocusData * TQWidget::focusData() { - return focusData( TRUE ); + return focusData( true ); } /*! \internal Internal function which lets us ask for the focus data, creating - it if it doesn't exist and \a create is TRUE. + it if it doesn't exist and \a create is true. */ TQFocusData * TQWidget::focusData( bool create ) { @@ -3524,7 +3524,7 @@ TQFocusData * TQWidget::focusData( bool create ) Most Widgets (as eg. buttons) that do not handle text input should have the input method disabled if they have focus. This is the default. - If a widget handles text input it should set this property to TRUE. + If a widget handles text input it should set this property to true. */ void TQWidget::setInputMethodEnabled( bool b ) @@ -3537,8 +3537,8 @@ void TQWidget::setInputMethodEnabled( bool b ) /*! - Enables key event compression, if \a compress is TRUE, and - disables it if \a compress is FALSE. + Enables key event compression, if \a compress is true, and + disables it if \a compress is false. Key compression is off by default (except for TQLineEdit and TQTextEdit), so widgets receive one key press event for each key @@ -3581,7 +3581,7 @@ void TQWidget::setKeyCompression(bool compress) The active window is the window that contains the widget that has keyboard focus. - When popup windows are visible, this property is TRUE for both the + When popup windows are visible, this property is true for both the active window \e and for the popup. \sa setActiveWindow(), TQApplication::activeWindow() @@ -3592,7 +3592,7 @@ bool TQWidget::isActiveWindow() const if(testWFlags(WSubWindow) && parentWidget()) tlw = parentWidget()->topLevelWidget(); if(tlw == tqApp->activeWindow() || ( isVisible() && tlw->isPopup() )) - return TRUE; + return true; #ifndef TQT_NO_STYLE const_cast<TQWidget*>(this)->createExtra(); if (!extra->m_ceData) { @@ -3606,16 +3606,16 @@ bool TQWidget::isActiveWindow() const if((tlw->isDialog() || (tlw->testWFlags(TQt::WStyle_Tool) && !tlw->isPopup())) && !tlw->testWFlags(TQt::WShowModal) && (!tlw->parentWidget() || tlw->parentWidget()->isActiveWindow())) - return TRUE; + return true; TQWidget *w = tqApp->activeWindow(); if( !testWFlags(WSubWindow) && w && w->testWFlags(WSubWindow) && w->parentWidget()->topLevelWidget() == tlw) - return TRUE; + return true; while(w && (tlw->isDialog() || tlw->testWFlags(TQt::WStyle_Tool)) && !w->testWFlags(TQt::WShowModal) && w->parentWidget()) { w = w->parentWidget()->topLevelWidget(); if( w == tlw ) - return TRUE; + return true; } } #endif @@ -3625,11 +3625,11 @@ bool TQWidget::isActiveWindow() const while ( parent ) { parent = ::GetParent( parent ); if ( parent && parent == topparent ) - return TRUE; + return true; } #endif - return FALSE; + return false; } /*! @@ -3690,7 +3690,7 @@ void TQWidget::setTabOrder( TQWidget* first, TQWidget *second ) while ( second->focusProxy() ) second = second->focusProxy(); - TQFocusData *f = first->focusData( TRUE ); + TQFocusData *f = first->focusData( true ); bool focusThere = (f->it.current() == second ); f->focusWidgets.removeRef( second ); if ( f->focusWidgets.findRef( first ) >= 0 ) @@ -3818,7 +3818,7 @@ void TQWidget::move( int x, int y ) TQPoint oldp(pos()); internalSetGeometry( x + geometry().x() - TQWidget::x(), y + geometry().y() - TQWidget::y(), - width(), height(), TRUE ); + width(), height(), true ); if ( isVisible() && oldp != pos() ) qt_update_bg_recursive( this ); } @@ -3830,7 +3830,7 @@ void TQWidget::move( int x, int y ) */ void TQWidget::resize( int w, int h ) { - internalSetGeometry( geometry().x(), geometry().y(), w, h, FALSE ); + internalSetGeometry( geometry().x(), geometry().y(), w, h, false ); setWState( WState_Resized ); } @@ -3842,7 +3842,7 @@ void TQWidget::resize( int w, int h ) void TQWidget::setGeometry( int x, int y, int w, int h ) { TQPoint oldp( pos( )); - internalSetGeometry( x, y, w, h, TRUE ); + internalSetGeometry( x, y, w, h, true ); setWState( WState_Resized ); if ( isVisible() && oldp != pos() ) qt_update_bg_recursive( this ); @@ -3906,7 +3906,7 @@ void TQWidget::setFocusPolicy( FocusPolicy policy ) if ( focusProxy() ) focusProxy()->setFocusPolicy( policy ); if ( policy != NoFocus ) { - TQFocusData * f = focusData( TRUE ); + TQFocusData * f = focusData( true ); if ( f->focusWidgets.findRef( this ) < 0 ) f->focusWidgets.append( this ); } @@ -3927,9 +3927,9 @@ void TQWidget::setFocusPolicy( FocusPolicy policy ) Example: \code - setUpdatesEnabled( FALSE ); + setUpdatesEnabled( false ); bigVisualChanges(); - setUpdatesEnabled( TRUE ); + setUpdatesEnabled( true ); repaint(); \endcode @@ -4032,7 +4032,7 @@ void TQWidget::show() if ( !testWState(WState_Polished) ) polish(); - showChildren( FALSE ); + showChildren( false ); if ( postLayoutHint ) TQApplication::postEvent( parentWidget(), @@ -4118,10 +4118,10 @@ void TQWidget::hide() // next bit tries to move the focus if the focus widget is now // hidden. if ( tqApp && tqApp->focusWidget() == this ) - focusNextPrevChild( TRUE ); + focusNextPrevChild( true ); TQHideEvent hideEvent; TQApplication::sendEvent( this, &hideEvent ); - hideChildren( FALSE ); + hideChildren( false ); #if defined(QT_ACCESSIBILITY_SUPPORT) TQAccessible::updateAccessibility( this, 0, TQAccessible::ObjectHide ); @@ -4286,10 +4286,10 @@ void TQWidget::polish() /*! \overload - Closes this widget. Returns TRUE if the widget was closed; - otherwise returns FALSE. + Closes this widget. Returns true if the widget was closed; + otherwise returns false. - If \a alsoDelete is TRUE or the widget has the \c + If \a alsoDelete is true or the widget has the \c WDestructiveClose widget flag, the widget is also deleted. The widget can prevent itself from being closed by rejecting the \l TQCloseEvent it gets. A close events is delivered to the widget @@ -4308,18 +4308,18 @@ void TQWidget::polish() bool TQWidget::close( bool alsoDelete ) { if ( is_closing ) - return TRUE; + return true; is_closing = 1; WId id = winId(); bool isMain = tqApp->mainWidget() == this; bool checkLastWindowClosed = isTopLevel() && !isPopup(); - bool deleted = FALSE; + bool deleted = false; TQCloseEvent e; TQApplication::sendEvent( this, &e ); deleted = !TQWidget::find(id); if ( !deleted && !e.isAccepted() ) { is_closing = 0; - return FALSE; + return false; } if ( !deleted && !isHidden() ) hide(); @@ -4345,7 +4345,7 @@ bool TQWidget::close( bool alsoDelete ) if ( isMain ) tqApp->quit(); if ( deleted ) - return TRUE; + return true; is_closing = 0; if ( alsoDelete ) delete this; @@ -4353,15 +4353,15 @@ bool TQWidget::close( bool alsoDelete ) clearWFlags(WDestructiveClose); deleteLater(); } - return TRUE; + return true; } /*! \fn bool TQWidget::close() - Closes this widget. Returns TRUE if the widget was closed; - otherwise returns FALSE. + Closes this widget. Returns true if the widget was closed; + otherwise returns false. First it sends the widget a TQCloseEvent. The widget is \link hide() hidden\endlink if it \link TQCloseEvent::accept() @@ -4407,13 +4407,13 @@ bool TQWidget::close( bool alsoDelete ) /*! - Returns TRUE if this widget would become visible if \a ancestor is - shown; otherwise returns FALSE. + Returns true if this widget would become visible if \a ancestor is + shown; otherwise returns false. - The TRUE case occurs if neither the widget itself nor any parent + The true case occurs if neither the widget itself nor any parent up to but excluding \a ancestor has been explicitly hidden. - This function will still return TRUE if the widget is obscured by + This function will still return true if the widget is obscured by other windows on the screen, but could be physically visible if it or they were to be moved. @@ -4448,7 +4448,7 @@ bool TQWidget::isVisibleTo(TQWidget* ancestor) const \property TQWidget::hidden \brief whether the widget is explicitly hidden - If FALSE, the widget is visible or would become visible if all its + If false, the widget is visible or would become visible if all its ancestors became visible. \sa hide(), show(), isVisible(), isVisibleTo(), shown @@ -4458,7 +4458,7 @@ bool TQWidget::isVisibleTo(TQWidget* ancestor) const \property TQWidget::shown \brief whether the widget is shown - If TRUE, the widget is visible or would become visible if all its + If true, the widget is visible or would become visible if all its ancestors became visible. \sa hide(), show(), isVisible(), isVisibleTo(), hidden @@ -4616,7 +4616,7 @@ TQSize TQWidget::minimumSizeHint() const \fn TQWidget *TQWidget::parentWidget( bool sameWindow ) const Returns the parent of this widget, or 0 if it does not have any - parent widget. If \a sameWindow is TRUE and the widget is top + parent widget. If \a sameWindow is true and the widget is top level returns 0; otherwise returns the widget's parent. */ @@ -4693,8 +4693,8 @@ TQSize TQWidget::minimumSizeHint() const (or the key press is not Tab or Shift+Tab), event() calls keyPressEvent(). - This function returns TRUE if it is able to pass the event over to - someone (i.e. someone wanted the event); otherwise returns FALSE. + This function returns true if it is able to pass the event over to + someone (i.e. someone wanted the event); otherwise returns false. \sa closeEvent(), focusInEvent(), focusOutEvent(), enterEvent(), keyPressEvent(), keyReleaseEvent(), leaveEvent(), @@ -4706,13 +4706,13 @@ TQSize TQWidget::minimumSizeHint() const bool TQWidget::event( TQEvent *e ) { if ( TQObject::event( e ) ) - return TRUE; + return true; switch ( e->type() ) { case TQEvent::MouseMove: mouseMoveEvent( (TQMouseEvent*)e ); if ( ! ((TQMouseEvent*)e)->isAccepted() ) - return FALSE; + return false; break; case TQEvent::MouseButtonPress: @@ -4725,25 +4725,25 @@ bool TQWidget::event( TQEvent *e ) #endif mousePressEvent( (TQMouseEvent*)e ); if ( ! ((TQMouseEvent*)e)->isAccepted() ) - return FALSE; + return false; break; case TQEvent::MouseButtonRelease: mouseReleaseEvent( (TQMouseEvent*)e ); if ( ! ((TQMouseEvent*)e)->isAccepted() ) - return FALSE; + return false; break; case TQEvent::MouseButtonDblClick: mouseDoubleClickEvent( (TQMouseEvent*)e ); if ( ! ((TQMouseEvent*)e)->isAccepted() ) - return FALSE; + return false; break; #ifndef TQT_NO_WHEELEVENT case TQEvent::Wheel: wheelEvent( (TQWheelEvent*)e ); if ( ! ((TQWheelEvent*)e)->isAccepted() ) - return FALSE; + return false; break; #endif case TQEvent::TabletMove: @@ -4751,25 +4751,25 @@ bool TQWidget::event( TQEvent *e ) case TQEvent::TabletRelease: tabletEvent( (TQTabletEvent*)e ); if ( ! ((TQTabletEvent*)e)->isAccepted() ) - return FALSE; + return false; break; case TQEvent::Accel: ((TQKeyEvent*)e)->ignore(); - return FALSE; + return false; case TQEvent::KeyPress: { TQKeyEvent *k = (TQKeyEvent *)e; - bool res = FALSE; + bool res = false; if ( !(k->state() & ControlButton || k->state() & AltButton) ) { if ( k->key() == Key_Backtab || (k->key() == Key_Tab && (k->state() & ShiftButton)) ) { TQFocusEvent::setReason( TQFocusEvent::Backtab ); - res = focusNextPrevChild( FALSE ); + res = focusNextPrevChild( false ); TQFocusEvent::resetReason(); } else if ( k->key() == Key_Tab ) { TQFocusEvent::setReason( TQFocusEvent::Tab ); - res = focusNextPrevChild( TRUE ); + res = focusNextPrevChild( true ); TQFocusEvent::resetReason(); } if ( res ) @@ -4777,21 +4777,21 @@ bool TQWidget::event( TQEvent *e ) } keyPressEvent( k ); if ( !k->isAccepted() ) - return FALSE; + return false; } break; case TQEvent::KeyRelease: keyReleaseEvent( (TQKeyEvent*)e ); if ( ! ((TQKeyEvent*)e)->isAccepted() ) - return FALSE; + return false; break; case TQEvent::IMStart: { TQIMEvent *i = (TQIMEvent *) e; imStartEvent(i); if (! i->isAccepted()) - return FALSE; + return false; } break; @@ -4799,7 +4799,7 @@ bool TQWidget::event( TQEvent *e ) TQIMEvent *i = (TQIMEvent *) e; imComposeEvent(i); if (! i->isAccepted()) - return FALSE; + return false; } break; @@ -4807,7 +4807,7 @@ bool TQWidget::event( TQEvent *e ) TQIMEvent *i = (TQIMEvent *) e; imEndEvent(i); if (! i->isAccepted()) - return FALSE; + return false; } break; @@ -4847,7 +4847,7 @@ bool TQWidget::event( TQEvent *e ) TQCloseEvent *c = (TQCloseEvent *)e; closeEvent( c ); if ( !c->isAccepted() ) - return FALSE; + return false; } break; @@ -4855,7 +4855,7 @@ bool TQWidget::event( TQEvent *e ) TQContextMenuEvent *c = (TQContextMenuEvent *)e; contextMenuEvent( c ); if ( !c->isAccepted() ) - return FALSE; + return false; } break; @@ -4939,7 +4939,7 @@ bool TQWidget::event( TQEvent *e ) } } if ( e->type() == TQEvent::LanguageChange ) { - int index = metaObject()->findSlot( "languageChange()", TRUE ); + int index = metaObject()->findSlot( "languageChange()", true ); if ( index >= 0 ) tqt_invoke( index, 0 ); } @@ -4950,7 +4950,7 @@ bool TQWidget::event( TQEvent *e ) if ( layout() ) { layout()->activate(); } else { - TQObjectList* llist = queryList( "TQLayout", 0, TRUE, TRUE ); + TQObjectList* llist = queryList( "TQLayout", 0, true, true ); TQObjectListIt lit( *llist ); TQLayout *lay; while ( ( lay = (TQLayout*)lit.current() ) != 0 ) { @@ -4994,9 +4994,9 @@ bool TQWidget::event( TQEvent *e ) break; default: - return FALSE; + return false; } - return TRUE; + return true; } /*! @@ -5208,7 +5208,7 @@ void TQWidget::focusInEvent( TQFocusEvent * ) update(); if ( testWState(WState_AutoMask) ) updateMask(); - setMicroFocusHint(width()/2, 0, 1, height(), FALSE); + setMicroFocusHint(width()/2, 0, 1, height(), false); } } @@ -5538,7 +5538,7 @@ void TQWidget::hideEvent( TQHideEvent * ) receive native X11 events. In your reimplementation of this function, if you want to stop the - event being handled by TQt, return TRUE. If you return FALSE, this + event being handled by TQt, return true. If you return false, this native event is passed back to TQt, which translates the event into a TQt event and sends it to the widget. @@ -5555,7 +5555,7 @@ void TQWidget::hideEvent( TQHideEvent * ) receive native Macintosh events. In your reimplementation of this function, if you want to stop the - event being handled by TQt, return TRUE. If you return FALSE, this + event being handled by TQt, return true. If you return false, this native event is passed back to TQt, which translates the event into a TQt event and sends it to the widget. @@ -5566,7 +5566,7 @@ void TQWidget::hideEvent( TQHideEvent * ) bool TQWidget::macEvent( MSG * ) { - return FALSE; + return false; } #endif @@ -5577,7 +5577,7 @@ bool TQWidget::macEvent( MSG * ) receive native Windows events. In your reimplementation of this function, if you want to stop the - event being handled by TQt, return TRUE. If you return FALSE, this + event being handled by TQt, return true. If you return false, this native event is passed back to TQt, which translates the event into a TQt event and sends it to the widget. @@ -5587,7 +5587,7 @@ bool TQWidget::macEvent( MSG * ) */ bool TQWidget::winEvent( MSG * ) { - return FALSE; + return false; } #endif @@ -5598,7 +5598,7 @@ bool TQWidget::winEvent( MSG * ) receive native X11 events. In your reimplementation of this function, if you want to stop the - event being handled by TQt, return TRUE. If you return FALSE, this + event being handled by TQt, return true. If you return false, this native event is passed back to TQt, which translates the event into a TQt event and sends it to the widget. @@ -5608,7 +5608,7 @@ bool TQWidget::winEvent( MSG * ) */ bool TQWidget::x11Event( XEvent * ) { - return FALSE; + return false; } #endif @@ -5619,7 +5619,7 @@ bool TQWidget::x11Event( XEvent * ) Transparent widgets use a mask to define their visible region. TQWidget has some built-in support to make the task of - recalculating the mask easier. When setting auto mask to TRUE, + recalculating the mask easier. When setting auto mask to true, updateMask() will be called whenever the widget is resized or changes its focus state. Note that you must reimplement updateMask() (which should include a call to setMask()) or nothing @@ -5742,13 +5742,13 @@ TQPoint TQWidget::backgroundOffset() const { const TQWidget *topl = this; while(topl && !topl->isTopLevel() && !topl->testWFlags(TQt::WSubWindow)) - topl = topl->parentWidget(TRUE); + topl = topl->parentWidget(true); return mapTo((TQWidget *)topl, TQPoint(0, 0) ); } case AncestorOrigin: { const TQWidget *topl = this; - bool ancestorIsWindowOrigin = FALSE; + bool ancestorIsWindowOrigin = false; while(topl && !topl->isTopLevel() && !topl->testWFlags(TQt::WSubWindow)) { if (!ancestorIsWindowOrigin) { @@ -5756,13 +5756,13 @@ TQPoint TQWidget::backgroundOffset() const break; if (topl->backgroundOrigin() == TQWidget::ParentOrigin) { - topl = topl->parentWidget(TRUE); + topl = topl->parentWidget(true); break; } if (topl->backgroundOrigin() == TQWidget::WindowOrigin) - ancestorIsWindowOrigin = TRUE; + ancestorIsWindowOrigin = true; } - topl = topl->parentWidget(TRUE); + topl = topl->parentWidget(true); } return mapTo((TQWidget *) topl, TQPoint(0,0) ); @@ -5868,7 +5868,7 @@ int TQWidget::heightForWidth( int w ) const \property TQWidget::customWhatsThis \brief whether the widget wants to handle What's This help manually - The default implementation of customWhatsThis() returns FALSE, + The default implementation of customWhatsThis() returns false, which means the widget will not receive any events in Whats This mode. @@ -5884,14 +5884,14 @@ int TQWidget::heightForWidth( int w ) const */ bool TQWidget::customWhatsThis() const { - return FALSE; + return false; } /*! Returns the visible child widget at pixel position \a (x, y) in the widget's own coordinate system. - If \a includeThis is TRUE, and there is no child visible at \a (x, + If \a includeThis is true, and there is no child visible at \a (x, y), the widget itself is returned. */ TQWidget *TQWidget::childAt( int x, int y, bool includeThis ) const @@ -5905,7 +5905,7 @@ TQWidget *TQWidget::childAt( int x, int y, bool includeThis ) const while( (w=(TQWidget *)it.current()) != 0 ) { --it; if ( w->isWidgetType() && !w->isTopLevel() && !w->isHidden() ) { - if ( ( t = w->childAt( x - w->x(), y - w->y(), TRUE ) ) ) + if ( ( t = w->childAt( x - w->x(), y - w->y(), true ) ) ) return t; } } @@ -5921,7 +5921,7 @@ TQWidget *TQWidget::childAt( int x, int y, bool includeThis ) const Returns the visible child widget at point \a p in the widget's own coordinate system. - If \a includeThis is TRUE, and there is no child visible at \a p, + If \a includeThis is true, and there is no child visible at \a p, the widget itself is returned. */ @@ -5954,7 +5954,7 @@ void TQWidget::updateGeometry() flags (\a f, but as usual, use 0) at a new position in its new parent (\a p). - If \a showIt is TRUE, show() is called once the widget has been + If \a showIt is true, show() is called once the widget has been reparented. If the new parent widget is in a different top-level widget, the @@ -6011,7 +6011,7 @@ void TQWidget::reparent( TQWidget *parent, const TQPoint & p, \property TQWidget::ownCursor \brief whether the widget uses its own cursor - If FALSE, the widget uses its parent widget's cursor. + If false, the widget uses its parent widget's cursor. \sa cursor */ @@ -6020,7 +6020,7 @@ void TQWidget::reparent( TQWidget *parent, const TQPoint & p, \property TQWidget::ownFont \brief whether the widget uses its own font - If FALSE, the widget uses its parent widget's font. + If false, the widget uses its parent widget's font. \sa font */ @@ -6029,7 +6029,7 @@ void TQWidget::reparent( TQWidget *parent, const TQPoint & p, \property TQWidget::ownPalette \brief whether the widget uses its own palette - If FALSE, the widget uses its parent widget's palette. + If false, the widget uses its parent widget's palette. \sa palette */ |
