Skip to main content
0 votes
0 answers
20 views

Long term file access on Avalonia cross platform application

I am trying to make an Avalonia cross platform application that lets you pick one or multiple images with a file picker. Once the images are selected, i store the file path into a collection that the ...
Alessandro Valentino's user avatar
0 votes
2 answers
57 views

How to add binding to the button inside DataGrid?

I don't understand how to add binding to the button inside DataGrid. Can you please help me? What I have: I can connect any simple button and I can give it some functionality. But when I want to do a ...
oao's user avatar
  • 3
0 votes
1 answer
29 views

Input to focused TextBox in Avalonia MVVM app

I am writing and application for a touchscreen, using .NET 8, Avalonia UI and Community toolkit MVVM. In my view I have three TextBoxes. I have created a UserControll which is a numpad that will be ...
pastor_j's user avatar
0 votes
0 answers
23 views

Apply to user control a style using converter with multiple values and value sources

I am working in Avalonia and have a user control (UC) whose IsVisible value I want to bind to properties of both its DataContext and that of the parent control. In the parent control/view I have an ...
Eric Eggers's user avatar
0 votes
0 answers
39 views

The problem of memory leakage when closing the window

The essence of my program is to create a window for all screens through the tray. In this case, the main program flow ends when the tray is closed. The bottom line is that when creating and closing a ...
callsign_332's user avatar
0 votes
1 answer
42 views

Styling Avalonia Slider Conntrol

I would like to style the sizes and colors of Avalonia Slider Control. Visually it seems to work but it stops the sliding functionailty, I tried to look at the Slider source code to find out how to do ...
tridy's user avatar
  • 1,248
0 votes
0 answers
25 views

Does ObservableCollection support cross thread use in Avalonia?

I am a novice to Avalonia. I've encountered with InvalidOperationException and I've found that's because I called ObservableCollection.Add() in another thread.I used Dispatcher.UIThread.Invoke() and ...
xlxdd's user avatar
  • 11
2 votes
2 answers
58 views

How to bind multiple controls to a single model value in Avalonia UI MVVM without making the model object contain [ObservableProperty]

When using MVVM Community Toolkit, C#, .NET and Avalonia UI, I find myself making my model objects observable because it solves a recurring problem that I encounter when editing a model value from ...
Daniel Farrell's user avatar
0 votes
1 answer
51 views

Avalonia DataContext is null in code behind

I have the following application structure: Views: MainWindow MainView View1 View2 ViewModels: MainViewModel MainWindow: <Window xmlns="https://github.com/avaloniaui" xmlns:x=&...
user107586's user avatar
-2 votes
1 answer
28 views

Setting DataGrid SelectedItem does not select item in grid

I have an Avalonia DataGrid. ItemSource and SelectedItem are binded in axaml. After i refresh collection DataGrid loses focus and SelectedItem becomes null. I want to get selected item back on ...
Sfairait's user avatar
1 vote
1 answer
42 views

In Avalonia, how do I calculate the size of a text without rendering it?

I'm using Avalonia 11.1 and I'd like to know the size of my TextBlock's content before actually rendering it, so that I can align components properly in one go. I can't find any ready-to-use function ...
cboittin's user avatar
  • 341
-1 votes
1 answer
73 views

Global keyboard shortcut with windows key on Windows with .NET 8

I am writing an app switcher inspired by Contexts kind of for fun, and got stuck on reacting to a global keyboard shortcut. I am using .NET 8 + Avalonia. What I got so far: using System; using System....
Krzysztof Skowronek's user avatar
0 votes
0 answers
31 views

How to recursively read folders with Avalonia StorageProvider (Android)

I am letting a user chose a folder on the device through topLevel.StorageProvider.OpenFolderPickerAsync. When the folder gets returned succesfully, i use the following code to try to read all ...
Alessandro Valentino's user avatar
0 votes
1 answer
65 views

How to draw on a canvas in avalonia?

I am learning Avalonia for a small project and I really enjoy it, but I can't find much documentation on drawing in a canvas. My goal is very simple: to draw a grid on my canvas... However, every time ...
Zartox29's user avatar
0 votes
0 answers
43 views

Avalonia Binding not updating

why is my binding not working correctly, its grabbing the value once but never updating after this.RaisPropertyChanged... public ScreenViewModel Screen => screen; public bool SetScreen(...
trashhacker's user avatar

15 30 50 per page
1
2 3 4 5
37