Fun stuff around Field types, Contextual Tabs and the whole Ribbon-concept

Working on some custom fields(come back on those in later posts) and found out some crazy stuff:

First of all, there’s an excellent article about creating your own fields on SDN: Creating Custom Field. As a matter of fact, going to provide the documentation team some additional information, but as it is now, it’s also excellent. And it works for 5.1, 5.2 รƒยกnd 5.3!

Second. Did you guys know, it a bunch of work to configure a Contextual Ribbon? Actually didn’t make it at all. What I did found out is that the new Content Editor definitelly has some hardcoded stuff. For example, the Template-Contextual Ribbon. It doesn’t reffer back to another item where it should apply to? Or did I miss one?”
How I came to this conclusion, let me explain:

Looking at the Core database, you’ll find a node called /sitecore/system/ribbons/ribbons/. It contains 1 child: Default. That’s the default menu. The default menu has 9 default tabs/strips(Home, Navigate…….Security, View). Those items are created under the Home-tab. Changing the order of these items, does immediatelly(!) change the order of the tabs/strips in the Editor. Try it yourself!

Ribbon with changed order

Those tabs/strips are configured in /sitecore/systems/ribbons/strips/. For example, the Configure contains children with the names ‘Appearence’, ‘Masters’, ‘Template’, ‘Attributes’. Changing order does immediately affect again :). But anyway, you call these groups ‘Chunks’. Chunk are editable in….. /sitecore/systems/ribbons/chunks/. The contain the actions who trigger events, which are followup by the Content Editor. Again changing order affect immediatelly. There are several actions definable:

  • Panel -> Allows you to load a Control on the place of a ribbon by defining the type => class and assembly(Take a look at ‘/Chuncks/New/New’)
  • Small Button -> Allows you to place a small button with a small icon and some text to the right of the icon
  • Large Button -> Allows you to place a large button with a large icon and some text below the icon.
  • Large Gallery Button -> Look ‘n Feel like Large Button but after clicking no action happends, but a menu or edit screen appears.
  • Small Combo Button -> Look ‘n Feel like Small Button but after clicking a menu appears

Just a second back to the chunk. You can setup a click-event(like here on sorting: ).

Looking at the tree, we only missed the ‘Menus’ and ‘Contextuel Ribbons’ in the story above. About the menu’s, I do no have to explain that much: Small Combo Buttons reffers to an item in the Menus folder and show the children of it.

Last thing to discuss should be the Contextual Tabs. I definitelly want to, but don’t have the time to figure exactly out how they work. They don’t behave like I expected. But that might be funny as well.

For now: have a nice sleep or monday morning cup of coffee :). Cheers!

Note for Jakob: Check in those items! 90% of the core database is checked out to ‘sitecore\Admin’… ๐Ÿ˜› And, when you read this: shouldn’t the Small Combo Button be renamed to Small Gallery Button or the Large Gallery Button to Large Combo Button?

6 thoughts on “Fun stuff around Field types, Contextual Tabs and the whole Ribbon-concept”

  1. Hi Alexey

    Of course I am reading this ๐Ÿ™‚

    Actually the template Contextual Tab is not hardcoded. The Contextual Tab field of the Template template just points into the Core database (which we do not have a field for). So if you paste a GUID into The Contextual Tab field that points to a Ribbon in the Core database, you should see the ribbon appear.

    Regarding Small Gallery Buttons – the difference between the Gallery and Combo button is that a Gallery always drops down a gallery while a Combo button is split into two parts – a button at the top and a gallery at the bottom. To me it seemed natural to call this a Combo button.


  2. I read a lot of interesting posts here. Probably you
    spend a lot of time writing, i know how to save you a lot of
    time, there is an online tool that creates unique, google friendly articles in seconds, just search in google – laranitas free content source

Comments are closed.