Button template with image and text in wpf -
i want create buttons images , text inside. example, use different images , text buttons 'browse folders' , 'import'. 1 of options use template. had @ simliar question
creating image+text button control template?
but there way can bind source of image without using dependency property or other class?
thanks
no. bind image.source
to? need dependencyproperty this. of course, define normal class contains 2 properties: text
, imagesource
or uri
, , use datatemplate render instances of class, more code write, , little "smelly".
what reason not want use dependency property or custom class?
Comments
Post a Comment