diff options
author | Tor Lillqvist <tml@iki.fi> | 2001-02-10 00:24:58 +0000 |
---|---|---|
committer | Tor Lillqvist <tml@src.gnome.org> | 2001-02-10 00:24:58 +0000 |
commit | d6f9b720674c1eef1f1975d567a8fdf197bc9fc7 (patch) | |
tree | 7c6cbeb9e84833cc3a59d55c67ad6a2257662f9f /pango/querymodules.c | |
parent | da18979679966822e231eebdf1c93b2fbdce4818 (diff) | |
download | pango-d6f9b720674c1eef1f1975d567a8fdf197bc9fc7.tar.gz |
Use g_win32_get_package_installation_subdirectory(). Use the same
2001-02-10 Tor Lillqvist <tml@iki.fi>
* pango/pango-utils.c (pango_get_sysconf_subdirectory,
pango_get_lib_subdirectory): (Win32): Use
g_win32_get_package_installation_subdirectory(). Use the same
directory structure as on Unix, etc\pango and lib\pango under the
installation "prefix".
* config.h.win32
* pango/makefile.mingw.in: Use mini-fribidi instead of full
FriBiDi.
* pango/pangowin32.c (pango_win32_render_layout_line): Adapt to
changed PangoAttrColor.
* pango/querymodules.c: Include <io.h> for getcwd() prototype.
(query_module): Handle modules with spaces in the path, and
backslashes, use g_strescape() (for Windows).
* pango/mini-fribidi/makefile.mingw: New file
Diffstat (limited to 'pango/querymodules.c')
-rw-r--r-- | pango/querymodules.c | 24 |
1 files changed, 20 insertions, 4 deletions
diff --git a/pango/querymodules.c b/pango/querymodules.c index 165dde70..ff9263f9 100644 --- a/pango/querymodules.c +++ b/pango/querymodules.c @@ -44,10 +44,9 @@ #include <stdlib.h> #define PATH_MAX _MAX_PATH #endif /* PATH_MAX */ -#ifdef _MSC_VER -#include <direct.h> +#include <direct.h> /* for getcwd() with MSVC */ +#include <io.h> /* for getcwd() with mingw */ #define getcwd _getcwd -#endif #else #define SOEXT ".so" #endif @@ -85,7 +84,24 @@ query_module (const char *dir, const char *name) for (i=0; i<n_engines; i++) { - g_print ("%s %s %s %s ", path, engines[i].id, engines[i].engine_type, engines[i].render_type); + const gchar *quote; + gchar *quoted_path; + + if (strchr (path, ' ') != NULL) + { + quote = "\""; + quoted_path = g_strescape (path, NULL); + } + else + { + quote = ""; + quoted_path = g_strdup (path); + } + + g_print ("%s%s%s %s %s %s ", quote, quoted_path, quote, + engines[i].id, engines[i].engine_type, engines[i].render_type); + g_free (quoted_path); + for (j=0; j < engines[i].n_ranges; j++) { if (j != 0) |