Skip to Content
Android Developer Tools深入精要
book

Android Developer Tools深入精要

by Mike Wolfson
July 2014
Intermediate to advanced
248 pages
5h 19m
Chinese
GoTop Information, Inc.
Content preview from Android Developer Tools深入精要
XML
格式化工具
|
63
[Page-67]
XML
格式化工具
你已知道
Android
layout
檔案是使用
XML
階層式標籤結構描述介面裡的各種畫面,
這些檔案可能很快變得雜亂、複雜而難以閱讀。
ADT
提供好用的按鍵組合讓你可以快
速地將
XML
檔案格式化。這工具不只將空格對齊,也會將標籤裡的屬性(
attributes
重新排序。
Windows
Linux
上可以使用
Ctrl+Shift+F
,在
Mac OS X
上可以使用
Command+
Shift+F
預設情況下,這會將屬性重新排列至一個
Android
團隊認為對多數開發者是最好的規
範。這順序規範能用在多數開發者上,而若有需要你也可以指定特定的順序。你可以
在以下位置指定參數設定:
Window
Preferences
XML
XML Files
Editor
你可以在第
174
頁「
XML
格式化」中學到更多。
Android
這按鍵組合值得一提,因為它可以快速訪問幾個常用的操作。使用這個快速鍵可以更
快地完成這些工作且加速開發。你可以使用以下按鍵來訪問這些快速捷徑:在
Windows
Linux
上使用
Alt+Shift+A
,在
Mac OS X
上使用
Option+Shift+A
當你使用這個按鍵組合,
IDE
右下角會開啟一個小的對話框(如圖
5-10
),包含三個
快速捷徑可以做以下的事情:
5-10
使用
Android
鍵訪問快速捷徑
[Page-68]
Run Android Application
(執行
Android ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.

Read now

Unlock full access

More than 5,000 organizations count on O’Reilly

AirBnbBlueOriginElectronic ArtsHomeDepotNasdaqRakutenTata Consultancy Services

QuotationMarkO’Reilly covers everything we've got, with content to help us build a world-class technology community, upgrade the capabilities and competencies of our teams, and improve overall team performance as well as their engagement.
Julian F.
Head of Cybersecurity
QuotationMarkI wanted to learn C and C++, but it didn't click for me until I picked up an O'Reilly book. When I went on the O’Reilly platform, I was astonished to find all the books there, plus live events and sandboxes so you could play around with the technology.
Addison B.
Field Engineer
QuotationMarkI’ve been on the O’Reilly platform for more than eight years. I use a couple of learning platforms, but I'm on O'Reilly more than anybody else. When you're there, you start learning. I'm never disappointed.
Amir M.
Data Platform Tech Lead
QuotationMarkI'm always learning. So when I got on to O'Reilly, I was like a kid in a candy store. There are playlists. There are answers. There's on-demand training. It's worth its weight in gold, in terms of what it allows me to do.
Mark W.
Embedded Software Engineer

You might also like

Android 高效能多執行緒

Android 高效能多執行緒

Anders Goransson
深入淺出 jQuery

深入淺出 jQuery

Ryan Benedetti, Ronan Cranley
HTML5 錦囊妙計

HTML5 錦囊妙計

Christopher Schmitt, Kyle Simpson

Publisher Resources

ISBN: 9789863470861