1
我在Windows上工作的通用應用程序(視窗10)Mobile.I在菜單Flyout.The菜單彈出按鈕的默認寬度查詢其餘同此代碼後不下降:在windows通用應用程序移動版中減小Menu Flyout的大小?
<AppBarButton Icon="OpenWith" Label="More.." Width="55">
<AppBarButton.Flyout>
<MenuFlyout>
<MenuFlyout.MenuFlyoutPresenterStyle>
<Style TargetType="MenuFlyoutPresenter">
<Setter Property="Margin" Value="0,-31,0,0" />
<Setter Property="Background" Value="#FFE45427" />
<Setter Property="FontSize" Value="12" />
<Setter Property="BorderBrush" Value="Transparent" />
<Setter Property="MinWidth" Value="70" />
</Style>
</MenuFlyout.MenuFlyoutPresenterStyle>
<MenuFlyoutItem Text="Logout" FontSize="13" Padding="8,8,0,8" Click="MenuFlyoutItem_Click" />
<MenuFlyoutItem Text="Sales" FontSize="13" Padding="8,8,0,8" Click="appbarsales_Click" />
</MenuFlyout>
</AppBarButton.Flyout>
</AppBarButton>
圖片:
您是否試過[this](http://stackoverflow.com/questions/32948697/tooglemenuflyout-and-menuflyoutpresenterstyle-set-width-windows-10-mobile)? –
@AlexejSommer:是的。我也試過這個東西,但我想減少我的菜單飛出寬度only.I可以輕鬆地增加寬度,但我不知道如何減少寬度,所以善意建議一個更好的方式,如果你知道。 –