[xml/sgml-commit] [SCM] linuxdoc-tools package for Debian. branch, master, updated. debian/0.9.51-16-g264d63e
Agustin Martin Domingo
agmartin at debian.org
Tue Jul 1 16:59:16 UTC 2008
The following commit has been merged in the master branch:
commit 449d4ce92f9accbce8e2ad4fa8e66cdc742606ba
Author: Agustin Martin Domingo <agmartin at debian.org>
Date: Sun Jun 8 22:22:02 2008 +0200
Move $lyxheader to $lyxout. Use @textclass at . Better scope $OUTPUT
* Move $lyxheader to $lyxout
* Better scoping for $OUTPUT
* Prepare things for replacing textclass
diff --git a/lib/dist/fmt_lyx.pl b/lib/dist/fmt_lyx.pl
index bce204e..cd9886e 100644
--- a/lib/dist/fmt_lyx.pl
+++ b/lib/dist/fmt_lyx.pl
@@ -1,8 +1,6 @@
#
# fmt_lyx.pl
#
-# $Id: fmt_lyx.pl,v 1.1.1.1 2001/05/24 15:57:40 sano Exp $
-#
# Lyx-specific driver stuff
#
# Copyright © 1996, Cees de Groot
@@ -85,7 +83,6 @@ $lyx->{postASP} = sub {
# -----------------------------------------------------------------------
# Take the sgmlsasp output, and make something useful from it.
# -----------------------------------------------------------------------
- my $OUTFILE;
my $INFILE = shift;
my $lyxfile = "$global->{filename}.lyx";
my $nbsp = chr(160);
@@ -99,11 +96,10 @@ $lyx->{postASP} = sub {
my $intag;
my $intt;
my $tscreen;
- my $lyxout = '';
- my $lyxheader = "#This file was created by LinuxDoc-SGML
+ my $lyxout = "#This file was created by LinuxDoc-SGML
#(conversion : Frank Pavageau and Jose' Matos)
\\lyxformat 2.15
-\\textclass linuxdoc
+\\textclass \@textclass\@
\\language default
\\inputencoding default
\\fontscheme default
@@ -129,7 +125,9 @@ $lyx->{postASP} = sub {
chomp;
if ( /^\@(article|book|report)\@/ ) {
- $lyxout = $lyxheader;
+ #my $class = $1;
+ my $class = "linuxdoc";
+ $lyxout =~ s/\@textclass\@/$class/;
} # Itemize; Enumerate and Description. $indent_level counts the level
elsif( /^\@itemize\@/ ) { # --- Itemized list begins
$indent_level++;
@@ -225,7 +223,7 @@ $lyx->{postASP} = sub {
$lyxout =~ s/\\end_deeper/\\end_deeper\n/gms;
# Print result
- open ($OUTFILE, "> $lyxfile")
+ open (my $OUTFILE, "> $lyxfile")
or die "fmt_lyx::postASP: Could not open \"$lyxfile\" for writing. Aborting ...";
print $OUTFILE $lyxout;
close $OUTFILE;
--
linuxdoc-tools package for Debian.
More information about the debian-xml-sgml-commit
mailing list