View Issue Details

IDProjectCategoryView StatusLast Update
0003664NoesisGUIC++ SDKpublic2026-09-10 18:32
ReporterFrancoisRecisio Assigned Tosfernandez  
PriorityhighSeveritymajor 
Status resolvedResolutionfixed 
Product Version3.2.4 
Target Version3.2.14Fixed in Version4.0.1 
Summary0003664: DropShadowEffect are not included in the object's bounds and overwrite the other drawn items in the same RT
Description

See attached files

Attached Files
DemoShadowRT.xaml (1,174 bytes)   
<Grid
  xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
  xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
  xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
  xmlns:noesis="clr-namespace:NoesisGUIExtensions;assembly=Noesis.GUI.Extensions"
  Background="#FF124C7A">
	<Viewbox>
		<Grid Width="200">
            <StackPanel>
                <Grid Opacity="0.75">
                    <TextBlock
                        Text="Hello world"
                        Foreground="#FFFFFF"
                        HorizontalAlignment="Center" VerticalAlignment="Center"
                        FontWeight="Bold" FontSize="8">
                    </TextBlock>
                </Grid>
                <Grid x:Name="Src" Opacity="0.5">
                    <Border Background="White" CornerRadius="30" Width="60" Height="60">
                        <Rectangle.Effect>
                            <DropShadowEffect BlurRadius="0" ShadowDepth="15" Opacity="1" />
                        </Rectangle.Effect>
                    </Border>
                </Grid>
            </StackPanel>
		</Grid>
	</Viewbox>
</Grid>
DemoShadowRT.xaml (1,174 bytes)   
rt.png (12,424 bytes)   
rt.png (12,424 bytes)   
PlatformAny

Relationships

related to 0003553 assignedjsantos Strokes and shadows are broken when used together 

Activities

jsantos

jsantos

2024-08-28 16:40

manager   ~0009919

Last edited: 2024-08-28 16:41

The opacity in the Grid named "Src" is causing this artifact.

As a workaround you can move that opacity inside, it is also a good optimization change.

FrancoisRecisio

FrancoisRecisio

2024-08-28 16:47

reporter   ~0009920

That's what I do, yes. But I noticed the problem because the different screens in our UI fade in and fade out, and the opacity is animated on the full blocks.

FrancoisRecisio

FrancoisRecisio

2025-04-28 15:04

reporter   ~0010543

I hadn't mentioned it, but the problem also exists for strokes

stroke.xaml (878 bytes)   
<Grid
  xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
  xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
  xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
  xmlns:noesis="clr-namespace:NoesisGUIExtensions;assembly=Noesis.GUI.Extensions"
  Background="#FF124C7A">
	<Viewbox>
		<Grid Width="200">
            <StackPanel>
                <Grid Opacity="0.75">
                    <TextBlock
                        Text="Hello world"
                        Foreground="#FFFFFF"
                        HorizontalAlignment="Center" VerticalAlignment="Center"
                        FontWeight="Bold" FontSize="8"
                        noesis:Text.Stroke="Black" noesis:Text.StrokeThickness="4">
                    </TextBlock>
                </Grid>
            </StackPanel>
		</Grid>
	</Viewbox>
</Grid>
stroke.xaml (878 bytes)   
image.png (13,665 bytes)   
image.png (13,665 bytes)   
sfernandez

sfernandez

2026-01-19 13:34

manager   ~0011702

There is a workaround for the issues you are describing with texts (both with italics bounding box, and stroked texts).

The idea is to grow (with padding) the text with its background (using a transparent brush) to account for the italic/stroke:

<Grid
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:noesis="clr-namespace:NoesisGUIExtensions;assembly=Noesis.GUI.Extensions"
Background="#FF124C7A">
  <Viewbox>
    <Grid Width="100">
      <TextBlock
        Text="Outline"
        Background="Transparent"
        Foreground="#FFFFFF"
        HorizontalAlignment="Center"
        FontWeight="Bold" FontSize="16"
        noesis:Text.Stroke="#000000" noesis:Text.StrokeThickness="2" Padding="2" Margin="-2">
        <TextBlock.Effect>
          <DropShadowEffect BlurRadius="0" ShadowDepth="20" Opacity="1" />
        </TextBlock.Effect>
      </TextBlock>
    </Grid>
  </Viewbox>
</Grid>

Could that work with you?

FrancoisRecisio

FrancoisRecisio

2026-01-26 11:01

reporter   ~0011765

I hadn't thought of doing that, thank you. I think that will do the trick for now :)

sfernandez

sfernandez

2026-09-10 18:29

manager   ~0012590

Last edited: 2026-09-10 18:32

DropShadowEffect leaking to other opacity groups fixed in changeset r18067.

I leave 0003553 open because it is a different issue.

Issue History

Date Modified Username Field Change
2024-08-28 16:26 FrancoisRecisio New Issue
2024-08-28 16:26 FrancoisRecisio File Added: DemoShadowRT.xaml
2024-08-28 16:26 FrancoisRecisio File Added: rt.png
2024-08-28 16:35 jsantos Assigned To => sfernandez
2024-08-28 16:35 jsantos Status new => assigned
2024-08-28 16:35 jsantos Target Version => 3.2.5
2024-08-28 16:40 jsantos Note Added: 0009919
2024-08-28 16:41 jsantos Note Edited: 0009919
2024-08-28 16:47 FrancoisRecisio Note Added: 0009920
2024-10-24 16:43 sfernandez Target Version 3.2.5 => 3.2.6
2024-11-14 17:42 jsantos Priority normal => high
2024-11-22 18:18 jsantos Target Version 3.2.6 => 3.2.7
2025-01-20 17:43 jsantos Target Version 3.2.7 => 3.2.8
2025-04-28 15:04 FrancoisRecisio Note Added: 0010543
2025-04-28 15:04 FrancoisRecisio File Added: stroke.xaml
2025-04-28 15:04 FrancoisRecisio File Added: image.png
2025-04-30 11:31 sfernandez Relationship added related to 0003553
2025-06-06 12:52 jsantos Target Version 3.2.8 => 3.2.9
2025-10-02 00:48 jsantos Target Version 3.2.9 => 3.2.10
2025-10-20 18:25 jsantos Target Version 3.2.10 => 3.2.11
2026-01-19 13:34 sfernandez Status assigned => feedback
2026-01-19 13:34 sfernandez Note Added: 0011702
2026-01-20 19:32 jsantos Target Version 3.2.11 => 3.2.12
2026-01-26 11:01 FrancoisRecisio Note Added: 0011765
2026-01-26 11:01 FrancoisRecisio Status feedback => assigned
2026-03-04 00:39 jsantos Target Version 3.2.12 => 3.2.13
2026-04-27 12:17 jsantos Target Version 3.2.13 => 3.2.14
2026-09-10 18:29 sfernandez Status assigned => resolved
2026-09-10 18:29 sfernandez Resolution open => fixed
2026-09-10 18:29 sfernandez Fixed in Version => 4.0.1
2026-09-10 18:29 sfernandez Note Added: 0012590
2026-09-10 18:32 sfernandez Note Edited: 0012590
2026-09-10 18:32 sfernandez Note Edited: 0012590