"is it possible to use a converter within a style?" Code Answer

3

yes, this is possible. for example:

<style targettype="textblock">
    <setter property="fontsize">
        <setter.value>
            <binding path="actualheight" relativesource="{relativesource self}">
                <binding.converter>
                    <myconverter/>
                </binding.converter>
            </binding>
        </setter.value>
    </setter>
</style>

depending on your exact scenario, you might also be able to use the more succinct:

<style targettype="textblock">
    <setter property="fontsize" value="{binding actualheight, relativesource={relativesource self}, converter={staticresource myconverter}}"/>
</style>
By z.shan on June 24 2022

Answers related to “is it possible to use a converter within a style?”

Only authorized users can answer the Search term. Please sign in first, or register a free account.