@@ -756,17 +756,19 @@ QString Expert::getDocsForNode(const QDomElement &child) const
756756 QString docs = SA (" " );
757757 // read documentation text
758758 QDomElement docsVal = child.firstChildElement ();
759+ bool first = true ;
759760 while (!docsVal.isNull ())
760761 {
761762 if (docsVal.tagName ()==SA (" docs" ) &&
762763 docsVal.attribute (SA (" doxywizard" )) != SA (" 0" ))
763764 {
765+ if (!first) docs += SA (" <br/>" );
766+ first = false ;
764767 for (QDomNode n = docsVal.firstChild (); !n.isNull (); n = n.nextSibling ())
765768 {
766769 QDomText t = n.toText ();
767770 if (!t.isNull ()) docs+=t.data ();
768771 }
769- docs += SA (" <br/>" );
770772 }
771773 docsVal = docsVal.nextSiblingElement ();
772774 }
@@ -818,12 +820,11 @@ QString Expert::getDocsForNode(const QDomElement &child) const
818820 }
819821 if (child.attribute (SA (" defval" )) != SA (" " ))
820822 {
821- docs+= SA (" <br/>" );
823+ if (! docs. endsWith ( SA ( " <br/> " ))) docs += SA (" <br/>" );
822824 docs+=SA (" <br/>" );
823825 QString defval = child.attribute (SA (" defval" ));
824826 docs+=SA (" " )+tr (" The default value is: <code>%1</code>." ).arg (defval);
825827 }
826- docs+= SA (" <br/>" );
827828 }
828829 else if (type==SA (" int" ))
829830 {
@@ -833,7 +834,6 @@ QString Expert::getDocsForNode(const QDomElement &child) const
833834 QString maxval = child.attribute (SA (" maxval" ));
834835 QString defval = child.attribute (SA (" defval" ));
835836 docs+=tr (" Minimum value: %1, maximum value: %2, default value: %3." ).arg (minval).arg (maxval).arg (defval);
836- docs+= SA (" <br/>" );
837837 }
838838 else if (type==SA (" bool" ))
839839 {
@@ -849,7 +849,6 @@ QString Expert::getDocsForNode(const QDomElement &child) const
849849 QString valStr = (defval==SA (" 1" )?SA (" YES" ):SA (" NO" ));
850850 docs+=SA (" " )+tr (" The default value is: <code>%1</code>." ).arg (valStr);
851851 }
852- docs+= SA (" <br/>" );
853852 }
854853 else if (type==SA (" list" ))
855854 {
@@ -913,7 +912,6 @@ QString Expert::getDocsForNode(const QDomElement &child) const
913912 docsVal = docsVal.nextSiblingElement ();
914913 }
915914 }
916- // docs+= SA("<br/>");
917915 }
918916 }
919917 else if (type==SA (" string" ))
@@ -926,7 +924,6 @@ QString Expert::getDocsForNode(const QDomElement &child) const
926924 if (!docs.endsWith (SA (" <br/>" ))) docs += SA (" <br/>" );
927925 docs+=SA (" <br/>" );
928926 docs += SA (" " )+tr (" The default directory is: <code>%1</code>." ).arg (defval);
929- docs += SA (" <br/>" );
930927 }
931928 }
932929 else if (child.attribute (SA (" format" )) == SA (" file" ))
@@ -944,7 +941,6 @@ QString Expert::getDocsForNode(const QDomElement &child) const
944941 {
945942 docs += SA (" " )+tr (" The default file (with absolute path) is: <code>%1</code>." ).arg (defval);
946943 }
947- docs += SA (" <br/>" );
948944 }
949945 else
950946 {
@@ -953,7 +949,6 @@ QString Expert::getDocsForNode(const QDomElement &child) const
953949 if (!docs.endsWith (SA (" <br/>" ))) docs += SA (" <br/>" );
954950 docs+=SA (" <br/>" );
955951 docs += SA (" " )+tr (" The file has to be specified with full path." );
956- docs += SA (" <br/>" );
957952 }
958953 }
959954 }
@@ -972,7 +967,6 @@ QString Expert::getDocsForNode(const QDomElement &child) const
972967 {
973968 docs += SA (" " )+tr (" The default image (with absolute path) is: <code>%1</code>." ).arg (defval);
974969 }
975- docs += SA (" <br/>" );
976970 }
977971 else
978972 {
@@ -981,7 +975,6 @@ QString Expert::getDocsForNode(const QDomElement &child) const
981975 if (!docs.endsWith (SA (" <br/>" ))) docs += SA (" <br/>" );
982976 docs+=SA (" <br/>" );
983977 docs += SA (" " )+tr (" The image has to be specified with full path." );
984- docs += SA (" <br/>" );
985978 }
986979 }
987980 }
@@ -992,7 +985,6 @@ QString Expert::getDocsForNode(const QDomElement &child) const
992985 if (!docs.endsWith (SA (" <br/>" ))) docs += SA (" <br/>" );
993986 docs+=SA (" <br/>" );
994987 docs += SA (" " )+tr (" The default value is: <code>%1</code>." ).arg (defval);
995- docs += SA (" <br/>" );
996988 }
997989 }
998990 }
0 commit comments