XlsxWriter 3.2.1__tar.gz → 3.2.2__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/Changes +20 -0
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/LICENSE.txt +1 -1
- {XlsxWriter-3.2.1/XlsxWriter.egg-info → xlsxwriter-3.2.2}/PKG-INFO +16 -9
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/README.rst +6 -7
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2/XlsxWriter.egg-info}/PKG-INFO +16 -9
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/XlsxWriter.egg-info/SOURCES.txt +3 -0
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/array_formula.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/autofilter.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/autofit.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/autofit_manually.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/background.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/cell_indentation.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/chart.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/chart_area.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/chart_bar.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/chart_clustered.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/chart_column.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/chart_combined.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/chart_data_labels.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/chart_data_table.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/chart_data_tools.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/chart_date_axis.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/chart_doughnut.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/chart_gauge.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/chart_gradient.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/chart_line.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/chart_pareto.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/chart_pattern.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/chart_pie.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/chart_radar.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/chart_scatter.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/chart_secondary_axis.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/chart_stock.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/chart_styles.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/chartsheet.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/check_close.py +2 -1
- xlsxwriter-3.2.2/examples/checkbox.py +39 -0
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/comments1.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/comments2.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/conditional_format.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/context_manager.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/data_validate.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/datetimes.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/defined_name.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/demo.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/diagonal_border.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/django_simple.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/doc_properties.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/dynamic_arrays.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/embedded_images.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/headers_footers.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/hello_world.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/hide_row_col.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/hide_sheet.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/http_server.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/hyperlink.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/ignore_errors.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/images.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/images_bytesio.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/inheritance1.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/inheritance2.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/lambda.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/macros.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/merge1.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/merge_rich_string.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/outline.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/outline_collapsed.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/pandas_autofilter.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/pandas_chart.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/pandas_chart_columns.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/pandas_chart_line.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/pandas_column_formats.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/pandas_conditional_format.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/pandas_datetime.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/pandas_header_format.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/pandas_multiple.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/pandas_percentage.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/pandas_positioning.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/pandas_simple.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/pandas_table.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/panes.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/polars_chart.py +2 -1
- xlsxwriter-3.2.2/examples/polars_checkbox.py +31 -0
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/polars_conditional_format.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/polars_format_custom.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/polars_format_default.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/polars_multiple.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/polars_positioning.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/polars_simple.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/polars_sparklines.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/polars_xlsxwriter.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/rich_strings.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/right_to_left.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/sensitivity_label.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/sparklines1.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/sparklines2.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/tab_colors.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/tables.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/text_indent.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/textbox.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/tutorial1.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/tutorial2.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/tutorial3.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/unicode.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/unicode_polish_utf8.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/unicode_shift_jis.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/user_types1.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/user_types2.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/user_types3.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/vba_extract.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/watermark.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/worksheet_protection.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/setup.py +1 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/xlsxwriter/__init__.py +3 -2
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/xlsxwriter/app.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/xlsxwriter/chart.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/xlsxwriter/chart_area.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/xlsxwriter/chart_bar.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/xlsxwriter/chart_column.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/xlsxwriter/chart_doughnut.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/xlsxwriter/chart_line.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/xlsxwriter/chart_pie.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/xlsxwriter/chart_radar.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/xlsxwriter/chart_scatter.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/xlsxwriter/chart_stock.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/xlsxwriter/chartsheet.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/xlsxwriter/comments.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/xlsxwriter/contenttypes.py +11 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/xlsxwriter/core.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/xlsxwriter/custom.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/xlsxwriter/drawing.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/xlsxwriter/exceptions.py +2 -1
- xlsxwriter-3.2.2/xlsxwriter/feature_property_bag.py +156 -0
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/xlsxwriter/format.py +22 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/xlsxwriter/metadata.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/xlsxwriter/packager.py +26 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/xlsxwriter/relationships.py +9 -3
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/xlsxwriter/rich_value.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/xlsxwriter/rich_value_rel.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/xlsxwriter/rich_value_structure.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/xlsxwriter/rich_value_types.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/xlsxwriter/shape.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/xlsxwriter/sharedstrings.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/xlsxwriter/styles.py +71 -19
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/xlsxwriter/table.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/xlsxwriter/theme.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/xlsxwriter/utility.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/xlsxwriter/vml.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/xlsxwriter/workbook.py +17 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/xlsxwriter/worksheet.py +46 -7
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/xlsxwriter/xmlwriter.py +2 -1
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/MANIFEST.in +0 -0
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/XlsxWriter.egg-info/dependency_links.txt +0 -0
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/XlsxWriter.egg-info/top_level.txt +0 -0
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/autofilter_data.txt +0 -0
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/unicode_polish_utf8.txt +0 -0
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/unicode_shift_jis.txt +0 -0
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/examples/vbaProject.bin +0 -0
- {XlsxWriter-3.2.1 → xlsxwriter-3.2.2}/setup.cfg +0 -0
|
@@ -1,3 +1,20 @@
|
|
|
1
|
+
Release 3.2.2 - January 28 2025
|
|
2
|
+
-------------------------------
|
|
3
|
+
|
|
4
|
+
* Added support for checkboxes via the :func:`insert_checkbox()` method.
|
|
5
|
+
|
|
6
|
+
Checkboxes are a new feature added to `Excel in 2024`_. They are a way of
|
|
7
|
+
displaying a boolean value as a checkbox in a cell. The underlying value is
|
|
8
|
+
still an Excel ``TRUE/FALSE`` boolean value and can be used in formulas and in
|
|
9
|
+
references.
|
|
10
|
+
|
|
11
|
+
.. image:: _images/checkbox.png
|
|
12
|
+
|
|
13
|
+
See :ref:`ex_checkbox`.
|
|
14
|
+
|
|
15
|
+
.. _Excel in 2024: https://techcommunity.microsoft.com/blog/excelblog/introducing-checkboxes-in-excel/4173561
|
|
16
|
+
|
|
17
|
+
|
|
1
18
|
Release 3.2.1 - January 22 2025
|
|
2
19
|
--------------------------------
|
|
3
20
|
|
|
@@ -34,6 +51,9 @@ everyone who has contributed code, given feedback or just used the library.
|
|
|
34
51
|
This has been a frequently requested feature for people creating spreadsheets
|
|
35
52
|
with images for product items. See also :ref:`ex_embedded_images`.
|
|
36
53
|
|
|
54
|
+
.. image:: _images/embedded_images.png
|
|
55
|
+
|
|
56
|
+
|
|
37
57
|
* Fix issue where a horizontal alignment format was ignored if indentation was
|
|
38
58
|
also set.
|
|
39
59
|
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
Metadata-Version: 2.
|
|
1
|
+
Metadata-Version: 2.2
|
|
2
2
|
Name: XlsxWriter
|
|
3
|
-
Version: 3.2.
|
|
3
|
+
Version: 3.2.2
|
|
4
4
|
Summary: A Python module for creating Excel XLSX files.
|
|
5
5
|
Home-page: https://github.com/jmcnamara/XlsxWriter
|
|
6
6
|
Author: John McNamara
|
|
@@ -21,6 +21,14 @@ Classifier: Programming Language :: Python :: 3.12
|
|
|
21
21
|
Classifier: Programming Language :: Python :: 3.13
|
|
22
22
|
Requires-Python: >=3.6
|
|
23
23
|
License-File: LICENSE.txt
|
|
24
|
+
Dynamic: author
|
|
25
|
+
Dynamic: author-email
|
|
26
|
+
Dynamic: classifier
|
|
27
|
+
Dynamic: description
|
|
28
|
+
Dynamic: home-page
|
|
29
|
+
Dynamic: license
|
|
30
|
+
Dynamic: requires-python
|
|
31
|
+
Dynamic: summary
|
|
24
32
|
|
|
25
33
|
XlsxWriter
|
|
26
34
|
==========
|
|
@@ -56,29 +64,28 @@ Here is a simple example:
|
|
|
56
64
|
|
|
57
65
|
import xlsxwriter
|
|
58
66
|
|
|
59
|
-
|
|
60
67
|
# Create an new Excel file and add a worksheet.
|
|
61
|
-
workbook = xlsxwriter.Workbook(
|
|
68
|
+
workbook = xlsxwriter.Workbook("demo.xlsx")
|
|
62
69
|
worksheet = workbook.add_worksheet()
|
|
63
70
|
|
|
64
71
|
# Widen the first column to make the text clearer.
|
|
65
|
-
worksheet.set_column(
|
|
72
|
+
worksheet.set_column("A:A", 20)
|
|
66
73
|
|
|
67
74
|
# Add a bold format to use to highlight cells.
|
|
68
|
-
bold = workbook.add_format({
|
|
75
|
+
bold = workbook.add_format({"bold": True})
|
|
69
76
|
|
|
70
77
|
# Write some simple text.
|
|
71
|
-
worksheet.write(
|
|
78
|
+
worksheet.write("A1", "Hello")
|
|
72
79
|
|
|
73
80
|
# Text with formatting.
|
|
74
|
-
worksheet.write(
|
|
81
|
+
worksheet.write("A2", "World", bold)
|
|
75
82
|
|
|
76
83
|
# Write some numbers, with row/column notation.
|
|
77
84
|
worksheet.write(2, 0, 123)
|
|
78
85
|
worksheet.write(3, 0, 123.456)
|
|
79
86
|
|
|
80
87
|
# Insert an image.
|
|
81
|
-
worksheet.insert_image(
|
|
88
|
+
worksheet.insert_image("B5", "logo.png")
|
|
82
89
|
|
|
83
90
|
workbook.close()
|
|
84
91
|
|
|
@@ -32,29 +32,28 @@ Here is a simple example:
|
|
|
32
32
|
|
|
33
33
|
import xlsxwriter
|
|
34
34
|
|
|
35
|
-
|
|
36
35
|
# Create an new Excel file and add a worksheet.
|
|
37
|
-
workbook = xlsxwriter.Workbook(
|
|
36
|
+
workbook = xlsxwriter.Workbook("demo.xlsx")
|
|
38
37
|
worksheet = workbook.add_worksheet()
|
|
39
38
|
|
|
40
39
|
# Widen the first column to make the text clearer.
|
|
41
|
-
worksheet.set_column(
|
|
40
|
+
worksheet.set_column("A:A", 20)
|
|
42
41
|
|
|
43
42
|
# Add a bold format to use to highlight cells.
|
|
44
|
-
bold = workbook.add_format({
|
|
43
|
+
bold = workbook.add_format({"bold": True})
|
|
45
44
|
|
|
46
45
|
# Write some simple text.
|
|
47
|
-
worksheet.write(
|
|
46
|
+
worksheet.write("A1", "Hello")
|
|
48
47
|
|
|
49
48
|
# Text with formatting.
|
|
50
|
-
worksheet.write(
|
|
49
|
+
worksheet.write("A2", "World", bold)
|
|
51
50
|
|
|
52
51
|
# Write some numbers, with row/column notation.
|
|
53
52
|
worksheet.write(2, 0, 123)
|
|
54
53
|
worksheet.write(3, 0, 123.456)
|
|
55
54
|
|
|
56
55
|
# Insert an image.
|
|
57
|
-
worksheet.insert_image(
|
|
56
|
+
worksheet.insert_image("B5", "logo.png")
|
|
58
57
|
|
|
59
58
|
workbook.close()
|
|
60
59
|
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
Metadata-Version: 2.
|
|
1
|
+
Metadata-Version: 2.2
|
|
2
2
|
Name: XlsxWriter
|
|
3
|
-
Version: 3.2.
|
|
3
|
+
Version: 3.2.2
|
|
4
4
|
Summary: A Python module for creating Excel XLSX files.
|
|
5
5
|
Home-page: https://github.com/jmcnamara/XlsxWriter
|
|
6
6
|
Author: John McNamara
|
|
@@ -21,6 +21,14 @@ Classifier: Programming Language :: Python :: 3.12
|
|
|
21
21
|
Classifier: Programming Language :: Python :: 3.13
|
|
22
22
|
Requires-Python: >=3.6
|
|
23
23
|
License-File: LICENSE.txt
|
|
24
|
+
Dynamic: author
|
|
25
|
+
Dynamic: author-email
|
|
26
|
+
Dynamic: classifier
|
|
27
|
+
Dynamic: description
|
|
28
|
+
Dynamic: home-page
|
|
29
|
+
Dynamic: license
|
|
30
|
+
Dynamic: requires-python
|
|
31
|
+
Dynamic: summary
|
|
24
32
|
|
|
25
33
|
XlsxWriter
|
|
26
34
|
==========
|
|
@@ -56,29 +64,28 @@ Here is a simple example:
|
|
|
56
64
|
|
|
57
65
|
import xlsxwriter
|
|
58
66
|
|
|
59
|
-
|
|
60
67
|
# Create an new Excel file and add a worksheet.
|
|
61
|
-
workbook = xlsxwriter.Workbook(
|
|
68
|
+
workbook = xlsxwriter.Workbook("demo.xlsx")
|
|
62
69
|
worksheet = workbook.add_worksheet()
|
|
63
70
|
|
|
64
71
|
# Widen the first column to make the text clearer.
|
|
65
|
-
worksheet.set_column(
|
|
72
|
+
worksheet.set_column("A:A", 20)
|
|
66
73
|
|
|
67
74
|
# Add a bold format to use to highlight cells.
|
|
68
|
-
bold = workbook.add_format({
|
|
75
|
+
bold = workbook.add_format({"bold": True})
|
|
69
76
|
|
|
70
77
|
# Write some simple text.
|
|
71
|
-
worksheet.write(
|
|
78
|
+
worksheet.write("A1", "Hello")
|
|
72
79
|
|
|
73
80
|
# Text with formatting.
|
|
74
|
-
worksheet.write(
|
|
81
|
+
worksheet.write("A2", "World", bold)
|
|
75
82
|
|
|
76
83
|
# Write some numbers, with row/column notation.
|
|
77
84
|
worksheet.write(2, 0, 123)
|
|
78
85
|
worksheet.write(3, 0, 123.456)
|
|
79
86
|
|
|
80
87
|
# Insert an image.
|
|
81
|
-
worksheet.insert_image(
|
|
88
|
+
worksheet.insert_image("B5", "logo.png")
|
|
82
89
|
|
|
83
90
|
workbook.close()
|
|
84
91
|
|
|
@@ -39,6 +39,7 @@ examples/chart_stock.py
|
|
|
39
39
|
examples/chart_styles.py
|
|
40
40
|
examples/chartsheet.py
|
|
41
41
|
examples/check_close.py
|
|
42
|
+
examples/checkbox.py
|
|
42
43
|
examples/comments1.py
|
|
43
44
|
examples/comments2.py
|
|
44
45
|
examples/conditional_format.py
|
|
@@ -84,6 +85,7 @@ examples/pandas_simple.py
|
|
|
84
85
|
examples/pandas_table.py
|
|
85
86
|
examples/panes.py
|
|
86
87
|
examples/polars_chart.py
|
|
88
|
+
examples/polars_checkbox.py
|
|
87
89
|
examples/polars_conditional_format.py
|
|
88
90
|
examples/polars_format_custom.py
|
|
89
91
|
examples/polars_format_default.py
|
|
@@ -135,6 +137,7 @@ xlsxwriter/core.py
|
|
|
135
137
|
xlsxwriter/custom.py
|
|
136
138
|
xlsxwriter/drawing.py
|
|
137
139
|
xlsxwriter/exceptions.py
|
|
140
|
+
xlsxwriter/feature_property_bag.py
|
|
138
141
|
xlsxwriter/format.py
|
|
139
142
|
xlsxwriter/metadata.py
|
|
140
143
|
xlsxwriter/packager.py
|
|
@@ -7,7 +7,8 @@
|
|
|
7
7
|
# simple criteria so that some data is shown and some is hidden.
|
|
8
8
|
#
|
|
9
9
|
# SPDX-License-Identifier: BSD-2-Clause
|
|
10
|
-
#
|
|
10
|
+
#
|
|
11
|
+
# Copyright (c) 2013-2025, John McNamara, jmcnamara@cpan.org
|
|
11
12
|
#
|
|
12
13
|
import xlsxwriter
|
|
13
14
|
|
|
@@ -4,7 +4,8 @@
|
|
|
4
4
|
# worksheet columns based on the data in the cells.
|
|
5
5
|
#
|
|
6
6
|
# SPDX-License-Identifier: BSD-2-Clause
|
|
7
|
-
#
|
|
7
|
+
#
|
|
8
|
+
# Copyright (c) 2013-2025, John McNamara, jmcnamara@cpan.org
|
|
8
9
|
#
|
|
9
10
|
from xlsxwriter.workbook import Workbook
|
|
10
11
|
|
|
@@ -3,7 +3,8 @@
|
|
|
3
3
|
# An example of creating Excel Area charts with Python and XlsxWriter.
|
|
4
4
|
#
|
|
5
5
|
# SPDX-License-Identifier: BSD-2-Clause
|
|
6
|
-
#
|
|
6
|
+
#
|
|
7
|
+
# Copyright (c) 2013-2025, John McNamara, jmcnamara@cpan.org
|
|
7
8
|
#
|
|
8
9
|
import xlsxwriter
|
|
9
10
|
|
|
@@ -3,7 +3,8 @@
|
|
|
3
3
|
# An example of creating Excel Bar charts with Python and XlsxWriter.
|
|
4
4
|
#
|
|
5
5
|
# SPDX-License-Identifier: BSD-2-Clause
|
|
6
|
-
#
|
|
6
|
+
#
|
|
7
|
+
# Copyright (c) 2013-2025, John McNamara, jmcnamara@cpan.org
|
|
7
8
|
#
|
|
8
9
|
import xlsxwriter
|
|
9
10
|
|
|
@@ -3,7 +3,8 @@
|
|
|
3
3
|
# A demo of a clustered category chart in XlsxWriter.
|
|
4
4
|
#
|
|
5
5
|
# SPDX-License-Identifier: BSD-2-Clause
|
|
6
|
-
#
|
|
6
|
+
#
|
|
7
|
+
# Copyright (c) 2013-2025, John McNamara, jmcnamara@cpan.org
|
|
7
8
|
#
|
|
8
9
|
from xlsxwriter.workbook import Workbook
|
|
9
10
|
|
|
@@ -3,7 +3,8 @@
|
|
|
3
3
|
# An example of creating Excel Column charts with Python and XlsxWriter.
|
|
4
4
|
#
|
|
5
5
|
# SPDX-License-Identifier: BSD-2-Clause
|
|
6
|
-
#
|
|
6
|
+
#
|
|
7
|
+
# Copyright (c) 2013-2025, John McNamara, jmcnamara@cpan.org
|
|
7
8
|
#
|
|
8
9
|
import xlsxwriter
|
|
9
10
|
|
|
@@ -3,7 +3,8 @@
|
|
|
3
3
|
# An example of a Combined chart in XlsxWriter.
|
|
4
4
|
#
|
|
5
5
|
# SPDX-License-Identifier: BSD-2-Clause
|
|
6
|
-
#
|
|
6
|
+
#
|
|
7
|
+
# Copyright (c) 2013-2025, John McNamara, jmcnamara@cpan.org
|
|
7
8
|
#
|
|
8
9
|
from xlsxwriter.workbook import Workbook
|
|
9
10
|
|
|
@@ -8,7 +8,8 @@
|
|
|
8
8
|
# a Gauge Chart in Excel: https://www.excel-easy.com/examples/gauge-chart.html
|
|
9
9
|
#
|
|
10
10
|
# SPDX-License-Identifier: BSD-2-Clause
|
|
11
|
-
#
|
|
11
|
+
#
|
|
12
|
+
# Copyright (c) 2013-2025, John McNamara, jmcnamara@cpan.org
|
|
12
13
|
#
|
|
13
14
|
import xlsxwriter
|
|
14
15
|
|
|
@@ -3,7 +3,8 @@
|
|
|
3
3
|
# An example of creating Excel Line charts with Python and XlsxWriter.
|
|
4
4
|
#
|
|
5
5
|
# SPDX-License-Identifier: BSD-2-Clause
|
|
6
|
-
#
|
|
6
|
+
#
|
|
7
|
+
# Copyright (c) 2013-2025, John McNamara, jmcnamara@cpan.org
|
|
7
8
|
#
|
|
8
9
|
import xlsxwriter
|
|
9
10
|
|
|
@@ -3,7 +3,8 @@
|
|
|
3
3
|
# An example of creating of a Pareto chart with Python and XlsxWriter.
|
|
4
4
|
#
|
|
5
5
|
# SPDX-License-Identifier: BSD-2-Clause
|
|
6
|
-
#
|
|
6
|
+
#
|
|
7
|
+
# Copyright (c) 2013-2025, John McNamara, jmcnamara@cpan.org
|
|
7
8
|
#
|
|
8
9
|
import xlsxwriter
|
|
9
10
|
|
|
@@ -3,7 +3,8 @@
|
|
|
3
3
|
# An example of an Excel chart with patterns using Python and XlsxWriter.
|
|
4
4
|
#
|
|
5
5
|
# SPDX-License-Identifier: BSD-2-Clause
|
|
6
|
-
#
|
|
6
|
+
#
|
|
7
|
+
# Copyright (c) 2013-2025, John McNamara, jmcnamara@cpan.org
|
|
7
8
|
#
|
|
8
9
|
import xlsxwriter
|
|
9
10
|
|
|
@@ -3,7 +3,8 @@
|
|
|
3
3
|
# An example of creating Excel Radar charts with Python and XlsxWriter.
|
|
4
4
|
#
|
|
5
5
|
# SPDX-License-Identifier: BSD-2-Clause
|
|
6
|
-
#
|
|
6
|
+
#
|
|
7
|
+
# Copyright (c) 2013-2025, John McNamara, jmcnamara@cpan.org
|
|
7
8
|
#
|
|
8
9
|
import xlsxwriter
|
|
9
10
|
|
|
@@ -3,7 +3,8 @@
|
|
|
3
3
|
# An example of creating Excel Scatter charts with Python and XlsxWriter.
|
|
4
4
|
#
|
|
5
5
|
# SPDX-License-Identifier: BSD-2-Clause
|
|
6
|
-
#
|
|
6
|
+
#
|
|
7
|
+
# Copyright (c) 2013-2025, John McNamara, jmcnamara@cpan.org
|
|
7
8
|
#
|
|
8
9
|
import xlsxwriter
|
|
9
10
|
|
|
@@ -3,7 +3,8 @@
|
|
|
3
3
|
# An example of creating Excel Stock charts with Python and XlsxWriter.
|
|
4
4
|
#
|
|
5
5
|
# SPDX-License-Identifier: BSD-2-Clause
|
|
6
|
-
#
|
|
6
|
+
#
|
|
7
|
+
# Copyright (c) 2013-2025, John McNamara, jmcnamara@cpan.org
|
|
7
8
|
#
|
|
8
9
|
from datetime import datetime
|
|
9
10
|
|
|
@@ -3,7 +3,8 @@
|
|
|
3
3
|
# A simple program demonstrating a check for exceptions when closing the file.
|
|
4
4
|
#
|
|
5
5
|
# SPDX-License-Identifier: BSD-2-Clause
|
|
6
|
-
#
|
|
6
|
+
#
|
|
7
|
+
# Copyright (c) 2013-2025, John McNamara, jmcnamara@cpan.org
|
|
7
8
|
#
|
|
8
9
|
import xlsxwriter
|
|
9
10
|
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
##############################################################################
|
|
2
|
+
#
|
|
3
|
+
# An example of adding checkbox boolean values to a worksheet using the the
|
|
4
|
+
# XlsxWriter Python module.
|
|
5
|
+
#
|
|
6
|
+
# SPDX-License-Identifier: BSD-2-Clause
|
|
7
|
+
#
|
|
8
|
+
# Copyright (c) 2013-2025, John McNamara, jmcnamara@cpan.org
|
|
9
|
+
#
|
|
10
|
+
import xlsxwriter
|
|
11
|
+
|
|
12
|
+
# Create a new Excel file object.
|
|
13
|
+
workbook = xlsxwriter.Workbook("checkbox.xlsx")
|
|
14
|
+
|
|
15
|
+
# Add a worksheet to the workbook.
|
|
16
|
+
worksheet = workbook.add_worksheet()
|
|
17
|
+
|
|
18
|
+
# Create some formats to use in the worksheet.
|
|
19
|
+
bold = workbook.add_format({"bold": True})
|
|
20
|
+
light_red = workbook.add_format({"bg_color": "#FFC7CE"})
|
|
21
|
+
light_green = workbook.add_format({"bg_color": "#C6EFCE"})
|
|
22
|
+
|
|
23
|
+
# Set the column width for clarity.
|
|
24
|
+
worksheet.set_column(0, 0, 30)
|
|
25
|
+
|
|
26
|
+
# Write some descriptions.
|
|
27
|
+
worksheet.write(1, 0, "Some simple checkboxes:", bold)
|
|
28
|
+
worksheet.write(4, 0, "Some checkboxes with cell formats:", bold)
|
|
29
|
+
|
|
30
|
+
# Insert some boolean checkboxes to the worksheet.
|
|
31
|
+
worksheet.insert_checkbox(1, 1, False)
|
|
32
|
+
worksheet.insert_checkbox(2, 1, True)
|
|
33
|
+
|
|
34
|
+
# Insert some checkboxes with cell formats.
|
|
35
|
+
worksheet.insert_checkbox(4, 1, False, light_red)
|
|
36
|
+
worksheet.insert_checkbox(5, 1, True, light_green)
|
|
37
|
+
|
|
38
|
+
# Close the workbook.
|
|
39
|
+
workbook.close()
|
|
@@ -6,7 +6,8 @@
|
|
|
6
6
|
# Each of the worksheets demonstrates different features of cell comments.
|
|
7
7
|
#
|
|
8
8
|
# SPDX-License-Identifier: BSD-2-Clause
|
|
9
|
-
#
|
|
9
|
+
#
|
|
10
|
+
# Copyright (c) 2013-2025, John McNamara, jmcnamara@cpan.org
|
|
10
11
|
#
|
|
11
12
|
import xlsxwriter
|
|
12
13
|
|