XCrySDen can print the
content (i.e. crystal structure) displayed in the main
window either in EPS formatted or PPM formatted file.
However it is possible to use some converting program,
that converts the PPM (or EPS) format to several
different graphics formats, such as PNG/JPG/GIF/TIFF.
The
convert
program of
ImageMagick package
is very suitable for this purpose. In order to use the
image converting program in
XCrySDen, one should
specify such a program in the
~/.xcrysden/custom-definitions
file. Here
is an example:
# ------------------------------------------------------------------------
# An image conversion program: we need PPM to PNG/JPG/GIF/... conversion.
# The "convert" program of ImageMagick (http://www.imagemagick.org/) is
# a convinient choice.
#
# It is possible to specify the command-line options. For example:
#
# set xcMisc(ImageMagick.convert) "/usr/bin/convert \
# -quality 90 -border 3x3 -bordercolor black"
#
# Instead one can also store the command line options for convert
# program into the xcMisc(ImageMagick.convertOptions) variable:
#
# set xcMisc(ImageMagick.convertOptions) "-quality 90 -antialias \
# -blur 1x1 -trim -bordercolor white \
# -border 20x20 -bordercolor black -border 3x3"
# ------------------------------------------------------------------------
set xcMisc(ImageMagick.convert) /usr/bin/convert
set xcMisc(ImageMagick.convertOptions) "-quality 90 -antialias \
-blur 1x1 -trim -bordercolor white \
-border 20x20 -bordercolor black -border 3x3"
|
The setting of the
xcMisc(ImageMagick.convert)
variable will
enable to print into all graphics formats supported by
the ImageMagick
convert
program.
Here the term
printing means "printing to
a file". Before printing the content (i.e. crystal
structure) displayed in
XCrySDen main window, it
is useful to perform the following steps:
-
Change the background according to
your needs. Background can be changed in the
Palette menu,
i.e., an icon located on the left of the File menu.
-
XCrySDen
print is, technically speaking, a screen dump, and
therefore the resulting resolution is around 75
dpi. This is far from sufficient for a paper-print.
However in your document the figure will probably
be only few centimeters large, therefore you can do
the following trick: the main window of
XCrySDen
should be maximized, and the displayed crystal
structure enlarged as much as possible
(use [Zoom +] button). By doing this you can
achieve the resolution larger than 300 dpi in the
document figure.
-
Increase the tessellation factor (a
value around 40 would be appropriate). The
tessellation factor can be modified via the
Modify-->Tessellation
Factor menu.
-
Turn on the anti-aliasing via the
Display-->Anti-aliasing
menu. The anti-aliasing can be time depending, and
can in worse cases take up to several minutes.
However it is worth to wait as the printing quality
will be much superior.
- Now you can print via the File --> Print menu.
Thanks to GL2PS library,
XCrySDen can produce a
vectorial EPS. This works very reasonable for
Lighting-Off display-modes (
read here about the
Lighting-Off and
Lighting-On modes).
When printing to EPS file a window will appear, where
you specify different EPS printing parameters. To
produce a vectorial EPS, the
Type of
Postscript flag should be set to VECTORIAL. For
the description of other entries see the
GL2PS documentation.
BEWARE: making the vectorial EPS in
Lighting-On mode can take quite a bit of
time, consume a lot of memory and produce the files
as large as several 100MB. But the resulting EPS is
excellent. Then you can do a 10m x 10m figure without
seing any aliasing.