Object renderings

You set object rendering in the Sitecore.Odg.config file so that Document Publisher users can change the content of text and image frames in their documents. By default, in the Sitecore.Odg.config file (Website\App_Config\Include\PXM\Sitecore.Odg.config) the following keys are set:

  • P_Textframe

  • P_ImageFrame

Object rendering needs the following key identifications:

  • renderingId – indicates the rendering of the item. The renderingId for the image and text frames are: TextEditRendering and ImageEdit Rendering. See sitecore/Client/Applications/ODG/Components/Controls in the Sitecore core database.

  • datarenderingId – is required for items that contain data such as image and text items. See sitecore/Client/Applications/ODG/Components/Controls.

For the P_Textframe and P_ImageFrame keys, the renderingID and the datarenderingID are configured as follows in the Sitecore.Odg.config file:

RequestResponse
<documentEditor>
<editorTypes>
<type key="P_TextFrame" renderingId="{CD8E4F2F-A6A4-4DEC-9406-39DE5C4E9C1F}"
dataRenderingId="{405DF344-671F-4EC3-AA07-6EFD0E39FD42}" additionalRenderings=""/>
<type key="P_ImageFrame" renderingId="{8CF4552A-2822-4A32-9E06-84C70E6C6A78}"
dataRenderingId="{405DF344-671F-4EC3-AA07-6EFD0E39FD42}" additionalRenderings=""/>
</editorTypes>
</documentEditor>

With these default settings, Document Publisher users can change the content of text and image frames.

If necessary, you can add additional renderings for the existing object renderings in the config file, or add a new object rendering. For example, you can add additional renderings so that Document Publisher users can change the position and size of text and image frames. To do this, you add the renderingId for a shape to the Sitecore.Odg.config file (Website\App_Config\Include\Sitecore.Odg.config):

RequestResponse
<type key="P_ImageFrame" renderingId="{8CF4552A-2822-4A32-9E06-84C70E6C6A78} "dataRenderingId="{405DF344-671F-4EC3-AA07-6EFD0E39FD42} "additionalRenderings="{CC74880A-49B7-474F-9E2B-69A05413FA87}"/>

After adding the additional rendering to the config file, Document Publisher users can change the size and position of image and text frames.

Do you have some feedback for us?

If you have suggestions for improving this article,