Button styles: MaterialDesignRaisedButton used with MahApps.Metro causes serious memory leak
メンテナーはふだん 1 日以内に返信
まだ誰も着手していません。
評価
調査の方向性
リポジトリのファイルもテストも指定されていません。まず、MahApps.MetroWindow、MaterialDesignRaisedButton、ButtonProgressAssist を使用した、提供されている WPF XAML の再現手順から始め、その後、バージョン 4.7.1 で実行し、メモリの挙動を確認するためにウィンドウを最小化してから復元します。リークの原因が説明され、報告されたシナリオが再現しなくなれば完了です。
索引モデルが issue の本文から書いたものです。
説明
Bug explanation
I found a problem, maybe a compatibility issue or a design bug, but I think it can be fixed. My WPF program uses MahApps, (<mah:MetroWindow...), in which I use a button control of MaterialDesignInXamlToolkit, the style of this button control is: MaterialDesignRaisedButton. When I run the program, everything seems to be fine, but immediately after I minimize the form, the memory increases at a rate of 1MB/s, and it won't stop, unless I restore this form that was just minimized, after restoring the memory immediately drop and return to normal levels. I know my question is about coming from two different places, (MahApps and MaterialDesignInXamlToolkit), but if I don't use MahApps(mah:MetroWindow), then, the above problem doesn't exist, everything works fine, also I tried several other Different styles of a similar button, only this style is found so far: MaterialDesignRaisedButton has this problem, the condition that triggers this problem is when the form is minimized.
**xaml code:
<mah:MetroWindow x:Class="WpfApp1.MainWindow"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:mah="clr-namespace:MahApps.Metro.Controls;assembly=MahApps.Metro"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:materialDesign="http://materialdesigninxaml.net/winfx/xaml/themes"
xmlns:local="clr-namespace:WpfApp1"
mc:Ignorable="d" WindowStartupLocation="CenterScreen"
Title="MainWindow" Height="450" Width="800">
<Grid>
<StackPanel>
<Grid
Width="124">
<Button
Margin="2,0"
materialDesign:ButtonProgressAssist.IsIndeterminate="True"
materialDesign:ButtonProgressAssist.IsIndicatorVisible="True"
materialDesign:ButtonProgressAssist.Value="-1"
Content="Indeterminate"
IsEnabled="{Binding DataContext.ControlsEnabled, RelativeSource={RelativeSource FindAncestor, AncestorType=Window}}"
Style="{StaticResource MaterialDesignRaisedButton}" />
</Grid>
</StackPanel>
</Grid>
</mah:MetroWindow>
I have captured two pictures. Figure 1 shows that after running the WPF program and minimizing it, the change of memory transmission at this time can be seen to be increasing

Figure 2 shows the memory changes after I restored the WPF program window that I just minimized. You can see that the memory has dropped rapidly and gradually returned to normal

Version
4.7.1
- 主要言語
- C#
- スター
- 16.3k
- フォーク
- 3.5k
- 平均マージ
- 4時間 25分
- マージ済み PR(30日)
- 4
環境構築
- Dockerfile・Docker Compose ファイルなし
- プルリクエストのテンプレートなし
- コントリビューションガイドを読む
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
MaterialDesignInXAML/MaterialDesignInXamlToolkit のほかの issue
-
難易度 1/5 1時間未満 初心者へのやさしさ 88/100
MaterialDesignInXAML/MaterialDesignInXamlToolkit#4124 ·
メンテナーはふだん 1 日以内に返信
-
MaterialDesignChoiceChipListBoxItem missing 'Path=Name' in GroupName binding causes selection conflict between ListBoxes対応中かも @corvinsz が 12 日前に担当しました。 オープンbug evaluation required
難易度 1/5 1〜3時間 初心者へのやさしさ 78/100
MaterialDesignInXAML/MaterialDesignInXamlToolkit#4118 · コメント 1 件 ·
メンテナーはふだん 1 日以内に返信
-
enhancement up-for-grabs
難易度 2/5 1〜3時間 初心者へのやさしさ 68/100
MaterialDesignInXAML/MaterialDesignInXamlToolkit#2485 ·
メンテナーはふだん 1 日以内に返信
-
enhancement evaluation required
難易度 3/5 半日 初心者へのやさしさ 30/100
MaterialDesignInXAML/MaterialDesignInXamlToolkit#4120 · コメント 1 件 ·
メンテナーはふだん 1 日以内に返信
-
Add Semantic, Theme-Aware Colors対応中かも @corvinsz が 22 日前に担当しました。 オープンenhancement
難易度 4/5 3〜5日 初心者へのやさしさ 48/100
MaterialDesignInXAML/MaterialDesignInXamlToolkit#4114 · リアクション 1 件 ·
メンテナーはふだん 1 日以内に返信
MaterialDesignInXAML/MaterialDesignInXamlToolkit の issue をすべて見る
似ている issue
-
enhancement
難易度 2/5 1〜3時間 初心者へのやさしさ 68/100
-
a-corriger documentation
難易度 2/5 1〜3時間 初心者へのやさしさ 82/100
christian-raj/S-Aloha#312 ·
-
ready-for-agent tech-debt
難易度 1/5 1〜3時間 初心者へのやさしさ 85/100
DigiBanks99/menlo#640 ·
メンテナーはふだん 1 日以内に返信
-
ci
難易度 1/5 1時間未満 初心者へのやさしさ 62/100
OpenTabletDriver/OpenTabletDriver#5283 ·
メンテナーはふだん 3 日以内に返信
-
area / templates
難易度 2/5 1〜3時間 初心者へのやさしさ 66/100
bitfoundation/bitplatform#15109 ·
メンテナーはふだん 1 日以内に返信