/usr/share/doc/libooolib-perl/examples/calc-example1 is in libooolib-perl 0.1.9-1.
This file is owned by root:root, with mode 0o755.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 | #!/usr/bin/perl
# calc-example1 - This program creates a SXC Calc file with 25 cells and a formula.
use ooolib;
# Set variables
$doc = new ooolib("sxc");
$doc->oooSet("builddir", "."); # Directory to create document in
$doc->oooSet("title", "Calc 25 Cells"); # Title of document
$doc->oooSet("subject", "Calc Example"); # Subject of document
$doc->oooSet("comments", "Who needs comments?"); # Comments for document
$doc->oooSet("keyword", "keyword1"); # Add a keyword for the document
$doc->oooSet("keyword", "keyword2"); # Add a keyword for the document
$doc->oooSet("author", "ooolib example"); # Set the author of the document
# User defined variables
$doc->oooSet("meta1-name", "Programmer"); # 1-4 user defined variables
$doc->oooSet("meta1-value", "Joseph Colton"); # 1-4 user defined variables
# Write the spreadsheet data
# It is in x, y cords.
for($x=1;$x<=5;$x++) {
for($y=1;$y<=5;$y++) {
$doc->oooSet("cell-loc", $x, $y);
$doc->oooData("cell-float", $x*$y);
}
}
$doc->oooSet("cell-loc", 1 ,6);
$doc->oooData("cell-formula", "=SUM(B2:C2)");
$filename = $doc->oooGenerate("calc-example1.sxc"); # Create the document and return a filename
exit;
|