Ubuntu 14.04 QtCreator Qt5 examples missing

After upgrading to Ubuntu 14.04 I removed the official qtcreator in order to install the modified version from the software center because I'd like to try the SDK.

Fortunately, the docs are now included in the official installation. Unfortunately, there is still something missing: the official examples. Luckily I had my old and official installation still on my harddrive and then, after some tries, I copied the examples to /usr/lib/x86_64-linux-gnu/qt5/examples and change the permission. Then QtCreator detected examples and I was able to select them from the examples section.

But there are still two problems remaining:

Firstly, I am not able to find all examples e.g the network examples (like the fortuneclient) are still missing. For the sake of testing I change the permission of the example folder to 777. Therefore permission shouldn't be a problem.

Secondly, some helping documents to the examples are missing. Therefore I get a normal editor and a blank right part after clicking on an example.


To get the Qt5.2 examples available in Qt Creator/Ubuntu SDK, you basically need two extra packages, open a Terminal with Ctrl+Alt+t an type:

sudo apt-get install qtbase5-examples qtbase5-doc-html

Restart Qt Creator to get:

enter image description here


I don't have enough reputation to comment on Sylvain's answer so my answer here is to back it up and expand as per gaoithe's comments.

In my case running Qt Creator 3.0.1 based on Qt 5.2.1. (on Ubuntu 14.04)

I had qtbase5-examples qtbase5-doc-html already installed, but was still missing network and multimedia examples (and others evidently, but these were the ones I cared about).

After installing the following additional packages:

qt4-demos qt4-doc qt4-doc-html qt5-doc qt5-doc-html

Now I have a shed load of examples that I didn't know were missing.

Thanks


In Ubuntu 18.04 the QtCreator examples and API docs missing, This is my way to solve this problem, should apply to almost every Ubuntu release.

For QtCreator and Examples and API Docs:

sudo apt install `apt-cache search 5-examples | grep qt | grep example | awk '{print $1 }' | xargs `

sudo apt install `apt-cache search 5-doc | grep "Qt 5 " | awk '{print $1}' | xargs`

sudo apt-get install build-essential qtcreator qt5-default

If something is also missing, then:

sudo apt install `apt-cache search qt | grep 5- | grep ^qt | awk '{print $1}' | xargs `

Hope to be helpful.