microsoft / microsoft/microsoft-ui-xaml
Padding on ItemsView clips items
- Dominant language
- C++
- Stars
- 8.4k
- Forks
- 942
- Avg merge
- 2d 7h
- Merged PRs (30d)
- 105
Description
### Describe the bug
I'm having a horizontal ItemsView that is scrollable. I want the items inset horizontally by 8 points so that they don't hug the window border. But when they are scrolled out of the view, the items should not clip at that 8 point padding, they should expand beyond the padding, and only clip at window edge. This works as expected when using ListView and a horizontal `ItemsStackPanel`
### Steps to reproduce the bug
```
```
Example project: [test.zip](https://github.com/user-attachments/files/20775053/test.zip)
### Expected behavior
The ItemsView does not clip its items at the padding specified
### Screenshots

### NuGet package version
WinUI 3 - Windows App SDK 1.8 Experimental 1: 1.8.250515001-experimental2
### Windows version
Windows 11 (24H2): Build 26100
### Additional context
_No response_
Contributor guide
Research direction
Start by running the linked test.zip example with the shown ItemsView markup and horizontal StackLayout, then compare its scrolling and clipping with the described ListView behavior. Verify that ItemsView Padding="8,0" still insets the items while clipping occurs only at the window edge; the issue is done when the expected scrolling behavior is reproduced and confirmed.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- cpp
- Domain
- desktop, frontend
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100