Apache OpenOffice (AOO) Bugzilla – Issue 64014
proposal to use external style sheets for Writer documents
Last modified: 2013-02-07 22:34:12 UTC
I would like propose the possibility to use external style sheets for Writer documents (much like the use of external style sheets for web sites). Now, one chooses a template when creating documents, and changes made to formatting styles inside the document are local. By keeping the style sheet external to the writer document, it will be much more easier to maintain a number of documents (and a master document) using the same formatting. F.i., if one is to write a book, it is very likely that each and every chapter is written in a seperate Write document and the book is combined in a master document. A template will be created which will contain the base formatting styles used for each chapter and used for the master document. If, however, a new style needs te be added, or an existing style needs to be changed (which will happen for sure), all other chapters and the master document must reload the styles (if one is to maintain the same look and feel for all chapters during the writing process - f.i. changing the page header and footer height to present an example). I propose the use of an external style sheet, where the changes of one style in one document is automatically carried over into any other document using the same external style sheet.
Reassigned to requirements.
I would like to commend this idea very much, but I wonder at the wisdom of attributing it to the Writer element. Surely it should be a framework item, so that this functionallity applies to all the application elements? It equally valid for presentations and spreadsheets, and probably for Draw.
Why is a master document not enough? Styles defined in the master document will always overrule the styles of the individual documents, so you can think of the master document to be the external stylesheet. If you add a style, you can always import that style into other documents. If you base your documents on templates, and you change that template, you're asked whether you'd like to update your document to the changed template. So why is this not enough?
I am using 2.0.2, and have never seen the question to update my chapters with the changed styles in the changed template (maybe I am doing something wrong). When I now add a new style to a chapter (or to the master document), I need to manually copy it into the template using the templates - orginize menu option. If I decide to change an existing style I too, need to copy this to the template. This could be an automatic process, if external style sheets are used. After all, this is what we do with web sites. Why not do the same with documents ?
> I am using 2.0.2, and have never seen the question to update my chapters with > the changed styles in the changed template (maybe I am doing something wrong). There's a bug that prevents that function. (see issue 63320 for details and a macro that fixes your document, so that it will update) And as to adding styles: Yes, either modify the template or modify the document and then import the new/modified styles back to the template. Honestly I see no other way to do that. You definietely don't want to update every template just because you modified a style in a derived document. And the use for an automatic update (vs the manual one) is rather limited, thus why should anyone invest time in adding that feature?
>Honestly I see no other way to do that. You definietely don't want to update every template just because you modified a style in a derived document. And the use for an automatic update (vs the manual one) is rather limited, thus why should anyone invest time in adding that feature?< No, but if I would be able to update an external stylesheet defintion, it would automatically update all document derived from the external style sheet. After, all, that is what we are doing with web sites, also. Eeach web page has got a link to an external style sheet. If I change something in the external style sheet, the whole site is updated. Why is the concept of doing the same thing with a bunch of related documents so hard to grasp ?
Yes. Think of the template as the external stylesheet. So what remains?
Nothing. I applied the macro mentioned in the text to one of my documents, and now the question is being asked when I open this document to re-apply the styles in the template. I can live with that. A pitty that such a bug has found it's way into version 2.0.2. Is there a way to see if it is already fixed and when version 2.0.3 (or any next version) will come out ? Also: is there a way to couple an existing document to a template ? This issue may be closed.
I would like to add my support for this, but I think it should be a framework idea, not a writer idea. The use of extrenal style sheets would make it possible to edit the style sheet and have the changes cascade to all sheets based on it, no matter how old or how many, next time they were opened. This would be invaluable when corporate layout rules changed, logos were updated etc. It would allow documents designed for one size paper to be rapidly adapted to another. An ESS would be like a CSS for a web page, like a template that could be modified retrospectively.
I am not sure this really is an issue because if you create all your documents on a customized template, any changes to the style will cascade down the first time you open it. One would maintain the style in the top-most template, then any custom styles created from this template will cascade to its child documents. This cascading will only happen the first time you open the file though as others have mentioned. I think this is what cloph was saying earlier. People shouldn't be expecting to change the master template by changing the child documents. If you want to do this, it would be best to change to another product.