Adding a custom paragraph style to ATTO editor

Adding a custom paragraph style to ATTO editor

by Andy Chaplin -
Number of replies: 4

Hi all!

Is there an easy (or even a complicated) way to add a custom text style to the ATTO editor?  there doesn't seem to be a style creator.  A plugin would be great, but I guess it's possible to add  some css, though I don't know where, and the forum posts I found for editing styles were very old.

As an example, I'm looking to create a style called 'Tutor's Comments" so that feedback text looks different to the normal paragraph text.

I'm using 2.8.3

Thanks for any help or pointers you can offer.


Average of ratings: Useful (1)
In reply to Andy Chaplin

Re: Adding a custom paragraph style to ATTO editor

by Mary Cooch -
Picture of Documentation writers Picture of Moodle HQ Picture of Particularly helpful Moodlers Picture of Testers Picture of Translators

Moving to the Text editor forum..

In reply to Andy Chaplin

Re: Adding a custom paragraph style to ATTO editor

by Daniel Thies -
Picture of Core developers Picture of Plugin developers Picture of Testers

Hi Andy,

I don't know that there is currently a way of just adding one style in the editor, but it would not be that hard to create a plugin to do it.  However, for the application that you are suggesting, you may find that the inline Corrections plugin is already tailored to fit your need.

Average of ratings: Useful (1)
In reply to Daniel Thies

Re: Adding a custom paragraph style to ATTO editor

by Andy Chaplin -

Hi Daniel

Thanks for the tip.  The plugin works pretty well and I will certainly use it, but I'm still slightly surprised that adding a new paragraph style is so hard.  The styles provided in the theme (or is it the editor?) are hardly comprehensive - for example, not having a style for quotations in an educational tool would seem to be a serious deficit to me.

Thanks again for the tip.  It certainly solved part of my problem.


Average of ratings: Useful (1)
In reply to Andy Chaplin

Re: Adding a custom paragraph style to ATTO editor

by Daniel Thies -
Picture of Core developers Picture of Plugin developers Picture of Testers

Thank you Andy.  I appreciate the comment regarding more styles especially block quotations which we have been working on in MDL-45662.  This would be another way of addressing your need, but it will not make it in until at least 3.0.

There are some reasons styles in the Atto editor are a little sparse. It is meant to produce text that is easily read and understood on the web in various contexts and with various applications. This means that text is formated mosty with HTML tags rather than CSS.  Adding CSS classes would have to be supported both in the theme and in the editor. Text that is cut and pasted from Moodle into another application might lose the intended formating when it is transferred.