WebView-based subtitle styling doesn't render EDGE_TYPE_OUTLINE correctly
- Dominant language
- Java
- Stars
- 21.9k
- Forks
- 6k
- PR merge metrics
- No merged PRs in 30d
Description
Copying from https://github.com/google/ExoPlayer/issues/2194#issuecomment-1084271458:
> If I use the webview by `subView.setViewType(SubtitleView.VIEW_TYPE_WEB)` , the Arabic comma appears at the correct place. But in this mode, the subtitle's style is unruly. **For example, `CaptionStyleCompat.EDGE_TYPE_OUTLINE` the outline is oddly**,
I can reproduce this in 2.17.1 (screenshots below), using the "TTML positioning" sample and the following patch to the demo app in `PlayerActivity#onCreate`:
```java
playerView.getSubtitleView().setViewType(SubtitleView.VIEW_TYPE_WEB);
playerView.getSubtitleView().setStyle(new CaptionStyleCompat(
/* foregroundColor= */ Color.RED,
/* backgroundColor= */ Color.GREEN,
/* windowColor= */ Color.CYAN,
CaptionStyleCompat.EDGE_TYPE_OUTLINE,
/* edgeColor= */ Color.BLACK,
/* typeface= */ null
));
```
Outline screenshots
**Canvas**

-----
**WebView**

Contributor guide
Assessment
This issue has not been assessed yet.