onetable
===============
Once defined, multiple ways to export table.
Install
===============
```
pip install onetable
```
Useage
===============
```python
from onetable import DefualtTable, HtmlRender, XlsRender, XlsxRender, PdfRender, CSVRender
table = DefualtTable({'fontSize': 10, 'color': 'red'})
table.setStyles(
('x', {'fontSize': 14}),
('red', {'color': 'red'}),
('title', {'color': 'black', 'font': u'宋体', 'fontSize': 16, 'align': 'center'})
)
table.writeNextRowCols([('Title1', 3, 'title')])
table.pushStatus()
table.popStatus()
table.writeNextRowCols([1, 2, 3])
table.writeNextRowCols([3, 2, 1, 1], style='red')
with open('test.xls', 'wb') as out:
XlsRender().save(tab=table, out=out)
```
CHANGES
===============
0.0.1
- first version
0.0.2
- add usage
0.0.5
- add background for xlsx
Raw data
{
"_id": null,
"home_page": "https://github.com/sintrb/onetable/",
"name": "onetable",
"maintainer": null,
"docs_url": null,
"requires_python": null,
"maintainer_email": null,
"keywords": "onetable, excel, csv, table, export",
"author": "trb",
"author_email": "sintrb@gmail.com",
"download_url": "https://files.pythonhosted.org/packages/05/d8/fc9e670c7bcc6aece43b7f9b61d619381ec7dff4b1f4ea330ae5392d96cf/onetable-0.0.5.tar.gz",
"platform": null,
"description": "onetable\n===============\nOnce defined, multiple ways to export table.\n\nInstall\n===============\n```\n pip install onetable\n```\n\nUseage\n===============\n```python\nfrom onetable import DefualtTable, HtmlRender, XlsRender, XlsxRender, PdfRender, CSVRender\n\ntable = DefualtTable({'fontSize': 10, 'color': 'red'})\ntable.setStyles(\n ('x', {'fontSize': 14}),\n ('red', {'color': 'red'}),\n ('title', {'color': 'black', 'font': u'\u5b8b\u4f53', 'fontSize': 16, 'align': 'center'})\n)\ntable.writeNextRowCols([('Title1', 3, 'title')])\ntable.pushStatus()\ntable.popStatus()\ntable.writeNextRowCols([1, 2, 3])\ntable.writeNextRowCols([3, 2, 1, 1], style='red')\nwith open('test.xls', 'wb') as out:\n XlsRender().save(tab=table, out=out)\n```\n\n\n\nCHANGES\n===============\n0.0.1\n\n- first version\n\n0.0.2\n\n- add usage\n\n0.0.5\n\n- add background for xlsx",
"bugtrack_url": null,
"license": null,
"summary": "Once defined, multiple ways to export table.",
"version": "0.0.5",
"project_urls": {
"Homepage": "https://github.com/sintrb/onetable/"
},
"split_keywords": [
"onetable",
" excel",
" csv",
" table",
" export"
],
"urls": [
{
"comment_text": "",
"digests": {
"blake2b_256": "05d8fc9e670c7bcc6aece43b7f9b61d619381ec7dff4b1f4ea330ae5392d96cf",
"md5": "e4e8c9643bd0b42befe47822b2c546fc",
"sha256": "b979cd0a6e982945ff9ae8c9af6a2f0adceff920a8e8da7802686680e87e8a14"
},
"downloads": -1,
"filename": "onetable-0.0.5.tar.gz",
"has_sig": false,
"md5_digest": "e4e8c9643bd0b42befe47822b2c546fc",
"packagetype": "sdist",
"python_version": "source",
"requires_python": null,
"size": 7919,
"upload_time": "2024-04-23T02:28:59",
"upload_time_iso_8601": "2024-04-23T02:28:59.784167Z",
"url": "https://files.pythonhosted.org/packages/05/d8/fc9e670c7bcc6aece43b7f9b61d619381ec7dff4b1f4ea330ae5392d96cf/onetable-0.0.5.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2024-04-23 02:28:59",
"github": true,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"github_user": "sintrb",
"github_project": "onetable",
"travis_ci": false,
"coveralls": false,
"github_actions": false,
"lcname": "onetable"
}