Page 1 of 1

Omero.editor: Protocol formatting?

PostPosted: Wed Oct 05, 2011 6:35 am
by jbyars
Is any formatting allowed in protcols beyond tab indenting? It would be really useful to be able to have tables, lists and images in protocols. Is there any documentation for this? I came up empty on the wiki. Sensitive is the stylesheet to editing? Thanks!

Re: Omero.editor: Protocol formatting?

PostPosted: Fri Oct 07, 2011 9:01 am
by wmoore
Hi, I'm not sure exactly what you're wanting here: Are you trying to change the appearance of Editor xml files in a web browser by editing the style sheets? Or are you asking about how Protocols and Experiments appear in the Editor itself?

You can have tables in protocols. When in "Edit Experiment" mode in the Table-View tab, you can click the 'Table +' icon for a step to create a table where each column is a parameter of that step (see screen-shot).
The screen-shot I'll attach below is one of the demo ones available with the "Open File from Web" option in the Editor.

When this same file is rendered in the browser it looks like this:
http://cvs.openmicroscopy.org.uk/snapsh ... AP.cpe.xml

Lists aren't specifically implemented, but you can always create a new set of indented steps? Or just format the text within a step to have one item per line (all in the same paragraph)? I can show you these if you like?

You can link to images that are on the same machine, although only the link is saved (the image is not saved alongside the Editor file). Choose "Data Reference" parameter, click the wrench icon in the right-hand panel and browse to the local image file (only jpeg and png supported). See second screen-shot.
Again, this feature is not as complete as it might be, but let me know how it goes.

Cheers,

Will.

Re: Omero.editor: Protocol formatting?

PostPosted: Tue Oct 25, 2011 6:14 pm
by jbyars
Sorry this fell on the back burner. Thank you for the help. I see how to embed images now. Though tedious it should suffice for the small number of images we will need to embed. The tables did not work out as well for me. You're right you can expand them in experiment mode and fill them in. But, now that I've updated the server to 4.3.3, I get this every time I try to view one of the protocols in a browser. I'm sure the fix is on the forums.

Error loading stylesheet: An unknown error has occurred (805303f4)
http://cvs.openmicroscopy.org.uk/snapsh ... r2html.xsl

What I really wanted to know was what potential there is for additional formatting options. Right now I can indent and indent some more. Could the style sheet be expanded to allow for other common html tags <ul> <ol> <div> etc., without causing major problems?

Re: Omero.editor: Protocol formatting?

PostPosted: Thu Oct 27, 2011 2:42 pm
by wmoore
Hi,

jbyars wrote: Could the style sheet be expanded to allow for other common html tags <ul> <ol> <div> etc., without causing major problems?


I'm afraid it won't be easy to add additional formatting options. Html tags aren't used in the Editor itself. The Editor uses XML to save a protocol or experiment. There is a conversion from the XML to the internal Editor data structure and then this is displayed in a custom Java UI.

Your best option for doing lists is to simply use new lines with "-" or something similar. This won't look as good as "real" lists but does it give you what you want? (see screen-shots).

I'm not sure what your issue is with style-sheets. Can you check that the style-sheet linked in your post downloads OK (your connection is OK etc).
If you download this example, does it work? http://cvs.openmicroscopy.org.uk/snapsh ... ot.cpe.xml

Cheers,
Will.