summaryrefslogtreecommitdiffstats
path: root/tests/auto/qgraphicsgridlayout
Commit message (Collapse)AuthorAgeFilesLines
* Merge branch 'master-upstream'Gabriel de Dietrich2011-02-081-0/+158
|\
| * Merge remote branch 'origin/4.7' into qt-master-from-4.7Olivier Goffart2011-01-251-0/+158
| |\ | | | | | | | | | | | | | | | Conflicts: configure src/network/bearer/bearer.pri
| | * Merge branch '4.7-review' into 4.7-stagingThierry Bastian2011-01-171-0/+158
| | |\
| | | * Some unit tests for layout explosion thingyJohn Tapsell2011-01-131-0/+158
| | | | | | | | | | | | | | | | | | | | | | | | Adds more tests for commit 7fbf1829e11504eca6a55f1e5dbddf2f658b5302 Task-number: QTBUG-13551
* | | | Merge branch 'master-upstream' into master-waterThierry Bastian2011-01-201-1/+1
|\ \ \ \ | |/ / /
| * | | Merge remote branch 'origin/4.7' into qt-master-from-4.7Olivier Goffart2011-01-171-1/+1
| |\ \ \ | | |/ / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: examples/webkit/imageanalyzer/imageanalyzer.h examples/webkit/imageanalyzer/mainwindow.h mkspecs/unsupported/qws/linux-x86-openkode-g++/qplatformdefs.h src/corelib/io/qfsfileengine_iterator_unix.cpp src/corelib/io/qfsfileengine_iterator_win.cpp src/corelib/kernel/qcoreapplication.cpp src/network/access/qnetworkaccessdatabackend.cpp src/plugins/bearer/connman/qconnmanservice_linux.cpp src/plugins/platforms/openvglite/qwindowsurface_vglite.h src/s60installs/bwins/QtCoreu.def src/s60installs/eabi/QtCoreu.def src/s60installs/s60installs.pro tools/assistant/tools/assistant/helpviewer_qwv.h tools/qdoc3/test/qt-html-templates.qdocconf
| | * | Update copyright year to 2011.Jason McDonald2011-01-101-1/+1
| | |/ | | | | | | | | | Reviewed-by: Trust Me
* | | Enable the widthForHeight() test case.Jan-Arve Saether2011-01-191-5/+4
| | | | | | | | | | | | | | | | | | | | | | | | While I did that I also found a copy-paste (?) bug in the WFH case of QGridLayoutEngine::sizeHint() that caused the widthForHeight() case to fail. Task-number: QTBUG-14693
* | | Fix some wrong tests in heightForWidth()Jan-Arve Saether2011-01-191-15/+18
| | | | | | | | | | | | | | | | | | | | | | | | This aligns better with heightForWidth() as it is in 4.7. However, I've left out the exact matching with stretch factors, (the expectedWidth() function tried to deal with that) because it makes the test less robust (relies on undocumented behaviour and floating point number comparisions).
* | | Fix and enable the tests that were disabled.Jan-Arve Saether2011-01-191-37/+33
|/ / | | | | | | | | | | This is basically doing the same fixes as commit 5c129ceed8cb157354250e1a938f0b8af5dfe507 did in 4.7 branch. (except that in 4.7 branch the tests were removed and then re-added)
* | Merge remote branch 'origin/4.7' into qt-master-from-4.7Olivier Goffart2010-11-251-22/+330
|\ \ | |/ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: qmake/generators/symbian/symmake.cpp src/corelib/global/qglobal.h src/gui/kernel/qwidget_p.h src/gui/painting/qtextureglyphcache.cpp src/opengl/gl2paintengineex/qpaintengineex_opengl2.cpp src/opengl/gl2paintengineex/qtextureglyphcache_gl.cpp src/opengl/gl2paintengineex/qtextureglyphcache_gl_p.h src/plugins/qpluginbase.pri src/qbase.pri tests/auto/qgraphicsgridlayout/tst_qgraphicsgridlayout.cpp tests/auto/qthread/tst_qthread.cpp tests/auto/selftests/expected_cmptest.txt tests/auto/selftests/expected_crashes_3.txt tests/auto/selftests/expected_longstring.txt tests/auto/selftests/expected_maxwarnings.txt tests/auto/selftests/expected_skip.txt tools/assistant/tools/assistant/doc/assistant.qdocconf tools/qdoc3/test/assistant.qdocconf tools/qdoc3/test/designer.qdocconf tools/qdoc3/test/linguist.qdocconf tools/qdoc3/test/qdeclarative.qdocconf tools/qdoc3/test/qmake.qdocconf tools/qdoc3/test/qt-build-docs.qdocconf tools/qdoc3/test/qt-build-docs_ja_JP.qdocconf tools/qdoc3/test/qt-build-docs_zh_CN.qdocconf tools/qdoc3/test/qt.qdocconf tools/qdoc3/test/qt_ja_JP.qdocconf tools/qdoc3/test/qt_zh_CN.qdocconf
| * Fix the tests that got affected by the behaviour added in 604c51f1fc5c79Jan-Arve Sæther2010-11-191-2/+2
| | | | | | | | | | Task-number: QTBUG-13551 Task-number: QTBUG-7756
| * Adhere to code styleJan-Arve Sæther2010-11-151-4/+4
| |
| * Change the QGraphics*Layout documentation to match the code - that the ↵John Tapsell2010-11-151-2/+43
| | | | | | | | | | | | | | | | | | | | default alignment is top-left. This includes unit tests to confirm that the alignment is top-left in a variety of different cases. Merge-request: 894 Reviewed-by: Jan-Arve Sæther <jan-arve.saether@nokia.com>
| * Fix item alignment in layouts bigger than the items thay they containJohn Tapsell2010-11-151-9/+61
| | | | | | | | | | | | | | | | Task-number: QTBUG-13551 Task-number: QTBUG-7756 Merge-request: 894 Reviewed-by: Jan-Arve Sæther <jan-arve.saether@nokia.com>
| * Add autotest to test a issue with stretches and preferred width.Jan-Arve Sæther2010-11-151-0/+62
| | | | | | | | | | | | | | | | | | | | The issue seemed to claim that the preferred size was not respected when there was another item that could stretch along the same axis: "A widget with a horizontal stretch next to it should get its preferredWidth()". This seems to works as expected, so nothing to fix. Task-number: QTBUG-12835
| * Add back the tests that were removed by commit ↵Jan-Arve Sæther2010-11-121-0/+174
| | | | | | | | | | | | fcda1b785bd7d86011f49bfe96cb22b04202933f Also add a proper test for the alignment problem
| * Fix a behaviour change of sizeHint() introduced by 6d4d265e7e67dde58Jan-Arve Sæther2010-11-111-7/+12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Commit 6d4d265e7e67dde58e45d7d89f4974d0bd8b70e4 added a behaviour change in the cases if there was an item with height-for-width and sizeHint() was called with no constraint. The commit tried to return the height needed for the preferred width, but it still did not satisfy the constraints, since the width used as the constraint could be less than the preferred width. This also meant that the sizeHint(Qt::MinimumSize) could actually be larger than the smallest possible size. The behaviour should be that it should return the smallest width possible regardless of height. For instance, for a label it could return the size of the longest word (to avoid hyphenation issues). The same logic applies for the height: It should return the smallest height possible regardless of width. For instance, for a label it could then return the height of the font. I also had to fix some stuff in the heightForWidthWithSpanning() autotest since it wrongly expected the maximum size to be QWIDGETSIZE_MAX in several of the cases. However, that is the current behaviour (and it is a bug), but it is unrelated to the problem with spans so I simply fix the test and mark them with QEXPECT_FAIL. Reviewed-by: John Tapsell
* | Merge commit 'fcda1b785bd7d86011f49bfe96cb22b04202933f' into qt-master-from-4.7Olivier Goffart2010-10-251-31/+219
|\ \ | |/ | | | | | | | | | | | | Conflicts: tests/auto/qgraphicsgridlayout/tst_qgraphicsgridlayout.cpp Some tests in tst_qgraphicsgridlayout are commented out because they are failing. See task QTBUG-14693
| * QGraphicsLayoutItem - user set sizes should always override, even if there's ↵John Tapsell2010-10-131-156/+177
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | a constraint Notes: * I have had to remove some of the old unit tests because the tested for strange behaviour. Now that height for width items behave more like normal items, it's no longer so easy to calculate what the geometries should be in strangely-sized layouts. * This also fixes alignment of height-for-width objects and adds a unit test for this. This couldn't be done in a seperate commit since the two fixes are related. Merge-request: 847 Reviewed-by: Olivier Goffart
| * QGridLayoutEngine - Rework height-for-width support so that row/col spanning ↵John Tapsell2010-10-131-0/+35
| | | | | | | | | | | | | | | | works Task-number: QTBUG-13547 Reviewed-by: Olivier Goffart Merge-request: 847
| * Revert "Revert "Fix (implement!) hfw/wfh in QGridLayoutEngine""Olivier Goffart2010-10-131-4/+360
| | | | | | | | | | | | | | | | This reverts commit 5bd6f7eb5c7d87c08539b6c2df416990cc417ec7. This is a revert of the revert. It is required apply the merge-request 847, which itself revert back part of this commit but fixing it the (hopefuly) right way
| * Revert "Fix (implement!) hfw/wfh in QGridLayoutEngine"Thierry Bastian2010-09-301-360/+4
| | | | | | | | | | | | | | | | | | | | | | This reverts commit 62b5ef3cc1306e46a4042b14867f2f92d9a110f3. The implementation of hfw from this patch is unfortunately not robust enough. It doesn't manage correctly the constraints on the layouts and the cell spans. It caused bad behaviour or regressions seen in tasks: QTBUG-13547, QTBUG-13067, QTBUG-13549, and more Reviewed-By: ogoffart
* | Enable the width-for-height codepath and add autotest for WFH.Jan-Arve Sæther2010-09-021-62/+301
| | | | | | | | Task-number: Side-effect of QTBUG-3570
* | Merge remote branch 'origin/4.7' into qt-master-from-4.7Olivier Goffart2010-08-131-16/+372
|\ \ | |/ | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/gui/painting/qpainter.cpp src/gui/text/qtextengine.cpp tests/auto/qimage/tst_qimage.cpp tests/auto/qpainter/tst_qpainter.cpp tools/qdoc3/test/assistant.qdocconf tools/qdoc3/test/designer.qdocconf tools/qdoc3/test/linguist.qdocconf tools/qdoc3/test/qmake.qdocconf tools/qdoc3/test/qt-build-docs.qdocconf tools/qdoc3/test/qt-html-templates.qdocconf tools/qdoc3/test/qt-html-templates_zh_CN.qdocconf tools/qdoc3/test/qt.qdocconf
| * Merge branch 'hfw_2nd' into 4.7Jan-Arve Sæther2010-08-111-4/+360
| |\
| | * Fix (implement!) hfw/wfh in QGridLayoutEngineJan-Arve Sæther2010-08-101-4/+360
| | | | | | | | | | | | | | | | | | | | | | | | Note that only height-for-width works, since we cannot add QSizePolicy::hasWidthForHeight() in a patch release. Task-number: QT-3570 Reviewed-by: Paul
| * | Layout items had the wrong size if the layout was resized to maximum.Jan-Arve Sæther2010-08-111-12/+12
| |/ | | | | | | | | | | | | | | | | | | | | | | The problem was that if targetSize was the layouts maximum size, then sumAvailable could be reduced to exactly 0 in the "while (keepGoing)" loop. That would mean that we would not enter the block that actually copied the new sizes from the temporary "newSizes" array to the output "sizes" array due to the "if (sumAvailable > 0)" condition. Task-number: none, discovered while fixing QT-3570 Reviewed-by: Frederik Gladhorn
* | Some polishing to merge request 723Jan-Arve Sæther2010-08-111-2/+11
| |
* | Patch to QTBUG-3078Carolina Gomes2010-08-111-0/+18
| | | | | | | | | | Merge-request: 723 Reviewed-by: Jan-Arve Sæther <jan-arve.saether@nokia.com>
* | Merge remote branch 'origin/4.7' into qt-master-from-4.7Olivier Goffart2010-07-281-0/+7
|\ \ | |/ | | | | | | | | | | | | | | | | | | | | Conflicts: src/gui/kernel/qapplication.cpp tests/auto/qfileinfo/tst_qfileinfo.cpp tools/qdoc3/test/assistant.qdocconf tools/qdoc3/test/designer.qdocconf tools/qdoc3/test/linguist.qdocconf tools/qdoc3/test/qmake.qdocconf tools/qdoc3/test/qt-build-docs.qdocconf tools/qdoc3/test/qt.qdocconf
| * Work around memory leak issue in grid and linear layouts.Andreas Aardal Hanssen2010-07-141-0/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | These classes create a new QWidget and assign it to a static pointer which is never cleaned up. Using Q_GLOBAL_STATIC ensures that they are deleted on library unload. This is really just a cosmetic change that removes a leak warning - the real fix should be to find a way to not use a new QWidget like this. It seems odd that QGraphicsLayouts, which don't use QWidget in any other way, should depend on QWidget like this. Task-number: QTBUG-10768 Merge-request: 741 Reviewed-by: Jan-Arve Sæther <jan-arve.saether@nokia.com>
* | Merge remote branch 'origin/4.7' into qt-master-from-4.7Thiago Macieira2010-07-011-22/+64
|\ \ | |/ | | | | | | | | | | | | | | Conflicts: bin/syncqt src/gui/text/qtextlayout.cpp tools/assistant/tools/assistant/helpviewer_qwv.cpp tools/assistant/tools/assistant/helpviewer_qwv.h tools/configure/configureapp.cpp
| * Fixed problem with wrong size hints when items were removed.Jan-Arve Sæther2010-06-161-22/+64
| | | | | | | | | | | | | | | | | | | | The reason was that the row/column count was not updated after an item was removed. (Note that qgraphicslinearlayout already did this, so we just follow the same pattern, except that the code for QGraphicsGridLayout is a bit more complex... Task-number: QTBUG-10314 Reviewed-by: Alexis Menard
* | Added 'parallel_test' for some QGraphics* auto-tests.Yoann Lopes2010-04-221-1/+1
|/
* Merge branch '4.6' of scm.dev.nokia.troll.no:qt/oslo-staging-1 into ↵Qt Continuous Integration System2010-01-071-1/+1
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 4.6-integration * '4.6' of scm.dev.nokia.troll.no:qt/oslo-staging-1: QIODevice: Fix readAll() Temporary hackiesh solution to prevent BOM in the xml data. Fixed qxmlstream autotest when using shadow builds. Attempt at readding the capital P headers for Phonon Remove special Phonon processing from syncqt. Use the lowercase/shortname.h headers for Phonon includes Fixes a crash when setting focus on a widget with a focus proxy. Update copyright year to 2010 doc: Clarified activeSubControls and subControls. Remove warning "statement with no effect" doc: Clarified that .lnk files are System files on Windows.
| * Update copyright year to 2010Jason McDonald2010-01-061-1/+1
| | | | | | | | Reviewed-by: Trust Me
* | Fixed a bug with distribution of spans.Jan-Arve Sæther2010-01-051-160/+222
|/ | | | | | | | | | If a span required more size than the rows/columns it spanned, the size of the span was not distributed to the rows it spanned. The result was that the size hints of the layout was not correct, causing the layout to be potentially smaller than the spanning item. Task: QT-2261 Reviewed-by: Alexis
* Replace most processEvents() with sendPostedEvents().Jan-Arve Sæther2009-11-101-8/+8
| | | | | | | After a change Brad did to the event dispatcher we are no longer guaranteed that processEvents will process *all* events in the event queue. (most of the time _it_will_ process all events) I only replaced processEvents for the tests that failed.
* Do not loop forever if we are adding the layout itself to the layout.Jan-Arve Sæther2009-10-191-0/+11
| | | | Reviewed-by: alexis
* Update license headers again.Jason McDonald2009-09-091-4/+4
| | | | Reviewed-by: Trust Me
* Merge branch '4.5' into 4.6Thiago Macieira2009-08-311-13/+13
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: demos/boxes/glshaders.cpp demos/boxes/vector.h demos/embedded/fluidlauncher/pictureflow.cpp demos/embedded/fluidlauncher/pictureflow.h doc/src/desktop-integration.qdoc doc/src/distributingqt.qdoc doc/src/examples-overview.qdoc doc/src/examples.qdoc doc/src/frameworks-technologies/dbus-adaptors.qdoc doc/src/geometry.qdoc doc/src/groups.qdoc doc/src/objecttrees.qdoc doc/src/platform-notes.qdoc doc/src/plugins-howto.qdoc doc/src/qt3support.qdoc doc/src/qtdbus.qdoc doc/src/qtdesigner.qdoc doc/src/qtgui.qdoc doc/src/qtmain.qdoc doc/src/qtopengl.qdoc doc/src/qtsvg.qdoc doc/src/qtuiloader.qdoc doc/src/qundo.qdoc doc/src/richtext.qdoc doc/src/topics.qdoc src/corelib/tools/qdumper.cpp src/gui/embedded/qkbdpc101_qws.cpp src/gui/embedded/qkbdsl5000_qws.cpp src/gui/embedded/qkbdusb_qws.cpp src/gui/embedded/qkbdvr41xx_qws.cpp src/gui/embedded/qkbdyopy_qws.cpp src/gui/embedded/qmousebus_qws.cpp src/gui/embedded/qmousevr41xx_qws.cpp src/gui/embedded/qmouseyopy_qws.cpp src/gui/painting/qpaintengine_d3d.cpp src/gui/painting/qwindowsurface_d3d.cpp src/opengl/gl2paintengineex/glgc_shader_source.h src/opengl/gl2paintengineex/qglpexshadermanager.cpp src/opengl/gl2paintengineex/qglpexshadermanager_p.h src/opengl/gl2paintengineex/qglshader.cpp src/opengl/gl2paintengineex/qglshader_p.h src/opengl/util/fragmentprograms_p.h src/plugins/kbddrivers/linuxis/linuxiskbdhandler.cpp src/plugins/mousedrivers/linuxis/linuxismousehandler.cpp src/script/parser/qscript.g src/script/qscriptarray_p.h src/script/qscriptasm_p.h src/script/qscriptbuffer_p.h src/script/qscriptclass.cpp src/script/qscriptclassdata_p.h src/script/qscriptcompiler.cpp src/script/qscriptcompiler_p.h src/script/qscriptcontext.cpp src/script/qscriptcontext_p.cpp src/script/qscriptcontext_p.h src/script/qscriptcontextfwd_p.h src/script/qscriptecmaarray.cpp src/script/qscriptecmaarray_p.h src/script/qscriptecmaboolean.cpp src/script/qscriptecmacore.cpp src/script/qscriptecmadate.cpp src/script/qscriptecmadate_p.h src/script/qscriptecmaerror.cpp src/script/qscriptecmaerror_p.h src/script/qscriptecmafunction.cpp src/script/qscriptecmafunction_p.h src/script/qscriptecmaglobal.cpp src/script/qscriptecmaglobal_p.h src/script/qscriptecmamath.cpp src/script/qscriptecmamath_p.h src/script/qscriptecmanumber.cpp src/script/qscriptecmanumber_p.h src/script/qscriptecmaobject.cpp src/script/qscriptecmaobject_p.h src/script/qscriptecmaregexp.cpp src/script/qscriptecmaregexp_p.h src/script/qscriptecmastring.cpp src/script/qscriptecmastring_p.h src/script/qscriptengine.cpp src/script/qscriptengine_p.cpp src/script/qscriptengine_p.h src/script/qscriptenginefwd_p.h src/script/qscriptextenumeration.cpp src/script/qscriptextenumeration_p.h src/script/qscriptextqobject.cpp src/script/qscriptextqobject_p.h src/script/qscriptextvariant.cpp src/script/qscriptfunction.cpp src/script/qscriptfunction_p.h src/script/qscriptgc_p.h src/script/qscriptmember_p.h src/script/qscriptobject_p.h src/script/qscriptprettypretty.cpp src/script/qscriptprettypretty_p.h src/script/qscriptvalue.cpp src/script/qscriptvalueimpl.cpp src/script/qscriptvalueimpl_p.h src/script/qscriptvalueimplfwd_p.h src/script/qscriptvalueiteratorimpl.cpp src/script/qscriptxmlgenerator.cpp src/script/qscriptxmlgenerator_p.h tests/auto/linguist/lupdate/testdata/recursivescan/project.ui tests/auto/linguist/lupdate/testdata/recursivescan/sub/finddialog.cpp tests/auto/qkeyevent/tst_qkeyevent.cpp tools/linguist/shared/cpp.cpp
| * Update tech preview license header.Jason McDonald2009-08-311-13/+13
| | | | | | | | Reviewed-by: Trust Me
| * Update license headers.Jason McDonald2009-08-111-1/+1
| | | | | | | | Reviewed-by: Trust Me
* | Update contact URL in license headers.Jason McDonald2009-08-121-1/+1
| | | | | | | | Reviewed-by: Trust Me
* | Removed trailing whitespace.Jan-Arve Sæther2009-06-241-59/+59
| |
* | Fixed count(), itemAt() and removeAt() in QGraphicsLinearLayout.Jan-Arve Sæther2009-06-241-0/+3
|/ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Due to this, the behaviour of count(), itemAt() and removeAt() was different between QGraphicsLinearLayout and QGraphicsGridLayout. QGraphicsGridLayout does it right. This adds some behaviour changes: 1. QGraphicsLinearLayout::count() is no longer affected by inserted stretches (through insertStretch) This means that code like this will break: QGraphicsLinearLayout *linearLayout = new QGraphicsLinearLayout; linearLayout->addItem(new QGraphicsWidget); linearLayout->addStretch(); int count = linearLayout->count(); linearLayout->removeAt(count - 1); // before this patch it would do nothing (and it wouldn't // actually remove the stretch), with the new patch it would // remove the QGraphicsWidget. 2. count(), itemAt() and removeAt() now prints a warning for an invalid index. The documentation actually says that "The reimplementation can assume that index is valid (i.e., it respects the value of count()", but I decided that its too risky to not assume that it is valid, since it would break the following common pattern: while(layout->itemAt(0)) { layout->removeAt(0); } Cleaned up autotests (and a small codeblock) that assumed itemAt/removeAt with an invalid index to work, since we should try to follow our own advice. :-) This change is also an alignment with what QGraphicsGridLayout does (it checks the index argument and prints a warning too.)
* Update license headers as requested by the marketing department.Jason McDonald2009-06-161-2/+2
| | | | Reviewed-by: Trust Me
* Long live Qt 4.5!Lars Knoll2009-03-233-0/+2100