Slide 1

Slide 1 text

Grokking Android Studio Tips and Tricks to Make You Look Really Cool Phil Shadlyn @physphil

Slide 2

Slide 2 text

Agenda 1. Basic Navigation 2. Helpful Key Mappings and Code Completion 3. Live Templates 4. Structural Search and Replace

Slide 3

Slide 3 text

Android Studio ● Announced at Google I/O 2013 ● Based off IntelliJ IDEA ● Free to download from Google

Slide 4

Slide 4 text

Navigation ● Hands off your mouse! ● Most navigation can be done with key mappings

Slide 5

Slide 5 text

Demo Time!

Slide 6

Slide 6 text

Navigation Shortcuts double shift Search Everywhere cmd + e Recently Opened Files cmd + alt + L / R Last/Previous Cursor Location cmd + shift + delete Last Edit Location cmd + shift + [ / ] Cycle Between Tabs cmd + w Close Tab shift + escape Collapse Current Window cmd + b Go to Declaration cmd + shift + b Go to Type Declaration cmd + alt + b Go to Implementation

Slide 7

Slide 7 text

Key Mappings and Code Completion ● Help with basic text editing ● IDE functionality ● When in doubt, just start typing...

Slide 8

Slide 8 text

Demo Number 2...

Slide 9

Slide 9 text

Key Mappings cmd + shift + a Find Any Action cmd + d Duplicate Line cmd + delete Delete Line option + up / down Expand / Shrink Selection cmd + option + l Reformat Code option + return Show Quick Fixes cmd + n Generate Code control + o Override Methods control + i Implement Methods cmd + k Commit to VCS

Slide 10

Slide 10 text

Live Templates ● Quickly generate common code snippets ● List with cmd + j ● Create your own ○ Highlight code → “Save as Live Template”

Slide 11

Slide 11 text

Live Templates Demo

Slide 12

Slide 12 text

No content

Slide 13

Slide 13 text

● “...performs search and replace in the supported languages code across the whole project, taking advantage of the IntelliJ IDEA's awareness of the syntax and code structure of the supported languages.” ● … Huh? Structural Search and Replace

Slide 14

Slide 14 text

No content

Slide 15

Slide 15 text

Want More Info? ● IntelliJ Reference Card ● Android Studio Tips of the Day ● No Tabs in IntelliJ IDEA ● IntelliJ IDEA Tips and Tricks ● Key Promoter Plugin ● Structural Search and Replace ● Android Studio Like A Boss

Slide 16

Slide 16 text

Questions? Phil Shadlyn @physphil