FIG2SXD(1)
π NAME π
okay so bestie, meet fig2sxd β it's the little utility that converts .fig files into .sxd files. that's it, that's the whole job. iconic. β¨
π¦ SYNOPSIS π¦
fig2sxd [-w] [-l(ine)w(idth)1 l] [-stylebase s] figfile sxdfile
πΈ DESCRIPTION πΈ
so basically, this program tries to take the file you hand it in xfig format and turn it into a sxd file that OpenOffice.org Draw can actually open. glow-up complete. π
here's the tea on the arguments:
- if
figfileends with.figor.xfigand you don't passsxdfile, the output file gets named just likefigfilebut with.sxdon the end instead of.(x)fig. auto-naming, we love her. π - if you use
-forfigfile, the program reads from stdin instead. which means you can do this little number:
pstoedit -f fig file.ps - | fig2sxd - file.sxd
and boom, you're converting ps files. πͺ
now, if your file has a LOT of objects, you might wanna reach for something like:
pstoedit -f 'fig:-startdepth 9999' file.ps - | fig2sxd - file.sxd
which gets you more layers. fair warning tho β the output of pstoedit is no longer a valid xfig file after this, but it makes the z ordering of the objects in OpenOffice.org Draw stay correct. trade-off, bestie. π€·
- if you use
-forsxdfile, the program writes to stdout instead.
and then there's the line width situation:
- with the
-linewidth1option (or its lil nickname-lw1), you can set the width of lines that have thickness 1 in xfig. the unit is1 cm. if you pass0here you get fine lines. example time:
pstoedit -f 'fig:-startdepth 9999' file.ps - | fig2sxd -lw1 0 -
file.sxd
- with the
-woption, out-of-specification values only get you warnings β but they will be sanitized. no chaos allowed, sorry. π§Ό - with the
-stylebaseoption, you can change the prefix of the generated style names. this is highkey useful if you don't want styles from several converted figures mixing together when they get joined into one OpenOffice.org document. the argument to-stylebasehas to consist of4..255alphanumeric characters. those are the rules. π
π DEFICIENCIES π
ngl, not every single .fig object gets converted perfectly. here's the honest list:
- splines look pretty similar but they are not exactly the same. close enough? maybe not. π
- text placement might be a little bit wrong, especially for very small font sizes.
- hatches look different in many cases.
- hollow arrows are not supported and get replaced by their filled counterparts. gone, reduced to atoms. π
- and yeah, there are various other things that could be improved. we're aware. π
also, it looks like OpenOffice.org cannot read xml attribute values longer than 64kB, which is exactly the kind of thing you'd run into with very long polygons or lines. so for unfilled polylines, fig2sxd creates several smaller polylines of 500 points each and groups them together. slay. π
but splitting an arbitrary filled polygon? not trivial, and not implemented. don't ask her to do that, she won't. π«
π₯ SEE ALSO π₯
pstoedit(1), xfig(1) and http://fig2sxd.sourceforge.net/ (for updates, bestie, go check it).
π AUTHOR π
the program and this manual page were both written by Alexander BΓΌrger <acfb@users.sourceforge.net>. we stan. π«Ά
okay that's the whole page, no cap. this was FIG2SXD(1) from the General Commands Manual, and that footer tag at the bottom is literally just FIG2SXD(1) again β she's her own hype woman. mwah π π β
π¦ where this page comes from
- debian bookworm: fig2sxd 0.23-1
- debian trixie: fig2sxd 0.23-1
- ubuntu noble: fig2sxd 0.23-1
- ubuntu questing: fig2sxd 0.23-1
- ubuntu resolute: fig2sxd 0.23-1build1
- ubuntu stonking: fig2sxd 0.24-1 Β· GPL-2.0-or-later
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms