I've got the following scenario:
div.container {
min-width: 500px;
}
div.container div.left {
}
div.container div.right {
}
<div class="container">
<div class="left">Fill-me</div>
<div class="right">As-needed-only, align right</div>
</div>
I need the second div to be right-aligned in a row and be only as wide as needed, and left one to fill remaining space on the left. How can I achieve that?
ASCII-art:
[ Fill-me ][As-needed-only, align right]
XAML version of what I want to achieve:
<DockPanel>
<Grid DockPanel.Dock="Right">
<TextBlock>Right</TextBlock>
</Grid>
<Grid> <!-- Will fill rest of space -->
<TextBlock>Left</TextBlock>
</Grid>
</DockPanel>