Scrollbar appearance in Spread 4.0

Posted by: dkennedy on 8 September 2017, 1:16 pm EST

  • Posted 8 September 2017, 1:16 pm EST

    I would like to configure the scrollbars in Spread 4.0 to appear like they did in Spread 2.5; i.e., take on the Windows theme appearance.  I have tried applying all the different scrollbar renderer options available but the default renderer looks like the old-old Spread, and the enhanced renderer doesn't match the scrollbar appearance on any other controls.


    I've search the Spread documentation, and all I can find is a cryptic note: "The scroll bars are children controls rendered by Visual Studio. To have them render with XP themes, you would need to set up a manifest for your application."  There are no instructions I can find that describes how to do this.  I found a link to an old gotdotnet.com article that explains how to do it, but the link is dead, and I'm not even sure if it applies to VS 2008.


    Can someone tell me how to get the scrollbars to display using the standard Windows appearance?  Thanks!

  • Replied 8 September 2017, 1:16 pm EST

    Bob,


    Thanks for the info.  Unfortunately, this does not appear to do anything.  The information appears to be ancient history (applicable to Visual Studio pre-2005, I guess, and .NET Framework 1.1).  The


    System.Windows.Forms.Application.EnableVisualStyles();


    method seems to supercede all this, and the docs on this method seems to confirm it.  (You might want to update the Spread docs to remove the reference to adding a manifest.)


    So, I guess my question is still:  Does anyone have information on how to make the scrollbars in Spread take on the standard Windows appearance, as in Spread 2.5?


    Thanks!


    P.S. The more I look at this, the more this appears to be a bug.  Spread 4.0 does not appear to be honoring the UseVisualStyles setting in the case of the scrollbars.  In other words, if I have the grid and/or sheet set to NOT use visual styles and to use the Classic skin (or default renderer), then the scrollbars should be the old flat-style gray bars.  This is clearly seen in combobox cells, which work properly.  When UseVisualStyles is true, then the scrollbars should get the themed appearance.  Combobox cells do this, but the scrollbars on the grid do not.  Older versions of Spread worked correctly, but 4.0 scrollbars are either the flat/gray style or are the Excel 2007 style, never the theme style.

  • Replied 8 September 2017, 1:16 pm EST

    Hello,


    There are only two scrollbars that we have built in to the Spread (EnhancedScrollBarRenderer and DefaultScrollBarRenderer). If you would like to paint your own scrollbar, you can create a custom class that implements the FarPoint.Win.Spread.IScrollBarRenderer interface.

  • Replied 8 September 2017, 1:16 pm EST

    Um, no thanks.  I just want the scrollbars take on the themed XP/Vista appearance like they did in earlier versions of Spread (2.5, for example).  App developers shouldn't have to render these scrollbars, it should be part of Spread.
  • Replied 8 September 2017, 1:16 pm EST

    Hello,


    Looknig into the code for the new Spread scrollbars, when you choose the DefaultScrollBarRenderer, we should be using the Visual tyles setting for painting and we are not. This has been reported as a bug and will be fixed in the next maintenance release.

  • Replied 8 September 2017, 1:16 pm EST

    Thanks, Scott.  I submitted a bug report (private question) on this one before I saw your reply (ticket #13335), sorry about that.
Need extra support?

Upgrade your support plan and get personal unlimited phone support with our customer engagement team

Learn More

Forum Channels