Right align Chunks in RadRibbon

5 posts, 1 answers
  1. me
    me avatar
    3 posts
    Member since:
    Aug 2007

    Posted 24 Jun 2008 Link to this post

    I tried to right align the chunks in the RadRibbon.. but only got them to reverse their order, still all the chunks are left aligned.. can you help?
  2. Peter
    Admin
    Peter avatar
    1148 posts

    Posted 25 Jun 2008 Link to this post

    Hi me,

    Thank you for your interest in RadRibbonBar.

    The RadRibbonBar is not designed to allow right-aligned RibbonBar chunks. The RadRibbonBar merely provides the best arrangement of the chunks from left to right for every possible size of the application window.

    I hope this helps. If you have any other questions, please contact me.

    Greetings,
    Peter
    the Telerik team

    Instantly find answers to your questions at the new Telerik Support Center
  3. UI for WinForms is Visual Studio 2017 Ready
  4. me
    me avatar
    3 posts
    Member since:
    Aug 2007

    Posted 25 Jun 2008 Link to this post

    Isn't there any workaround/hack to at least simulate the right to left alignment? like umm.. adding an invisible chunk to fill the space on the left?
  5. Answer
    Nikolay
    Admin
    Nikolay avatar
    1803 posts

    Posted 26 Jun 2008 Link to this post

    Hello,

    There are two workarounds which I can suggest in order to make your chunks right-aligned. I would recommend using the second one:
    1. As per your proposal, you can add several chunks and set their Visibility property to Hidden. Please note that you should do it in the Form_Shown or at a later moment of your application cycle:
      private void Form1_Shown(object sender, EventArgs e)  
      {  
          this.radRibbonBarChunk1.Visibility = Telerik.WinControls.ElementVisibility.Hidden;  
          this.radRibbonBarChunk2.Visibility = Telerik.WinControls.ElementVisibility.Hidden;  
    2. RadRibbonBarChunks are hold by a StackLayoutPanel. You should set its Alignment property to TopRight:
      ((StackLayoutPanel)this.radRibbonBarChunk1.Parent).Alignment = ContentAlignment.TopRight; 

    If you have additional questions, feel free to contact me. 

    All the best,

    Nikolay
    the Telerik team


    Instantly find answers to your questions at the new Telerik Support Center
  6. me
    me avatar
    3 posts
    Member since:
    Aug 2007

    Posted 26 Jun 2008 Link to this post

    Worked like a charm.. you're the best :)
Back to Top
UI for WinForms is Visual Studio 2017 Ready