diff options
author | Qt Continuous Integration System <qt-info@nokia.com> | 2011-09-27 00:20:24 (GMT) |
---|---|---|
committer | Qt Continuous Integration System <qt-info@nokia.com> | 2011-09-27 00:20:24 (GMT) |
commit | d7489680a80df5d77fbc032b1bc656a8dab1a986 (patch) | |
tree | 57e8d94833275c2df28ad71dfa70f843498c243a | |
parent | 2f86072e5daf318a2aa9d400f045eae9563b2ae6 (diff) | |
parent | ad7ddea09126efeb58ab626dc13113e3e1956912 (diff) | |
download | Qt-d7489680a80df5d77fbc032b1bc656a8dab1a986.zip Qt-d7489680a80df5d77fbc032b1bc656a8dab1a986.tar.gz Qt-d7489680a80df5d77fbc032b1bc656a8dab1a986.tar.bz2 |
Merge branch 'master' of scm.dev.nokia.troll.no:qt/qt-fire-staging into master-integration
* 'master' of scm.dev.nokia.troll.no:qt/qt-fire-staging:
Update changes-4.8.0 file
Only limit cursor position when line is wrapped
Make sure cursor position doesn't exceed line end
Allow shared EGL contexts for xcb and xlib platforms
Allow generic EGL platform contexts to be shared
4.8 Changes: OpenGL Framebuffer Format
stop tslib plugin having same file name as linux input plugin
Avoid unnecessary detach of a QImage in QPixmapDropShadowFilter
-rw-r--r-- | dist/changes-4.8.0 | 4 | ||||
-rw-r--r-- | src/gui/image/qpixmapfilter.cpp | 12 | ||||
-rw-r--r-- | src/gui/text/qtextlayout.cpp | 3 | ||||
-rw-r--r-- | src/plugins/generic/tslib/tslib.pro | 2 | ||||
-rw-r--r-- | src/plugins/platforms/eglconvenience/qeglplatformcontext.cpp | 5 | ||||
-rw-r--r-- | src/plugins/platforms/eglconvenience/qeglplatformcontext.h | 2 | ||||
-rw-r--r-- | src/plugins/platforms/xcb/qxcbwindow.cpp | 2 | ||||
-rw-r--r-- | src/plugins/platforms/xlib/qxlibwindow.cpp | 2 |
8 files changed, 18 insertions, 14 deletions
diff --git a/dist/changes-4.8.0 b/dist/changes-4.8.0 index 9b118d5..5dd1d8a 100644 --- a/dist/changes-4.8.0 +++ b/dist/changes-4.8.0 @@ -33,7 +33,7 @@ General Improvements Third party components ---------------------- - - Updated libpng to version 1.5.1 + - Updated libpng to version 1.5.4 - Updated libjpeg to version 8c - Updated zlib to version 1.2.5 @@ -154,6 +154,8 @@ QtNetwork - Optimize behavior of QGLTextureCache - Support subpixel antialiasing when possible. - [QTBUG-13450] Fixed path drawing on FBOs without stencil buffer. + - Reading from the FrameBuffer with Qt now correctly gives an image + marked as premultiplied. QtScript -------- diff --git a/src/gui/image/qpixmapfilter.cpp b/src/gui/image/qpixmapfilter.cpp index a33e173..6c03990 100644 --- a/src/gui/image/qpixmapfilter.cpp +++ b/src/gui/image/qpixmapfilter.cpp @@ -1362,16 +1362,14 @@ void QPixmapDropShadowFilter::draw(QPainter *p, qt_blurImage(&blurPainter, tmp, d->radius, false, true); blurPainter.end(); - tmp = blurred; - // blacken the image... - tmpPainter.begin(&tmp); - tmpPainter.setCompositionMode(QPainter::CompositionMode_SourceIn); - tmpPainter.fillRect(tmp.rect(), d->color); - tmpPainter.end(); + QPainter blackenPainter(&blurred); + blackenPainter.setCompositionMode(QPainter::CompositionMode_SourceIn); + blackenPainter.fillRect(blurred.rect(), d->color); + blackenPainter.end(); // draw the blurred drop shadow... - p->drawImage(pos, tmp); + p->drawImage(pos, blurred); // Draw the actual pixmap... p->drawPixmap(pos, px, src); diff --git a/src/gui/text/qtextlayout.cpp b/src/gui/text/qtextlayout.cpp index d0c1a0e..a86cf05 100644 --- a/src/gui/text/qtextlayout.cpp +++ b/src/gui/text/qtextlayout.cpp @@ -2612,6 +2612,9 @@ qreal QTextLine::cursorToX(int *cursorPos, Edge edge) const x += eng->offsetInLigature(si, pos, end, glyph_pos); } + if (eng->option.wrapMode() != QTextOption::NoWrap && x > line.width) + x = line.width; + *cursorPos = pos + si->position; return x.toReal(); } diff --git a/src/plugins/generic/tslib/tslib.pro b/src/plugins/generic/tslib/tslib.pro index 74c7fd2..760fbae 100644 --- a/src/plugins/generic/tslib/tslib.pro +++ b/src/plugins/generic/tslib/tslib.pro @@ -1,4 +1,4 @@ -TARGET = qlinuxinputplugin +TARGET = qtslibplugin include(../../qpluginbase.pri) QTDIR_build:DESTDIR = $$QT_BUILD_TREE/plugins/generic diff --git a/src/plugins/platforms/eglconvenience/qeglplatformcontext.cpp b/src/plugins/platforms/eglconvenience/qeglplatformcontext.cpp index 4d1d63e..d733cd6 100644 --- a/src/plugins/platforms/eglconvenience/qeglplatformcontext.cpp +++ b/src/plugins/platforms/eglconvenience/qeglplatformcontext.cpp @@ -48,7 +48,7 @@ #include <EGL/egl.h> -QEGLPlatformContext::QEGLPlatformContext(EGLDisplay display, EGLConfig config, EGLint contextAttrs[], EGLSurface surface, EGLenum eglApi) +QEGLPlatformContext::QEGLPlatformContext(EGLDisplay display, EGLConfig config, EGLint contextAttrs[], EGLSurface surface, EGLenum eglApi, QEGLPlatformContext *shareContext) : QPlatformGLContext() , m_eglDisplay(display) , m_eglSurface(surface) @@ -59,7 +59,8 @@ QEGLPlatformContext::QEGLPlatformContext(EGLDisplay display, EGLConfig config, E } eglBindAPI(m_eglApi); - m_eglContext = eglCreateContext(m_eglDisplay,config, 0,contextAttrs); + EGLContext shareEglContext = shareContext ? shareContext->eglContext() : 0; + m_eglContext = eglCreateContext(m_eglDisplay,config, shareEglContext, contextAttrs); if (m_eglContext == EGL_NO_CONTEXT) { qWarning("Could not create the egl context\n"); eglTerminate(m_eglDisplay); diff --git a/src/plugins/platforms/eglconvenience/qeglplatformcontext.h b/src/plugins/platforms/eglconvenience/qeglplatformcontext.h index 9be1480..614b3cb 100644 --- a/src/plugins/platforms/eglconvenience/qeglplatformcontext.h +++ b/src/plugins/platforms/eglconvenience/qeglplatformcontext.h @@ -48,7 +48,7 @@ class QEGLPlatformContext : public QPlatformGLContext { public: - QEGLPlatformContext(EGLDisplay display, EGLConfig config, EGLint contextAttrs[], EGLSurface surface, EGLenum eglApi); + QEGLPlatformContext(EGLDisplay display, EGLConfig config, EGLint contextAttrs[], EGLSurface surface, EGLenum eglApi, QEGLPlatformContext *shareContext = 0); ~QEGLPlatformContext(); void makeCurrent(); diff --git a/src/plugins/platforms/xcb/qxcbwindow.cpp b/src/plugins/platforms/xcb/qxcbwindow.cpp index 0a02c7e..ed88138 100644 --- a/src/plugins/platforms/xcb/qxcbwindow.cpp +++ b/src/plugins/platforms/xcb/qxcbwindow.cpp @@ -516,7 +516,7 @@ QPlatformGLContext *QXcbWindow::glContext() const EGLSurface eglSurface = eglCreateWindowSurface(display,config,(EGLNativeWindowType)m_window,0); QXcbWindow *that = const_cast<QXcbWindow *>(this); - that->m_context = new QEGLPlatformContext(display, config, eglContextAttrs.data(), eglSurface, EGL_OPENGL_ES_API); + that->m_context = new QEGLPlatformContext(display, config, eglContextAttrs.data(), eglSurface, EGL_OPENGL_ES_API, static_cast<QEGLPlatformContext *>(widget()->platformWindowFormat().sharedGLContext())); #elif defined(XCB_USE_DRI2) QXcbWindow *that = const_cast<QXcbWindow *>(this); that->m_context = new QDri2Context(that); diff --git a/src/plugins/platforms/xlib/qxlibwindow.cpp b/src/plugins/platforms/xlib/qxlibwindow.cpp index 823fae9..16c5ed5 100644 --- a/src/plugins/platforms/xlib/qxlibwindow.cpp +++ b/src/plugins/platforms/xlib/qxlibwindow.cpp @@ -687,7 +687,7 @@ QPlatformGLContext *QXlibWindow::glContext() const eglContextAttrs.append(EGL_NONE); EGLSurface eglSurface = eglCreateWindowSurface(display,config,(EGLNativeWindowType)x_window,0); - that->mGLContext = new QEGLPlatformContext(display, config, eglContextAttrs.data(), eglSurface, EGL_OPENGL_ES_API); + that->mGLContext = new QEGLPlatformContext(display, config, eglContextAttrs.data(), eglSurface, EGL_OPENGL_ES_API, static_cast<QEGLPlatformContext *>(windowFormat.sharedGLContext())); #endif #endif } |