kmadej_fast_excel_fork 0.2.2

Sign up to get free protection for your applications and to get access to all the features.
Files changed (119) hide show
  1. checksums.yaml +7 -0
  2. data/.gitignore +13 -0
  3. data/.travis.yml +28 -0
  4. data/CHANGELOG.md +13 -0
  5. data/Gemfile +17 -0
  6. data/Gemfile.lock +70 -0
  7. data/Makefile +14 -0
  8. data/README.md +95 -0
  9. data/Rakefile +24 -0
  10. data/appveyor.yml +25 -0
  11. data/benchmarks/1k_rows.rb +59 -0
  12. data/benchmarks/20k_rows.rb +26 -0
  13. data/benchmarks/init.rb +59 -0
  14. data/benchmarks/memory.rb +49 -0
  15. data/examples/example.rb +42 -0
  16. data/examples/example_align.rb +23 -0
  17. data/examples/example_chart.rb +21 -0
  18. data/examples/example_colors.rb +37 -0
  19. data/examples/example_formula.rb +18 -0
  20. data/examples/example_image.rb +13 -0
  21. data/examples/example_styles.rb +27 -0
  22. data/examples/logo.png +0 -0
  23. data/extconf.rb +0 -0
  24. data/fast_excel.gemspec +20 -0
  25. data/lib/fast_excel.rb +600 -0
  26. data/lib/fast_excel/binding.rb +2819 -0
  27. data/lib/fast_excel/binding/chart.rb +2666 -0
  28. data/lib/fast_excel/binding/format.rb +1177 -0
  29. data/lib/fast_excel/binding/workbook.rb +338 -0
  30. data/lib/fast_excel/binding/worksheet.rb +1555 -0
  31. data/libxlsxwriter/.gitignore +49 -0
  32. data/libxlsxwriter/.indent.pro +125 -0
  33. data/libxlsxwriter/.travis.yml +25 -0
  34. data/libxlsxwriter/CONTRIBUTING.md +226 -0
  35. data/libxlsxwriter/Changes.txt +557 -0
  36. data/libxlsxwriter/LICENSE.txt +89 -0
  37. data/libxlsxwriter/Makefile +156 -0
  38. data/libxlsxwriter/Readme.md +78 -0
  39. data/libxlsxwriter/cocoapods/libxlsxwriter-umbrella.h +30 -0
  40. data/libxlsxwriter/cocoapods/libxlsxwriter.modulemap +7 -0
  41. data/libxlsxwriter/include/xlsxwriter.h +23 -0
  42. data/libxlsxwriter/include/xlsxwriter/app.h +79 -0
  43. data/libxlsxwriter/include/xlsxwriter/chart.h +3476 -0
  44. data/libxlsxwriter/include/xlsxwriter/common.h +372 -0
  45. data/libxlsxwriter/include/xlsxwriter/content_types.h +74 -0
  46. data/libxlsxwriter/include/xlsxwriter/core.h +51 -0
  47. data/libxlsxwriter/include/xlsxwriter/custom.h +52 -0
  48. data/libxlsxwriter/include/xlsxwriter/drawing.h +111 -0
  49. data/libxlsxwriter/include/xlsxwriter/format.h +1214 -0
  50. data/libxlsxwriter/include/xlsxwriter/hash_table.h +76 -0
  51. data/libxlsxwriter/include/xlsxwriter/packager.h +80 -0
  52. data/libxlsxwriter/include/xlsxwriter/relationships.h +77 -0
  53. data/libxlsxwriter/include/xlsxwriter/shared_strings.h +83 -0
  54. data/libxlsxwriter/include/xlsxwriter/styles.h +77 -0
  55. data/libxlsxwriter/include/xlsxwriter/theme.h +47 -0
  56. data/libxlsxwriter/include/xlsxwriter/third_party/ioapi.h +214 -0
  57. data/libxlsxwriter/include/xlsxwriter/third_party/queue.h +694 -0
  58. data/libxlsxwriter/include/xlsxwriter/third_party/tmpfileplus.h +53 -0
  59. data/libxlsxwriter/include/xlsxwriter/third_party/tree.h +801 -0
  60. data/libxlsxwriter/include/xlsxwriter/third_party/zip.h +375 -0
  61. data/libxlsxwriter/include/xlsxwriter/utility.h +166 -0
  62. data/libxlsxwriter/include/xlsxwriter/workbook.h +757 -0
  63. data/libxlsxwriter/include/xlsxwriter/worksheet.h +2641 -0
  64. data/libxlsxwriter/include/xlsxwriter/xmlwriter.h +178 -0
  65. data/libxlsxwriter/lib/.gitignore +0 -0
  66. data/libxlsxwriter/libxlsxwriter.podspec +47 -0
  67. data/libxlsxwriter/src/Makefile +130 -0
  68. data/libxlsxwriter/src/app.c +443 -0
  69. data/libxlsxwriter/src/chart.c +6346 -0
  70. data/libxlsxwriter/src/content_types.c +345 -0
  71. data/libxlsxwriter/src/core.c +293 -0
  72. data/libxlsxwriter/src/custom.c +224 -0
  73. data/libxlsxwriter/src/drawing.c +746 -0
  74. data/libxlsxwriter/src/format.c +729 -0
  75. data/libxlsxwriter/src/hash_table.c +223 -0
  76. data/libxlsxwriter/src/packager.c +948 -0
  77. data/libxlsxwriter/src/relationships.c +245 -0
  78. data/libxlsxwriter/src/shared_strings.c +266 -0
  79. data/libxlsxwriter/src/styles.c +1088 -0
  80. data/libxlsxwriter/src/theme.c +348 -0
  81. data/libxlsxwriter/src/utility.c +515 -0
  82. data/libxlsxwriter/src/workbook.c +1930 -0
  83. data/libxlsxwriter/src/worksheet.c +5022 -0
  84. data/libxlsxwriter/src/xmlwriter.c +355 -0
  85. data/libxlsxwriter/third_party/minizip/Makefile +44 -0
  86. data/libxlsxwriter/third_party/minizip/Makefile.am +45 -0
  87. data/libxlsxwriter/third_party/minizip/Makefile.orig +25 -0
  88. data/libxlsxwriter/third_party/minizip/MiniZip64_Changes.txt +6 -0
  89. data/libxlsxwriter/third_party/minizip/MiniZip64_info.txt +74 -0
  90. data/libxlsxwriter/third_party/minizip/README.txt +5 -0
  91. data/libxlsxwriter/third_party/minizip/configure.ac +32 -0
  92. data/libxlsxwriter/third_party/minizip/crypt.h +131 -0
  93. data/libxlsxwriter/third_party/minizip/ioapi.c +247 -0
  94. data/libxlsxwriter/third_party/minizip/ioapi.h +208 -0
  95. data/libxlsxwriter/third_party/minizip/iowin32.c +456 -0
  96. data/libxlsxwriter/third_party/minizip/iowin32.h +28 -0
  97. data/libxlsxwriter/third_party/minizip/make_vms.com +25 -0
  98. data/libxlsxwriter/third_party/minizip/miniunz.c +660 -0
  99. data/libxlsxwriter/third_party/minizip/miniunzip.1 +63 -0
  100. data/libxlsxwriter/third_party/minizip/minizip.1 +46 -0
  101. data/libxlsxwriter/third_party/minizip/minizip.c +520 -0
  102. data/libxlsxwriter/third_party/minizip/minizip.pc.in +12 -0
  103. data/libxlsxwriter/third_party/minizip/mztools.c +291 -0
  104. data/libxlsxwriter/third_party/minizip/mztools.h +37 -0
  105. data/libxlsxwriter/third_party/minizip/unzip.c +2125 -0
  106. data/libxlsxwriter/third_party/minizip/unzip.h +437 -0
  107. data/libxlsxwriter/third_party/minizip/zip.c +2007 -0
  108. data/libxlsxwriter/third_party/minizip/zip.h +367 -0
  109. data/libxlsxwriter/third_party/tmpfileplus/Makefile +42 -0
  110. data/libxlsxwriter/third_party/tmpfileplus/tmpfileplus.c +342 -0
  111. data/libxlsxwriter/third_party/tmpfileplus/tmpfileplus.h +53 -0
  112. data/libxlsxwriter/version.txt +1 -0
  113. data/test/date_test.rb +22 -0
  114. data/test/default_format_test.rb +19 -0
  115. data/test/format_test.rb +171 -0
  116. data/test/test_helper.rb +52 -0
  117. data/test/tmpfile_test.rb +23 -0
  118. data/test/worksheet_test.rb +86 -0
  119. metadata +182 -0
@@ -0,0 +1,89 @@
1
+
2
+ Libxlsxwriter is released under a FreeBSD license:
3
+
4
+ Copyright 2014-2017, John McNamara <jmcnamara@cpan.org>
5
+ All rights reserved.
6
+
7
+ Redistribution and use in source and binary forms, with or without
8
+ modification, are permitted provided that the following conditions are
9
+ met:
10
+
11
+ 1. Redistributions of source code must retain the above copyright notice,
12
+ this list of conditions and the following disclaimer.
13
+ 2. Redistributions in binary form must reproduce the above copyright
14
+ notice, this list of conditions and the following disclaimer in the
15
+ documentation and/or other materials provided with the distribution.
16
+
17
+ THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS
18
+ IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
19
+ THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
20
+ PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
21
+ CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
22
+ EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
23
+ PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
24
+ PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
25
+ LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
26
+ NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
27
+ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
28
+
29
+ The views and conclusions contained in the software and documentation are
30
+ those of the authors and should not be interpreted as representing
31
+ official policies, either expressed or implied, of the FreeBSD Project.
32
+
33
+
34
+ Libxlsxwriter includes `queue.h` from FreeBSD and the `minizip` component of
35
+ `zlib` which have the following licenses:
36
+
37
+
38
+ Queue.h from FreeBSD:
39
+
40
+ Copyright (c) 1991, 1993
41
+ The Regents of the University of California. All rights reserved.
42
+
43
+ Redistribution and use in source and binary forms, with or without
44
+ modification, are permitted provided that the following conditions
45
+ are met:
46
+ 1. Redistributions of source code must retain the above copyright
47
+ notice, this list of conditions and the following disclaimer.
48
+ 2. Redistributions in binary form must reproduce the above copyright
49
+ notice, this list of conditions and the following disclaimer in the
50
+ documentation and/or other materials provided with the distribution.
51
+ 4. Neither the name of the University nor the names of its contributors
52
+ may be used to endorse or promote products derived from this software
53
+ without specific prior written permission.
54
+
55
+ THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
56
+ ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
57
+ IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
58
+ ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
59
+ FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
60
+ DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
61
+ OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
62
+ HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
63
+ LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
64
+ OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
65
+ SUCH DAMAGE.
66
+
67
+
68
+ Zlib has the following License/Copyright:
69
+
70
+ (C) 1995-2013 Jean-loup Gailly and Mark Adler
71
+
72
+ This software is provided 'as-is', without any express or implied
73
+ warranty. In no event will the authors be held liable for any damages
74
+ arising from the use of this software.
75
+
76
+ Permission is granted to anyone to use this software for any purpose,
77
+ including commercial applications, and to alter it and redistribute it
78
+ freely, subject to the following restrictions:
79
+
80
+ 1. The origin of this software must not be misrepresented; you must not
81
+ claim that you wrote the original software. If you use this software
82
+ in a product, an acknowledgment in the product documentation would be
83
+ appreciated but is not required.
84
+ 2. Altered source versions must be plainly marked as such, and must not be
85
+ misrepresented as being the original software.
86
+ 3. This notice may not be removed or altered from any source distribution.
87
+
88
+ Jean-loup Gailly Mark Adler
89
+ jloup@gzip.org madler@alumni.caltech.edu
@@ -0,0 +1,156 @@
1
+ ###############################################################################
2
+ #
3
+ # Makefile for libxlsxwriter library.
4
+ #
5
+ # Copyright 2014-2017, John McNamara, jmcnamara@cpan.org
6
+ #
7
+
8
+ # Keep the output quiet by default.
9
+ Q=@
10
+ ifdef V
11
+ Q=
12
+ endif
13
+
14
+ .PHONY: docs tags examples
15
+
16
+ # Build the libs.
17
+ all :
18
+ $(Q)$(MAKE) -C third_party/minizip
19
+ ifndef USE_STANDARD_TMPFILE
20
+ $(Q)$(MAKE) -C third_party/tmpfileplus
21
+ endif
22
+ $(Q)$(MAKE) -C src
23
+
24
+ # Build the example programs.
25
+ examples :
26
+ $(Q)$(MAKE) -C examples
27
+
28
+ # Clean src and test directories.
29
+ clean :
30
+ $(Q)$(MAKE) clean -C src
31
+ $(Q)$(MAKE) clean -C test/unit
32
+ $(Q)$(MAKE) clean -C test/functional/src
33
+ $(Q)$(MAKE) clean -C examples
34
+ $(Q)$(MAKE) clean -C third_party/minizip
35
+ $(Q)rm -rf docs/html
36
+ $(Q)rm -rf test/functional/__pycache__
37
+ $(Q)rm -f test/functional/*.pyc
38
+ $(Q)rm -f lib/*
39
+ ifndef USE_STANDARD_TMPFILE
40
+ $(Q)$(MAKE) clean -C third_party/tmpfileplus
41
+ endif
42
+
43
+ # Run the unit tests.
44
+ test : all test_functional test_unit
45
+
46
+ # Run the functional tests.
47
+ test_functional : all
48
+ $(Q)$(MAKE) -C test/functional/src
49
+ $(Q)py.test test/functional -v
50
+
51
+ # Run all tests.
52
+ test_unit :
53
+ @echo "Compiling unit tests ..."
54
+ $(Q)$(MAKE) -C third_party/minizip
55
+ ifndef USE_STANDARD_TMPFILE
56
+ $(Q)$(MAKE) -C third_party/tmpfileplus
57
+ endif
58
+ $(Q)$(MAKE) -C src test_lib
59
+ $(Q)$(MAKE) -C test/unit test
60
+
61
+ # Test the functional test exes with valgrind (in 64bit mode only).
62
+ test_valgrind : all
63
+ ifndef NO_VALGRIND
64
+ $(Q)$(MAKE) -C test/functional/src test_valgrind
65
+ $(Q)$(MAKE) -C examples test_valgrind
66
+ endif
67
+
68
+ # Minimal target for quick compile without creating the libs.
69
+ test_compile :
70
+ $(Q)$(MAKE) -C src test_compile
71
+
72
+ # Indent the source files with the .indent.pro settings.
73
+ indent:
74
+ $(Q)gindent src/*.c include/*.h include/xlsxwriter/*.h
75
+
76
+ tags:
77
+ $(Q)rm -f TAGS
78
+ $(Q)etags src/*.c include/*.h include/xlsxwriter/*.h
79
+
80
+ # Build the doxygen docs.
81
+ doc: docs
82
+ docs:
83
+ $(Q)$(MAKE) -C docs
84
+
85
+ # Simple minded install.
86
+ install:
87
+ $(Q)cp -r include/* /usr/include
88
+ $(Q)cp lib/* /usr/lib
89
+
90
+ # Simpler minded uninstall.
91
+ uninstall:
92
+ $(Q)rm -rf /usr/include/xlsxwriter*
93
+ $(Q)rm /usr/lib/libxlsxwriter.*
94
+
95
+ # Strip the lib files.
96
+ strip:
97
+ $(Q)strip lib/*
98
+
99
+ # Run a coverity static analysis.
100
+ coverity:
101
+ $(Q)$(MAKE) -C third_party/minizip
102
+ ifndef USE_STANDARD_TMPFILE
103
+ $(Q)$(MAKE) -C third_party/tmpfileplus
104
+ endif
105
+ $(Q)$(MAKE) -C src clean
106
+ $(Q)rm -f lib/*
107
+ $(Q)rm -rf cov-int
108
+ $(Q)rm -f libxlsxwriter-coverity.tgz
109
+ $(Q)../../cov-analysis-linux64-8.7.0/bin/cov-build --dir cov-int make -C src libxlsxwriter.a
110
+ $(Q)tar -czf libxlsxwriter-coverity.tgz cov-int
111
+ $(Q)$(MAKE) -C src clean
112
+ $(Q)rm -f lib/*
113
+
114
+ # Run a scan-build static analysis.
115
+ scan_build:
116
+ $(Q)$(MAKE) -C third_party/minizip
117
+ ifndef USE_STANDARD_TMPFILE
118
+ $(Q)$(MAKE) -C third_party/tmpfileplus
119
+ endif
120
+ $(Q)$(MAKE) -C src clean
121
+ $(Q)rm -f lib/*
122
+ $(Q)scan-build make -C src libxlsxwriter.a
123
+ $(Q)$(MAKE) -C src clean
124
+ $(Q)rm -f lib/*
125
+
126
+ spellcheck:
127
+ $(Q)for f in docs/src/*.dox; do aspell --lang=en_US --check $$f; done
128
+ $(Q)for f in include/xlsxwriter/*.h; do aspell --lang=en_US --check $$f; done
129
+ $(Q)for f in src/*.c; do aspell --lang=en_US --check $$f; done
130
+ $(Q)for f in examples/*.c; do aspell --lang=en_US --check $$f; done
131
+ $(Q)aspell --lang=en_US --check Changes.txt
132
+ $(Q)aspell --lang=en_US --check Readme.md
133
+
134
+ releasecheck:
135
+ $(Q)dev/release/release_check.sh
136
+
137
+ release: releasecheck
138
+ @echo
139
+ @echo "Pushing to git master ..."
140
+ $(Q)git push origin master
141
+ $(Q)git push --tags
142
+
143
+ @echo
144
+ @echo "Pushing updated docs ..."
145
+ $(Q)make -C ../libxlsxwriter.github.io release
146
+
147
+ @echo
148
+ @echo "Pushing the cocoapod ..."
149
+ $(Q)pod trunk push libxlsxwriter.podspec --use-libraries
150
+
151
+ @echo
152
+ @echo "Finished. Opening files."
153
+ $(Q)open http://libxlsxwriter.github.io/changes.html
154
+ $(Q)open http://cocoadocs.org/docsets/libxlsxwriter
155
+ $(Q)open https://github.com/jmcnamara/libxlsxwriter
156
+ $(Q)open https://github.com/jmcnamara/libxlsxwriter/releases
@@ -0,0 +1,78 @@
1
+ # libxlsxwriter
2
+
3
+
4
+ Libxlsxwriter: A C library for creating Excel XLSX files.
5
+
6
+
7
+ ![demo image](http://libxlsxwriter.github.io/demo.png)
8
+
9
+
10
+ ## The libxlsxwriter library
11
+
12
+ Libxlsxwriter is a C library that can be used to write text, numbers, formulas
13
+ and hyperlinks to multiple worksheets in an Excel 2007+ XLSX file.
14
+
15
+ It supports features such as:
16
+
17
+ - 100% compatible Excel XLSX files.
18
+ - Full Excel formatting.
19
+ - Merged cells.
20
+ - Defined names.
21
+ - Autofilters.
22
+ - Charts.
23
+ - Worksheet PNG/JPEG images.
24
+ - Memory optimization mode for writing large files.
25
+ - Source code available on [GitHub](https://github.com/jmcnamara/libxlsxwriter).
26
+ - FreeBSD license.
27
+ - ANSI C.
28
+ - Works with GCC, Clang, Xcode, MSVC 2015, ICC, TCC, MinGW, MingGW-w64/32.
29
+ - Works on Linux, FreeBSD, OpenBSD, OS X, iOS and Windows. Also works on MSYS/MSYS2 and Cygwin.
30
+ - Compiles for 32 and 64 bit.
31
+ - The only dependency is on `zlib`.
32
+
33
+ Here is an example that was used to create the spreadsheet shown above:
34
+
35
+
36
+ ```C
37
+ #include "xlsxwriter.h"
38
+
39
+ int main() {
40
+
41
+ /* Create a new workbook and add a worksheet. */
42
+ lxw_workbook *workbook = workbook_new("demo.xlsx");
43
+ lxw_worksheet *worksheet = workbook_add_worksheet(workbook, NULL);
44
+
45
+ /* Add a format. */
46
+ lxw_format *format = workbook_add_format(workbook);
47
+
48
+ /* Set the bold property for the format */
49
+ format_set_bold(format);
50
+
51
+ /* Change the column width for clarity. */
52
+ worksheet_set_column(worksheet, 0, 0, 20, NULL);
53
+
54
+ /* Write some simple text. */
55
+ worksheet_write_string(worksheet, 0, 0, "Hello", NULL);
56
+
57
+ /* Text with formatting. */
58
+ worksheet_write_string(worksheet, 1, 0, "World", format);
59
+
60
+ /* Writer some numbers. */
61
+ worksheet_write_number(worksheet, 2, 0, 123, NULL);
62
+ worksheet_write_number(worksheet, 3, 0, 123.456, NULL);
63
+
64
+ /* Insert an image. */
65
+ worksheet_insert_image(worksheet, 1, 2, "logo.png");
66
+
67
+ workbook_close(workbook);
68
+
69
+ return 0;
70
+ }
71
+
72
+ ```
73
+
74
+
75
+
76
+ See the [full documentation](http://libxlsxwriter.github.io) for the getting
77
+ started guide, a tutorial, the main API documentation and examples.
78
+
@@ -0,0 +1,30 @@
1
+ #import <UIKit/UIKit.h>
2
+
3
+ #import "../xlsxwriter.h"
4
+ #import "app.h"
5
+ #import "chart.h"
6
+ #import "common.h"
7
+ #import "content_types.h"
8
+ #import "core.h"
9
+ #import "custom.h"
10
+ #import "drawing.h"
11
+ #import "format.h"
12
+ #import "hash_table.h"
13
+ #import "packager.h"
14
+ #import "relationships.h"
15
+ #import "shared_strings.h"
16
+ #import "styles.h"
17
+ #import "theme.h"
18
+ #import "third_party/ioapi.h"
19
+ #import "third_party/queue.h"
20
+ #import "third_party/tmpfileplus.h"
21
+ #import "third_party/tree.h"
22
+ #import "third_party/zip.h"
23
+ #import "utility.h"
24
+ #import "workbook.h"
25
+ #import "worksheet.h"
26
+ #import "xmlwriter.h"
27
+
28
+ FOUNDATION_EXPORT double xlsxwriterVersionNumber;
29
+ FOUNDATION_EXPORT const unsigned char xlsxwriterVersionString[];
30
+
@@ -0,0 +1,7 @@
1
+ framework module xlsxwriter {
2
+ umbrella header "libxlsxwriter-umbrella.h"
3
+ header "../xlsxwriter.h"
4
+
5
+ export *
6
+ module * { export * }
7
+ }
@@ -0,0 +1,23 @@
1
+ /*
2
+ * libxlsxwriter
3
+ *
4
+ * Copyright 2014-2017, John McNamara, jmcnamara@cpan.org. See LICENSE.txt.
5
+ */
6
+
7
+ /**
8
+ * @file xlsxwriter.h
9
+ *
10
+ * xlsxwriter - A library for creating Excel XLSX files.
11
+ *
12
+ */
13
+ #ifndef __LXW_XLSXWRITER_H__
14
+ #define __LXW_XLSXWRITER_H__
15
+
16
+ #include "xlsxwriter/workbook.h"
17
+ #include "xlsxwriter/worksheet.h"
18
+ #include "xlsxwriter/format.h"
19
+ #include "xlsxwriter/utility.h"
20
+
21
+ #define LXW_VERSION "0.6.9"
22
+
23
+ #endif /* __LXW_XLSXWRITER_H__ */
@@ -0,0 +1,79 @@
1
+ /*
2
+ * libxlsxwriter
3
+ *
4
+ * Copyright 2014-2017, John McNamara, jmcnamara@cpan.org. See LICENSE.txt.
5
+ *
6
+ * app - A libxlsxwriter library for creating Excel XLSX app files.
7
+ *
8
+ */
9
+ #ifndef __LXW_APP_H__
10
+ #define __LXW_APP_H__
11
+
12
+ #include <stdint.h>
13
+ #include <string.h>
14
+ #include "workbook.h"
15
+ #include "common.h"
16
+
17
+ /* Define the queue.h TAILQ structs for the App structs. */
18
+ STAILQ_HEAD(lxw_heading_pairs, lxw_heading_pair);
19
+ STAILQ_HEAD(lxw_part_names, lxw_part_name);
20
+
21
+ typedef struct lxw_heading_pair {
22
+
23
+ char *key;
24
+ char *value;
25
+
26
+ STAILQ_ENTRY (lxw_heading_pair) list_pointers;
27
+
28
+ } lxw_heading_pair;
29
+
30
+ typedef struct lxw_part_name {
31
+
32
+ char *name;
33
+
34
+ STAILQ_ENTRY (lxw_part_name) list_pointers;
35
+
36
+ } lxw_part_name;
37
+
38
+ /* Struct to represent an App object. */
39
+ typedef struct lxw_app {
40
+
41
+ FILE *file;
42
+
43
+ struct lxw_heading_pairs *heading_pairs;
44
+ struct lxw_part_names *part_names;
45
+ lxw_doc_properties *properties;
46
+
47
+ uint32_t num_heading_pairs;
48
+ uint32_t num_part_names;
49
+
50
+ } lxw_app;
51
+
52
+
53
+ /* *INDENT-OFF* */
54
+ #ifdef __cplusplus
55
+ extern "C" {
56
+ #endif
57
+ /* *INDENT-ON* */
58
+
59
+ lxw_app *lxw_app_new();
60
+ void lxw_app_free(lxw_app *app);
61
+ void lxw_app_assemble_xml_file(lxw_app *self);
62
+ void lxw_app_add_part_name(lxw_app *self, const char *name);
63
+ void lxw_app_add_heading_pair(lxw_app *self, const char *key,
64
+ const char *value);
65
+
66
+ /* Declarations required for unit testing. */
67
+ #ifdef TESTING
68
+
69
+ STATIC void _app_xml_declaration(lxw_app *self);
70
+
71
+ #endif /* TESTING */
72
+
73
+ /* *INDENT-OFF* */
74
+ #ifdef __cplusplus
75
+ }
76
+ #endif
77
+ /* *INDENT-ON* */
78
+
79
+ #endif /* __LXW_APP_H__ */