Windows Phone 7 中的透明按钮



我想让我的按钮透明。 im 做不透明度 0 但它对我不起作用。如何使我的按钮在正常和按下状态下透明。

<Button VerticalAlignment="Top" HorizontalAlignment="Left" Width="140"  Height="80" Margin="0,240,0,0" >
                <StackPanel Orientation="Horizontal">
                    <Image Source="/Images/Search.png"/>
                </StackPanel>
</Button>

您是否希望使用搜索.png图像作为按钮?

如果是,为什么不挂接到 MouseLeftButtonDown 事件来执行特定操作。

我不确定通过想要用图像替换整个按钮控件,然后使按钮本身透明来获得什么。

如果您想要按钮的所有功能,但希望它看起来像图像,则应考虑使用 Expression Blend 使您的按钮看起来像您想要的样子。

下面是如何执行此操作的演练。 http://www.c-sharpcorner.com/uploadfile/cd80b9/creating-a-custom-button-from-an-image-in-expression-blend/

最新更新