回答編集履歴
2
🎉
answer
CHANGED
|
@@ -16,4 +16,60 @@
|
|
|
16
16
|
|
|
17
17
|
[WebBrowser overlaps other controls in WPF? · Issue #356 · MicrosoftEdge/WebView2Feedback](https://github.com/MicrosoftEdge/WebView2Feedback/issues/356)
|
|
18
18
|
|
|
19
|
-
#286を見ると、もしかしたら何か動きがあるのかも??
|
|
19
|
+
#286を見ると、もしかしたら何か動きがあるのかも??
|
|
20
|
+
|
|
21
|
+
---
|
|
22
|
+
|
|
23
|
+
ついに`WebView2CompositionControl`が来ました^^
|
|
24
|
+
[WebView2CompositionControl Class (Microsoft.Web.WebView2.Wpf) | Microsoft Learn](https://learn.microsoft.com/ja-jp/dotnet/api/microsoft.web.webview2.wpf.webview2compositioncontrol)
|
|
25
|
+
|
|
26
|
+
```xml
|
|
27
|
+
<Window
|
|
28
|
+
x:Class="Q344069.MainWindow"
|
|
29
|
+
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
|
30
|
+
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
|
31
|
+
xmlns:wv2="clr-namespace:Microsoft.Web.WebView2.Wpf;assembly=Microsoft.Web.WebView2.Wpf"
|
|
32
|
+
Width="800"
|
|
33
|
+
Height="450">
|
|
34
|
+
<Grid>
|
|
35
|
+
<Grid.ColumnDefinitions>
|
|
36
|
+
<ColumnDefinition />
|
|
37
|
+
<ColumnDefinition />
|
|
38
|
+
</Grid.ColumnDefinitions>
|
|
39
|
+
<GroupBox Header="WebView2">
|
|
40
|
+
<wv2:WebView2 Source="https://teratail.com/questions/344069" />
|
|
41
|
+
</GroupBox>
|
|
42
|
+
|
|
43
|
+
<GroupBox Grid.Column="1" Header="WebView2CompositionControl">
|
|
44
|
+
<wv2:WebView2CompositionControl Source="https://teratail.com/questions/344069" />
|
|
45
|
+
</GroupBox>
|
|
46
|
+
|
|
47
|
+
<Border
|
|
48
|
+
Grid.ColumnSpan="2"
|
|
49
|
+
HorizontalAlignment="Center"
|
|
50
|
+
VerticalAlignment="Center"
|
|
51
|
+
BorderBrush="Red"
|
|
52
|
+
BorderThickness="4">
|
|
53
|
+
<Image Source="https://teratail-v2.storage.googleapis.com/uploads/avatars/u13/132786/KnkDDC5A_thumbnail.jpg" Stretch="None" />
|
|
54
|
+
</Border>
|
|
55
|
+
</Grid>
|
|
56
|
+
</Window>
|
|
57
|
+
```
|
|
58
|
+
```xml
|
|
59
|
+
<Project Sdk="Microsoft.NET.Sdk">
|
|
60
|
+
|
|
61
|
+
<PropertyGroup>
|
|
62
|
+
<OutputType>WinExe</OutputType>
|
|
63
|
+
<TargetFramework>net9.0-windows10.0.19041.0</TargetFramework>
|
|
64
|
+
<Nullable>enable</Nullable>
|
|
65
|
+
<ImplicitUsings>enable</ImplicitUsings>
|
|
66
|
+
<UseWPF>true</UseWPF>
|
|
67
|
+
</PropertyGroup>
|
|
68
|
+
|
|
69
|
+
<ItemGroup>
|
|
70
|
+
<PackageReference Include="Microsoft.Web.WebView2" Version="1.0.2895-prerelease" />
|
|
71
|
+
</ItemGroup>
|
|
72
|
+
|
|
73
|
+
</Project>
|
|
74
|
+
```
|
|
75
|
+

|
1
見直しキャンペーン中
answer
CHANGED
|
@@ -1,19 +1,19 @@
|
|
|
1
|
-
`WebBrowser`・`WebView`・`WebVew2`すべてそうだと思いますが、別のハンドルを持ったウィンドウ(`IE`や`Egde`の描画部分のようなもの)が重なっているからです。
|
|
1
|
+
`WebBrowser`・`WebView`・`WebVew2`すべてそうだと思いますが、別のハンドルを持ったウィンドウ(`IE`や`Egde`の描画部分のようなもの)が重なっているからです。
|
|
2
|
-
|
|
2
|
+
|
|
3
|
-
空域問題(Airspace problem)といって、上にコントロールを重ねたり透過にしたりができません。
|
|
3
|
+
空域問題(Airspace problem)といって、上にコントロールを重ねたり透過にしたりができません。
|
|
4
|
-
[WPF 相互運用 : "空域" およびウィンドウ領域の概要 | Microsoft Docs](https://docs.microsoft.com/ja-jp/previous-versions/dotnet/netframework-3.5/aa970688(v=vs.90))
|
|
4
|
+
[WPF 相互運用 : "空域" およびウィンドウ領域の概要 | Microsoft Docs](https://docs.microsoft.com/ja-jp/previous-versions/dotnet/netframework-3.5/aa970688(v=vs.90))
|
|
5
|
-
|
|
5
|
+
|
|
6
|
-
ではどうするかですが、`Popup
|
|
6
|
+
ではどうするかですが、`Popup`や別の`Window`をさらに上に重ねるのをよく見ますね(もちろんウィンドウが動いたら一緒に動かす必要があります)
|
|
7
|
-
|
|
7
|
+
|
|
8
|
-
「wpf webview
|
|
8
|
+
「[wpf webview airspace](https://www.google.co.jp/search?q=wpf+webview+airspace)」あたりで検索してみてください。
|
|
9
|
-
|
|
9
|
+
|
|
10
|
-
---
|
|
10
|
+
---
|
|
11
|
-
|
|
11
|
+
|
|
12
|
-
`WebView2`でも要望は上がっています。
|
|
12
|
+
`WebView2`でも要望は上がっています。
|
|
13
|
-
技術的には可能でも需要が少ないと優先度が上がりませんので、投票等しておくといいかもしれません。
|
|
13
|
+
技術的には可能でも需要が少ないと優先度が上がりませんので、投票等しておくといいかもしれません。
|
|
14
|
-
|
|
14
|
+
|
|
15
|
-
[When using Webview2 in WPF, unable to overlay WPF controls on the Webview · Issue #286 · MicrosoftEdge/WebView2Feedback](https://github.com/MicrosoftEdge/WebView2Feedback/issues/286)
|
|
15
|
+
[When using Webview2 in WPF, unable to overlay WPF controls on the Webview · Issue #286 · MicrosoftEdge/WebView2Feedback](https://github.com/MicrosoftEdge/WebView2Feedback/issues/286)
|
|
16
|
-
|
|
16
|
+
|
|
17
|
-
[WebBrowser overlaps other controls in WPF? · Issue #356 · MicrosoftEdge/WebView2Feedback](https://github.com/MicrosoftEdge/WebView2Feedback/issues/356)
|
|
17
|
+
[WebBrowser overlaps other controls in WPF? · Issue #356 · MicrosoftEdge/WebView2Feedback](https://github.com/MicrosoftEdge/WebView2Feedback/issues/356)
|
|
18
|
-
|
|
18
|
+
|
|
19
19
|
#286を見ると、もしかしたら何か動きがあるのかも??
|