[英]Strange screen on Nexus 4
I have this strange glitch on my Nexus4 screen when testing a very simple layout: just a linear layout with a TextView inside. 在测试非常简单的布局时,我在Nexus4屏幕上出现了一个奇怪的毛刺:只是一个内部带有TextView的线性布局。 Does anyone have an idea why and how to fix this bug ?
有谁知道为什么以及如何解决此错误?
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:orientation="vertical"
android:layout_width="match_parent"
android:layout_height="match_parent">
<TextView
android:layout_width="match_parent"
android:layout_height="match_parent"
android:textColor="@color/highlighted_text_material_light"
android:id="@+id/measurement_tv"
/>
</LinearLayout>
This happens systematically when I use a simple layout but there is no problem for a more complicated layout 当我使用简单的布局时,这会系统地发生,但是对于更复杂的布局则没有问题
This may be a possible cause, but it is not programming related: 这可能是可能的原因,但与编程无关:
Is it possible that You have enabled HW Overlay. 您是否启用了硬件覆盖。 Sometimes it conflicts with rendering the layout.
有时它与渲染布局冲突。 To disable or enable, go to:
要禁用或启用,请转到:
settings-->developer options-->deactivate HW-Overlays
设置->开发人员选项->停用硬件覆盖
Had a similar problem, my screen looked like Yours and this was the cause. 遇到类似的问题,我的屏幕看起来像是您的,这就是原因。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.