Android的布局编辑器怪胎的问号 [英] Android Layout Editor Freaks Out on Question Mark

查看:216
本文介绍了Android的布局编辑器怪胎的问号的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

这是奇怪的,但我看到这一切的时候,我有很多理由在此应用程序中显示只是一个简单的问号。

This is strange, yet I see it all the time as I have lots of reasons to display just a simple question mark in this app.

在与Eclipse图形布局编辑器中编辑,一切都很好...直到我告诉TextEdit或一个按钮只显示一个问号。这里是我的code:

When editing with the Eclipse graphical layout editor, everything is fine...until I tell a TextEdit or a Button to display just a question mark. Here's my code:

<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
    android:layout_width="fill_parent"
    android:layout_height="fill_parent"
    android:orientation="vertical"
    >
    <TextView
        android:id="@+id/test_title"
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:text="@string/question_mark" />
</LinearLayout>

和该字符串在res /价值/ strings.xml中定义。相关行是:

And the string is defined in res/values/strings.xml. The relevant line is:

<string name="question_mark">\u003f</string>

该错误消息我得到的是:

The error message I get is:

缺少样式。是正确的主题选择了此布局?使用
  布局上述的主题组合框中选择不同的布局,或修复
  主题风格的引用。

Missing styles. Is the correct theme chosen for this layout? Use the Theme combo box above the layout to choose a different layout, or fix the theme style references.

找不到主题资源为当前主题

Couldn't find theme resource for the current theme

更改文本和错误消息消失。

Change the text, and the error message goes away.

您可以看到,在我的挣扎,我甚至试图用一个问号的UNI code版本。是的, \\?也不行。

You can see that in my struggles, I'm even trying to use the unicode version of a question mark. And yes, \? doesn't work either.

注意,当图形布局编辑器被设置为API 7或更大。这只是发生

Note that this only happens when the graphical layout editor is set to API 7 or greater.

现在的图形化布局编辑器正确显示了问号,仿真器和我的手机显示的问号没有任何问题。我只是在错误信息占用了我的屏幕的1/4为我所有的布局(和模糊,可能会突然出现其他错误消息)恼火。

Now the graphical layout editor displays the question mark properly, and the emulator and my phone display the question mark without any problems. I'm just annoyed with the error message taking up 1/4 of my screen for all my layouts (and obscuring other error messages that may crop up).

有什么建议?

推荐答案

哇,我进入了一个bug报告... [按时游行] ...终于,我收到了几封电子邮件作为谷歌团队开始看吧。

Wow, I entered a bug report...[time marches on]...finally, I get a few emails as the Google team starts to look at it.

今天,我收到了一些好消息。它看起来像错误已得到修复(他们找到了一些相关的错误,已固定为好)。该修补程序将在下一版本,版本21.1 preVIEW 2.你可以阅读官方的细节的这里

Today, I received some good news. It looks like the bug has been fixed (and they found a few related bugs, which have been fixed as well). The fix will be in the next release, Version 21.1 Preview 2. You can read the official details here.

期待呢!

这篇关于Android的布局编辑器怪胎的问号的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆