Windowscommunitytoolkit: DropShadowPanel streched in a Viewbox

Created on 19 Jul 2018  路  17Comments  路  Source: windows-toolkit/WindowsCommunityToolkit

Hi Guys,

If I put a DropShadowPanel inside of a Viewbox with Strech="Fill" the DropShadowPanel doesn't work like expected here.

Take a look on my Screenshots for this:

image

image

You can use the following SourceCode to check this:

<Viewbox Stretch="Fill" HorizontalAlignment="Stretch" VerticalAlignment="Stretch" Margin="100,100,100,100">
            <Grid>
                <extControls:DropShadowPanel ShadowOpacity="1"
                                  BlurRadius="10"
                                  Color="Black"
                                  x:Name="MyShadow">
                    <Rectangle x:Name="Rect" Fill="Red" Width="100" Height="100" />
                </extControls:DropShadowPanel>
            </Grid>
        </Viewbox>

Best Regards
Thilo

bug controls help wanted

All 17 comments

Hi Thilo, thanks for reporting the issue! @hermitdave is there a chance you can take a look at this?

Hi @kbrons @hermitdave

frist of all thanks for your help.
I just wanted to ask if you're working on this issue :)

Best Regards
Thilo

I'm out of town at present with little computer time. I'll look at our next week

Apologies

Hermit

Thank you for the information.

Thilo

Chaps, my VS / machine is busted.. despite Reset and VS installation I cannot build the toolkit solution. I sadly cannot have a look until I sort it out.

Apologies

@hermitdave, are you able to take a look at this now?

Let me try a full solution compile.. if it works then definitely

I can't reproduce the issue on the current codebase
dropshadowpanel2
dropshadowpanel1

@hermitdave, try it in a blank app and make sure the rectangle is not square. Here is what it looks like for me with the latest codebase and the repro code provided:

image

I have a repro and I'm looking into it. I've also reached out to composition team.

Having talked to composition team they can repro the same and are looking at Viewbox Fill option. They suggested that others should work

However the only one that works correctly is Uniform.

UniformToFill generates dropshadow that hides fully behind the content it is supposed to shadown.

Another suggestion is using CustomMask option rather than GetAlphaMask. This needs to be looked at further.

I have also tried is setting size to the grid that contains the DropShadowPanel and that works slightly better. Fill option though is no better.

@ThiBro @hermitdave any update on this? Was this resolved?

I suppose asking is easier than reading through the conversation

I have read the conversation but not certain what was decided since the convo goes back to 2018. Whether there was any resolution or not other than the convo mentioned above?

@Kyaa-dost for me it was not fixed. I just accepted the bug :)

@ThiBro Thank you so much for the update 馃檪

Was this page helpful?
0 / 5 - 0 ratings