MJW Posted February 17, 2020 Share Posted February 17, 2020 I have a use for a pan slider control with no background image. I simply want a square with either a white or (preferably) colored background. I could create an appropriately-sized bitmap, fill it with the desired color, and call: ImageResource bgImage = ImageResource.FromImage(bitmap); configUI.SetPropertyControlValue(name, ControlInfoPropertyNames.StaticImageUnderlay, bgImage); There are at least two reasons I'd prefer a different approach if one exists. First, since it's a bitmap, I assume I should dispose of it when the effect exits, which prevents me (as far as I can see) from creating it at the low level of the call that configures the control. Second, I want to make the bitmap as small as possible, while still creating a full-sized rectangle in the control. That seems like it might depend on the screen resolution, which would prevent me from determining the correct size through trial and error. If I just want a white background, I can leave off the SetPropertyControlValue call. That works, except it creates a rectangle without a border. I want a border. Is there a way, other than using a bitmap, to create a pan slider control with a blank background and a border? And if not, how do I determine the correct size for the bitmap, so that it works with all displays? Quote Link to comment Share on other sites More sharing options...
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.