Skip to content

Instantly share code, notes, and snippets.

@ubap
Last active August 23, 2016 14:11
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
Star You must be signed in to star a gist
Save ubap/55d22ef9b2e00347a2dc58ca4cb8b0ea to your computer and use it in GitHub Desktop.
GSoC Writer Table Styles
Jakub Trzebiatowski,
Improving user experience with Table Styles final report
I want to summarize my work that has been done till now.
My project was to improve user experience with table styles.
I was building the table styles functionality on top of current table
autoformat (class SwTableAutoFormat).
I started with implementing TableFamily UNO API (class SwXTextTableStyle). The
UNO API exposes the SwTableAutoFormatTable table as a container.
SwTableAutoFormat as SwXTextTableStyle element.
Inlucde TableStyles in GetStyles test
https://gerrit.libreoffice.org/gitweb?p=core.git;a=commitdiff;h=7eb86f35537aa9fc1b861c8880e474b369870937
Implement basic TableStyle Family
https://gerrit.libreoffice.org/gitweb?p=core.git;a=commitdiff;h=8b8159784821b7ddf031aec925353c274a10875e
Sw UNO API TableStyles getByName
https://gerrit.libreoffice.org/gitweb?p=core.git;a=commitdiff;h=d4188f643db050c962a937547d19a9a08bd2235d
Sw UNO API SwXTextCellStyle; TableStyles createInstance, XNameAccess
https://gerrit.libreoffice.org/gitweb?p=core.git;a=commitdiff;h=be0c898587f9464cd7a11be5e6b1d4e8dbd078d8
fdo47267 fix import crash
https://gerrit.libreoffice.org/gitweb?p=core.git;a=commitdiff;h=efb38949a44dec7e9f5fee7e9ec34164633d926c
fdo47267 odf import unit test
https://gerrit.libreoffice.org/gitweb?p=core.git;a=commitdiff;h=3fd25d2fd8dd29a2c775dee2781591074f1f8f34
GSoC Table Styles, TableStyle isInUse, isUserDefined, mutex fixes
https://gerrit.libreoffice.org/gitweb?p=core.git;a=commitdiff;h=17f440e7e7f1621edebc58f8be5e85b68ee7dcf4
GSoC Table Styles, Add TableStyle properties
https://gerrit.libreoffice.org/gitweb?p=core.git;a=commitdiff;h=98e3e2414b4cf80343af3499414f6a5ef86d7ae8
GSoC Table Style Family: insertByName, replaceByName, removeByName
https://gerrit.libreoffice.org/gitweb?p=core.git;a=commitdiff;h=d945e97d8f85465f04f59fd197ded2edb56caac3
To be able to export table styles the CellFamily had to be implemented also.
sw UNO Cell Style family, SwXTextCellStyle
https://gerrit.libreoffice.org/gitweb?p=core.git;a=commitdiff;h=45a6fdad8101e4ba552ca4d4532d0b03b79dd15a
sw SwXTextCellStyle fix possible nullptr dereference
https://gerrit.libreoffice.org/gitweb?p=core.git;a=commitdiff;h=05cd178535619d7cfecc15c059a92c2006f9282d
GSoC Table Styles, CellStyle
https://gerrit.libreoffice.org/gitweb?p=core.git;a=commitdiff;h=3464befb48ccf1bf9ad4c8f321c7342db43c4019
GSoC Writer Table Styles; Cell Style XPropertyState
https://gerrit.libreoffice.org/gitweb?p=core.git;a=commitdiff;h=0710fcd58d29d7ba98f0305caab79f9b7b1519a2
Also extended the XTextTable, made it possible to set table style via UNO API.
That was required for the import code.
sw UNO API XTextTable add TableTemplateName property
https://gerrit.libreoffice.org/gitweb?p=core.git;a=commitdiff;h=fe10783e4abd5509676c777c7aa6f172ab3a8bf6
Next, when the UNO API was done I started working on the import and export
of table styles. I was looking how the export of table styles works in the
Impress. Table styles are exported as a <table:table-template> element. Export
of cell styles had to be implemented also.
GSoC Table Styles, Export Cell Styles
https://gerrit.libreoffice.org/gitweb?p=core.git;a=commitdiff;h=309bc35559cb823415139044272b10feccdb6ae7
GSoC Writer Table Styles Import
https://gerrit.libreoffice.org/gitweb?p=core.git;a=commitdiff;h=40fba0f4418084d50cc5c388cb0b6e1abe395d61
GSoC Writer Table Styles export of paragraph and char properties
https://gerrit.libreoffice.org/gitweb?p=core.git;a=commitdiff;h=50a6f3d51f32e7176c3b2d036c60bb48d51d6a1a
GSoC Writer Table Styles; Import bugfix
https://gerrit.libreoffice.org/gitweb?p=core.git;a=commitdiff;h=b7138e03ebc8a33258c099c5cf6015970646a40e
Then I started to work on the UI. Started with Table Styles, Styles and
Formatting tab (F11). Undo & Redo had to be implemented too.
GSoC Writer Table Styles; Table Styles Panel
https://gerrit.libreoffice.org/gitweb?p=core.git;a=commitdiff;h=e7ea91f283ce9b96db58087d87d81d29bcb727a4
GSoC Writer Table Styles; Table styles panel; Delete table style
https://gerrit.libreoffice.org/gitweb?p=core.git;a=commitdiff;h=8c80a56ea979eccc39cc748c35e4fd9d33e837dc
GSoC Writer Table Styles; Create by example; fix undo
https://gerrit.libreoffice.org/gitweb?p=core.git;a=commitdiff;h=0943ee2decb8d5a1a2a5bf3b1c233934a89e9c97
GSoC Writer Table Styles; Update by example
https://gerrit.libreoffice.org/gitweb?p=core.git;a=commitdiff;h=592a8657fa6bdc6ed72281d792c19ff0bff31387
What has to be done:
Table style dialog.
Table styles dropdown menu is still under work.
Default set of table styles is not implemented yet.
Newly inserted table should be inserted with default table style.
All commits can be found at
https://github.com/LibreOffice/core/commits?author=ubap
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment