Replace the fixed 8-column grid with a real spreadsheet engine authored in Kry (src/engine.kry): sparse 256x65536 cell store, multiple sheets, the Gnumeric expression language (relative/absolute/cross-sheet references, ranges, operators with Gnumeric coercion and error semantics) and a function library spanning math, statistics, text, logical, date, and information functions with Excel-compatible date serials. Files load from and save to .gnumeric (Gnumeric XML, gzipped or plain) and CSV, with the legacy workbook.json profile format still readable. The desktop app renders any sheet with A1 headers, sheet tabs, and row/column editing on top of the engine. The new `cell` CLI evaluates workbooks headlessly. Every fixture in tests/fixtures is evaluated by the installed Gnumeric and by this engine and compared cell by cell by scripts/parity-test.sh, plus round-trips where Gnumeric re-reads files this engine wrote; the suite runs as part of make test. Bump vendor/kryon for the kry_xml and kry_gzip primitives the format support builds on.
52 lines
2.5 KiB
XML
52 lines
2.5 KiB
XML
<?xml version="1.0" encoding="UTF-8"?>
|
|
<gnm:Workbook xmlns:gnm="http://www.gnumeric.org/v10.dtd">
|
|
<gnm:Version Epoch="1" Major="12" Minor="57" Full="1.12.57"/>
|
|
<gnm:SheetNameIndex><gnm:SheetName>Ops</gnm:SheetName></gnm:SheetNameIndex>
|
|
<gnm:Sheets><gnm:Sheet><gnm:Name>Ops</gnm:Name><gnm:MaxCol>3</gnm:MaxCol><gnm:MaxRow>30</gnm:MaxRow>
|
|
<gnm:Cells>
|
|
<gnm:Cell Row="0" Col="0" ValueType="40">10</gnm:Cell>
|
|
<gnm:Cell Row="1" Col="0" ValueType="40">20</gnm:Cell>
|
|
<gnm:Cell Row="2" Col="0" ValueType="40">30</gnm:Cell>
|
|
<gnm:Cell Row="3" Col="0" ValueType="40">-5</gnm:Cell>
|
|
<gnm:Cell Row="4" Col="0" ValueType="40">2.5</gnm:Cell>
|
|
<gnm:Cell Row="0" Col="1" ValueType="60">alpha</gnm:Cell>
|
|
<gnm:Cell Row="1" Col="1" ValueType="60">Beta gamma</gnm:Cell>
|
|
<gnm:Cell Row="2" Col="1" ValueType="60">delta</gnm:Cell>
|
|
<gnm:Cell Row="3" Col="1" ValueType="40">3</gnm:Cell>
|
|
<gnm:Cell Row="0" Col="2" ValueType="20">TRUE</gnm:Cell>
|
|
<gnm:Cell Row="1" Col="2" ValueType="20">FALSE</gnm:Cell>
|
|
<gnm:Cell Row="0" Col="3">=B1*2</gnm:Cell>
|
|
<gnm:Cell Row="1" Col="3">=$A$1+B2</gnm:Cell>
|
|
<gnm:Cell Row="2" Col="3">=2^10</gnm:Cell>
|
|
<gnm:Cell Row="3" Col="3">=10%+0.5</gnm:Cell>
|
|
<gnm:Cell Row="4" Col="3">="a"&"b"&1</gnm:Cell>
|
|
<gnm:Cell Row="5" Col="3">=1<2</gnm:Cell>
|
|
<gnm:Cell Row="6" Col="3">=(1>2)+(3<>4)</gnm:Cell>
|
|
<gnm:Cell Row="7" Col="3">=2>=2</gnm:Cell>
|
|
<gnm:Cell Row="8" Col="3">=3<=2</gnm:Cell>
|
|
<gnm:Cell Row="9" Col="3">=1=1.0</gnm:Cell>
|
|
<gnm:Cell Row="10" Col="3">="A"="a"</gnm:Cell>
|
|
<gnm:Cell Row="11" Col="3">=-A4</gnm:Cell>
|
|
<gnm:Cell Row="12" Col="3">=+A1-A2</gnm:Cell>
|
|
<gnm:Cell Row="13" Col="3">=(A1+A2)*3</gnm:Cell>
|
|
<gnm:Cell Row="14" Col="3">=A1/4</gnm:Cell>
|
|
<gnm:Cell Row="15" Col="3">=3=3</gnm:Cell>
|
|
<gnm:Cell Row="16" Col="3">="x"&1.5</gnm:Cell>
|
|
<gnm:Cell Row="17" Col="3">=TRUE+1</gnm:Cell>
|
|
<gnm:Cell Row="18" Col="3">="3"+1</gnm:Cell>
|
|
<gnm:Cell Row="19" Col="3">=-"3"</gnm:Cell>
|
|
<gnm:Cell Row="20" Col="3">="a"<5</gnm:Cell>
|
|
<gnm:Cell Row="21" Col="3">="2"<"10"</gnm:Cell>
|
|
<gnm:Cell Row="22" Col="3">=B2=""</gnm:Cell>
|
|
<gnm:Cell Row="23" Col="3">=1/0</gnm:Cell>
|
|
<gnm:Cell Row="24" Col="3">=0/0</gnm:Cell>
|
|
<gnm:Cell Row="25" Col="3">=SQRT(-1)</gnm:Cell>
|
|
<gnm:Cell Row="26" Col="3">#DIV/0!</gnm:Cell>
|
|
<gnm:Cell Row="27" Col="3">#N/A</gnm:Cell>
|
|
<gnm:Cell Row="28" Col="3">1+2*3</gnm:Cell>
|
|
<gnm:Cell Row="29" Col="3">(1+2)*3</gnm:Cell>
|
|
<gnm:Cell Row="30" Col="3">2^3^2</gnm:Cell>
|
|
</gnm:Cells><gnm:SheetLayout TopLeft="A1"/></gnm:Sheet></gnm:Sheets>
|
|
<gnm:UIData SelectedTab="0"/>
|
|
</gnm:Workbook>
|