Relative Content

Tag Archive for c#winui-3

WinUI 3 touchpad doesn’t fire PointerWheelChanged

I’m trying to implement custom zoom on image in WinUI 3 using ScrollView. Its standard zoom is working with pinching on touchpad but not on mouse wheel. So I decided to use PointerWheelChanged to handle zoom using wheel but for this to work I needed to set VerticalScrollMode="Disabled". Now zoom on mouse wheel works fine but two finger scrolling with touchpad doesn’t work at all. It doesn’t fire PointerWheelChanged and scrolling with it doesn’t work, because vertical scroll is disabled.

WinUI3 bind Grid size to Window Size in ContentControl

I’m trying to use WinUI3 with MVVM.
For that case, I’m using a Content Control to bind the view model.
But the Content Control seems to break automatic resize of the inner Grid.
So I’m trying to bind the grid to the window size, but this does not work properly, when the window size changes.

WinUI3: how to set disabled button background

So I’m adding buttons via code to the grid, when some button is clicked i want to disable it and set background color to green or other, background should be set only to that one clicked button. But no matter what disabled button have transparent background.

Displaying children item of Listview

I had a demo for list view to display menu having parent and child. I simply added items into list view, but the result is only parent item is showing. How can I get to show my list view including both parent and children items?
My debug result is having 2 child items in parent. But can’t display. Is it binding problem?

Displaying children item of Listview. (Winui3 c#)

I had a demo for list view to display menu having parent and child. I simply added items into list view but the result is only parent item is showing. How can I get to show my list view including both parent and children items?