Created attachment 95202 [details] Example Open and save the attached document. It will have about 200 unused automatic styles. Unused automatic styles must be cleaned automatically.
So you want the styles to just disappear for individual documents? The default styles that come with LibreOffice. If so I disagree with the request and will seek additional input from devs
Automatic styles are not default. Don't write nonsensical comments, please.
Urmas - don't be rude please. Again, warned.
That is not 'enhancement'. That is a bug.
I can confirm this on LibreOffice 4.2.6.3 build id 3fd416d4c6db7d3204c17ce57a1d70f6e531ee21 running on Windows Vista 64 bits. I suspected this long ago, LibreOffice just keeps adding automatic styles to the document, so if we create a new one from an older document, it will inherit the automatic styles and the document will be bigger and slower to parse. It is a bug, not a enhancement, as there are people (myself included) which don't use official templates for creating documents - the template is the last document of the same type used. Lawyers do that when writing petitions of the same kind (the facts are changed, but the law it's based remains the same), judges also do that (the suit report and the judgement is changed, but the law it's based remains the same). It also happens because, in Brazil, the petitions don't have a defined form factor, one can use different fonts to make a better emphasis, many times just a word or two of the sentence (which already had emphasis) gets another emphasis by changing the body font (bold, italics, both - I do that), the size (from 12pt to 16pt - I see others doing that), another font entirely or even the color (from black to red, or orange - God forbid people from using blinking letters! On a petition! LOL). It happens a lot when doing evictions, when the consumer doesn't receive what s/he bought etc. Also people who do write reports do that when changing a little bit of the style to make the document feel nicer etc, sometimes it's not the style. Yes, I know we may change the default styles or even create new ones, but it's just not possible to always do that because it's a slow process and we need to be fast when writing, so we just use the formatting tools when is a little bit change that won't be used again on the document. At my office, we use the Flat OpenDocument format (.fodt) (better for backing up, it is much more compressible than the zipped .odt type), but now I see documents with almost 300Kb that, opened using Notepad++, when the contents of the "<office:automatic-styles>" node is erased (not the node itself) and saved as another name, the size gets back to less than 90Kb and the document is still normally editable without errors. So the only conclusion is LibreOffice isn't cleaning up its automatic styles, which is a kind of memory leak. Worse still, a persistent one. PS: May I change this bug status as confirmed? I am doing that right after saving this comment.
Just to clarify to Joel Madero: * Default Styles are those which already comes with LibreOffice; * Automatic Styles are those created by LibreOffice automatically every time the user changes the formatting without using styles. LO does that because the OpenDocument Format specs don't allow to use direct formatting, the software has to create the illusion of direct formatting creating automatically (and hidden) styles every time the user apply direct formatting on the document content.
To clarify even more: http://ask.libreoffice.org/en/question/32602/difference-between-styles-and-automatic-styles/
Bug is confirmed and status is NEW -> Removing needAdvice tag.
** Please read this message in its entirety before responding ** To make sure we're focusing on the bugs that affect our users today, LibreOffice QA is asking bug reporters and confirmers to retest open, confirmed bugs which have not been touched for over a year. There have been thousands of bug fixes and commits since anyone checked on this bug report. During that time, it's possible that the bug has been fixed, or the details of the problem have changed. We'd really appreciate your help in getting confirmation that the bug is still present. If you have time, please do the following: Test to see if the bug is still present on a currently supported version of LibreOffice (5.0.1 or preferably 5.0.2.2 or later) https://www.libreoffice.org/download/ If the bug is present, please leave a comment that includes the version of LibreOffice and your operating system, and any changes you see in the bug behavior If the bug is NOT present, please set the bug's Status field to RESOLVED-WORKSFORME and leave a short comment that includes your version of LibreOffice and Operating System Please DO NOT Update the version field Reply via email (please reply directly on the bug tracker) Set the bug's Status field to RESOLVED - FIXED (this status has a particular meaning that is not appropriate in this case) If you want to do more to help you can test to see if your issue is a REGRESSION. To do so: 1. Download and install oldest version of LibreOffice (usually 3.3 unless your bug pertains to a feature added after 3.3) http://downloadarchive.documentfoundation.org/libreoffice/old/ 2. Test your bug 3. Leave a comment with your results. 4a. If the bug was present with 3.3 - set version to "inherited from OOo"; 4b. If the bug was not present in 3.3 - add "regression" to keyword Feel free to come ask questions or to say hello in our QA chat: http://webchat.freenode.net/?channels=libreoffice-qa Thank you for your help! -- The LibreOffice QA Team This NEW Message was generated on: 2015-10-14
** Please read this message in its entirety before responding ** To make sure we're focusing on the bugs that affect our users today, LibreOffice QA is asking bug reporters and confirmers to retest open, confirmed bugs which have not been touched for over a year. There have been thousands of bug fixes and commits since anyone checked on this bug report. During that time, it's possible that the bug has been fixed, or the details of the problem have changed. We'd really appreciate your help in getting confirmation that the bug is still present. If you have time, please do the following: Test to see if the bug is still present on a currently supported version of LibreOffice (5.1.6 or 5.2.3 https://www.libreoffice.org/download/ If the bug is present, please leave a comment that includes the version of LibreOffice and your operating system, and any changes you see in the bug behavior If the bug is NOT present, please set the bug's Status field to RESOLVED-WORKSFORME and leave a short comment that includes your version of LibreOffice and Operating System Please DO NOT Update the version field Reply via email (please reply directly on the bug tracker) Set the bug's Status field to RESOLVED - FIXED (this status has a particular meaning that is not appropriate in this case) If you want to do more to help you can test to see if your issue is a REGRESSION. To do so: 1. Download and install oldest version of LibreOffice (usually 3.3 unless your bug pertains to a feature added after 3.3) http://downloadarchive.documentfoundation.org/libreoffice/old/ 2. Test your bug 3. Leave a comment with your results. 4a. If the bug was present with 3.3 - set version to "inherited from OOo"; 4b. If the bug was not present in 3.3 - add "regression" to keyword Feel free to come ask questions or to say hello in our QA chat: http://webchat.freenode.net/?channels=libreoffice-qa Thank you for helping us make LibreOffice even better for everyone! Warm Regards, QA Team MassPing-UntouchedBug-20161108
Regina, please look at this bug. Are we sure it's a bug?
The "automatic" styles belong to direct formatting. It is not a file format error to keep them, it is allowed. But I dislike it too. Such styles should only be there, if there are objects which use them. If you save the example file in odt-format and then open and re-save it with Word 365, it shrinks from 13KB to 7KB, because Word does not save these useless styles. I consider it a bug.
I confirm this behavior / bug is still present on: Version: 7.4.0.3 (x64) / LibreOffice Community Build ID: f85e47c08ddd19c015c0114a68350214f7066f5a CPU threads: 8; OS: Windows 10.0 Build 19045; UI render: Skia/Raster; VCL: win Locale: pt-BR (pt_BR); UI: pt-BR Calc: threaded
I confirm this behavior / bug is still present on: Version: 24.2.0.3 (X86_64) / LibreOffice Community Build ID: 420(Build:3) CPU threads: 16; OS: Linux 6.6; UI render: default; VCL: gtk3 Locale: fr-FR (fr_FR.UTF-8); UI: fr-FR Debian package version: 4:24.2.0-1 Calc: threaded
This bug seems to have been fixed. The OP's file has shrunk from 102945 bytes to 43859. Used version: Version: 24.8.2.1 (X86_64) / LibreOffice Community Build ID: 480(Build:1) CPU threads: 16; OS: Linux 6.10; UI render: default; VCL: gtk3 Locale: en-US (C); UI: en-US Debian package version: 4:24.8.2-1 Calc: threaded
I viewed the contents of the OP's file to verify the <automatic-styles> node before and after saving with LibreOffice, and the document was cleaned. So I can confirm Rémi Hérilier report and I am marking this bug as fixed. Version: 24.8.2.1 (X86_64) / LibreOffice Community Build ID: 0f794b6e29741098670a3b95d60478a65d05ef13 CPU threads: 8; OS: Windows 11 X86_64 (10.0 build 22631); UI render: Skia/Raster; VCL: win Locale: pt-BR (pt_BR); UI: pt-BR Calc: threaded