Page 1 of 1

"folded" CSS property

Posted: Thu Apr 30, 2009 8:34 pm
by solarian
To complement the foldable extended CSS property in Oxygen, it would be helpful to have a folded property, so that when switching to Author view the respective elements appear folded.

There are a number of possible uses for this, but for myself it would be useful in a TEI project which has alternate text and translation <seg> elements, e.g.:

Code: Select all


<p>
<seg type="original">...</seg>
<seg type="translation">...</seg>
</p>
so one can proof the original text without having to fiddle with folding down the other <seg> element every paragraph.

Re: "folded" CSS property

Posted: Fri May 01, 2009 10:41 am
by sorin_ristache
Hello,

I added your request for a folded CSS property to our system. We will add it in a future version of Author.


Thank you for your request,
Sorin

Re: "folded" CSS property

Posted: Thu Jul 30, 2009 2:35 pm
by Radu
Hi,

One way in which you can hide different parts of the document when editing is to use alternate CSS's.
The CSS used for TEI is located in the OXYGEN_INSTALL_DIR/frameworks/tei/xml/tei/css/tei_oxygen.css

You can create a CSS file called tei_no_original.css with the following content:

Code: Select all


@import "tei_oxygen.css";

*[type="original"]{
display:none;
}
Edit the TEI P4 or P5 document type association and in the "Author" tab add an additional CSS ${frameworks}/tei/xml/tei/css/tei_no_original.css checking the "Alternate" checkbox and giving it a title.
Also edit the original CSS reference and set it as "Alternate" and with a title.

After that, when editing TEI files you will be able to switch in the "CSS" toolbar combo between the two of them.

Regards,
Radu

Re: "folded" CSS property

Posted: Sun Aug 02, 2009 1:56 pm
by solarian
Thanks, that's very helpful.

Re: "folded" CSS property

Posted: Fri Jan 08, 2010 1:25 pm
by ra0543
I think it would still be really helpful to have CSS control over the default display of foldable elements, so that one could mark a number of levels of a hierarchy (e.g. levels 2, 3 and 4) as foldable but have a default for the CSS (e.g. elements at level 2 are unfolded but those inside at level 3, and therefore also level 4, are folded).

Perhaps the implementation could just be another value for the existing property foldable:folded, which would imply foldable:true but with the default display of the element appearing folded rather than unfolded?

[The alternate CSS solution suggested above is helpful in some circumstances, such as those described, but obviously won't work if one wants to work on one (e.g. level 2) part of a document unfolded while leaving another parallel (level 2) part folded.]

Re: "folded" CSS property

Posted: Mon Jan 11, 2010 10:52 am
by Radu
Hi,

The alternative of course is not useful in all instances.
We already have this registered as an improvement to our issues list.
The idea is to be able to specify for elements which can be folded the initial state (folded or not folded) in which they are when the document is opened.

Regards,
Radu

Re: "folded" CSS property

Posted: Wed Jan 13, 2010 1:24 pm
by ra0543
Thanks. We'll look forward to this becoming available. Either at the same time as this or even before if possible, would it also be possible to implement toolbar shortcut buttons to unfold and fold all foldable elements (perhaps with the exception of folding the part of the document containing the cursor if that falls within a foldable element)?

Re: "folded" CSS property

Posted: Wed Jan 13, 2010 5:52 pm
by ra0543
One further (and I hope final) request on this:

Can you add a fold control (perhaps an upwards pointing triangle) at the end of a foldable element like the existing control that appears as a downwards pointing triangle on the line of the start tag of an unfolded foldable element? The new control should have the same function, i.e. to fold the element. This is one way to make it quicker and easier to fold up an element (especially a long one) that one has just finished working with.

Thanks.

Re: "folded" CSS property

Posted: Thu Jan 14, 2010 10:48 am
by Radu
Hi,

We noted both of your requests and they will be discussed.

Regards,
Radu

Re: "folded" CSS property

Posted: Thu Jan 14, 2010 7:15 pm
by paulmathew38
Hi. I'm new and I've come across this topic. Helps a lot especially for a layman like me. Thanks!

Re: "folded" CSS property

Posted: Thu Jul 08, 2010 11:14 pm
by kwringe
We would also find it useful to be able to fold an element at the end of the element as described below:
Can you add a fold control (perhaps an upwards pointing triangle) at the end of a foldable element like the existing control that appears as a downwards pointing triangle on the line of the start tag of an unfolded foldable element? The new control should have the same function, i.e. to fold the element. This is one way to make it quicker and easier to fold up an element (especially a long one) that one has just finished working with.
It would also be cool if the folding options in Text mode (e.g., Document>Folding) would be also available in Author mode.

Thank you,
Kate

Re: "folded" CSS property

Posted: Fri Jul 09, 2010 9:39 am
by Radu
Hi Kate,

You are probably thinking at the "Collapse All/Expand All/Close other folds" actions which are available in the Text page.
You will be notified when this gets implemented.

Regards,
Radu

Re: "folded" CSS property

Posted: Tue Sep 06, 2011 3:43 pm
by Radu
Hi Kate,

Oxygen 13 added support for the "folded" CSS property and also for more powerful expand/collapse fold actions which can be performed by right clicking a fold triangle in the Author page.

Regards,
Radu