Added the &K option page_setup.rst #1067
Open
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Added the &K option to give colors to the text in header&footer
Pull Requests and Contributing to XlsxWriter
Ad a Missing option in documentation.
And I'm missing a easy way to report that.
All patches and pull requests are welcome but must start with an issue tracker.
Getting Started
make test
.Writing Tests
This is the most important step. XlsxWriter has over 1000 tests and a 2:1 test to code ratio. Patches and pull requests for anything other than minor fixes or typos will not be merged without tests.
Use the existing tests in
XlsxWriter/xlsxwriter/test/
as examples.Ideally, new features should be accompanied by tests that compare XlsxWriter output against actual Excel 2007 files. See the
XlsxWriter/xlsxwriter/test/comparison
test files for examples. If you don't have access to Excel 2007 I can help you create input files for test cases.Tests should use the standard unittest Python module.
Code Style
Follow the general style of the surrounding code and format it to the PEP8 coding standards.
Tests should conform to
PEP8
but can ignoreE501
for long lines to allow the inclusion of Excel XML in tests.There is a make target that will verify the source and test files using flake8:
Running tests
As a minimum, tests should be run using Python 3.6+.
I use pythonbrew and Tox to test with a variety of Python versions. See the Makefile for example test targets. A
tox.ini
file is already configured.When you push your changes they will also be tested using GitHub Actions.
Documentation
If your feature requires it then write some RST documentation in Sphinx format or add to the existing documentation.
The docs, in
dev/docs/source
can be built in Html format using:Example programs
If applicable add an example program to the
examples
directory.Copyright and License
Copyright remains with the original author. Do not include additional copyright claims or Licensing requirements. GitHub and the
git
repository will record your contribution an it will be acknowledged in the Changes file.Submitting the Pull Request
If your change involves several incremental
git
commits thenrebase
orsquash
them onto another branch so that the Pull Request is a single commit or a small number of logical commits.Push your changes to GitHub and submit the Pull Request with a hash link to the to the Issue tracker that was opened above.