wpf - How to make image not stretch? -
[imgur deleted image]
the icon on left result of code:
<button height="23" horizontalalignment="left" margin="12,276,0,0" name="button1" verticalalignment="top" width="75"> <stackpanel orientation="horizontal"> <image source="resources/add.png" stretch="none" /> <textblock margin="5,0,0,0" text="add" /> </stackpanel> </button>
the 1 on right original image placed beside using photoshop. appears 1 added via code stretched pixel causing distortion. how prevent that?
stretch="none"
should that. if there difference in how image displayed may due pixels ending "on edge".
you try setting snapstodevicepixels
="true"
avoid this.
Comments
Post a Comment