XAML元素未在其他某些设备上正确对齐 [英] XAML elements not getting aligned properly on some other devices

查看:167
本文介绍了XAML元素未在其他某些设备上正确对齐的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在我的应用程序中,我有一个网格,我在网格中有几行,每个网格行都有元素。问题是,当它来到普通的硬件按钮手机时,应用程序UI非常适合但在手机中那些有软件按钮看起来会喜欢跟随软件
导航按钮隐藏。那么如何在软件导航最小化时正确对齐这些元素?我希望在软件导航最小化时删除空间。






我的XAML网格c代码是:

< Grid x:Name =" RootGrid"> 
< Grid.RowDefinitions>
< RowDefinition Height =" 70" />
< RowDefinition Height =" 110" />
< RowDefinition Height =" 77 *" />
< RowDefinition Height =" 45 *" />
< RowDefinition Height =" 1 *" />
< /Grid.RowDefinitions>

<! - 内容在这里 - >

< / Grid>






Dileepa S. Rajapaksa

------------- --------------------

见习开发人员

微软,斯里兰卡


----------------

Twitter:@dsrajapaksa

博客:http:// www .dileepatech.net

解决方案

Hello Dileepa,


欢迎来到MSDN论坛,我建议您查看

本指南发布
为主题标题添加适当的标记,让我们更清楚地了解您的问题。


>>那么当软件导航最小化时如何正确对齐这些元素?


是您是否通过项目中的某些代码隐藏了软件导航?如果是这样,我的建议是,当您尝试隐藏导航栏时,可以通过设置其边距值来调整这些XAML元素。


问候。


In my app i have a grid and i have few rows in the grid each grid row has elements. The problem is when it's come to normal hardware button phone the apps UI fits well but in the phones those has software buttons will looks likes follows when the software navigation buttons hidden. So how to align these elements properly when the software navigation minimized ? I want to remove the space when the software navigation is minimized.

My XAML grid c code is :

    <Grid x:Name="RootGrid">
        <Grid.RowDefinitions>
            <RowDefinition Height="70" />
            <RowDefinition Height="110" />
            <RowDefinition Height="77*"/>
            <RowDefinition Height="45*"/>
            <RowDefinition Height="1*"/>
        </Grid.RowDefinitions>

<!-- Content goes here -->

</Grid>


Dileepa S. Rajapaksa
---------------------------------
Trainee Developer
Microsoft, Sri Lanka

----------------
Twitter : @dsrajapaksa
Blog : http://www.dileepatech.net

解决方案

Hello Dileepa,

Welcome to the MSDN forum and I would suggest you could check this guide post to add a proper tag for the thread title to let us understand your problem clearer.

>>So how to align these elements properly when the software navigation minimized?

Is that you hide the software navigation via some code in your project? If so, my suggestion is that when you are trying to hide the navigation bar, you could adjust these XAML elements by setting their margin values.

Regards.


这篇关于XAML元素未在其他某些设备上正确对齐的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆