internal release
authorLuc Moreau <l.moreau@ecs.soton.ac.uk>
Thu, 14 Jun 2012 09:43:14 +0100
changeset 3339 7a9fa34da9af
parent 3338 79762cbb0988
child 3340 0912358eba84
internal release
model/glossary.js
model/prov-dm.html
--- a/model/glossary.js	Thu Jun 14 09:25:47 2012 +0100
+++ b/model/glossary.js	Thu Jun 14 09:43:14 2012 +0100
@@ -3,7 +3,7 @@
 //  with <script src="glossary.js" class="remove"></script>
 //Insert glossary definitions with the following 
 // <div class="glossary-ref" ref="glossary-generation"></div>
-glossary_hg='http://dvcs.w3.org/hg/prov/file/7a444573c675/model/glossary.html';
+glossary_hg='http://dvcs.w3.org/hg/prov/file/79762cbb0988/model/glossary.html';
 glossary_string= 
 ' ' + 
 '<html> ' + 
--- a/model/prov-dm.html	Thu Jun 14 09:25:47 2012 +0100
+++ b/model/prov-dm.html	Thu Jun 14 09:43:14 2012 +0100
@@ -77,6 +77,32 @@
         });
       }
 
+        // function to replace figure since not allowed by prov rules, and not transformed by respec.js
+      function updateFigures() {
+        $('figure').each(function(index) {
+
+          var myid=$(this).attr('id');
+          var mystyle=$(this).attr('style');
+
+             console.log( "figure " + myid + " " + $(this).contents());
+
+          $(this).replaceWith(function(){
+                                          var aNewElement=$('<span>').addClass('figure').append($(this).contents());
+                                          if (myid) {
+                                            aNewElement.attr('id',myid)
+                                          }                                          
+                                          if (mystyle) {
+                                            aNewElement.attr('style',mystyle)
+                                          }                                          
+                                          return aNewElement });
+
+
+
+        //          $(this).replaceWith(function(){return $('<span>').addClass('figure').attr('id',myid).attr('style',mystyle).append($(this).contents())});
+             console.log( "figure " + myid);
+        });
+      }
+
       function updateExamples() {
         var count=1;
         $('.anexample').each(function(index) {
@@ -356,7 +382,7 @@
           // Add extraReferences to bibliography database
           preProcess: [addExtraReferences],
 
-          postProcess: [updateSectionRefs, updateDfn],
+          postProcess: [updateSectionRefs, updateDfn, updateFigures],
       };
     </script> 
   </head>