Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

After upgrading to version 11.2.1, the usercontrol response speed has become very slow. #17585

Open
nipeone opened this issue Nov 22, 2024 · 1 comment

Comments

@nipeone
Copy link

nipeone commented Nov 22, 2024

Describe the bug

I designed a usercontrol to display search images and text content. Each page shows 20 records, and each record is wrapped in the usercontrol. With version 11.2.0, resizing the mainform was very smooth, but after upgrading to version 11.2.1, the response speed has significantly slowed down, and it feels very laggy.

To Reproduce

<UserControl xmlns="https://github.com/avaloniaui"
             xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
             x:Class="OmnipocketLiteAvalonia.SearchResultItem">
    <Border BorderBrush="{DynamicResource SystemControlForegroundBaseMediumBrush}" 
            BorderThickness="1" Margin="0,0,0,10" Padding="10" CornerRadius="15">
        <Grid ColumnDefinitions="Auto,*">
            <Image Grid.Column="0"
				   x:Name="DocTypeImage"
				   Width="64"
				   Height="64"
				   Margin="0,0,10,0" />
            <StackPanel Grid.Column="1">
                <TextBlock x:Name="TextContent"
						   TextWrapping="Wrap"
                           Foreground="{DynamicResource SystemControlForegroundBaseHighBrush}"
                           Margin="0,0,0,5"/>
                <Separator Height="1"
						   Margin="0,5,0,5"
                           Background="{DynamicResource SystemControlForegroundBaseLowBrush}"/>
                <Button x:Name="FilePathButton" 
                        Foreground="{DynamicResource SystemControlForegroundBaseMediumBrush}" 
                        FontStyle="Italic"
                        Background="Transparent"
						BorderThickness="0"
						Padding="0"
                        HorizontalAlignment="Left"
						Cursor="Hand"/>
            </StackPanel>
        </Grid>
    </Border>
</UserControl>

Expected behavior

No response

Avalonia version

11.2.1

OS

Windows

Additional context

No response

@nipeone nipeone added the bug label Nov 22, 2024
@timunie
Copy link
Contributor

timunie commented Nov 22, 2024

@nipeone please provide a full minimum sample to reproduce. Also I wonder how you set the data, are you doing it in code behind? Is the image loading async?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants