diff options
Diffstat (limited to 'tqtinterface/qt4/src/opengl')
| -rw-r--r-- | tqtinterface/qt4/src/opengl/tqgl.cpp | 24 | ||||
| -rw-r--r-- | tqtinterface/qt4/src/opengl/tqgl_x11.cpp | 28 | ||||
| -rw-r--r-- | tqtinterface/qt4/src/opengl/tqglcolormap.cpp | 8 | ||||
| -rw-r--r-- | tqtinterface/qt4/src/opengl/tqglcolormap.h | 4 |
4 files changed, 32 insertions, 32 deletions
diff --git a/tqtinterface/qt4/src/opengl/tqgl.cpp b/tqtinterface/qt4/src/opengl/tqgl.cpp index 80e3658..7054e8e 100644 --- a/tqtinterface/qt4/src/opengl/tqgl.cpp +++ b/tqtinterface/qt4/src/opengl/tqgl.cpp @@ -79,7 +79,7 @@ static TQCleanupHandler<TQGLFormat> qgl_cleanup_format; own TQGLWidget subclass you can use the identifiers in the TQGL namespace without qualification. - However, you may occasionally tqfind yourself in situations where you + However, you may occasionally find yourself in situations where you need to refer to these identifiers from outside the TQGL namespace's scope, e.g. in static functions. In such cases, simply write e.g. \c TQGL::DoubleBuffer instead of just \c DoubleBuffer. @@ -149,7 +149,7 @@ static TQCleanupHandler<TQGLFormat> qgl_cleanup_format; MyGLWidget* myWidget = new MyGLWidget( f, ... ); \endcode - After the widget has been created, you can tqfind out which of the + After the widget has been created, you can find out which of the requested features the system was able to provide: \code TQGLFormat f; @@ -670,7 +670,7 @@ TQGLFormat TQGLFormat::defaultOverlayFormat() TQGLFormat::setDefaultOverlayFormat( f ); \endcode - As usual, you can tqfind out after widget creation whether the + As usual, you can find out after widget creation whether the underlying OpenGL system was able to provide the requested specification: @@ -1058,8 +1058,8 @@ bool TQGLContext::create( const TQGLContext* shareContext ) shareContext as closely as possible. On Windows, it calls the virtual function choosePixelFormat(), - which tqfinds a matching pixel format identifier. On X11, it calls - the virtual function chooseVisual() which tqfinds an appropriate X + which finds a matching pixel format identifier. On X11, it calls + the virtual function chooseVisual() which finds an appropriate X visual. On other platforms it may work differently. */ @@ -1277,10 +1277,10 @@ static TQGLWidgetPrivate * qgl_d( const TQGLWidget * w ) qgl_cleanup_d_ptr.set( &qgl_d_ptr ); qgl_d_ptr->setAutoDelete( TRUE ); } - TQGLWidgetPrivate * ret = qgl_d_ptr->tqfind( (void *) w ); + TQGLWidgetPrivate * ret = qgl_d_ptr->find( (void *) w ); if ( !ret ) { ret = new TQGLWidgetPrivate; - qgl_d_ptr->tqreplace( (void *) w, ret ); + qgl_d_ptr->replace( (void *) w, ret ); } return ret; } @@ -2019,9 +2019,9 @@ void TQGLWidget::qglColor( const TQColor& c ) const else if ( ctx->tqdevice() == context()->tqdevice() && !cmap.isEmpty() ) { // TQGLColormap in use? - int i = cmap.tqfind( c.rgb() ); + int i = cmap.find( c.rgb() ); if ( i < 0 ) - i = cmap.tqfindNearest( c.rgb() ); + i = cmap.findNearest( c.rgb() ); glIndexi( i ); } else glIndexi( ctx->colorIndex( c ) ); @@ -2045,9 +2045,9 @@ void TQGLWidget::qglClearColor( const TQColor& c ) const (GLfloat)c.blue() / 255.0, (GLfloat) 0.0 ); else if ( ctx->tqdevice() == context()->tqdevice() && !cmap.isEmpty() ) { // TQGLColormap in use? - int i = cmap.tqfind( c.rgb() ); + int i = cmap.find( c.rgb() ); if ( i < 0 ) - i = cmap.tqfindNearest( c.rgb() ); + i = cmap.findNearest( c.rgb() ); glClearIndex( i ); } else glClearIndex( ctx->colorIndex( c ) ); @@ -2166,7 +2166,7 @@ int TQGLWidget::displayListBase( const TQFont & fnt, int listBase ) TQString key = fnt.key() + TQString::number((int) regenerate); #endif - if ( !regenerate && (d->displayListCache.tqfind( key ) != d->displayListCache.end()) ) { + if ( !regenerate && (d->displayListCache.find( key ) != d->displayListCache.end()) ) { base = d->displayListCache[ key ]; } else { int maxBase = listBase - 256; diff --git a/tqtinterface/qt4/src/opengl/tqgl_x11.cpp b/tqtinterface/qt4/src/opengl/tqgl_x11.cpp index 70abe7d..2bedfd6 100644 --- a/tqtinterface/qt4/src/opengl/tqgl_x11.cpp +++ b/tqtinterface/qt4/src/opengl/tqgl_x11.cpp @@ -68,7 +68,7 @@ extern "C" { Status XmuLookupStandardColormap( Display *dpy, int screen, VisualID visualid, unsigned int depth, Atom property, - Bool tqreplace, Bool retain ); + Bool replace, Bool retain ); } #endif @@ -189,7 +189,7 @@ bool qt_resolve_gl_symbols(bool fatal) /* The choose_cmap function is internal and used by TQGLWidget::setContext() - and GLX (not Windows). If the application can't tqfind any sharable + and GLX (not Windows). If the application can't find any sharable colormaps, it must at least create as few colormaps as possible. The dictionary solution below ensures only one colormap is created per visual. Colormaps are also deleted when the application terminates. @@ -244,7 +244,7 @@ static Colormap choose_cmap( Display *dpy, XVisualInfo *vi ) qAddPostRoutine( cleanup_cmaps ); } - CMapEntry *x = cmap_dict->tqfind( (long) vi->visualid + ( vi->screen * 256 ) ); + CMapEntry *x = cmap_dict->find( (long) vi->visualid + ( vi->screen * 256 ) ); if ( x ) // found colormap for visual return x->cmap; @@ -284,7 +284,7 @@ static Colormap choose_cmap( Display *dpy, XVisualInfo *vi ) if ( !x->cmap ) { #ifdef TQT_DLOPEN_OPENGL typedef Status (*_XmuLookupStandardColormap)( Display *dpy, int screen, VisualID visualid, unsigned int depth, - Atom property, Bool tqreplace, Bool retain ); + Atom property, Bool replace, Bool retain ); _XmuLookupStandardColormap qt_XmuLookupStandardColormap; qt_XmuLookupStandardColormap = (_XmuLookupStandardColormap) TQLibrary::resolve("Xmu.so.6", "XmuLookupStandardColormap"); if (!qt_XmuLookupStandardColormap) @@ -334,7 +334,7 @@ static TQMemArray<TransColor> trans_colors; static int trans_colors_init = FALSE; -static void tqfind_trans_colors() +static void find_trans_colors() { struct OverlayProp { long visual; @@ -407,7 +407,7 @@ bool TQGLFormat::hasOpenGLOverlays() { qt_resolve_gl_symbols(); if ( !trans_colors_init ) - tqfind_trans_colors(); + find_trans_colors(); return trans_colors.size() > 0; } @@ -508,7 +508,7 @@ bool TQGLContext::chooseContext( const TQGLContext* shareContext ) /*! - <strong>X11 only</strong>: This virtual function tries to tqfind a + <strong>X11 only</strong>: This virtual function tries to find a visual that matches the format, reducing the demands if the original request cannot be met. @@ -599,12 +599,12 @@ void *TQGLContext::tryVisual( const TQGLFormat& f, int bufDepth ) if ( f.plane() && !useTranspExtChecked && d->paintDevice ) { TQCString estr( glXQueryExtensionsString( d->paintDevice->x11Display(), d->paintDevice->x11Screen() ) ); - useTranspExt = estr.tqcontains( "GLX_EXT_visual_info" ); + useTranspExt = estr.contains( "GLX_EXT_visual_info" ); //# (A bit simplistic; that could theoretically be a substring) if ( useTranspExt ) { TQCString cstr( glXGetClientString( d->paintDevice->x11Display(), GLX_VENDOR ) ); - useTranspExt = !cstr.tqcontains( "Xi Graphics" ); // bug workaround + useTranspExt = !cstr.contains( "Xi Graphics" ); // bug workaround if ( useTranspExt ) { // bug workaround - some systems (eg. FireGL) refuses to return an overlay // visual if the GLX_TRANSPARENT_TYPE_EXT attribute is specfied, even if @@ -747,7 +747,7 @@ TQColor TQGLContext::overlayTransparentColor() const //### make more efficient using the transpColor member if ( isValid() ) { if ( !trans_colors_init ) - tqfind_trans_colors(); + find_trans_colors(); VisualID myVisualId = ((XVisualInfo*)vi)->visualid; int myScreen = ((XVisualInfo*)vi)->screen; @@ -785,7 +785,7 @@ uint TQGLContext::colorIndex( const TQColor& c ) const return c.pixel( screen ); // We're using TQColor's cmap XVisualInfo *info = (XVisualInfo *) vi; - CMapEntry *x = cmap_dict->tqfind( (long) info->visualid + ( info->screen * 256 ) ); + CMapEntry *x = cmap_dict->find( (long) info->visualid + ( info->screen * 256 ) ); if ( x && !x->alloc) { // It's a standard colormap int rf = (int)(((float)c.red() * (x->scmap.red_max+1))/256.0); int gf = (int)(((float)c.green() * (x->scmap.green_max+1))/256.0); @@ -800,7 +800,7 @@ uint TQGLContext::colorIndex( const TQColor& c ) const qglcmap_dict = new TQIntDict< TQMap<int, TQRgb> >; } TQMap<int, TQRgb> *cmap; - if ((cmap = qglcmap_dict->tqfind((long) info->visualid)) == 0) { + if ((cmap = qglcmap_dict->find((long) info->visualid)) == 0) { cmap = new TQMap<int, TQRgb>; qglcmap_dict->insert((long) info->visualid, cmap); } @@ -1177,7 +1177,7 @@ void TQGLWidget::setContext( TQGLContext *context, XVisualInfo *vi = (XVisualInfo*)glcx->vi; XSetWindowAttributes a; - a.colormap = choose_cmap( x11Display(), vi ); // tqfind best colormap + a.colormap = choose_cmap( x11Display(), vi ); // find best colormap a.background_pixel = backgroundColor().pixel( vi->screen ); a.border_pixel = TQt::black.pixel( vi->screen ); Window p = RootWindow( x11Display(), vi->screen ); @@ -1198,7 +1198,7 @@ void TQGLWidget::setContext( TQGLContext *context, XFree( (char *)cmwret ); int i; for ( i=0; i<count; i++ ) { - if ( cmw[i] == winId() ) { // tqreplace old window + if ( cmw[i] == winId() ) { // replace old window cmw[i] = w; break; } diff --git a/tqtinterface/qt4/src/opengl/tqglcolormap.cpp b/tqtinterface/qt4/src/opengl/tqglcolormap.cpp index 6366e8b..3afdb7c 100644 --- a/tqtinterface/qt4/src/opengl/tqglcolormap.cpp +++ b/tqtinterface/qt4/src/opengl/tqglcolormap.cpp @@ -255,10 +255,10 @@ int TQGLColormap::size() const Returns the index of the color \a color. If \a color is not in the map, -1 is returned. */ -int TQGLColormap::tqfind( TQRgb color ) const +int TQGLColormap::find( TQRgb color ) const { if ( d ) - return d->cells.tqfind( color ); + return d->cells.find( color ); return -1; } @@ -266,9 +266,9 @@ int TQGLColormap::tqfind( TQRgb color ) const Returns the index of the color that is the closest match to color \a color. */ -int TQGLColormap::tqfindNearest( TQRgb color ) const +int TQGLColormap::findNearest( TQRgb color ) const { - int idx = tqfind( color ); + int idx = find( color ); if ( idx >= 0 ) return idx; int mapSize = size(); diff --git a/tqtinterface/qt4/src/opengl/tqglcolormap.h b/tqtinterface/qt4/src/opengl/tqglcolormap.h index d6fec59..2019496 100644 --- a/tqtinterface/qt4/src/opengl/tqglcolormap.h +++ b/tqtinterface/qt4/src/opengl/tqglcolormap.h @@ -72,8 +72,8 @@ public: void setEntry( int idx, const TQColor & color ); TQRgb entryRgb( int idx ) const; TQColor entryColor( int idx ) const; - int tqfind( TQRgb color ) const; - int tqfindNearest( TQRgb color ) const; + int find( TQRgb color ) const; + int findNearest( TQRgb color ) const; private: class Private : public TQShared |
