How can I set a "MinHeight" or "MaxHeight" on unpinned panels?

6 posts, 0 answers
  1. Rob
    Rob avatar
    238 posts
    Member since:
    Jan 2009

    Posted 10 Jun 2011 Link to this post

    I have a fairly simple RadDocking control with a main document host and bottom split container with two tabs...

    <telerik:RadDocking>
      
      <!-- Main Content -->
      <telerik:RadDocking.DocumentHost>
        <telerik:RadSplitContainer>
          <telerik:RadPaneGroup>
            <telerik:RadPane CanUserClose="False" >
      
              <Border Background="YellowGreen" BorderBrush="Green" BorderThickness="3">
                <TextBlock Text="Main" Foreground="Green" FontSize="14" FontWeight="Bold" VerticalAlignment="Center" HorizontalAlignment="Center" />
              </Border>
            </telerik:RadPane>
          </telerik:RadPaneGroup
        </telerik:RadSplitContainer>
      </telerik:RadDocking.DocumentHost>
      
      <!-- Panels (Bottom) -->
      <telerik:RadSplitContainer InitialPosition="DockedBottom" telerik:DockingPanel.InitialSize="1,280" telerik:RadDocking.SerializationTag="SplitBottom" MinHeight="250" >
        <telerik:RadPaneGroup TabStripPlacement="Bottom" TabOrientation="Horizontal">
      
          <!-- Panel 1 -->
          <telerik:RadPane Title="x1" Header="x2" CanUserClose="False" CanFloat="False" CanDockInDocumentHost="False">
      
            <Border Background="LightBlue" BorderBrush="Navy" BorderThickness="3">
              <TextBlock Text="Panel 1" Foreground="Navy" FontSize="14" FontWeight="Bold" VerticalAlignment="Center" HorizontalAlignment="Center" />  
            </Border>
      
          </telerik:RadPane>
      
          <!-- Panel 2 -->
          <telerik:RadPane Title="y1" Header="y2" CanUserClose="False" CanFloat="False" CanDockInDocumentHost="False">
      
            <Border Background="Pink" BorderBrush="Red" BorderThickness="3">
              <TextBlock Text="Panel 2" Foreground="Red" FontSize="14" FontWeight="Bold" VerticalAlignment="Center" HorizontalAlignment="Center" />
            </Border>
      
          </telerik:RadPane>
      
        </telerik:RadPaneGroup>
       
      </telerik:RadSplitContainer>
      
    </telerik:RadDocking>


    I have set the MinHeight property on the RadSplitContainer which seems to restrict the height of the two RadPanes when they are pinned open.  If I however unpin the panes, I am able to change their heights (when hovered and opened of course) to whatever I like...

    How can I restrict the heights to a minimum value when they are pinned and unpinned?

    This is an important feature for me because my RadPanes contain charts which look ridiculous if we allow the user to change the height to a small value...

    Thanks in advance.
  2. Konstantina
    Admin
    Konstantina avatar
    2332 posts

    Posted 16 Jun 2011 Link to this post

    Hi Rob,

    You can check out this forum post in which similar issue is discussed.

    Please let us know how did that worked for you.

    Regards,
    Konstantina
    the Telerik team
    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
  3. DevCraft banner
  4. Rob
    Rob avatar
    238 posts
    Member since:
    Jan 2009

    Posted 02 Dec 2011 Link to this post

    Is it possible to log this as a feature request?  The ability to set a minimum/maximum pane height (when docked at top/bottom) and minimum/maximum pane width (when docked at left/right) when the panes are pinned and unpinned would be of value to at least myself but possibly others.
  5. Konstantina
    Admin
    Konstantina avatar
    2332 posts

    Posted 05 Dec 2011 Link to this post

    Hi Rob,

    We have added an GeneratedItemsFactory which is responsible for creating the ToolWindows. You can create your own ToolWindows and set their size. You can create your own factory and set it to the RadDocking control. For more information and a sample project how to achieve this you can refer to this forum post. This is the best approach if you are aiming to change the size of the dragged panes generally.
    However, if this is not what you are requesting, can you explain in details how do you expect the Docking control to behave and I will log it in PITS for you.

    All the best,
    Konstantina
    the Telerik team
    Explore the entire Telerik portfolio by downloading the Ultimate Collection trial package. Get it now >>
  6. Rob
    Rob avatar
    238 posts
    Member since:
    Jan 2009

    Posted 05 Dec 2011 Link to this post

    I think that forum post is dealing more specifically with dragged toolwindows.  We do not allow the user to drag panels around the screen - we only allow them to pin or unpin them and set the size.  In my application the RadDocking control is failry simple, having one main document host and a handful (1-3) panes docked at the bottom.  When the tabs are pinned, I can define the maximum and minimum heights so the user cannot shoot themselves in the foot and make the panels a silly size.  However, if the user happens to unpin the panels there's doesn't appear to be a setting for the maximum/minimum sizes.  I'd like to restrict the user from simply resizing an unpinned panel to a riduculous height (maximum or minimum).
  7. Konstantina
    Admin
    Konstantina avatar
    2332 posts

    Posted 07 Dec 2011 Link to this post

    Hello Rob,

    I understand your concern.

    I have added your request in PITS. You can view it here. You can vote for it and track its progress.

    Regards,
    Konstantina
    the Telerik team
    Explore the entire Telerik portfolio by downloading the Ultimate Collection trial package. Get it now >>
Back to Top
DevCraft banner