summaryrefslogtreecommitdiffstats
path: root/examples/widgets
Commit message (Collapse)AuthorAgeFilesLines
* Address Book example: Fix QTableView column sortingTopi Reinio2014-07-021-7/+6
| | | | | | | | | | | | Rearrange the code so that QTableView::setSortingEnabled() is called after setting up the sort filter. This ensures that new entries added to the model always follow the column header's sort order. Task-number: QTBUG-39585 Change-Id: Iaec8aa9342981817a019473ba12bad52cdbdfbb8 Reviewed-by: Mitch Curtis <mitch.curtis@digia.com> Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
* Merge remote-tracking branch 'origin/stable' into 5.3Sergio Ahumada2014-06-144-34/+70
|\ | | | | | | Change-Id: Icd073d40ce10ab4733b997036815795dd3fbaac1
| * Polish the image viewer example.Friedemann Kleint2014-06-124-34/+70
| | | | | | | | | | | | | | | | | | | | | | | | - Open files passed on the command line. - Point the file dialog to the pictures location and use a filter string for the supported types. - Set the window title according to file name. Task-number: QTBUG-37203 Task-number: QTBUG-39287 Change-Id: I4e5e43875c3a7544c862c054181e75942939c1d5 Reviewed-by: David Faure <david.faure@kdab.com>
* | Merge remote-tracking branch 'origin/stable' into 5.3Sergio Ahumada2014-06-112-2/+2
|\| | | | | | | Change-Id: I147a75ac74bd7b19dbeb99e1ec2836cc5bfc2806
| * fix qmaccocoaviewcontainer exampleOswald Buddenhagen2014-06-052-2/+2
| | | | | | | | | | | | | | | | - fix build on 10.6 - actually build it at all Change-Id: Ib929f8b56e55f00191f7fcfb2be25975e46a1af2 Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
* | Doc: Updated Layout examples.Jerome Pasion2014-06-104-23/+39
|/ | | | | | | | | | | -added links to and from the overviews. -added information on how to run the example. -updated copyright. Task-number: QTBUG-33597 Change-Id: Ib049cb94f136caa6916878959ae830248bd236b5 Reviewed-by: Martin Smith <martin.smith@digia.com> Reviewed-by: Nico Vertriest <nico.vertriest@digia.com>
* Update AddressBook ExampleSteven Ceuppens2014-04-283-3/+3
| | | | | | | | | | Adding parent to QDialog As proposed on qt-project.org forum: http://qt-project.org/forums/viewthread/41686/ Change-Id: Ib66d24e4afd0be803a1080c37bc6c0a189844786 Reviewed-by: Sze Howe Koh <szehowe.koh@gmail.com> Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@digia.com>
* purge vestiges of opengl es 1 supportOswald Buddenhagen2014-04-042-3/+3
| | | | | | | | amends 0d5170256c1. Change-Id: Ifa178d38f602bb7c66ef13334673ff47e332af5b Reviewed-by: Jørgen Lind <jorgen.lind@digia.com> Reviewed-by: Laszlo Agocs <laszlo.agocs@digia.com>
* Polish the image gestures example.Friedemann Kleint2014-03-285-34/+138
| | | | | | | | | | | | | | | | | | - Add a command line parser to properly evaluate help option and directory argument, add options to disable gestures. - Add logging category so that the user can actually see what is happening. - Scale large images. - Use qreal instead of float. - Minor polishing: set window title, position file dialog at pictures location. Task-number: QTBUG-37759 Task-number: QTBUG-37203 Change-Id: Ibaf54a13034b150386a8aee476f83a9eba298298 Reviewed-by: Indrajit Tapadar <indrajit.tapadar@digia.com> Reviewed-by: Shawn Rutledge <shawn.rutledge@digia.com>
* Save using a window-modal sheet on Mac OS X.Morten Johan Sørvig2014-03-201-3/+8
| | | | | | Change-Id: Icd150787f9ff0878fafd459b3741d1b1e008f8bc Reviewed-by: Jake Petroules <jake.petroules@petroules.com> Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@digia.com>
* Doc: correction link, example and parameter issues qtbaseNico Vertriest2014-03-102-1/+1
| | | | | | | | | | | | | Moved codecs folder to qtbase/examples Corrected quote in dropsite.qdoc Replaced snippet statement by include statement Added doc for undocumented parameters Task-number: QTBUG-34749 Change-Id: If4de95b8d39e5680fd0f63f8d2b6685a4b0a8052 Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@digia.com> Reviewed-by: Sean Harmer <sean.harmer@kdab.com>
* Fix warning about unused memberJędrzej Nowacki2014-03-061-2/+1
| | | | | | | sub-attaq/boat_p.h:134:9: warning: private field 'key' is not used [-Wunused-private-field] Change-Id: I3f4cb1325aaac71d2bf0e7807381742937d173f7 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
* CustomSortFilterModel example: fix build with QT_NO_CURSORAndrew Knight2014-03-061-0/+2
| | | | | Change-Id: Icb40e49365114fedd5f1ef118dbd61ff2c413863 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
* Doc: Replace obsolete types with their newer counterpartsSze Howe Koh2014-02-251-1/+1
| | | | | | | | | This patch ignores: - Docs for obsolete types themselves - Comparisons between new and obsolete types Change-Id: Id9b1e628255113e7c44520abe0f8a4e0db4a283d Reviewed-by: Jerome Pasion <jerome.pasion@digia.com>
* Merge remote-tracking branch 'origin/stable' into devFrederik Gladhorn2014-02-122-4/+1
|\ | | | | | | | | | | | | | | | | | | Conflicts: src/gui/image/qimage.cpp src/gui/text/qtextengine.cpp src/plugins/platforms/linuxfb/qlinuxfbscreen.cpp src/printsupport/kernel/qprintengine_win.cpp Change-Id: I09ce991a57f39bc7b1ad6978d0e0d858df0cd444
| * Fix out-of-tree compilation of widget examplesKai Koehne2014-02-112-4/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | 'styles' are only defined in the qt build internals, when the examples are compiled inside a configured Qt source. That's not the case for the examples e.g. in the Qt SDK. (windows is a default style on all platforms, anyway. So I think the check is superfluous in the first place.) Task-number: QTBUG-36655 Change-Id: I7114619efd479408dad99c8514f8e33ddcab7c7c Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
* | Merge "Merge remote-tracking branch 'origin/stable' into dev" into ↵Frederik Gladhorn2014-02-1122-14/+677
|\ \ | | | | | | | | | refs/staging/dev
| * | Merge remote-tracking branch 'origin/stable' into devFrederik Gladhorn2014-02-0722-14/+677
| |\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/gui/kernel/qguiapplication.cpp src/plugins/platforms/android/androidjnimain.cpp src/plugins/platforms/android/qandroidplatformintegration.cpp src/plugins/platforms/android/qandroidplatformintegration.h src/plugins/platforms/android/qandroidplatformopenglcontext.cpp src/plugins/platforms/cocoa/qcocoawindow.h src/plugins/platforms/cocoa/qcocoawindow.mm src/plugins/platforms/xcb/qxcbconnection_xi2.cpp src/sql/doc/src/sql-driver.qdoc src/widgets/widgets/qtoolbararealayout.cpp Change-Id: Ifd7e58760c3cb6bd8a7d1dd32ef83b7ec190d41e
| | * Update some more screenshots in qtbase/examples/widgets.Mitch Curtis2014-01-314-0/+0
| | | | | | | | | | | | | | | | | | | | | The screenshots were taken on Windows 7 with the Aero theme. Change-Id: I2517664e25389f4fb87408daec7b720dfb785bf0 Reviewed-by: Topi Reiniö <topi.reinio@digia.com>
| | * Doc: corrected link/example errorsNico Vertriest2014-01-3110-4/+667
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Update pro files after move gestures folder Update snippet statements Corrected path in imagegestures.pro Task-number: QTBUG-34749 Change-Id: Icc19908914e36507e412ab63bf0cc2809aa48e17 Reviewed-by: Jerome Pasion <jerome.pasion@digia.com>
| | * Update some screenshots in qtbase/examples/widgets.Mitch Curtis2014-01-318-0/+0
| | | | | | | | | | | | | | | | | | | | | The screenshots were taken on Windows 7 with the Aero theme. Change-Id: Ief04c3a9c0084a778606ba72f1f3199119d5c64e Reviewed-by: Topi Reiniö <topi.reinio@digia.com>
| | * Doc: corrected broken linksNico Vertriest2014-01-231-10/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Links fixed: Extra Filters Basic Tools blockingfortuneclient Thread Support Drag and drop examples qBinaryFind qmake common project types imagegestures Task-number: QTBUG-34749 Change-Id: Ib93dda00716dc596db327fee5b97e110a9f27fa7 Reviewed-by: Martin Smith <martin.smith@digia.com>
* | | widgets/mainwindows/mainwindow example: Use mouse release event for dock title.Friedemann Kleint2014-02-072-2/+2
|/ / | | | | | | | | | | | | Task-number: QTBUG-36364 Change-Id: Ie3352c8e72a636aee2099ca3138eb0ac77425e7e Reviewed-by: Topi Reiniö <topi.reinio@digia.com>
* | Fix MSVC-warnings about stray */* in sources.Friedemann Kleint2014-01-242-2/+2
| | | | | | | | | | Change-Id: Ifa8de548dc8df79fa2b5d884383dc120661cb45a Reviewed-by: Topi Reiniö <topi.reinio@digia.com>
* | Merge remote-tracking branch 'origin/stable' into devFrederik Gladhorn2014-01-201-1/+1
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/corelib/global/qglobal.h src/corelib/tools/qstring.cpp src/gui/image/image.pri src/gui/image/qimage.cpp src/plugins/platforms/cocoa/qcocoawindow.h src/plugins/platforms/cocoa/qcocoawindow.mm src/plugins/platforms/eglfs/qeglfshooks_stub.cpp tests/auto/corelib/io/qstandardpaths/tst_qstandardpaths.cpp Change-Id: I3b9ba029c8f2263b011f204fdf68c3231c6d4ce5
| * Doc: Fix typo in Fade Message Effect Example documentationJonathan Liu2014-01-161-1/+1
| | | | | | | | | | Change-Id: I3a64f296d01f2b0147f87b406163ff25c4d12ada Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@digia.com>
* | expand tabs and related whitespace fixes in *.{cpp,h,qdoc}Oswald Buddenhagen2014-01-1320-142/+142
| | | | | | | | | | | | | | | | the diff -w for this commit is empty. Started-by: Thiago Macieira <thiago.macieira@intel.com> Change-Id: I77bb84e71c63ce75e0709e5b94bee18e3ce6ab9e Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* | Merge remote-tracking branch 'origin/stable' into devSimon Hausmann2014-01-031-2/+2
|\| | | | | | | Change-Id: Id13badc270db98806048753fd7fb658aa17f1ede
| * Fix some typos in documentation.Jeff Tranter2014-01-021-2/+2
| | | | | | | | | | | | | | | | Fix some spelling and grammatical errors in comments that show up in Qt documentation. No changes to code. Change-Id: I2e946fda0bd9a2117f8e9b2fb300df9bf0a98a6c Reviewed-by: Thiago Macieira <thiago.macieira@intel.com> Reviewed-by: Topi Reiniö <topi.reinio@digia.com>
* | Merge remote-tracking branch 'origin/stable' into devFrederik Gladhorn2013-12-242-4/+4
|\| | | | | | | Change-Id: I2defae1904154283446b069d151c3ef57302ec7b
| * Doc: corrected broken linksNico Vertriest2013-12-202-4/+4
| | | | | | | | | | | | | | | | | | | | | | Task-number: QTBUG-34749 Corrected link to drag and drop example. Corrected link to {mandatory fields} Created target referring to macros for defining plugins Change-Id: I387a2d9bab428b2eacd8d371f08c72f42f7e2be2 Reviewed-by: Topi Reiniö <topi.reinio@digia.com>
* | Merge remote-tracking branch 'origin/stable' into devFrederik Gladhorn2013-11-2622-947/+5
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | For the conflicts in msvc_nmake.cpp the ifdefs are extended since we need to support windows phone in the target branch while it is not there in the current stable branch (as of Qt 5.2). Conflicts: configure qmake/generators/win32/msvc_nmake.cpp src/3rdparty/angle/src/libEGL/Surface.cpp src/angle/src/common/common.pri src/corelib/global/qglobal.h src/corelib/io/qstandardpaths.cpp src/plugins/platforms/qnx/qqnxintegration.cpp src/plugins/platforms/qnx/qqnxscreeneventhandler.h src/plugins/platforms/xcb/qglxintegration.h src/widgets/kernel/win.pri tests/auto/corelib/thread/qreadwritelock/tst_qreadwritelock.cpp tests/auto/corelib/tools/qdatetime/tst_qdatetime.cpp tests/auto/gui/text/qtextdocument/tst_qtextdocument.cpp tools/configure/configureapp.cpp Change-Id: I00b579eefebaf61d26ab9b00046d2b5bd5958812
| * Doc: Fix broken linksSze Howe Koh2013-11-052-4/+4
| | | | | | | | | | | | | | | | Task-number: QTBUG-33360 Change-Id: Ic944cb2f575c35ebad64852ef5fc44a50ac03571 Reviewed-by: Jerome Pasion <jerome.pasion@digia.com> Reviewed-by: Topi Reiniö <topi.reinio@digia.com>
| * Doc: Clean up threading examplesSze Howe Koh2013-11-0520-943/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | - Example 3 (Clock) is a collection of anti-patterns. - It implements a slot in a QThread subclass and then forces the new thread to use Qt::DirectConnection to invoke the slot in the "wrong" thread. - It talks about getting away with non-thread-safe usage - It uses a thread as a timer and then admits that it's an over- complicated approach. - Example 4 (Permanent Thread) is over-complicated yet incomplete. A better one exists in the QThread class ref. - Example 1 (Thread Pool) is covered by the QThreadPool class ref. - Example 2 (QtConcurrent::run()) is covered in the "Threading and Concurrent Programming Examples" page and the "QtConcurrentRun" page. - The undocumented "Hello Thread" example is covered in the QThread class ref. - These examples cannot be accessed from Qt Creator's Examples tool. - These examples are neither widget-related nor tutorials, contrary to their source paths. Task-number: QTBUG-33360 Change-Id: Ic79cb764ee925ddbcbeafee8e1d01db7fe0f6cfe Reviewed-by: Topi Reiniö <topi.reinio@digia.com> Reviewed-by: Jerome Pasion <jerome.pasion@digia.com>
* | added QAbstractSpinBox::setGroupSeparatorShown function.Oto Magaldadze2013-10-292-0/+28
|/ | | | | | | | | | | [ChangeLog][QtWidgets][QAbstractSpinBox] QTBUG-5142 - This will allow a group (thousand) separator to be shown in QSpinBox and QDoubleSpinBox widgets. Task-number: QTBUG-5142 Change-Id: I2e23f5f83c93bb092a2dbd784e06d17d40d42909 Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
* Remove warnings about examples not running in the Qt SimulatorTor Arne Vestbø2013-10-0965-130/+0
| | | | | | | The Qt Simulator is no longer supported with Qt 5. Change-Id: I0f98351d482dd0554ea0754746d56f94ee6bf22f Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
* QMacNativeWidget: Have example use a delegateGabriel de Dietrich2013-09-261-8/+17
| | | | | | | This would be the case in most if not all the real life use cases. Change-Id: Ib7ebc6dbe471ce50f4bd1df9becba8e9806008e7 Reviewed-by: Morten Johan Sørvig <morten.sorvig@digia.com>
* Port QMacCocoaViewContainer to Qt 5.Morten Johan Sørvig2013-09-233-2/+78
| | | | | | | Includes example. Change-Id: Ifdda5c535d0ec41694712405d921b2c32cb8dfc8 Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@digia.com>
* Port QMacNativeWidget to Qt 5Morten Johan Sørvig2013-09-234-0/+155
| | | | | | | | Also adds examples/widgets/mac subdir for Mac specific examples, starting with one for this feature. Change-Id: I4cc7d84ce3d7562259d6206faa5d6996c2392a3e Reviewed-by: Liang Qi <liang.qi@digia.com>
* Merge branch 'stable' into devSergio Ahumada2013-09-211-1/+1
|\ | | | | | | Change-Id: I37d85631ab1165ab91457d8880c4da907a9df73b
| * stickman example: fix header include guardMarc Mutz2013-09-161-1/+1
| | | | | | | | | | Change-Id: I65f2187b309f075035ad6c8beab40bf2a177140c Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
* | Merge remote-tracking branch 'origin/stable' into devFrederik Gladhorn2013-09-163-8/+2
|\| | | | | | | | | | | | | Conflicts: src/corelib/tools/qstring.cpp Change-Id: Ifc6cd3a0f1cf14cc0fe6cf30afb0c7f40cfdbc3e
| * Doc: Remove section about how to start threadsSze Howe Koh2013-09-143-8/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | - Incomplete: It doesn't talk about how to use a raw QThread, or QRunnable, or Qt Concurrent. - Redundant: Its contents are already presented in QThread's class ref, and the line before this section links to the "Multithreading Technologies in Qt" overview page which provides a more complete intro Also remove snippet markers that are no longer used. Change-Id: I89b7bd72f10c8ffdfd9b7772e2493050aafc9c88 Reviewed-by: Jerome Pasion <jerome.pasion@digia.com> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* | Remove qSort usages from qtbase examplesGiuseppe D'Angelo2013-09-142-3/+7
| | | | | | | | | | | | | | | | QtAlgorithms is getting deprecated, see http://www.mail-archive.com/development@qt-project.org/msg01603.html Change-Id: I68dec0cb6efa1f164ba9f1671b55332ee4ad2e23 Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
* | Merge branch 'stable' into devSergio Ahumada2013-09-132-1/+5
|\| | | | | | | | | | | | | | | Conflicts: src/concurrent/qtconcurrentmedian.h src/corelib/itemmodels/qabstractitemmodel.cpp Change-Id: Iac46a90bbb2958cef7670031a4b59c3becd8538a
| * standarddialogs example: add detailed textShawn Rutledge2013-09-121-0/+4
| | | | | | | | | | | | | | | | | | Demonstrates that you can have mnemonic buttons which don't conflict with the Ctrl-A and Ctrl-C shortcuts. Task-number: QTBUG-6731 Change-Id: I41ce64e6f3bd0cf387af13c5c37894b721b5a3bb Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
| * Fix echoplugin docs: Q_INTERFACES expects a space-separated list.Mitch Curtis2013-09-111-1/+1
| | | | | | | | | | | | | | Task-number: QTBUG-25580 Change-Id: I736d5743b7901bf207c31795c96acc02fd149277 Reviewed-by: Jerome Pasion <jerome.pasion@digia.com>
* | Add clear button and side action to customsortfiltermodel example.Friedemann Kleint2013-09-127-33/+223
| | | | | | | | | | | | | | | | Demonstrate the new side widgets feature of QLineEdit. Change-Id: I1c4289c652abf2209e50601871249008fdec4f6b Reviewed-by: Kevin Ottens <kevin.ottens@kdab.com> Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
* | Merge remote-tracking branch 'origin/stable' into devSergio Ahumada2013-09-071-2/+3
|\| | | | | | | Change-Id: I9ee4176f0a0078908d49896508826154c9f71530
| * Do not attempt to save a file in the resourcesGiuseppe D'Angelo2013-08-271-2/+3
| | | | | | | | | | | | | | | | | | | | A wrong code path caused the textedit example to attempting to try to save the file it was currently editing even if it was loaded from the resource system. Task-number: QTBUG-33105 Change-Id: I9e03168968a98a421e8ab93a8d06f808b72ac3b0 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>