[twg-tds] Question: how to include an image file in a document class?

Lei Ye lei at uow.edu.au
Mon Sep 14 05:36:10 CEST 2015

Hi, Karl,

My understanding for your comments is that the only and proper way to
fix this problem is to let the .png files placed with the class file in
the same folder, which should be fixed by distributors.

I guess the cause of the problem is that, the distributors did not know
the .png file is required by the class and therefore put them into doc/
folder as part of sample.

I read somewhere someone says all image files like .png should go to
/doc folders as required by TDS, that is why I thought if this is
required by TDS, TDS should have a way to resolve the path.


On 14/09/2015 7:58 AM, Karl Berry wrote:
>     Are there generic, platform-independent TEX variables like @TEXMF and
>     @TEXMFLOCAL to resolve the directory tree defined in TDS for both Tex
>     Live and MikTeX?
> No.  There is no platform-independent way to access environment or
> other configuration variable values at the TeX level in the first place.
>     I post a generic question for a hypothetical package in an attempt to
>     find a general answer.
> The general answer is, files to be accessed by TeX at runtime need to be
> placed by the TeX distributor in a place where TeX can read them.  Those
> places (texmf/tex/...) are described in the TDS, but obviously the TDS
> cannot address bugs by the distributors.  An individual package author
> cannot plausibly solve this within his or her own TeX code.
> Files being misplaced by distributors (both TL and MiKTeX) happens all
> the time.  The answer is, file a bug report, and we fix it.  That's it.
>     e.g. To allow any of the following to work:
> Those constructs would be far more fragile and cause far more problems
> than anything we have today.
> I believe that the best approach for package authors is to completely
> avoid using directory names at the TeX level.
> Best,
> Karl

More information about the twg-tds mailing list