RadScrollBarElement + Larger

7 posts, 0 answers
  1. Bryan Brannon
    Bryan Brannon avatar
    65 posts
    Member since:
    Aug 2012

    Posted 01 Aug 2008 Link to this post

    I have a RadScrollbar (RadVScrollBar) working great except for some sizing problems.

    I want to increase the size of the RadVScrollBar1.  I have increased the size of the .Size property and also adjusted the size of the thumb scroller according to:
    http://www.telerik.com/support/kb/article/b454K-tmh-b454T-ckt-b454c-ckt.aspx

    However, I want to adjust the size of the Up arrow and down arrow.  I want the area of clickability to be larger so it is easer to click on a larger sized control.  Also, is is possible to insert my own (arrow) image to replace the current arrows provided?
  2. Bryan Brannon
    Bryan Brannon avatar
    65 posts
    Member since:
    Aug 2012

    Posted 01 Aug 2008 Link to this post

    I solved part of my problem.  With the RadVScrollbar1 in my form, I clicked the smart-tag and hit Edit UI Elements.

    You can update the ScaleTransform property of the Telerik.WinControls.UI.ScrollBarButton element to modify the size scale.  I updated mine to 1.5 to increase the button size dynamically to 1.5x of the original.

    The last thing is still un-answered is can I replace the default arrow with a custom image.
  3. UI for WinForms is Visual Studio 2017 Ready
  4. Angel
    Admin
    Angel avatar
    121 posts

    Posted 04 Aug 2008 Link to this post

    Hi Bryan Brannon,

    Thank you for the followup.

    Indeed, ScaleTransform will help you achieve what you are after. Alternatively, you could set the Padding or MinSize property for each button, but in that case the arrow will stay small. But you can easily extend the UI with our architecture. You can add an arbitrary element inside the button - see the attached project for a demo how to use the ImagePrimitive inside the scrollbar buttons.

    Note that if you use scaling for the scrollbar buttons, the images inside them will also scale since the ImagePrimitive is a child of a scaled element (the scrollbar button).

      
    Sincerely yours,
    Angel
    the Telerik team

    Check out Telerik Trainer, the state of the art learning tool for Telerik products.
  5. Ben
    Ben avatar
    11 posts
    Member since:
    Dec 2015

    Posted 23 Sep Link to this post

    I came here looking to do the same thing Bryan asked, but was never answered: "The last thing is still un-answered is can I replace the default arrow with a custom image."

    How can I replace the arrow image on the scrollbars?

    I have attempted this but it does not change the image.:

    TableElement.VScrollBar.FirstButton.Image = global::Core.Client.telerik.Properties.Resources.chevron_up_dark;

    TableElement.VScrollBar.SecondButton.Image = global::Core.Client.telerik.Properties.Resources.chevron_down_dark;

     

    Any help would be awesome.

     

    Ben

  6. Hristo Merdjanov
    Admin
    Hristo Merdjanov avatar
    711 posts

    Posted 26 Sep Link to this post

    Hello Ben,

    Thank you for writing.

    The project my colleague submitted provides an example how an image can be added and the default arrows substituted. Could you please check and let me know if you need further assistance.

    I hope this helps. Should you have further questions please do not hesitate to write back.

    Regards,
    Hristo Merdjanov
    Telerik by Progress
    Check out the Windows Forms project converter, which aids the conversion process from standard Windows Forms applications written in C# or VB to Telerik UI for WinForms. For more information check out this blog post and share your thoughts.
  7. Ben
    Ben avatar
    11 posts
    Member since:
    Dec 2015

    Posted 26 Sep in reply to Hristo Merdjanov Link to this post

    Thank you. I will do that today!
  8. Ben
    Ben avatar
    11 posts
    Member since:
    Dec 2015

    Posted 26 Sep in reply to Ben Link to this post

    Thank you very much. The above sample had exactly what I needed.

     

    Ben Marsh

Back to Top
UI for WinForms is Visual Studio 2017 Ready