xaml - Fill width on Windows Phone 8.1 -
i'm developing application using windows phone 8.1 sdk, write ui descriptions using xaml
markup.
i can't text box fill width.
i see similar questions posted involve listview.
i'm confused. there seems no proportional sizing options. tutorials show use of explicit pixel counts in design.
is preferred method on windows? how supposed deal unpredictable screen sizes in windows?
the items had, failing fill parent, inside contentcontrol
. contentcontrol
correctly filled width, child, grid
, not.
i found solution here – https://stackoverflow.com/a/17627257/5476004 – , echo solution here in case post found else searching same problem.
the contentcontrol
requires 2 special properties in order child element fill parent. horizontalcontentalignment
, verticalcontentalignment
. so":
<contentcontrol name="mycontent" horizontalcontentalignment="stretch" verticalcontentalignment="stretch"> … </contentcontrol>
fill occurs correctly.
Comments
Post a Comment