Categories > Coding > C# >
DropShadow applies to Child Elements
Posted
Mods forgive me for posting XAML related stuff in C#, i don't have an other choice.
I want to add an shadow around the Window. I tried this piece of code
<Grid.Effect>
<DropShadowEffect BlurRadius="15" Direction="-90"
RenderingBias="Quality" ShadowDepth="2"/>
</Grid.Effect>
Instead of it applying to an Shadow around my Window, it applies to the Child Elements of the Grid. What am i doing wrong?
Who's Deez?
Replied
use a border or something for the window instead of grid, then do border.effect and apply the drop shadow effect.
example make the grid tag just <grid><border background="#121212"></grid> that should work C:
Cancel
Post
Replied
@55258 I tried that, this only gives me an 90 Degree Shadow, but i want it to go fully around the Window.
Cancel
Post
Who's Deez?
Replied
he said he wanted a drop shadow around the window not around the grid items.
Anyway to fix this you will need to use a border instead of an actual microsoft windowstyle, do windowstyle="none", resizemode as noresize and then do allowstransparency as true and get started
Cancel
Post
https://cdn.discordapp.com/attachments/995469995742068832/1073019970012848228/Untitled39_20220604185345.png
Who's Deez?
Users viewing this thread:
( Members: 0, Guests: 1, Total: 1 )
Cancel
Post