Evince
Evince is a document viewer capable of displaying multiple and single page document formats like PDF and Postscript.
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros Pages
texmfcnf.h File Reference
#include <glib.h>
+ Include dependency graph for texmfcnf.h:
+ This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Functions

G_BEGIN_DECLS gchar * get_texmfcnf (void)
 

Function Documentation

G_BEGIN_DECLS gchar* get_texmfcnf ( void  )

Definition at line 30 of file texmfcnf.c.

31 {
32  char *env = getenv("TEXMFCNF");
33  if (env)
34  return g_strdup(env);
35 
36 #ifdef G_OS_WIN32
37  gchar *texmfcnf = NULL;
38  TCHAR path[_MAX_PATH];
39 
40  if (SearchPath(NULL, "mktexpk", ".exe", _MAX_PATH, path, NULL))
41  {
42  gchar *sdir, *sdir_parent, *sdir_grandparent;
43  const gchar *texmfcnf_fmt = "{%s,%s,%s}{,{/share,}/texmf{-local,}/web2c}";
44 
45  sdir = g_path_get_dirname(path);
46  sdir_parent = g_path_get_dirname(sdir);
47  sdir_grandparent = g_path_get_dirname(sdir_parent);
48 
49  texmfcnf = g_strdup_printf(texmfcnf_fmt,
50  sdir, sdir_parent, sdir_grandparent);
51 
52  g_free(sdir);
53  g_free(sdir_parent);
54  g_free(sdir_grandparent);
55  }
56  return texmfcnf;
57 #else
58  return NULL;
59 #endif
60 }

+ Here is the caller graph for this function: