question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Dialog does not size to content

See original GitHub issue

This is an issue I have not been able to repeatably reproduce and I mostly see it in production. I’m not sure how to troubleshoot it so any pointers would be appreciated.

I use a single dialog host in the “shell” view:

<UserControl>
    <Grid>
      <mdt:DialogHost Name="ShellDialogHost" Identifier="ShellDialog" UseLayoutRounding="True" >
    </Grid>
</UserControl>

Dialogs are opened by calling DialogHost.Show.

Most of the time the dialogs are opened with the correct size but sometimes they open like this:

file-259

Issue Analytics

  • State:open
  • Created 4 years ago
  • Comments:22 (21 by maintainers)

github_iconTop GitHub Comments

1reaction
mgnslndhcommented, Aug 21, 2019

The window is always full screen. I’m using a view model and a data template. Most of the time it works. Some times it doesn’t and then mostly in production.

0reactions
Isaac-r00tead0commented, Mar 15, 2023

Hi everyone, in my case occurs with ColorZone ONLY if the DialogMargin property is not settled as 0 in the DialogHost tag. image

If DialogMargin is settled, the behavior disappears image

Read more comments on GitHub >

github_iconTop Results From Across the Web

Make MUI dialog content size follow the size of the content
You can change the width of Dialog by using maxWidth attributes. There are 5 different dialog width that you can choose from, xs,...
Read more >
MdDialog not resizing height to contents on open #2351
Given that I've removed the styles and tried this, I do think that it is a md2 problem. Moreover, it appears that the...
Read more >
Content dialog size is getting changed with window scalling
Hi Team, Its a winui3 application - Content dialog size is getting changed with window scaling. Error scenario. 1.Window scalling 2.height ...
Read more >
modal windows - Remember dialog sizes or not?
A lot of program dialogs can be resized. Some programs remember the new size of the dialog after you've resized it. So next...
Read more >
wrong calculation of dialog content width and height with ...
It seems that problem occurs with theme "start" because I could not make a jsFiddle showing it. My dialog is very simple, At...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found