[Pkg-ocaml-maint-commits] [hevea] 01/03: Imported Upstream version 2.11
Ralf Treinen
treinen at moszumanska.debian.org
Tue Jan 14 10:51:32 UTC 2014
This is an automated email from the git hooks/post-receive script.
treinen pushed a commit to branch master
in repository hevea.
commit 38a81dd3b1a71fa837eb5800ca393ec1c6159888
Author: Ralf Treinen <treinen at debian.org>
Date: Tue Jan 14 11:45:37 2014 +0100
Imported Upstream version 2.11
---
CHANGES | 16 ++++++++++++++++
README | 12 ++++++------
cross.ml | 31 ++++++++++++++++++-------------
cut.mll | 44 ++++++++++++++++++++++++++++----------------
cutOut.ml | 5 ++++-
cutOut.mli | 1 +
html/color.hva | 2 ++
htmllex.mll | 4 +++-
latexcommon.hva | 4 ++--
package.ml | 4 ++--
text/hevea.hva | 4 ++--
version.ml | 4 ++--
12 files changed, 86 insertions(+), 45 deletions(-)
diff --git a/CHANGES b/CHANGES
index 63dd5a2..bdb89cc 100644
--- a/CHANGES
+++ b/CHANGES
@@ -1,3 +1,19 @@
+version 2.11
+ * hacha: allow ':' in attribute names.
+version 2.10
+ * Bug in \@makesection (latexcommon.hva). \end at sec@step was
+ absent from the definition of stared sectionning comamnd.
+ As a result the first label in section was used as the id of the
+ section.
+ * typo-bug in text/hevea.hva
+version 2.09
+ * Corrected a very unfortunate bug in german babel:
+ \@german at dquote has to consider the case when '"' is not active..
+version 2.08
+ * Added \fcolorbox
+version 2.07
+ * bug in hacha -tocbis/-tocter when no cut induced by section.
+ * Do not change (\cutname) the name of toplevel file.
version 2.06
* Two bugs reported by Michael Ernst fixed *
- Some spaces dissapeared in toc's FIX -> add braces around macro
diff --git a/README b/README
index cdea20c..8084952 100644
--- a/README
+++ b/README
@@ -1,4 +1,4 @@
- This is HEVEA, version 2.06, a fast Latex to HTML translator.
+This is HEVEA, version 2.11, a fast Latex to HTML translator.
ADVERTISEMENT
@@ -68,16 +68,16 @@ REQUIREMENTS
INSTALLATION FROM THE SOURCE DISTRIBUTION
Download the source distribution
- http://hevea.inria.fr/distri/hevea-2.06.tar.gz
+ http://hevea.inria.fr/distri/hevea-2.09.tar.gz
Unzip,
- gunzip hevea-2.06.tar.gz
+ gunzip hevea-2.09.tar.gz
Untar,
- tar xf hevea-2.06.tar
+ tar xf hevea-2.09.tar
Go to the source directory
- cd hevea-2.06
+ cd hevea-2.09
CONFIGURATION
There are a few configuration variables at the beginning of
@@ -127,5 +127,5 @@ MAKE
IN CASE OF TROUBLE.
- You do need version 3.12 (or newer) of the Objective Caml System.
- Older versions of OCaml cannot compile hevea 2.06.
+ Older versions of OCaml cannot compile hevea 2.09.
diff --git a/cross.ml b/cross.ml
index 13ae05d..c1c617d 100644
--- a/cross.ml
+++ b/cross.ml
@@ -34,21 +34,26 @@ let decode_fragment frag =
Buff.to_string buff
let fullname change myfilename name =
- try
- let filename = Hashtbl.find table (decode_fragment name) in
- let newname =
- if myfilename = filename then
- "#"^name
- else
- change filename^"#"^name in
+ if !verbose > 1 then
+ Printf.eprintf "FULL: filename=%s, name=%s ->" myfilename name ;
+ let r =
+ try
+ let filename = Hashtbl.find table (decode_fragment name) in
+ let newname =
+ if myfilename = filename then
+ "#"^name
+ else
+ change filename^"#"^name in
if !verbose > 1 then
prerr_endline ("From "^name^" to "^newname) ;
- newname
- with Not_found -> begin
- Location.print_pos () ;
- prerr_endline ("Warning, cannot find anchor: "^name) ;
- raise Not_found
- end
+ newname
+ with Not_found -> begin
+ Location.print_pos () ;
+ prerr_endline ("Warning, cannot find anchor: "^name) ;
+ raise Not_found
+ end in
+ if !verbose > 1 then Printf.eprintf " %s\n" r ;
+ r
;;
let dump outname change =
diff --git a/cut.mll b/cut.mll
index 74c3db4..a59b938 100644
--- a/cut.mll
+++ b/cut.mll
@@ -148,10 +148,12 @@ and otherout = ref !out
let close_loc _ctx _name out = Out.close out
+let dont_change = ref ""
+
let change_name oldname name =
- if !phase <= 0 then begin
+ if !phase <= 0 && oldname <> !dont_change then begin
if verbose > 0 then
- prerr_endline ("Change "^oldname^" into "^name) ;
+ eprintf "Change '%s' into '%s'\n" oldname name ;
record_changed oldname name ;
end
@@ -160,6 +162,7 @@ let start_phase () =
if verbose > 0 then
prerr_endline ("Starting phase number: "^string_of_int !phase);
let base_out = Filename.basename name_out in
+ dont_change := base_out ;
outname := base_out ;
tocname := base_out ;
otheroutname := "" ;
@@ -388,19 +391,28 @@ let close_chapter () =
if verbose > 0 then
prerr_endline ("Close chapter out="^ !outname^" toc="^ !tocname) ;
if !phase > 0 then begin
- if !outname <> !tocname then closehtml std_file_opt !outname !out ;
- begin match toc_style with
- | Both|Special ->
- let real_out = real_open_out !outname in
+ if !outname <> !tocname then begin
+ closehtml std_file_opt !outname !out ;
+ let doout out what =
+ if false then begin
+ eprintf "DEBUG:\n" ;
+ Out.debug stderr what ;
+ eprintf "\n"
+ end ;
+ Out.to_chan out what in
+ begin match toc_style with
+ | Both|Special ->
+ let real_out = real_open_out !outname in
(* Those hacking try with avoid failure for cuttingsection = document *)
- begin try
- Out.to_chan real_out !out_prefix
- with Misc.Fatal _ -> () end ;
- begin try
- Out.to_chan real_out !out ;
- with Misc.Fatal _ -> () end ;
- close_out real_out
- | Normal -> ()
+ begin try
+ doout real_out !out_prefix
+ with Misc.Fatal _ -> () end ;
+ begin try
+ doout real_out !out ;
+ with Misc.Fatal _ -> () end ;
+ close_out real_out
+ | Normal -> ()
+ end ;
end ;
out := !toc
end else begin
@@ -578,7 +590,7 @@ let blank = [' ''\t''\n']
let tag = ['a'-'z''A'-'Z''0'-'9']+
let anchor = ['a'-'z''A'-'Z''0'-'9']+
let class_name = ['a'-'z''A'-'Z''0'-'9''-']+
-let attr_name = ['a'-'z''A'-'Z''-''0'-'9']+
+let attr_name = ['a'-'z''A'-'Z']['a'-'z''A'-'Z''-''0'-'9'':']*
rule main = parse
| "<!--HEVEA" [^'>']* "-->" '\n'?
@@ -783,7 +795,7 @@ and save_html = parse
| "<!--END" ' '* ['A'-'Z']+ ' '* "-->" '\n'?
{let s = Out.to_string html_buff in
if verbose > 0 then
- prerr_endline ("save_html -> ``"^s^"''");
+ eprintf "save_html -> '%s'\n" s;
s}
| _
{let lxm = lexeme_char lexbuf 0 in
diff --git a/cutOut.ml b/cutOut.ml
index 17e369a..98c3394 100644
--- a/cutOut.ml
+++ b/cutOut.ml
@@ -36,5 +36,8 @@ and to_string { out = out } = Out.to_string out
and to_chan chan { out = out } = Out.to_chan chan out
and copy { out = out1 } { out = out2 } = Out.copy out1 out2
and flush { out = out } = Out.flush out
-
+let debug chan { out; name; } =
+ Printf.fprintf chan "Out=%s\n" name ;
+ Out.debug chan out ;
+ ()
end
diff --git a/cutOut.mli b/cutOut.mli
index 0bd6776..e8ac7d2 100644
--- a/cutOut.mli
+++ b/cutOut.mli
@@ -30,4 +30,5 @@ type t
val to_chan : out_channel -> t -> unit
val copy : t -> t -> unit
val flush : t -> unit
+ val debug : out_channel -> t -> unit
end
diff --git a/html/color.hva b/html/color.hva
index de102ce..2a1e597 100644
--- a/html/color.hva
+++ b/html/color.hva
@@ -3,6 +3,8 @@
\newcommand{\textcolor}[3][!*!]{{\color[#1]{#2}#3}}
\newcommand{\colorbox}[3][!*!]
{{\@span{style="background-color:\@getstylecolor[#1]{#2}"}#3}}
+\newcommand{\fcolorbox}[4][!*!]
+{{\@span{style="background-color:\@getstylecolor[#1]{#3};border:solid \@getstylecolor[#1]{#2}"}#4}}
\newenvironment{bgcolor}[2][style="padding:1em"]
{\@open{table}{}\@open{tr}{}%
\@open{td}{\@addstyle{background-color:\@getcolor{#2}}{#1}}}
diff --git a/htmllex.mll b/htmllex.mll
index 85c4fa7..9b64914 100644
--- a/htmllex.mll
+++ b/htmllex.mll
@@ -187,6 +187,8 @@ let aput s = Buff.put abuff s
let blank = [' ''\t''\n''\r']
let tag = ['a'-'z''A'-'Z''0'-'9']+
let class_name = ['a'-'z''A'-'Z''0'-'9''-']+
+let attr_name = ['a'-'z''A'-'Z']['a'-'z''A'-'Z''-''0'-'9'':']*
+
rule main = parse
| (blank|" "|"&XA0;")+ as lxm {Blanks lxm}
| "<!--"
@@ -233,7 +235,7 @@ and text = parse
and read_attrs = parse
| blank+ as lxm
{aput lxm ; read_attrs lexbuf}
-| ['a'-'z''A'-'Z''-''0'-'9']+ as name
+| attr_name as name
{aput name ;
let v = read_avalue lexbuf in
let atxt = Buff.to_string abuff in
diff --git a/latexcommon.hva b/latexcommon.hva
index f1925cd..d209ca7 100644
--- a/latexcommon.hva
+++ b/latexcommon.hva
@@ -160,7 +160,7 @@
\newstyle{.li-enumerate}{margin:1ex 0ex;}
\newcommand{\@itemenumerate}[1][!*!]
{\let\@currentlabel\csname the\@enumcitem\endcsname%
-\stepcounter{\@itemcount}\@enumerate at linum{\envclass at attr{li-enumerate}}\ifthenelse{\equal{#1}{!*!}}{}{\hva at warn{Ignored optional argument to \item in enumerate enironment}}}
+\stepcounter{\@itemcount}\@enumerate at linum{\envclass at attr{li-enumerate}}\ifthenelse{\equal{#1}{!*!}}{}{\hva at warn{Ignored optional argument to \item in enumerate environment}}}
%environement itemize
\setenvclass{itemize}{itemize}
\newenvironment{itemize}
@@ -546,7 +546,7 @@
##2{}#7\end at step@sec\@secend}%
\newcommand{#1*}[1]{%
\@secbegin\@step at sec\cuthere{#3}{##1}%
-#4\@secanchor{}##1{}#7\@secend}}%
+#4\@secanchor{}##1{}#7\end at step@sec\@secend}}%
%%%%%%%%%%%%%%
% Images %
%%%%%%%%%%%%%%
diff --git a/package.ml b/package.ml
index c9574ad..ea92561 100644
--- a/package.ml
+++ b/package.ml
@@ -1078,8 +1078,8 @@ register_init "german"
(fun () ->
def_code "\\@german at dquote"
(fun lexbuf ->
- if effective !alltt then
- Dest.put_char '"'
+ if effective !alltt || not (is_plain '"') then (* '"' *)
+ Dest.put_char '"' (* '"' *)
else try
let c = Save.peek_next_char lexbuf in
match c with
diff --git a/text/hevea.hva b/text/hevea.hva
index a0b512f..bb19152 100644
--- a/text/hevea.hva
+++ b/text/hevea.hva
@@ -39,8 +39,8 @@
\newcommand{\imgsrc}[2][]{\hva at warn{Image in text}*#2*}
\newcommand{\anchor}[1]{}
%% Hyper-text references inside the document:
-\newcomand{\@openlocref}[1]{}
-\newcomand{\@closelocref}[1]{}
+\newcommand{\@openlocref}[1]{}
+\newcommand{\@closelocref}[1]{}
\newcommand{\@locref}[2]{{#2}}
\newcommand{\@locname}[2]{{#2}}
\newcommand{\@locnameref}[3]{{#3}}
diff --git a/version.ml b/version.ml
index ed7ff49..90ccfdb 100644
--- a/version.ml
+++ b/version.ml
@@ -9,8 +9,8 @@
(* *)
(***********************************************************************)
-let real_version = "2.06"
-let release_date = "2013-03-29"
+let real_version = "2.11"
+let release_date = "2014-01-14"
let version =
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-ocaml-maint/packages/hevea.git
More information about the Pkg-ocaml-maint-commits
mailing list