Doc: Rename snippet id to a unique identifier

The header file has two snippets with the same id. Rename to unique
values and link to the correct snippet id from the qdoc file.

Fixes: QTWEBSITE-1051
Pick-to: 6.3
Change-Id: I9003916f831898026f520fd86d60ab1c0230e6c4
Reviewed-by: Kai Koehne <kai.koehne@qt.io>
This commit is contained in:
Andreas Eliasson 2022-05-31 14:41:42 +02:00
parent e5251efe97
commit 92419f7f1b
2 changed files with 3 additions and 4 deletions

View File

@ -165,7 +165,7 @@ developed in the previous examples into two types - a \c Boy and a \c Girl.
\section1 Declare Boy and Girl \section1 Declare Boy and Girl
\snippet referenceexamples/coercion/person.h 0 \snippet referenceexamples/coercion/person.h 1
The Person class remains unaltered in this example and the Boy and Girl C++ The Person class remains unaltered in this example and the Boy and Girl C++
classes are trivial extensions of it. The types and their QML name are classes are trivial extensions of it. The types and their QML name are

View File

@ -77,8 +77,7 @@ private:
int m_shoeSize = 0; int m_shoeSize = 0;
}; };
// ![1]
// ![0]
class Boy : public Person class Boy : public Person
{ {
Q_OBJECT Q_OBJECT
@ -97,6 +96,6 @@ public:
}; };
//! [girl class] //! [girl class]
// ![0] // ![1]
#endif // PERSON_H #endif // PERSON_H