An open API service indexing awesome lists of open source software.

https://github.com/dsdatsme/learninggithubpages

adding android tips to my github page
https://github.com/dsdatsme/learninggithubpages

Last synced: 2 months ago
JSON representation

adding android tips to my github page

Awesome Lists containing this project

README

        

# LearningGitHubPages
#### adding android tips to my github page

for page visit: https://dsdatsme.github.io/LearningGitHubPages

### Tip 1:
use hint attribute for textviews to lable what they are for .
> tools:hint="Set Number"

### Tip 2:
Use Reformat code for better presentation of your code (XML or Java)
> Ctrl + Alt + L
or
Code -> Reformat Code

### Tip 3:
Use Rearrange code as much as you can, this organizes the code as per the convention used for android.
> Code -> Rearrange Code

### Tip 4:
use Structure Tab of xml to know the proper nesting of you xml code (this can be used for Java too)
> Alt + 7

### Tip 5:
`layout_gravity` & `graity` are the two most useful tools for creating layouts for differrent screen sizes.
One should make proper use ofthem and should know what attribute to use when for efficient coding.

### Tip 6:
When developing large projects developers use `TODO` tags extensively.
One should make a habbit of using TODO tags , they an act as a bookmarks too.
Syntax:
> // TODO Your message here!
You can find all your TODOs to the left of Logcat tabat the bottom of your android studio

### Tip 7:
Make more use of `onCLickListener` method in Java on a widget rather than adding an `onClick` attribute in XML.
This done to ease maintainance of code and there is no harm to performance.

### Tip 8:
Its a good practice to run your app when you make some changes or implement something new.
This acts as a checkpoint for your work and you know that till this point there were no issues in your work.

### Tip 9:
Make use of `` & `` tags while creating a complicated XML layouts.
They will help you to seperate different parts of your XML to different layout files , so it becomes easy to maintain files and easy to point out which file has UI issue