lyx_mirror/src/Spacing.C
Lars Gullik Bjønnes 75c5c8c9e5 the fstream/iostream changes and some small other things
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@354 a592a061-630c-0410-9148-cb99ea01b6c8
1999-12-07 00:44:53 +00:00

22 lines
491 B
C

#include <config.h>
#include <cstdio>
#include "Spacing.h"
/// how can I put this inside of Spacing (class)
static
char const * spacing_string[] = {"single", "onehalf", "double", "other"};
void Spacing::writeFile(ostream & os)
{
if (getSpace() == Spacing::Other) {
os.setf(ios::showpoint|ios::fixed);
os.precision(2);
os << "\\spacing " << spacing_string[getSpace()]
<< " " << getValue() << " \n";
} else {
os << "\\spacing " << spacing_string[getSpace()] << " \n";
}
}