summaryrefslogtreecommitdiffstats
path: root/examples/widgets/doc
diff options
context:
space:
mode:
authorFriedemann Kleint <Friedemann.Kleint@qt.io>2021-04-22 11:29:08 +0200
committerFriedemann Kleint <Friedemann.Kleint@qt.io>2021-04-23 12:43:28 +0000
commit2393a40ccd455cc2dca410e8a1830856dbfde12d (patch)
tree5b15c09ee1f1b0e7c436cea288f3dbed3ac3bae5 /examples/widgets/doc
parent43d6778ce59266067d2fb5adf88a1ba3f73b29ae (diff)
Rewrite the fetchmore example
- Start in root folder so that large directories (/bin/, Windows) are easily reachable - Remove the line edit and navigate by double clicking instead since this is more in line with expectations - Use a QPlainTextEdit for logging - Make the log message more informative - Add icons Change-Id: Ia3cd7fc143efef80772923291f0b711913aa47be Reviewed-by: Paul Wicking <paul.wicking@qt.io>
Diffstat (limited to 'examples/widgets/doc')
-rw-r--r--examples/widgets/doc/src/fetchmore.qdoc17
1 files changed, 10 insertions, 7 deletions
diff --git a/examples/widgets/doc/src/fetchmore.qdoc b/examples/widgets/doc/src/fetchmore.qdoc
index a27efaf071..940a252319 100644
--- a/examples/widgets/doc/src/fetchmore.qdoc
+++ b/examples/widgets/doc/src/fetchmore.qdoc
@@ -34,15 +34,9 @@
\image fetchmore-example.png
-
- This example consists of a dialog where you can enter a directory
- name in the \uicontrol Directory edit field. The application loads and
- visualizes all files it finds as you are typing. It is not required
- to press [Enter] to launch the search.
-
When you have large - or perhaps even infinite - data sets, you
will need to add items to the model in batches, and preferably only
- when the items are needed by the view (i.e., when they are visible
+ when the items are needed by the view (i.e., when they become visible
in the view).
In this example, we implement \c FileListModel - an item view
@@ -50,6 +44,15 @@
Window, which sets up the GUI and feeds the model with
directories.
+ The UI consists of a dialog with a list showing the contents
+ of the root directory. Directories can be navigated by double-clicking.
+
+ At the bottom, there is a log window displaying messages when the view
+ asks the model for more data.
+
+ To exercise it, navigate to a large directory (say \c /bin), and scroll
+ to the bottom. Log messages appear showing the data being retrieved.
+
Let's take a tour of \c {FileListModel}'s code.
\section1 FileListModel Class Definition