diff --git a/plone/app/deco/interfaces.py b/plone/app/deco/interfaces.py index 57e5010..f1122f8 100644 --- a/plone/app/deco/interfaces.py +++ b/plone/app/deco/interfaces.py @@ -1,76 +1,5 @@ from zope.interface import Interface from zope import schema -from zope.i18nmessageid import MessageFactory -from plone.directives import form - -_ = MessageFactory('plone.app.deco') - - -class IDecoSettings(form.Schema): - """This interface defines the deco settings.""" - - form.fieldset('actions', - label=_(u"Actions"), - fields=['default_available_actions', 'primary_actions', 'secondary_actions'], - ) - - primary_actions = schema.List( - title=_(u"Primary actions"), - description=_(u"Enter a list of primary actions. Format is name|fieldsetname|fieldsetlable|label|action|icon|menu|item1value|item1label|item2value... one per line."), - value_type=schema.TextLine(), - required=False) - - secondary_actions = schema.List( - title=_(u"Secondary actions"), - description=_(u"Enter a list of secondary actions. Format is name|fieldsetname|fieldsetlable|label|action|icon|menu|item1value|item1label|item2value... one per line."), - value_type=schema.TextLine(), - required=False) - - default_available_actions = schema.List( - title=_(u"Default available actions"), - description=_(u"Enter a list of default available actions, one per line."), - value_type=schema.TextLine(), - required=False) - - form.fieldset('formats', - label=_(u"Styles"), - fields=['formats'], - ) - -# format_categories = schema.List( -# title=_(u"Style categories"), -# description=_(u"Enter a list of format categories. Format is name|label, one format per line."), -# value_type=schema.TextLine(), -# required=False) - -# formats = schema.List( -# title=_(u"Styles"), -# description=_(u"Enter a list of formats. Format is name|category|label|action|icon|favorite, one format per line."), -# value_type=schema.TextLine(), -# required=False) - -# form.fieldset('tiles', -# label=_(u"Tiles"), -# fields=['tile_categories', 'structure_tiles', 'app_tiles'], -# ) - -# tile_categories = schema.List( -# title=_(u"Tile categories"), -# description=_(u"Enter a list of tile categories. Format is name|title, one format per line."), -# value_type=schema.TextLine(), -# required=False) - -# structure_tiles = schema.List( -# title=_(u"Structure tiles"), -# description=_(u"Enter a list of structure tiles. Format is name|category|label|type|default_value|read_only|settings|favorite|rich_text|available_actions, one format per line."), -# value_type=schema.TextLine(), -# required=False) - -# app_tiles = schema.List( -# title=_(u"Application tiles"), -# description=_(u"Enter a list of application tiles. Format is name|category|label|read_only|settings|favorite|rich_text|available_actions, one format per line."), -# value_type=schema.TextLine(), -# required=False) class IDecoRegistryAdapter(Interface): diff --git a/plone/app/deco/profiles/default/registry.xml b/plone/app/deco/profiles/default/registry.xml index c30c92b..3f576d4 100644 --- a/plone/app/deco/profiles/default/registry.xml +++ b/plone/app/deco/profiles/default/registry.xml @@ -1,413 +1,374 @@ - - - save|save|Save|Save|save|false|false - cancel|||Cancel|cancel|false|false - page_properties|||Page properties|page-properties|false|false - - - - - layout|||Layout|layout|false|true|none|Layout|newslisting|News listing|projectdetails|Project details|gallery|Gallery|another|Choose another...|template|Save as template... - format|||Format|format|false|true|none|Format - insert|||Insert|insert|false|true|none|Insert - - - - - save - cancel - page_propertiesproperties - undo - redo - format - insert - - + + + Default available actions + + + + save + cancel + page_propertiesproperties + undo + redo + format + insert + + - - - Tile categories - - - - - Actions - Text - Selection - Lists - Justify - Print - - + + + Tile categories + + + + + Actions + Text + Selection + Lists + Justify + Print + + - - - strong - em - paragraph - heading - subheading - discreet - literal - quote - callout - highlight - sub - sup - remove-format - ul - ol - justify-left - justify-center - justify-right - justify-justify - tile-align-block - tile-align-left - tile-align-right - pagebreak - - + + strong + text + B + strong + false + true + + + em + text + I + em + false + true + + + paragraph + text + Paragraph + paragraph + true + false + + + heading + text + Heading + heading + true + false + + + subheading + text + Subheading + subheading + true + false + + + discreet + text + Discreet + discreet + true + false + + + literal + text + Literal + literal + true + false + + + quote + text + Quote + quote + true + false + + + callout + text + Callout + callout + true + false + + + highlight + selection + Highlight + highlight + true + false + + + sub + selection + Subscript + sub + true + false + + + sup + selection + Superscript + sup + true + false + + + remove-format + selection + (Remove format) + remove-format + true + false + + + ul + lists + Unordered list + ul + true + false + + + ol + lists + Ordered list + ol + true + false + + + justify-left + justify + Left-aligned + justify-left + true + false + + + justify-center + justify + Center + justify-center + true + false + + + justify-right + justify + Right-aligned + justify-right + true + false + + + justify-justify + justify + Justified + justify-justify + true + false + + + tile-align-block + justify + Tile block + tile-align-block + true + false + + + tile-align-left + justify + Tile left + tile-align-left + true + false + + + tile-align-right + justify + Tile right + tile-align-right + true + false + + + pagebreak + print + Page break + pagebreak + true + false + - - strong - text - B - strong - false - true - - - em - text - I - em - false - true - - - paragraph - text - Paragraph - paragraph - true - false - - - heading - text - Heading - heading - true - false - - - subheading - text - Subheading - subheading - true - false - - - discreet - text - Discreet - discreet - true - false - - - literal - text - Literal - literal - true - false - - - quote - text - Quote - quote - true - false - - - callout - text - Callout - callout - true - false - - - highlight - selection - Highlight - highlight - true - false - - - sub - selection - Subscript - sub - true - false - - - sup - selection - Superscript - sup - true - false - - - remove-format - selection - (Remove format) - remove-format - true - false - - - ul - lists - Unordered list - ul - true - false - - - ol - lists - Ordered list - ol - true - false - - - justify-left - justify - Left-aligned - justify-left - true - false - - - justify-center - justify - Center - justify-center - true - false - - - justify-right - justify - Right-aligned - justify-right - true - false - - - justify-justify - justify - Justified - justify-justify - true - false - - - tile-align-block - justify - Tile block - tile-align-block - true - false - - - tile-align-left - justify - Tile left - tile-align-left - true - false - - - tile-align-right - justify - Tile right - tile-align-right - true - false - - - pagebreak - print - Page break - pagebreak - true - false - + + pagebreak + print + Page break + pagebreak + true + false + - - pagebreak - print - Page break - pagebreak - true - false - + + + Tile categories + + + + + Structure + Media + Fields + + - - - Tile categories - - - - - Structure - Media - Fields - - - - - - Tile categories - - - - - <p>New block</p> - structure - False - text - True - False - Text - text - True - - - - - Available actions for the Text structure tile - - - - strong - em - paragraph - heading - subheading - discreet - literal - quote - callout - highlight - sub - sup - remove-format - pagebreak - ul - ol - justify-left - justify-center - justify-right - justify-justify - tile-align-block - tile-align-right - - - - - - plone.app.standardtiles.title - - - - - False - fields - plone.app.standardtiles.title - False - False - Title - True - - - - - Available actions for the Text structure tile - - - - tile-align-block - tile-align-right - tile-align-left - - - - - plone.app.standardtiles.description - - - - - False - fields - plone.app.standardtiles.description - False - False - Description - True - - - - - Available actions for the Text structure tile - - - - tile-align-block - tile-align-right - tile-align-left - - + + + Tile categories + + + + + <p>New block</p> + structure + False + text + True + False + Text + text + True + + + + + Available actions for the Text structure tile + + + + strong + em + paragraph + heading + subheading + discreet + literal + quote + callout + highlight + sub + sup + remove-format + pagebreak + ul + ol + justify-left + justify-center + justify-right + justify-justify + tile-align-block + tile-align-right + + + + + plone.app.standardtiles.title + + + + + False + fields + plone.app.standardtiles.title + False + False + Title + True + + + + + Available actions for the Text structure tile + + + + tile-align-block + tile-align-right + tile-align-left + + + + + plone.app.standardtiles.description + + + + + False + fields + plone.app.standardtiles.description + False + False + Description + True + + + + + Available actions for the Text structure tile + + + + tile-align-block + tile-align-right + tile-align-left + + diff --git a/plone/app/deco/registry.py b/plone/app/deco/registry.py index 3e17011..815874b 100644 --- a/plone/app/deco/registry.py +++ b/plone/app/deco/registry.py @@ -47,6 +47,9 @@ def parseRegistry(self): result = DottedDict() for record in self.registry.records: + if not record.startswith(self.prefix): + continue + splitted = record.split('.') current = result for x in splitted[:-1]: @@ -118,7 +121,7 @@ def mapActions(self, settings, config): def mapTilesCategories(self, settings, config): config['tiles'] = config.get('tiles', []) - categories = settings.get("%s.tiles_categories" % self.prefix, []) + categories = settings.get("%s.tiles_categories" % self.prefix, {}) for name, label in categories.items(): config['tiles'].append({ 'name': name, @@ -129,7 +132,7 @@ def mapTilesCategories(self, settings, config): def mapFormatCategories(self, settings, config): config['formats'] = config.get('formats', []) - categories = settings.get("%s.format_categories" % self.prefix, []) + categories = settings.get("%s.format_categories" % self.prefix, {}) for name, label in categories.items(): config['formats'].append({ 'name': name, @@ -139,7 +142,7 @@ def mapFormatCategories(self, settings, config): return config def mapFormats(self, settings, config): - formats = settings.get('%s.formats' % self.prefix, []) + formats = settings.get('%s.formats' % self.prefix, {}) for key, format in formats.items(): index = GetCategoryIndex(config['formats'], format['category']) config['formats'][index]['actions'].append(format) @@ -148,7 +151,7 @@ def mapFormats(self, settings, config): def mapStructureTiles(self, settings, config): # Structure Tiles - tiles = settings.get('%s.structure_tiles' % self.prefix, []) + tiles = settings.get('%s.structure_tiles' % self.prefix, {}) for key, tile in tiles.items(): if not 'category' in tile: continue @@ -157,7 +160,7 @@ def mapStructureTiles(self, settings, config): return config def mapApplicationTiles(self, settings, config): - tiles = settings.get('%s.app_tiles' % self.prefix, []) + tiles = settings.get('%s.app_tiles' % self.prefix, {}) for key, tile in tiles.items(): if not 'category' in tile: continue @@ -167,68 +170,6 @@ def mapApplicationTiles(self, settings, config): def mapFieldTiles(self, settings, config): return config - # Field Tiles - #type = self.context.portal_type - #if hasattr(self.context.REQUEST, 'type'): - # type = self.context.REQUEST['type'] - #fti = getUtility(IDexterityFTI, name=type) - #for x in fti.lookupSchema(): - # pass - # #log(x) - - #for behavior_name in fti.behaviors: - # try: - # behavior_interface = resolveDottedName(behavior_name) - # except ValueError: - # continue - # if behavior_interface is not None: - # behavior_schema = IFormFieldProvider(behavior_interface, None) - # if behavior_schema is not None: - # for x in behavior_schema: - # pass - # #log(x) - - config['tiles'][GetCategoryIndex(config['tiles'], 'fields')]['tiles'].append({ - 'name': 'date', - 'label': 'Date', - 'type': 'field', - 'field_type': 'Datetime', - 'widget': 'DateTimePickerFieldWidget', - 'id': 'formfield-form-widgets-date', - 'read_only': False, - 'settings': True, - 'favorite': False, - 'available_actions': ['tile-align-block', 'tile-align-right', 'tile-align-left', ], - }) - - config['tiles'][GetCategoryIndex(config['tiles'], 'fields')]['tiles'].append({ - 'name': 'agenda', - 'label': 'Agenda', - 'type': 'field', - 'field_type': 'Text', - 'widget': 'WysiwygFieldWidget', - 'id': 'formfield-form-widgets-agenda', - 'read_only': False, - 'settings': True, - 'favorite': False, - 'available_actions': ['strong', 'em', 'paragraph', 'heading', 'subheading', 'discreet', 'literal', 'quote', 'callout', 'highlight', 'sub', 'sup', 'remove-format', 'pagebreak', 'ul', 'ol', 'justify-left', 'justify-center', 'justify-right', 'justify-justify', 'tile-align-block', 'tile-align-right', 'tile-align-left'], - }) - - config['tiles'][GetCategoryIndex(config['tiles'], 'fields')]['tiles'].append({ - 'name': 'recurrence', - 'label': 'Recurrence', - 'type': 'field', - 'field_type': 'Choice', - 'widget': 'SelectFieldWidget', - 'id': 'formfield-form-widgets-recurrence', - 'read_only': True, - 'settings': False, - 'favorite': False, - 'rich_text': True, - 'available_actions': ['tile-align-block', 'tile-align-right', 'tile-align-left'], - }) - - return config def __call__(self): settings = self.parseRegistry() diff --git a/plone/app/deco/tests/registry_testdata.py b/plone/app/deco/tests/registry_testdata.py index b6fa8d3..fc512c4 100644 --- a/plone/app/deco/tests/registry_testdata.py +++ b/plone/app/deco/tests/registry_testdata.py @@ -1,418 +1,379 @@ xml = """ - - - - save|save|Save|Save|save|false|false - cancel|||Cancel|cancel|false|false - page_properties|||Page properties|page-properties|false|false - - + - - - layout|||Layout|layout|false|true|none|Layout|newslisting|News listing|projectdetails|Project details|gallery|Gallery|another|Choose another...|template|Save as template... - format|||Format|format|false|true|none|Format - insert|||Insert|insert|false|true|none|Insert - - + + + Default available actions + + + + save + cancel + page_propertiesproperties + undo + redo + format + insert + + - - - save - cancel - page_propertiesproperties - undo - redo - format - insert - - + + + Tile categories + + + + + Actions + Text + Selection + Lists + Justify + Print + + - - - Tile categories - - - - - Actions - Text - Selection - Lists - Justify - Print - - + + strong + text + B + strong + false + true + + + em + text + I + em + false + true + + + paragraph + text + Paragraph + paragraph + true + false + + + heading + text + Heading + heading + true + false + + + subheading + text + Subheading + subheading + true + false + + + discreet + text + Discreet + discreet + true + false + + + literal + text + Literal + literal + true + false + + + quote + text + Quote + quote + true + false + + + callout + text + Callout + callout + true + false + + + highlight + selection + Highlight + highlight + true + false + + + sub + selection + Subscript + sub + true + false + + + sup + selection + Superscript + sup + true + false + + + remove-format + selection + (Remove format) + remove-format + true + false + + + ul + lists + Unordered list + ul + true + false + + + ol + lists + Ordered list + ol + true + false + + + justify-left + justify + Left-aligned + justify-left + true + false + + + justify-center + justify + Center + justify-center + true + false + + + justify-right + justify + Right-aligned + justify-right + true + false + + + justify-justify + justify + Justified + justify-justify + true + false + + + tile-align-block + justify + Tile block + tile-align-block + true + false + + + tile-align-left + justify + Tile left + tile-align-left + true + false + + + tile-align-right + justify + Tile right + tile-align-right + true + false + + + pagebreak + print + Page break + pagebreak + true + false + - - - strong - em - paragraph - heading - subheading - discreet - literal - quote - callout - highlight - sub - sup - remove-format - ul - ol - justify-left - justify-center - justify-right - justify-justify - tile-align-block - tile-align-left - tile-align-right - pagebreak - - + + pagebreak + print + Page break + pagebreak + true + false + - - strong - text - B - strong - false - true - - - em - text - I - em - false - true - - - paragraph - text - Paragraph - paragraph - true - false - - - heading - text - Heading - heading - true - false - - - subheading - text - Subheading - subheading - true - false - - - discreet - text - Discreet - discreet - true - false - - - literal - text - Literal - literal - true - false - - - quote - text - Quote - quote - true - false - - - callout - text - Callout - callout - true - false - - - highlight - selection - Highlight - highlight - true - false - - - sub - selection - Subscript - sub - true - false - - - sup - selection - Superscript - sup - true - false - - - remove-format - selection - (Remove format) - remove-format - true - false - - - ul - lists - Unordered list - ul - true - false - - - ol - lists - Ordered list - ol - true - false - - - justify-left - justify - Left-aligned - justify-left - true - false - - - justify-center - justify - Center - justify-center - true - false - - - justify-right - justify - Right-aligned - justify-right - true - false - - - justify-justify - justify - Justified - justify-justify - true - false - - - tile-align-block - justify - Tile block - tile-align-block - true - false - - - tile-align-left - justify - Tile left - tile-align-left - true - false - - - tile-align-right - justify - Tile right - tile-align-right - true - false - - - pagebreak - print - Page break - pagebreak - true - false - + + + Tile categories + + + + + Structure + Media + Fields + + - - pagebreak - print - Page break - pagebreak - true - false - - - - - Tile categories - - - - - Structure - Media - Fields - - - - - - Tile categories - - - - - <p>New block</p> - structure - False - text - True - False - Text - text - True - - - - - Available actions for the Text structure tile - - - - strong - em - paragraph - heading - subheading - discreet - literal - quote - callout - highlight - sub - sup - remove-format - pagebreak - ul - ol - justify-left - justify-center - justify-right - justify-justify - tile-align-block - tile-align-right - - - - - - plone.app.standardtiles.title - - - - - False - fields - plone.app.standardtiles.title - False - False - Title - True - - - - - Available actions for the Text structure tile - - - - tile-align-block - tile-align-right - tile-align-left - - - - - plone.app.standardtiles.description - - - - - False - fields - plone.app.standardtiles.description - False - False - Description - True - - - - - Available actions for the Text structure tile - - - - tile-align-block - tile-align-right - tile-align-left - - + + + Tile categories + + + + + <p>New block</p> + structure + False + text + True + False + Text + text + True + + + + + Available actions for the Text structure tile + + + + strong + em + paragraph + heading + subheading + discreet + literal + quote + callout + highlight + sub + sup + remove-format + pagebreak + ul + ol + justify-left + justify-center + justify-right + justify-justify + tile-align-block + tile-align-right + + + + + plone.app.standardtiles.title + + + + + False + fields + plone.app.standardtiles.title + False + False + Title + True + + + + + Available actions for the Text structure tile + + + + tile-align-block + tile-align-right + tile-align-left + + + + + plone.app.standardtiles.description + + + + + False + fields + plone.app.standardtiles.description + False + False + Description + True + + + + + Available actions for the Text structure tile + + + + tile-align-block + tile-align-right + tile-align-left + + + """ parsed_data = {'tiles': [{'tiles': [{'default_value': u'

New block

', 'read_only': False, 'name': u'text', 'available_actions': [u'strong', u'em', u'paragraph', u'heading', u'subheading', u'discreet', u'literal', u'quote', u'callout', u'highlight', u'sub', u'sup', u'remove-format', u'pagebreak', u'ul', u'ol', u'justify-left', u'justify-center', u'justify-right', u'justify-justify', u'tile-align-block', u'tile-align-right'], 'settings': True, 'favorite': False, 'type': u'text', 'rich_text': True, 'label': u'Text'}], 'name': u'structure', 'label': u'Structure'}, {'tiles': [], 'name': u'media', 'label': u'Media'}, {'tiles': [{'default_value': '', 'read_only': False, 'name': u'plone.app.standardtiles.title', 'available_actions': [u'tile-align-block', u'tile-align-right'], 'settings': False, 'favorite': False, 'type': 'app', 'rich_text': True, 'label': u'Title'}, {'default_value': '', 'read_only': False, 'name': u'plone.app.standardtiles.description', 'available_actions': [u'tile-align-block', u'tile-align-right'], 'settings': False, 'favorite': False, 'type': 'app', 'rich_text': True, 'label': u'Description'}, {'read_only': False, 'field_type': 'Datetime', 'widget': 'DateTimePickerFieldWidget', 'name': 'date', 'available_actions': ['tile-align-block', 'tile-align-right', 'tile-align-left'], 'settings': True, 'favorite': False, 'type': 'field', 'id': 'formfield-form-widgets-date', 'label': 'Date'}, {'read_only': False, 'field_type': 'Text', 'widget': 'WysiwygFieldWidget', 'name': 'agenda', 'available_actions': ['strong', 'em', 'paragraph', 'heading', 'subheading', 'discreet', 'literal', 'quote', 'callout', 'highlight', 'sub', 'sup', 'remove-format', 'pagebreak', 'ul', 'ol', 'justify-left', 'justify-center', 'justify-right', 'justify-justify', 'tile-align-block', 'tile-align-right', 'tile-align-left'], 'settings': True, 'favorite': False, 'type': 'field', 'id': 'formfield-form-widgets-agenda', 'label': 'Agenda'}, {'widget': 'SelectFieldWidget', 'id': 'formfield-form-widgets-recurrence', 'read_only': True, 'field_type': 'Choice', 'name': 'recurrence', 'settings': False, 'type': 'field', 'favorite': False, 'label': 'Recurrence', 'available_actions': ['tile-align-block', 'tile-align-right', 'tile-align-left'], 'rich_text': True}], 'name': u'fields', 'label': u'Fields'}], 'default_available_actions': [u'save', u'cancel', u'page-properties', u'undo', u'redo', u'format', u'insert'], 'primary_actions': [{'name': u'save', 'actions': [{'name': u'save', 'menu': False, 'label': u'Save', 'items': [], 'action': u'save', 'icon': False}], 'label': u'Save'}, {'name': u'cancel', 'menu': False, 'label': u'Cancel', 'items': [], 'action': u'cancel', 'icon': False}, {'name': u'page_properties', 'menu': False, 'label': u'Page properties', 'items': [], 'action': u'page-properties', 'icon': False}], 'secondary_actions': [{'name': u'layout', 'menu': True, 'label': u'Layout', 'items': [{'value': u'none', 'label': u'Layout'}, {'value': u'newslisting', 'label': u'News listing'}, {'value': u'projectdetails', 'label': u'Project details'}, {'value': u'gallery', 'label': u'Gallery'}, {'value': u'another', 'label': u'Choose another...'}, {'value': u'template', 'label': u'Save as template...'}], 'action': u'layout', 'icon': False}, {'name': u'format', 'menu': True, 'label': u'Format', 'items': [{'value': u'none', 'label': u'Format'}], 'action': u'format', 'icon': False}, {'name': u'insert', 'menu': True, 'label': u'Insert', 'items': [{'value': u'none', 'label': u'Insert'}], 'action': u'insert', 'icon': False}], 'formats': [{'name': u'actions', 'actions': [], 'label': u'Actions'}, {'name': u'text', 'actions': [{'action': u'strong', 'icon': False, 'favorite': True, 'name': u'strong', 'label': u'B'}, {'action': u'em', 'icon': False, 'favorite': True, 'name': u'em', 'label': u'I'}, {'action': u'paragraph', 'icon': True, 'favorite': False, 'name': u'paragraph', 'label': u'Paragraph'}, {'action': u'heading', 'icon': True, 'favorite': False, 'name': u'heading', 'label': u'Heading'}, {'action': u'subheading', 'icon': True, 'favorite': False, 'name': u'subheading', 'label': u'Subheading'}, {'action': u'discreet', 'icon': True, 'favorite': False, 'name': u'discreet', 'label': u'Discreet'}, {'action': u'literal', 'icon': True, 'favorite': False, 'name': u'literal', 'label': u'Literal'}, {'action': u'quote', 'icon': True, 'favorite': False, 'name': u'quote', 'label': u'Quote'}, {'action': u'callout', 'icon': True, 'favorite': False, 'name': u'callout', 'label': u'Callout'}], 'label': u'Text'}, {'name': u'selection', 'actions': [{'action': u'highlight', 'icon': True, 'favorite': False, 'name': u'highlight', 'label': u'Highlight'}, {'action': u'sub', 'icon': True, 'favorite': False, 'name': u'sub', 'label': u'Subscript'}, {'action': u'sup', 'icon': True, 'favorite': False, 'name': u'sup', 'label': u'Superscript'}, {'action': u'remove-format', 'icon': True, 'favorite': False, 'name': u'remove-format', 'label': u'(Remove format)'}], 'label': u'Selection'}, {'name': u'lists', 'actions': [{'action': u'ul', 'icon': True, 'favorite': False, 'name': u'ul', 'label': u'Unordered list'}, {'action': u'ol', 'icon': True, 'favorite': False, 'name': u'ol', 'label': u'Ordered list'}], 'label': u'Lists'}, {'name': u'justify', 'actions': [{'action': u'justify-left', 'icon': True, 'favorite': False, 'name': u'justify-left', 'label': u'Left-aligned'}, {'action': u'justify-center', 'icon': True, 'favorite': False, 'name': u'justify-center', 'label': u'Center'}, {'action': u'justify-right', 'icon': True, 'favorite': False, 'name': u'justify-right', 'label': u'Right-aligned'}, {'action': u'justify-justify', 'icon': True, 'favorite': False, 'name': u'justify-justify', 'label': u'Justified'}, {'action': u'tile-align-block', 'icon': True, 'favorite': False, 'name': u'tile-align-block', 'label': u'Tile block'}, {'action': u'tile-align-left', 'icon': True, 'favorite': False, 'name': u'tile-align-left', 'label': u'Tile left'}, {'action': u'tile-align-right', 'icon': True, 'favorite': False, 'name': u'tile-align-right', 'label': u'Tile right'}], 'label': u'Justify'}, {'name': u'print', 'actions': [{'action': u'pagebreak', 'icon': True, 'favorite': False, 'name': u'pagebreak', 'label': u'Page break'}], 'label': u'Print'}]}