访问 Android Studio 属性窗口?

声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow 原文地址: http://stackoverflow.com/questions/22440430/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me): StackOverFlow

提示:将鼠标放在中文语句上可以显示对应的英文。显示中英文
时间:2020-08-20 05:57:33  来源:igfitidea点击:

Accessing Android Studio properties window?

androidideandroid-studio

提问by user1352057

I have recently started using Android Studio and cannot work out how to access the properties window.

我最近开始使用 Android Studio,但不知道如何访问属性窗口。

The following screenshot was taken from Google and shows exactlywhat I'm trying to access denoted by the red rectangle around the properties window.

以下屏幕截图取自 Google,准确显示了我试图访问的内容,由属性窗口周围的红色矩形表示。

enter image description here

在此处输入图片说明

Can anyone please tell me how I can access this?

谁能告诉我如何访问它?

回答by 13knives

enter image description hereSwitch to design view. Click "Design" tab at bottom-left work area.

在此处输入图片说明切换到设计视图。单击左下角工作区的“设计”选项卡。

回答by Pablo Rioseco

In the new Android Studio Version 3.1.2, the name of the Propierties Windows is "Attributes".

在新的 Android Studio 版本 3.1.2 中,属性窗口的名称是“属性”。

Look at this picture: Attributes basic viewAnd, if you want to see the complete attributes, simply click on "View all attributes": Attributes full view

看这张图片: 属性基本视图而且,如果您想查看完整的属性,只需单击“查看所有属性”: 属性完整视图

How to restore windows?: restore windows

如何恢复 Windows?: 恢复 Windows

回答by Quint Jer

I had the same issue than found that the properties window was always there but I had to drag it out with my mouse. Just go to the far right vertical bar in Design mode then drag to the right when your mouse turns into horizontal arrows pointing away from each other. Hope this helps!

我遇到了与发现属性窗口始终存在相同的问题,但我不得不用鼠标将其拖出。只需在设计模式中转到最右侧的垂直条,然后在鼠标变成彼此远离的水平箭头时向右拖动即可。希望这可以帮助!

回答by Sahil Gami

Design Tab

设计选项卡

You can just click on the design tab on your screen (at the left bottom corner below your code text window) and just click on anything whose property you want to change

您只需单击屏幕上的设计选项卡(在代码文本窗口下方的左下角),然后单击您想要更改其属性的任何内容

make sure you are in the '.xml' file

确保您在“.xml”文件中

回答by Ola Skowrońska

I accidentally deleted the properties side bar and Window-->restore deafult layout helped.

我不小心删除了属性侧栏和 Window-->restore deafult layout 帮助。

回答by kmonsoor

Follow the doc.

按照文档

Instead of editing your view properties in XML, you can do so from the Properties window (on the right side of the Layout Editor). This window is available only when the design editor is open, so be sure you've selected the Design tab at the bottom of the window.

When you select a view, the Properties window shows the following, as indicated in figure 5:

View inspector with controls for width/height style, margins, and bias (available only for views in a ConstraintLayout). For more information, see Build a Responsive UI with ConstraintLayout.

您可以从“属性”窗口(在布局编辑器的右侧)中,而不是在 XML 中编辑您的视图属性。此窗口仅在设计编辑器打开时可用,因此请确保您已选择窗口底部的“设计”选项卡。

当您选择一个视图时,Properties 窗口将显示以下内容,如图 5 所示:

带有宽度/高度样式、边距和偏差控件的视图检查器(仅适用于 ConstraintLayout 中的视图)。有关更多信息,请参阅使用 ConstraintLayout 构建响应式 UI。