Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion docs/reference/controls/border.md
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ You can specify multiple shadows by providing a comma-separated list of shadow d

This table describes the box shadow values, in the order in which they appear:

<table><thead><tr><th width="203">Value</th><th>Description</th></tr></thead><tbody><tr><td><code>inset</code></td><td>If not specified (default), the shadow is assumed to be a drop shadow (as if the box were raised above the content). The presence of the inset keyword changes the shadow to inside the frame (as if the content was depressed inside the box). Inset shadows are drawn inside the border (even transparent ones), and above the background but below any content</td></tr><tr><td><code>offset-x</code> </td><td>Specifies the horizontal distance. Negative values place the shadow to the left of the element.</td></tr><tr><td><code>offset-y</code></td><td>Specifies the vertical distance. Negative values place the shadow above the element.</td></tr><tr><td><code>blur-radius</code></td><td>The larger this value, the bigger the blur effect, so the shadow becomes bigger and lighter. Negative values are not allowed. If not specified, the default (zero) is used and the shadow edge is sharp.</td></tr><tr><td><code>spread-radius</code></td><td>Positive values will cause the shadow to expand and grow bigger, negative values will cause the shadow to shrink. If not specified, it will be 0 (the shadow will be the same size as the element).</td></tr><tr><td><code>color</code></td><td>The color of the shadow using a color name (such as red), or a # prefix and a hexadecimal color value. For example: #dadada</td></tr></tbody></table>
<table><thead><tr><th width="203">Value</th><th>Description</th></tr></thead><tbody><tr><td><code>inset</code></td><td>If not specified (default), the shadow is assumed to be a drop shadow (as if the box were raised above the content). The presence of the inset keyword changes the shadow to inside the frame (as if the content was depressed inside the box). Inset shadows are drawn inside the border (even transparent ones), and above the background but below any content</td></tr><tr><td><code>offset-x</code> </td><td>Specifies the horizontal distance. Negative values place the shadow to the left of the element.</td></tr><tr><td><code>offset-y</code></td><td>Specifies the vertical distance. Negative values place the shadow above the element.</td></tr><tr><td><code>blur-radius</code></td><td>The larger this value, the bigger the blur effect, so the shadow becomes bigger and lighter. Negative values are not allowed. If not specified, the default (zero) is used and the shadow edge is sharp.</td></tr><tr><td><code>spread-radius</code></td><td>Positive values will cause the shadow to expand and grow bigger, negative values will cause the shadow to shrink. If not specified, it will be 0 (the shadow will be the same size as the element).</td></tr><tr><td><code>color</code></td><td>The color of the shadow using a color name (such as red), a # prefix with a hexadecimal color value (e.g., #dadada), or a color function (e.g., rgb(13, 110, 253), hsl(215, 98%, 52%)).</td></tr></tbody></table>
Copy link

Copilot AI Dec 23, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The word "red" should be capitalized to "Red" for consistency. In the description, color names are typically shown in PascalCase in Avalonia documentation.

Copilot uses AI. Check for mistakes.

:::info
If both offset values are set to zero, the shadow is placed behind the element, and will only generate a blur effect if `blur-radius` and/or `spread-radius` are set.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ import BorderDropShadowScreenshot from '/img/reference/controls/border/border-dr

此表描述了盒廓阴影值,按它们出现的顺序:

<table><thead><tr><th width="203">值</th><th>描述</th></tr></thead><tbody><tr><td><code>inset</code></td><td>如果未指定(默认),则假定阴影为投影(如同盒廓被抬高在内容之上)。inset 关键字的存在将阴影更改为框架内部(如同内容被压入盒廓内部)。内嵌阴影绘制在边框内(即使是透明的),并且在背景之上但在任何内容之下</td></tr><tr><td><code>offset-x</code> </td><td>指定水平距离。负值将阴影放置在元素的左侧。</td></tr><tr><td><code>offset-y</code></td><td>指定垂直距离。负值将阴影放置在元素的上方。</td></tr><tr><td><code>blur-radius</code></td><td>此值越大,模糊效果越大,因此阴影变得更大且更轻。负值不允许。如果未指定,则使用默认值(零),阴影边缘是锐利的。</td></tr><tr><td><code>spread-radius</code></td><td>正值将导致阴影扩展和变大,负值将导致阴影收缩。如果未指定,它将为 0(阴影将与元素大小相同)。</td></tr><tr><td><code>color</code></td><td>使用颜色名称(例如红色)或带有 # 前缀的十六进制颜色值的阴影颜色。例如:#dadada</td></tr></tbody></table>
<table><thead><tr><th width="203">值</th><th>描述</th></tr></thead><tbody><tr><td><code>inset</code></td><td>如果未指定(默认),则假定阴影为投影(如同盒廓被抬高在内容之上)。inset 关键字的存在将阴影更改为框架内部(如同内容被压入盒廓内部)。内嵌阴影绘制在边框内(即使是透明的),并且在背景之上但在任何内容之下</td></tr><tr><td><code>offset-x</code> </td><td>指定水平距离。负值将阴影放置在元素的左侧。</td></tr><tr><td><code>offset-y</code></td><td>指定垂直距离。负值将阴影放置在元素的上方。</td></tr><tr><td><code>blur-radius</code></td><td>此值越大,模糊效果越大,因此阴影变得更大且更轻。负值不允许。如果未指定,则使用默认值(零),阴影边缘是锐利的。</td></tr><tr><td><code>spread-radius</code></td><td>正值将导致阴影扩展和变大,负值将导致阴影收缩。如果未指定,它将为 0(阴影将与元素大小相同)。</td></tr><tr><td><code>color</code></td><td>使用颜色名称(例如 Red),或带有 # 前缀的十六进制颜色值,或使用色彩函数(例如 rgb(13, 110, 253)、hsl(215, 98%, 52%))的阴影颜色。例如:#dadada</td></tr></tbody></table>

:::info
如果两个偏移值都设置为零,阴影将放置在元素后面,并且只有在同时或者单独设置了 `blur-radius` , `spread-radius` 时才会生成模糊效果。
Expand All @@ -87,7 +87,7 @@ import BorderDropShadowScreenshot from '/img/reference/controls/border/border-dr
这是一个投影的示例:

```xml
<<StackPanel>
<StackPanel>
<Border Background="Gainsboro"
BorderBrush="Black"
BorderThickness="2"
Expand Down