LO Styles organization

classic Classic list List threaded Threaded
5 messages Options
John Kaufmann John Kaufmann
Reply | Threaded
Open this post in threaded view
|

LO Styles organization

I'm trying to understand what is contained in LO styles [which I know changes according to style class (for Writer: Paragraph, Page, etc)]. To simplify this question, I have decided to:
        (a) focus on a Page style (instead of the more complex Paragraph style) to understand the principles;
        (b) limit the initial inquiry to the relationship between the attributes defined in the tabs of that style definition and the attributes summarized in the Organizer tab's "Contains" section.

For example, for a custom Page style "Booklet" (used for 7.5"x8" folded/stapled booklets), the Organizer tab lists:
"
        *Contains*
        8.5 inch + From top 0.5 inch, From bottom 0.5 inch + No header + No footer + No grid + Text direction left-to-
        right (horizontal) + Page Description: Arabic, Portrait, All + Booklet + Not register-true
"

"Contains" uses "+" [rather than, say, \n] to separate attributes. [BTW: is there a better term than "attribute" to use here?]
In this case it lists 9 attributes (including the 2-part top/bottom margins attribute and the 3-part Page Description attribute):
        - 2 (not all) attributes from the Page tab,
        - 2 attributes from other tabs;
        - 1 attribute defined in "Tools > Options > LibreOffice Writer (or is it LibreOffice Writer/Web?) > Grid";
        - 2 attributes (Text direction, Page Description) defined nowhere that I can find;
        - 1 attribute (the style name: "Booklet") defined in the Organizer tab;
        - 1 more attribute (Not register-true) defined in the Page tab.

With the background provided by that example, I ask these questions about the Organizer tab "Contains" section:
        (1) What is the significance of this section? Does it have any formal significance or functional use?
        (2) Why does it list attributes not defined in the style?

[Any further questions would be clarified by the answers to those questions.]

Thanks,
John

--
To unsubscribe e-mail to: [hidden email]
Problems? https://www.libreoffice.org/get-help/mailing-lists/how-to-unsubscribe/
Posting guidelines + more: https://wiki.documentfoundation.org/Netiquette
List archive: https://listarchives.libreoffice.org/global/users/
Privacy Policy: https://www.documentfoundation.org/privacy
mikey mikey
Reply | Threaded
Open this post in threaded view
|

Re: LO Styles organization

I tried approaching this from the dialogs, and eventually gave up trying to
map it back to the spec.

However, when I found flat file format, I found that it's easier to
understand how it works by opening the .fodt files in a plain text editor,
and especially doing 'diff' style comparison between the same file saved as
flat file format before and after making only a couple changes to the
dialog in question.

However, pages are more complex than paragraph styles.  There's 3 (?)
different spots that changes to page definition reside in the actual xml,
and understanding their relationship is fun..





On Tue, May 5, 2020 at 4:29 PM John Kaufmann <[hidden email]> wrote:

> I'm trying to understand what is contained in LO styles [which I know
> changes according to style class (for Writer: Paragraph, Page, etc)]. To
> simplify this question, I have decided to:
>         (a) focus on a Page style (instead of the more complex Paragraph
> style) to understand the principles;
>         (b) limit the initial inquiry to the relationship between the
> attributes defined in the tabs of that style definition and the attributes
> summarized in the Organizer tab's "Contains" section.
>
> For example, for a custom Page style "Booklet" (used for 7.5"x8"
> folded/stapled booklets), the Organizer tab lists:
> "
>         *Contains*
>         8.5 inch + From top 0.5 inch, From bottom 0.5 inch + No header +
> No footer + No grid + Text direction left-to-
>         right (horizontal) + Page Description: Arabic, Portrait, All +
> Booklet + Not register-true
> "
>
> "Contains" uses "+" [rather than, say, \n] to separate attributes. [BTW:
> is there a better term than "attribute" to use here?]
> In this case it lists 9 attributes (including the 2-part top/bottom
> margins attribute and the 3-part Page Description attribute):
>         - 2 (not all) attributes from the Page tab,
>         - 2 attributes from other tabs;
>         - 1 attribute defined in "Tools > Options > LibreOffice Writer (or
> is it LibreOffice Writer/Web?) > Grid";
>         - 2 attributes (Text direction, Page Description) defined nowhere
> that I can find;
>         - 1 attribute (the style name: "Booklet") defined in the Organizer
> tab;
>         - 1 more attribute (Not register-true) defined in the Page tab.
>
> With the background provided by that example, I ask these questions about
> the Organizer tab "Contains" section:
>         (1) What is the significance of this section? Does it have any
> formal significance or functional use?
>         (2) Why does it list attributes not defined in the style?
>
> [Any further questions would be clarified by the answers to those
> questions.]
>
> Thanks,
> John
>
> --
> To unsubscribe e-mail to: [hidden email]
> Problems?
> https://www.libreoffice.org/get-help/mailing-lists/how-to-unsubscribe/
> Posting guidelines + more: https://wiki.documentfoundation.org/Netiquette
> List archive: https://listarchives.libreoffice.org/global/users/
> Privacy Policy: https://www.documentfoundation.org/privacy
>

--
To unsubscribe e-mail to: [hidden email]
Problems? https://www.libreoffice.org/get-help/mailing-lists/how-to-unsubscribe/
Posting guidelines + more: https://wiki.documentfoundation.org/Netiquette
List archive: https://listarchives.libreoffice.org/global/users/
Privacy Policy: https://www.documentfoundation.org/privacy
John Kaufmann John Kaufmann
Reply | Threaded
Open this post in threaded view
|

Re: LO Styles organization

On 2020-05-05 17:51, Michael H wrote:
> I tried approaching this from the dialogs, and eventually gave up trying to
> map it back to the spec.

Michael, I begin by observing that, while you have dropped many intriguing hints, you are way ahead of me, so I hope you will excuse a couple of novice questions.  Like you, I tried working from the dialogs (the user view of the style definition), but you were already a step ahead: to what spec were you mapping? Where do you find it?


> However, when I found flat file format, I found that it's easier to
> understand how it works by opening the .fodt files in a plain text editor,
> and especially doing 'diff' style comparison between the same file saved as
> flat file format before and after making only a couple changes to the
> dialog in question.

Great tip, but [sorry, novice question again] where are these .fodt files?


> However, pages are more complex than paragraph styles.  There's 3 (?)
> different spots that changes to page definition reside in the actual xml,
> and understanding their relationship is fun..

By "actual xml", you mean the document file? If so, wouldn't the page definition naturally be there?


I appreciate you pointing me in the right direction,
John

--
To unsubscribe e-mail to: [hidden email]
Problems? https://www.libreoffice.org/get-help/mailing-lists/how-to-unsubscribe/
Posting guidelines + more: https://wiki.documentfoundation.org/Netiquette
List archive: https://listarchives.libreoffice.org/global/users/
Privacy Policy: https://www.documentfoundation.org/privacy
John Kaufmann John Kaufmann
Reply | Threaded
Open this post in threaded view
|

Re: LO Styles organization

Dear list: After posting those clueless followup questions, I dig some further digging and found the answers. But before I could post back to the list, Michael was so kind as to write to me (inadvertently off-list), not only with answers to the questions but with additional info that the current version of the ODT spec is v.1.3 (for LO 7) <https://www.oasis-open.org/news/announcements/open-document-format-for-office-applications-opendocument-v1-3-from-the-opendocum>.

For anyone else who might be equally as clueless as I was,
- Michael was referring to ODT spec v.1.2 (the version applicable to LO 6) <https://www.oasis-open.org/committees/tc_home.php?wg_abbrev=office>.
- .fodt files are just the format you get when choosing "Flat XML ODF Text Document (*.fodt)" when saving a document.

None of that gets to clarity on my original question, about the relationship between a style's Organizer tab "Contains" section and the attributes defined in the style, but that may come from more more digging through the spec. If so, I will post back to complete the thread. This is basic to understanding how styles are structured and used in a document.

John


On 2020-05-05 23:31, John Kaufmann wrote:

> On 2020-05-05 17:51, Michael H wrote:
>> I tried approaching this from the dialogs, and eventually gave up trying to
>> map it back to the spec.
>
> Michael, I begin by observing that, while you have dropped many intriguing hints, you are way ahead of me, so I hope you will excuse a couple of novice questions.  Like you, I tried working from the dialogs (the user view of the style definition), but you were already a step ahead: to what spec were you mapping? Where do you find it?
>
>
>> However, when I found flat file format, I found that it's easier to
>> understand how it works by opening the .fodt files in a plain text editor,
>> and especially doing 'diff' style comparison between the same file saved as
>> flat file format before and after making only a couple changes to the
>> dialog in question.
>
> Great tip, but [sorry, novice question again] where are these .fodt files?
>
>
>> However, pages are more complex than paragraph styles.  There's 3 (?)
>> different spots that changes to page definition reside in the actual xml,
>> and understanding their relationship is fun..
>
> By "actual xml", you mean the document file? If so, wouldn't the page definition naturally be there?
>
>
> I appreciate you pointing me in the right direction,
> John


--
To unsubscribe e-mail to: [hidden email]
Problems? https://www.libreoffice.org/get-help/mailing-lists/how-to-unsubscribe/
Posting guidelines + more: https://wiki.documentfoundation.org/Netiquette
List archive: https://listarchives.libreoffice.org/global/users/
Privacy Policy: https://www.documentfoundation.org/privacy
Heiko Tietze-5 Heiko Tietze-5
Reply | Threaded
Open this post in threaded view
|

Re: LO Styles organization

On 06.05.20 17:01, John Kaufmann wrote:
> None of that gets to clarity on my original question, about the relationship between a style's Organizer tab "Contains" section and the attributes defined in the style...

Don't get this but maybe this proposal might shed some light https://design.blog.documentfoundation.org/2019/11/05/proposal-to-conveniently-highlight-and-inspect-styles-in-libreoffice-writer/

In a nutshell: styles have a hierarchy and derived styles contain changed attributes. So "Default" might use Liberation Sans and "Text Body" Liberation Serif. Those differences are listed in the organizer today.

Hope to not have missed the actual question ;-).


--
To unsubscribe e-mail to: [hidden email]
Problems? https://www.libreoffice.org/get-help/mailing-lists/how-to-unsubscribe/
Posting guidelines + more: https://wiki.documentfoundation.org/Netiquette
List archive: https://listarchives.libreoffice.org/global/users/
Privacy Policy: https://www.documentfoundation.org/privacy