$include_dir="/home/hyper-archives/boost-commit/include"; include("$include_dir/msg-header.inc") ?>
Subject: [Boost-commit] svn:boost r68559 - in trunk/tools/quickbook: src test
From: dnljms_at_[hidden]
Date: 2011-01-30 05:52:36
Author: danieljames
Date: 2011-01-30 05:52:35 EST (Sun, 30 Jan 2011)
New Revision: 68559
URL: http://svn.boost.org/trac/boost/changeset/68559
Log:
Place section anchors inside the section title.
Generates better html.
Text files modified: 
   trunk/tools/quickbook/src/actions.cpp  |    10 ++++++----                              
   trunk/tools/quickbook/test/anchor.gold |     6 +++---                                  
   2 files changed, 9 insertions(+), 7 deletions(-)
Modified: trunk/tools/quickbook/src/actions.cpp
==============================================================================
--- trunk/tools/quickbook/src/actions.cpp	(original)
+++ trunk/tools/quickbook/src/actions.cpp	2011-01-30 05:52:35 EST (Sun, 30 Jan 2011)
@@ -1216,23 +1216,25 @@
         std::string str;
         phrase.swap(str);
 
+        out << "<title>";
+
         actions.anchors.swap(actions.saved_anchors);
         actions.output_pre(out);
 
         if (qbk_version_n < 103) // version 1.2 and below
         {
-            out << "<title>" << str << "</title>\n";
+            out << str;
         }
         else // version 1.3 and above
         {
-            out << "<title>"
-                << "<link linkend=\"" << library_id
+            out << "<link linkend=\"" << library_id
                     << "." << qualified_section_id << "\">"
                 << str
                 << "</link>"
-                << "</title>\n"
                 ;
         }
+        
+        out << "</title>\n";
     }
 
     void end_section_action::operator()(iterator first, iterator last) const
Modified: trunk/tools/quickbook/test/anchor.gold
==============================================================================
--- trunk/tools/quickbook/test/anchor.gold	(original)
+++ trunk/tools/quickbook/test/anchor.gold	2011-01-30 05:52:35 EST (Sun, 30 Jan 2011)
@@ -34,13 +34,13 @@
     <anchor id="a8"/>
   </section>
   <section id="anchor_test.section_anchor">
-    <anchor id="a9"/> <title>Section Anchor</title>
+    <title><anchor id="a9"/> Section Anchor</title>
     <section id="anchor_test.nested_section">
-      <anchor id="a10"/> <title>Nested Section</title>
+      <title><anchor id="a10"/> Nested Section</title>
     </section>
     <anchor id="a11"/>
   </section>
   <section id="anchor_test.conditional_section_anchor">
-    <anchor id="a12"/> <title>Conditional Section Anchor</title>
+    <title><anchor id="a12"/> Conditional Section Anchor</title>
   </section>
 </article>