WARNING: This e-mail has been altered by the NFIT virus/spamfilter. Please see
below for a record of the changes made.
. In case of problems consider contacting the sender or [email protected]
-------Change report:
An attachment named SetTex.cmd was removed from this document as it
constituted a security hazard. If you require this document, please contact
the sender and arrange an alternate means of receiving it.
Hi All,
Here is a slightly better solution that the one posted yesterday.
Instead of using an external program "sed" to modify the pattern file,
the perl distrubuted with texlive is used instead.
Now there are only 3 small files:
1) SetTex.cmd
2) local.conf.pattern
3) subs.pl
The script "SetTex.cmd" can be installed where you wish. It
creates a "local.font" file with the correct letter for the drive,
redo the font cache and then call "texworks" and a command windows
with the environment variable PATH set with the path to all the TL2011
binaries plus the paths to few others useful binaries.
"subs.pl" a small perl script which substitute a specific
pattern with a disk letter in the model of the file
"local.font". This files should be located in "texmf-local/bin/win32"
The file "local.font.pattern" is the "local.fonts" files
with specifics pattern for the disk letter. This file will be
modified with the perl script. It should be installed
in "texmf-var/fonts/conf".
By modifying path in "SetTex.cmd", it is possible to adapt the script
to other configuration.
best regards,
Alain
On Thu, Sep 29, 2011 at 09:31:06PM +0200, [email protected] wrote:
> Hi All,
> Thanks for all your advices. Finally, I was able to do what I want:
> to have TL2011 installed on an USB stick easily usable with XeLaTeX
> (the other engines do not seem to have problem with the font loading).
>
> This was surprisingly simple.
>
> In the attachement, you will find 4 files:
> 1) sed.exe
> 2) regex.dll
> 3) local.conf.pattern
> 4) SetTex.cmd
>
> The two first are simply the Unix sed command for Windows
> directly downloaded from the GnuWin32 site. These files
> should be located in "texmf-local/bin/win32".
>
> The file "local.font.pattern" is the "local.fonts" files
> with specifics pattern for the disk letter. This file will be
> modified with the sed command. It should be installed
> in "texmf-var/fonts/conf".
>
> The script "SetTex.cmd" which can be installed where you wish. It
> create a "local.font" file with the correct letter for the drive,
> redo the font cache and then call "texworks" and a command windows
> with the environment variable PATH set with the path to all the TL2011
> binaries plus few others.
>
> By changing the paths inside "SetTex.cmd", you can adapt the script to your
> configuration.
>
> best regards,
>
> Alain
>
<?xml version="1.0"?>
<!DOCTYPE fontconfig SYSTEM "fonts.dtd">
<!-- /etc/fonts/fonts.conf file to configure system font access -->
<fontconfig>
<!-- Font directory list -->
<!-- On Windows, the texlive distribution is generally
located in the directory "/texlive" followed
by the year of the TL distribution.
However, when the TeXlive is running from a removable device
the letter of the disk can change. The pattern "_DISQUE_"
should then be replaced by the correct drive letter and
then the command "fc-cache" should be run to redefine
the content of the cache.
-->
<dir>_DISQUE_:/texlive/2011/texmf-dist/fonts/opentype</dir>
<dir>_DISQUE_:/texlive/2011/texmf-dist/fonts/truetype</dir>
<dir>_DISQUE_:/texlive/2011/texmf-dist/fonts/type1</dir>
<dir>_DISQUE_:/texlive/2011/texmf-local/fonts/opentype</dir>
<dir>_DISQUE_:/texlive/2011/texmf-local/fonts/truetype</dir>
<dir>_DISQUE_:/texlive/2011/texmf-local/fonts/type1</dir>
</fontconfig>#!/usr/bin/perl
#
#This small perl program open a file, and substitute
#a pattern by a new string. The result is printed on STDOUT.
#
#The program has 3 arguments
#
# 1) The file to modify
# 2) The string to be replaced
# 3) The replacement string
if ($#ARGV+1 != 3){
print "Please give 3 arguments: FileName ToBeReplaced Replacement\n";
exit(1);
}
my $file=$ARGV[0];
my $toBeReplaced=$ARGV[1];
my $replacement=$ARGV[2];
my $record;
open(FILE,$file) || die "File '$file' cannot be open.";
while ($record = <FILE>){
$record =~ s/$toBeReplaced/$replacement/g;
print $record;
}
close(FILE);
--------------------------------------------------
Subscriptions, Archive, and List information, etc.:
http://tug.org/mailman/listinfo/xetex