Number to number name and money text conversion libraries in C++, Java, JavaScript and Python & LibreOffice Calc Extension
Switch branches/tags
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
META-INF (remaining) import from Numbertext 0.8 (2010-04-19) Apr 4, 2018
bin (remaining) import from Numbertext 0.9.5 (2012-12-06) Apr 4, 2018
data [pl] fix ordinal numbers Oct 9, 2018
doc Tutorial: new task (Deeper in recursion) May 3, 2018
idl import Numbertext 0.4 (2009-08-09) Apr 4, 2018
java Jar packaging: create non-existing dictionary Oct 9, 2018
m4 Add enable-boost option to work with older gcc-4.8 and like using boo… Jun 4, 2018
pkg-desc import Numbertext 0.8.1 (2010-04-22) Apr 4, 2018
pythonpath LibreOffice extension: default capitalization May 25, 2018
rdb import Numbertext 0.4 (2009-08-09) Apr 4, 2018
src Don't depend on en_US.UTF-8 locale Oct 30, 2018
test fix testing Apr 16, 2018
web [web] new video: chapter numbering in LibreOffice 6.1 Oct 9, 2018
.travis.yml Add travis ci integration Jun 29, 2018
AUTHORS prepare version 1.0.5 Oct 9, 2018
COPYING Disambiguate license: Modified BSD, LGPL-3+ dual-license May 3, 2018
CalcAddIn.xcu Added a Bulgarian module and translation. May 7, 2018
ChangeLog prepare version 1.0.5 Oct 9, 2018
Makefile.am Package README.md instead of README Oct 9, 2018
Makefile.orig Package README.md instead of README Oct 9, 2018
NEWS (remaining) import from Numbertext 0.9.5 (2012-12-06) Apr 4, 2018
README.md Fix inconsistency in README.md Nov 19, 2018
THANKS (remaining) import from Numbertext 0.6.1 (2009-09-04) Apr 4, 2018
VERSION prepare version 1.0.5 Oct 9, 2018
configure.ac prepare version 1.0.5 Oct 9, 2018
description.xml.in Added a Bulgarian module and translation. May 7, 2018
libnumbertext.pc.in C++11 port Apr 17, 2018
reg.uno.py (remaining) import from Numbertext 0.9.5 (2012-12-06) Apr 4, 2018

README.md

Soros interpreters for C++11, Java, JavaScript and Python

Build Status

Language-neutral NUMBERTEXT and MONEYTEXT functions for LibreOffice Calc

version 1.0.5 (2018-10-09)

Numbertext LibreOffice extension,
Soros programming language specification (draft) and IDE*,
Soros interpreter in Python: pythonpath/Soros.py,
Soros interpreter in JavaScript: Soros.js*
Soros interpreter in Java: see NUMBERTEXT.org

* Not in LibreOffice Numbertext extension, see http://NUMBERTEXT.org.

Copyright: 2009-2018 (C) László Németh (nemeth at numbertext dot org)
License: LGPL-3+/Modified BSD dual-license

Numbertext language data (Soros programs):
License: LGPL-3+/Modified BSD dual-license (except Serbian)

Copyright: 2009-2018 (C) László Németh et al. (see AUTHORS)
Bulgarian: 2018 (C) Mihail Balabanov (m dot balabanov at gmail dot com)
Croatian: 2014 (C) Mihovil Stanić (mihovil dot stanic at gmail dot com)
Hebrew module: 2010 (C) Alex Bodnaru (alexbodn at 012 dot net dot il)
French (Belgian and Swiss): 2009 (C) Olivier Ronez
Galician: 2018 (C) Adrián Chaves (adrian at chaves dot io)
Indonesian: 2010 (C) Eko Prasetiyo (ekoprasetiyo at gmail)
Latvian: 2012 (C) Asterisks at OOo Wiki
Luxembourgish: 2009 (C) Michel Weimerskirch (michel at weimerskirch dot net)
Portuguese: 2009 (C) Eduardo Moreno (emoreno at tokonhu dot com)
Turkish: 2009 (C) Randem

Serbian: 2009 (C) Goran Rakić (grakic at devbase dot net)
License: CC BY-SA/LGPL-3+/Modified BSD tri-license


* Note: for full distribution with specifications, IDE and JavaScript
  implementation, see http://NUMBERTEXT.org

Software distributed under the License is distributed on an "AS IS" basis,
WITHOUT WARRANTY OF ANY KIND, either express or implied.

= Supported languages in this version =

af	Africaans
bg	Bulgarian
ca	Catalan
cs	Czech
da	Danish
de	German
de-CH	Swiss Standard German orthography (dreissig instead of dreißig)
de-LI	Swiss Standard German orthography (dreissig instead of dreißig)
el	Greek
en	English (one hundred one)
en-AU	English (one hundred and one)
en-GB	English (one hundred and one)
en-IE	English (one hundred and one)
en-IN	English with Indian numbering system (lakh = 100.000, crore = 10^7)
en-NZ	English (one hundred and one)
eo	Esperanto
es	Spanish
et	Estonian
fi	Finnish
fr	French
fr-BE	Belgian French
fr-CH	Swiss French
gl	Galician
he	Hebrew
hr	Croatian
hu	Hungarian
id	Indonesian
is	Icelandic
it	Italian
ja	Japanese
ko	South-Korean
ko-KP	North-Korean
lb	Luxembourgish
lt	Lithuanian
lv	Latvian
ms	Malaysian
nb	Norwegian Bokmål
nl	Dutch
nn	Norwegian Nynorsk
no	Norwegian (Bokmål)
pl	Polish
pt	Portuguese
pt-BR	Brazilian Portuguese
ro	Romanian
ru	Russian
sh	Serbian (Latin)
sl	Slovenian
sq	Albanian
sr	Serbian (Cyrillic)
sv	Swedish
th	Thai
tr	Turkish
uk	Ukrainian
vi	Vietnamese
zh	Chinese (simplified)

Old number systems:

Hung		Old Hungarian Script
Roman		Roman numbers
Roman-large	Roman numbers for very large numbers
		using parenthesized syntax
Suzhou		Chinese Suzhou numerals

= Build C++11 =

autoreconf -i
./configure
make

# test it

src/spellout -l en 123

= Build Java jar =

cd java
make

= Build and using LibreOffice Extension =

make -f Makefile.orig lo

and install the *.oxt package by
Tools->Extension Manager->Add of LibreOffice.

After restarting OpenOffice.org/LibreOffice, there are
two new Calc functions,
NUMBERTEXT() and MONEYTEXT().

Examples:

=NUMBERTEXT(25)
=NUMBERTEXT(25;"th-TH")
=MONEYTEXT(25)
=MONEYTEXT(25;"USD")
=MONEYTEXT(25;"CNY";"zh-ZH")

Module Help (enlarge the row to see all lines), containing
available prefix functions of the module:

= NUMBERTEXT("help")
= NUMBERTEXT("help";"de")

= Development =

See doc/addnewlocale.txt and doc/sorosspec.odt

For general Calc and (portable Excel) Add-In developments, see
Jan Holst Jensen's excellent Add-in example and documentation:

http://biochemfusion.com/doc/Calc_addin_howto.html

== Integrated development environment ==

There is a JavaScript/HTML IDE in this distribution. 

Use the online version: http://numbertext.org/Soros.html or
build it with

make -f Makefile.orig

and open web/webroot/Soros.html in a JavaScript capable browser,

= Test =

make -f Makefile.orig check

test/thaicheck.ods is a simple test of the equivalence of
the Soros implementation of Thai number to number name conversion
and BAHTTEXT function.