]> matita.cs.unibo.it Git - helm.git/blobdiff - matitaB/components/content_pres/boxPp.ml
Compilation fix
[helm.git] / matitaB / components / content_pres / boxPp.ml
index 7f71aa20bd81f8ffd0abbfb63a9c59a0cc19a851..9bf360a637d45fd1c5d654aae2e8007c19a832ce 100644 (file)
@@ -40,8 +40,8 @@ let string_ink_len = utf8_string_length string_ink
 let contains_attrs contained container =
   List.for_all (fun attr -> List.mem attr container) contained
 
-let want_indent = contains_attrs (RenderingAttrs.indent_attributes `BoxML)
-let want_spacing = contains_attrs (RenderingAttrs.spacing_attributes `BoxML)
+let want_indent = contains_attrs (* (RenderingAttrs.indent_attributes `BoxML) *)[]
+let want_spacing = contains_attrs (* (RenderingAttrs.spacing_attributes `BoxML) *) []
 
 let shift off = List.map (fun (start,stop,v) -> start+off,stop+off,v);;
 
@@ -101,6 +101,7 @@ let fixed_rendering s =
   fun _ -> s_len,[s]
 
 let render_to_strings ~map_unicode_to_tex choose_action size markup =
+  prerr_endline ("render size is " ^ string_of_int size);
   let max_size = max_int in
   let rec aux_box =
     function
@@ -125,7 +126,7 @@ let render_to_strings ~map_unicode_to_tex choose_action size markup =
             res
           else  (* break needed, re-render using a Box.V *)
             aux_box (Box.V (attrs, children)) size)
-    | Box.V (attrs, []) -> assert false
+    | Box.V (attrs, []) -> aux_box (Box.Text (attrs,"")) (* FIXME *)
     | Box.V (attrs, [child]) -> aux_box child
     | Box.V (attrs, hd :: tl) ->
         let indent = want_indent attrs in