diff options
author | John Wiegley <johnw@newartisans.com> | 2007-05-14 11:09:58 +0000 |
---|---|---|
committer | John Wiegley <johnw@newartisans.com> | 2008-04-13 03:38:50 -0400 |
commit | 3fb5a1c320c32f14daa60f6cc4a3d0041663076a (patch) | |
tree | fc3c9c7b29fc71937cf8d116d17a976ab6ddd921 /src/abbrev.h | |
parent | f83705b847c59a8197f5098cb7dc2d484704e24d (diff) | |
download | fork-ledger-3fb5a1c320c32f14daa60f6cc4a3d0041663076a.tar.gz fork-ledger-3fb5a1c320c32f14daa60f6cc4a3d0041663076a.tar.bz2 fork-ledger-3fb5a1c320c32f14daa60f6cc4a3d0041663076a.zip |
Changed xpath to use intrusive_ptr; got the xml command working
Diffstat (limited to 'src/abbrev.h')
-rw-r--r-- | src/abbrev.h | 23 |
1 files changed, 23 insertions, 0 deletions
diff --git a/src/abbrev.h b/src/abbrev.h new file mode 100644 index 00000000..ad880e45 --- /dev/null +++ b/src/abbrev.h @@ -0,0 +1,23 @@ +#ifndef _ABBREV_H +#define _ABBREV_H + +#include "utils.h" + +namespace ledger { + +enum elision_style_t { + TRUNCATE_TRAILING, + TRUNCATE_MIDDLE, + TRUNCATE_LEADING, + ABBREVIATE +}; + +string abbreviate(const string& str, + unsigned int width, + elision_style_t elision_style = TRUNCATE_TRAILING, + const bool is_account = false, + int abbrev_length = 2); + +} // namespace ledger + +#endif // _ABBREV_H |