[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Gnumed-devel] placeholder <patient_photo>
From: |
Karsten Hilbert |
Subject: |
[Gnumed-devel] placeholder <patient_photo> |
Date: |
Thu, 2 Aug 2012 16:36:27 +0200 |
User-agent: |
Mutt/1.5.21 (2010-09-15) |
I have enhanced the patient_photo placeholder thusly:
u'patient_photo', # args:
<template>//<target mime type>//<optional target extension>
# returns full path to an exported copy of the
# image rather than the image data itself,
# returns u'' if no mugshot available,
# template: string template for outputting the path
# target mime type: a mime type into which to convert the image
# target extension: target file name extension, derived from
target mime type if not given
such that proper placeholder instances will look like this:
$<patient_photo::\includegraphics[width=30mm]{%s}//image/png//.png::250>$
Rationale:
Users might have imported patient photographs in any of the
myriad image formats out there. However, when including such
photos the target format (say, LaTeX) will not be able to
handle every single format. Hence the placeholder will now
allow to specify which format to convert an exported image
into before returning the file path.
For that, GNUmed relies on a script / program
gm-convert_file
An example script for Linux is provided, requires
ImageMagick to be installed, and the man page of which is as
follows:
gm-convert_file(1) gm-convert_file(1)
NAME
gm-convert_file - converts files from within GNUmed
SYNOPSIS
gm-convert_file <input file> <target mime type> <target file extension>
<target filename>
DESCRIPTION
gm-convert_file is a helper script which GNUmed uses to convert files
from one format into another as needed.
OPTIONS
input file
The file to convert.
target mime type
The mime type into which to convert the input file.
target file extension
The extension of the target filename
Some programs (say, convert of ImageMagick fame) use this
(rather than the target mime type) to determine the target for‐
mat.
target filename
The filename under which to store the converted file.
SEE ALSO
convert(1)
http://www.gnumed.de
AUTHOR
This manual page was written by Karsten Hilbert
<address@hidden> for the Debian GNU/Linux system (but may be
used by others).
Convert files from within GNUmed2012 August 2nd gm-convert_file(1)
Karsten
--
GPG key ID E4071346 @ gpg-keyserver.de
E167 67FD A291 2BEA 73BD 4537 78B9 A9F9 E407 1346
gm-convert_file
Description: Text document
- [Gnumed-devel] placeholder <patient_photo>,
Karsten Hilbert <=