سؤال

Using windows forms PropertyGrid control I can add images into select for any property using some UI type converters, etc. This control adds black border for each picture in the list. Does anybody know how to remove it?

See the samples of desired and existing picture here

enter image description here

and

enter image description here

هل كانت مفيدة؟

المحلول

Use the following line of code in your custom UITypeEditor class before drawing the image:

e.Graphics.ExcludeClip(e.Bounds);
مرخصة بموجب: CC-BY-SA مع الإسناد
لا تنتمي إلى StackOverflow
scroll top